Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[AAPointerInfo] refactor how offsets and Access objects are tracked
AAPointerInfo now maintains a list of all Access objects that it owns, along with the following maps: - OffsetBins: OffsetAndSize -> { Access } - InstTupleMap: RemoteI x LocalI -> Access A RemoteI is any instruction that accesses memory. RemoteI is different from LocalI if and only if LocalI is a call; then RemoteI is some instruction in the callgraph starting from LocalI. Motivation: When AAPointerInfo recomputes the offset for an instruction, it sets the value to Unknown if the new offset is not the same as the old offset. The instruction must now be moved from its current bin to the bin corresponding to the new offset. This happens for example, when: - A PHINode has operands that result in different offsets. - The same remote inst is reachable from the same local inst via different paths in the callgraph: ``` A (local inst) | B / \ C1 C2 \ / D (remote inst) ``` This fixes a bug where a store is incorrectly eliminated in a lit test. Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D136526
- Loading branch information
Showing
5 changed files
with
320 additions
and
145 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
Oops, something went wrong.