Abstract: When compiling a program using an object oriented language and virtual functions addressed by virtual function tables, the program may include virtual functions that are defined but not used. The compiler identifies such functions by tagging each defined virtual function with a code identifying it as a member of related virtual functions. The compiler also tags each virtual function call to identify which group (or groups) of related virtual functions are candidates for invocation by the virtual function call at runtime. The linker combines the two codes to identify which defined virtual functions are not candidates for invocation by any virtual function call. The linker omits those non-candidate virtual functions from the link if all references to them were from virtual function tables.
Type:
Grant
Filed:
December 10, 1996
Date of Patent:
January 30, 2001
Assignee:
International Business Machines Corporation