[llvm] [GlobalOpt] Look through non-PointerType constant expressions. (PR #125205)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 15 04:15:52 PDT 2025


https://github.com/fhahn commented:

> The GEP version is UB due to provenance.
> 
> But yes, we probably want need to restrict more optimizations on comparison operators.

I put up https://github.com/llvm/llvm-project/pull/153789 to try to reject some cases where we may access a different global via a pointer based on a different global.

Is that along the lines you had in mind?

https://github.com/llvm/llvm-project/pull/125205


More information about the llvm-commits mailing list