[llvm-commits] patch: treat selector ref globals as constant in MachineLICM
Peter Cooper
peter_cooper at apple.com
Wed Nov 2 17:11:38 PDT 2011
Hi
Please review this patch to allow the compiler to treat objc selector reference globals as constant when optimizing. These globals aren't actually constant at compile time in that the value they point at may be changed by the linker or runtime, but the value they have is the same for all loads from that address once the program has started.
Ideally this code shouldn't be checking for the name of the global, but the correct change likely involves adding a new linkage type which is much more significant and overkill while there's only one type of variable this applies to.
Thanks,
Pete
-------------- next part --------------
A non-text attachment was scrubbed...
Name: selref.patch
Type: application/octet-stream
Size: 3408 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20111102/49f5c6f3/attachment.obj>
More information about the llvm-commits
mailing list