[PATCH] D140837: [AAPointerInfo] fix assertion at the pass-through use of a pointer

Sameer Sahasrabuddhe via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 4 03:29:26 PST 2023


sameerds added a comment.

In D140837#4021892 <https://reviews.llvm.org/D140837#4021892>, @arsenm wrote:

> In D140837#4021833 <https://reviews.llvm.org/D140837#4021833>, @sameerds wrote:
>
>> In D140837#4021788 <https://reviews.llvm.org/D140837#4021788>, @arsenm wrote:
>>
>>> Testcase?
>>
>> I am not sure how to go about writing a reliable test for an invalidated reference into a container, especially a map. It would have to depend on possibly adding enough entries to cause a reallocation, or inserting keys in an order that causes earlier keys to be moved around. What would such a test actually check? That the invalidation "never" happens?
>
> What does llvm-reduce give you if you just feed your original testcase to it?

It did produce a pretty small testcase, but it was not convincing. The crash only happens with "opt -O3", at the point where a specific pass OpenMPOptCGSCC runs. All optimizations up to that point have no effect on the test IR, but running only that pass does not produce a crash. It's basically a very fragile situation where all the earlier passes produce an application state that just happens to produce the right invalidation inside the map. That's not very robust.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D140837/new/

https://reviews.llvm.org/D140837



More information about the llvm-commits mailing list