Method, apparatus, and computer program for specializing serializer
AssigneeInternational Business Machines Corporation
InventorAkihiko Tozawa
Life of this patent
Estimating the term…
Abstract
To provide a method, apparatus, and computer program for performing type inference of serialization for each generation site and specializing a serializer for each generation site. A type of serialization is inferred for each generation site of compiling a query, and a serializer is specialized for each generation site based on the inferred type and a type that is actually used. A data value is serialized using the specialized serializer for each generation site. The inference is executed while transcribing identification information assigned to each generation site to a type as an annotation, and the inferred type and the type used in serialization are recursively compared.
Claims12
A method for generating at least one of a serializer and a deserializer for compiling a query, the method comprising:
- inferring, by one or more processors, a type of serialization for each generation site of compiling a query;
- executing, by one or more processors, the inferred type of serialization, while transcribing identification information assigned to each generation site to a type as an annotation;
- specializing, by one or more processors, a serializer for each generation site based on the inferred type of serialization and a type of serialization that is actually used at a generation site;
- recursively, by one or more processors, comparing the inferred type of serialization and the type of serialization that is actually used at a generation site;
- and
- serializing, by one or more processors, a data value using the specialized serializer for each generation site.
A computer program product for generating at least one of a serializer and a deserializer for compiling a query, the computer program product comprising:
- one or more computer readable storage media and program instructions stored on the one or more computer readable storage media, the program instructions comprising:
- program instructions to infer a type of serialization for each generation site of compiling a query;
- program instructions to execute the inferred type of serialization, while transcribing identification information assigned to each generation site to a type as an annotation;
- program instructions to specialize a serializer for each generation site, based on the inferred type of serialization and a type of serialization that is actually used at a generation site;
- program instructions to recursively compare the inferred type of serialization and the type of serialization that is actually used at a generation site;
- and
- program instructions to serialize a data value using the specialized serializer for each generation site.
A computer system for generating at least one of a serializer and a deserializer for compiling a query, the computer system comprising:
- one or more computer processors;
- one or more computer readable storage media;
- and
- program instructions stored on the computer readable storage media for execution by at least one of the one or more processors, the program instructions comprising:
- program instructions to infer a type of serialization for each generation site of compiling a query;
- program instructions to execute the inferred type of serialization, while transcribing identification information assigned to each generation site to a type as an annotation;
- program instructions to specialize a serializer for each generation site, based on the inferred type of serialization and a type of serialization that is actually used at a generation site;
- program instructions to recursively compare the inferred type of serialization and the type of serialization that is actually used at a generation site;
- and
- program instructions to serialize a data value using the specialized serializer for each generation site.
Dependencies are inferred from the claim text.