[PATCH] D144518: Preserve the address space for llvm.used and llvm.compiler.used global variables in GlobalOpt pass.
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 31 12:07:42 PDT 2023
arsenm added inline comments.
================
Comment at: llvm/lib/Transforms/IPO/GlobalOpt.cpp:2122-2123
+
+ if (const auto *VAT = cast<ArrayType>(UsedArrayType))
+ if (const auto *VEPT = cast<PointerType>(VAT->getArrayElementType()))
+ ElemAddrSpace = VEPT->getAddressSpace();
----------------
Don't need the if to check a cast<>
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144518/new/
https://reviews.llvm.org/D144518
More information about the llvm-commits
mailing list