Verification of computer-executable code generated from a model
First Claim
Patent Images
1. One or more tangible non-transitory computer-readable storage media storing instructions, the instructions comprising:
- one or more instructions that, when executed by one or more processors, cause the one or more processors to;
slice a model into a plurality of slices,each slice, of the plurality of slices, including a different portion of the model;
select a slice from the plurality of slices;
generate a first intermediate representation based on the selected slice;
identify a portion of code, in code generated from the model, that corresponds to the selected slice;
generate a second intermediate representation based on the portion of code;
normalize the first intermediate representation and the second intermediate representation;
compare the normalized first intermediate representation with the normalized second intermediate representation; and
verify, based on the comparing the normalized first intermediate representation and the normalized second intermediate representation, whether the portion of code is equivalent to the selected slice.
1 Assignment
0 Petitions
Accused Products
Abstract
In an embodiment, a model is sliced into a plurality of slices. A slice in the plurality of slices is selected. A portion of code, that corresponds to the selected slice, is identified from code generated from the model. The identified code is verified to be equivalent to the selected slice. Equivalence may include equivalent functionality, equivalent data types, equivalent performance, and or other forms of equivalence between the selected slice and the identified generated code.
32 Citations
29 Claims
-
1. One or more tangible non-transitory computer-readable storage media storing instructions, the instructions comprising:
one or more instructions that, when executed by one or more processors, cause the one or more processors to; slice a model into a plurality of slices, each slice, of the plurality of slices, including a different portion of the model; select a slice from the plurality of slices; generate a first intermediate representation based on the selected slice; identify a portion of code, in code generated from the model, that corresponds to the selected slice; generate a second intermediate representation based on the portion of code; normalize the first intermediate representation and the second intermediate representation; compare the normalized first intermediate representation with the normalized second intermediate representation; and verify, based on the comparing the normalized first intermediate representation and the normalized second intermediate representation, whether the portion of code is equivalent to the selected slice. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19)
-
20. A method comprising:
-
selecting a slice of a model from a plurality of slices of the model, the plurality of slices of the model being identified based on one or more criteria, and the selecting the slice being performed by a device; identifying a portion of code, in code generated for the model, that corresponds to the slice, the identifying the portion of code being performed by the device; generating an intermediate representation (IR) of the slice of the model, the generating the IR of the slice being performed by the device; generating an IR of the portion of code, the generating the IR of the portion of the code being performed by the device; normalizing the IR of the slice and the IR of the portion of the code, the normalizing the IR of the slice and the IR of the portion of code being performed by the device; comparing the normalized IR of the slice with the normalized IR of the portion of code, the comparing the normalized IR of the slice with the normalized IR of the portion of code being performed by the device; and verifying, based on the comparing the normalized IR of the slice and the normalized IR of the portion of code, whether the portion of code is equivalent to the slice, the verifying whether the slice is equivalent to the portion of code being performed by the device. - View Dependent Claims (21, 22, 23, 24, 25)
-
-
26. A device comprising:
one or more processors, implemented at least partially in hardware, to; slice a model into a plurality of slices, each slice, of the plurality of slices, including a different portion of the model; select a slice from the plurality of slices; generate a first intermediate representation based on the selected slice; identify a portion of code, in code generated from the model, that corresponds to the selected slice; generate a second intermediate representation based on the portion of code; normalize the first intermediate representation and the second intermediate representation; compare the normalized first intermediate representation with the normalized second intermediate representation; and verify, based on the comparing the normalized first intermediate representation and the normalized second intermediate representation, whether the portion of code is equivalent to the selected slice. - View Dependent Claims (27, 28, 29)
Specification