-
Notifications
You must be signed in to change notification settings - Fork 246
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
analyze: allow pointee analysis to work interprocedurally (#1172)
This branch modifies the pointee-type analysis to use a single global `VarTable` for all functions, which allows pointee inference variables produced in one function to be resolved in another. This is necessary for lighttpd's `buffer` module, which allocates a `buffer` object in one function (producing an inference variable for the `malloc`) and initializes it in a different function (where the inference variable can now be resolved). The pointee analysis previously involved an "export" operation that ran after processing each function to convert the analysis results to a form that makes sense in other functions. This meant that the results couldn't contain any inference variables or mention any local `PointerId`s. Any entries in the results that violated these constraints would be erased, and the result set would be marked "incomplete". With this branch, both constraints are lifted, as both inference variables and local `PointerId`s are representable in the global scope.
- Loading branch information
Showing
6 changed files
with
55 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters