IP Library Granted Patent US 8,707,278
Granted Patent B2
US 8,707,278 · App. 13/251,463 · Granted Apr 22, 2014

Embedding class hierarchy into object models for multiple class inheritance

View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 8,707,278
App. No.
13/251,463
Granted
Apr 22, 2014
Kind
B2
Abstract

A model is provided for transforming a program with a priori given class hierarchy that is induced by inheritance. An inheritance remover is configured to remove inheritance from a given program to produce an analysis-friendly program which does not include virtual-function pointer tables and runtime libraries associated with inheritance-related operations. The analysis-friendly program preserves the semantics of the given program with respect to a given class hierarchy. A clarifier is configured to identify implicit expressions and function calls and transform the given program into at least one intermediate program having explicit expressions and function calls.

Claims (27)

1. A system for transforming a program with a priori given class hierarchy that is induced by inheritance, comprising:

a processor for executing computer program instructions; and

an inheritance remover configured to remove inheritance from a given program stored on a computer readable storage medium to produce an analysis-friendly program which does not include virtual-function pointer tables and runtime libraries associated with inheritance-related operations, the analysis-friendly program preserving the semantics of the given program with respect to a given class hierarchy.

2. The system as recited in claim 1 , further comprising a clarifier configured to identify implicit expressions and function calls in the given program and transform the given program into at least one intermediate program with explicit expressions and function calls.

3. The system as recited in claim 2 , wherein the inheritance remover operates on the at least one intermediate program generated by the clarifier.

4. The system as recited in claim 2 , wherein the clarifier introduces a construct into the at least one intermediate program to preserve semantics of base class constructor invocations.

5. The system as recited in claim 2 , wherein the clarifier introduces a construct into the at least one intermediate program to preserve the semantics of a ternary operator and operations which include creating temporary objects.

6. The system as recited in claim 1 , wherein the inheritance remover comprises an object model builder configured to transform an object with inheritance in the given program to an object without inheritance in the analysis-friendly program.

7. The system as recited in claim 1 , further comprising an object model builder configured to create separate, independent instances of each sub-object associated with an object and utilize additional pointer fields to indicate relationships among the object and sub-objects.

8. The system as recited in claim 7 , wherein the additional pointer fields are appended to an object or sub-object to identify an immediate base class of the object or sub-object.

9. The system as recited in claim 7 , wherein the object model builder is configured to incorporate all fields and members of each sub-object into the object.

10. The system as recited in claim 1 , wherein the inheritance remover is further configured to resolve casts, field accesses and member function calls.

11. A method for transforming a program, comprising:

providing a given program having inheritance, wherein the program is stored on a computer readable storage medium; and

removing inheritance from the given program to produce an analysis-friendly program which does not include virtual-function pointer tables and runtime libraries associated with inheritance-related operations, the analysis-friendly program preserving the semantics of the given program with respect to a given class hierarchy.

12. The method as recited in claim 11 , further comprising identifying implicit expressions and function calls in the given program and transforming the given program into at least one intermediate program with explicit expressions and function calls.

13. The method as recited in claim 11 , wherein a construct is introduced into the at least one intermediate program to preserve semantics of base class constructor invocations.

14. The method as recited in claim 11 , wherein a construct is introduced into the at least one intermediate program to preserve the semantics of a ternary operator and operations which include creating temporary objects.

15. The method as recited in claim 11 , further comprising:

creating separate, independent instances of each sub-object associated with an object; and

utilizing additional pointer fields to indicate relationships among the object and sub-objects.

16. The method as recited in claim 15 , wherein the additional pointer fields are appended to an object or sub-object to identify an immediate base class of the object or sub-object.

17. The method as recited in claim 15 , further comprising incorporating all fields and members of each sub-object into the object.

18. The method as recited in claim 11 , further comprising resolving casts, field accesses and member function calls.

19. A system for transforming a program with a priori given class hierarchy that is induced by inheritance, comprising:

a processor executing an inheritance remover configured to remove inheritance from a given program stored on a computer readable storage medium to produce an analysis-friendly program which does not include virtual-function pointer tables and runtime libraries associated with inheritance-related operations, the analysis-friendly program preserving the semantics of the given program with respect to a given class hierarchy; and

a clarifier configured to identify implicit expressions and function calls in the given program and transform the given program into at least one intermediate program with explicit expressions and function calls.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 13, 2015
From: NEC LABORATORIES AMERICA, INC.
To: NEC CORPORATION
Reel/Frame 034765/0565 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 3, 2011
From: BALAKRISHNAN, GOGUL; MAEDA, NAOTO; IVANCIC, FRANJO; SINHA, NISHANT; GUPTA, AARTI; YANG, JING
To: NEC LABORATORIES AMERICA, INC.
Reel/Frame 027005/0308 →