US 12,367,097 B2
Efficient encoding validation
Marco Patrick Schroeder, Munich (DE); Suyeon Maeng, Seoul (KR); Sooyoung Kim, Seoul (KR); and Kyungwook Ko, Seoul (KR)
Assigned to SAP SE, Walldorf (DE)
Filed by SAP SE, Walldorf (DE)
Filed on Sep. 6, 2023, as Appl. No. 18/242,981.
Prior Publication US 2025/0077342 A1, Mar. 6, 2025
Int. Cl. G06F 11/10 (2006.01); G06F 40/126 (2020.01)
CPC G06F 11/10 (2013.01) [G06F 40/126 (2020.01)] 35 Claims
OG exemplary drawing
 
1. A computing system comprising:
at least one memory;
one or more hardware processor units coupled to the at least one memory; and
one or more computer readable storage media storing computer-executable instructions that, when executed, cause the computing system to perform operations comprising:
receiving an input data set comprising a plurality of bytes;
analyzing a first subset of the plurality of bytes, the first subset selected according to a defined length and comprising multiple bytes of the plurality of bytes;
for a first byte of the multiple bytes of the first subset, using information in the first byte to perform a lookup using a first lookup table to provide a first byte result for the first subset;
for a second byte of the multiple bytes of the first subset, using information in the second byte to perform a lookup using a second lookup table to provide a second byte result for the first subset, wherein the second lookup table is the first lookup table or is a lookup table other than the first lookup table;
for a third byte of the multiple bytes of the first subset, using information in the third byte to perform a lookup using a third lookup table to provide a third byte result for the first subset, wherein the third lookup table is the first lookup table, the second lookup table, or is a lookup table other than the first and second lookup tables;
combining the first byte result, the second byte result, and the third byte result for the first subset to provide a first combined result, wherein the first combined result is in a format where at least a portion of a plurality of bits in the format are associated with specific validation errors, bits of the at least a portion of the plurality of bits in the format thus serving as flag bits for a particular validation error; and
determining from the first combined result whether the first subset is validly encoded.
 
19. One or more non-transitory computer-readable storage media comprising: computer-executable instructions that, when executed by a computing system comprising at least one hardware processor and at least one memory coupled to the at least one hardware processor, cause the computing system to receive an input data set comprising a plurality of bytes; computer-executable instructions that, when executed by the computing system, cause the computing system to analyze a first subset of the plurality of bytes, the first subset selected according to a defined length and comprising multiple bytes of the plurality of bytes; computer-executable instructions that, when executed by the computing system, cause the computing system to, for a first byte of the multiple bytes of the first subset, use information in the first byte to perform a lookup using a first lookup table to provide a first byte result for the first subset; computer-executable instructions that, when executed by the computing system, cause the computing system to, for a second byte of the multiple bytes of the first subset, use information in the second byte to perform a lookup using a second lookup table to provide a second byte result for the first subset, wherein the second lookup table is the first lookup table or is a lookup table other than the first lookup table; computer-executable instructions that, when executed by the computing system, cause the computing system to, for a third byte of the multiple bytes of the first subset, use information in the third byte to perform a lookup using a third lookup table to provide a third byte result for the first subset, wherein the third lookup table is the first lookup table, the second lookup table, or is a lookup table other than the first and second lookup tables, wherein respective high nibbles of the first byte, the second byte, and the third byte are used as indices into, respectively, the first lookup table, the second lookup table, and the third lookup table; computer-executable instructions that, when executed by the computing system, cause the computing system to combine the first byte result, the second byte result, and the third byte result for the first subset to provide a first combined result; computer-executable instructions that, when executed by the computing system, cause the computing system to use a low nibble of the first byte as an index to a fourth lookup table to provide a low nibble result; computer-executable instructions that, when executed by the computing system, cause the computing system to, based on the low nibble result, determine whether the first subset corresponds to a leading surrogate or a trailing surrogate of a surrogate pair; and computer-executable instructions that, when executed by the computing system, cause the computing system to determine whether the first subset is validly encoded based on the first combined result and whether the first subset corresponds to a leading surrogate or a trailing surrogate of a surrogate pair.