[PATCH] D104950: [OpaquePtr] Support forward references in textual IR
Arthur Eubanks via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 29 09:41:22 PDT 2021
aeubanks accepted this revision.
aeubanks added a comment.
This revision is now accepted and ready to land.
lgtm, thanks!
================
Comment at: llvm/lib/AsmParser/LLParser.cpp:1463
+ // RAUW it later with a global/function of the correct type.
+ Type *ElemTy = PTy->isOpaque() ? Type::getInt8Ty(M->getContext())
+ : PTy->getElementType();
----------------
aeubanks wrote:
> With --force-opaque-pointers, we never get to `Function::Create()`. Can we always create a GlobalVariable (or always create a Function) and RAUW with the proper GlobalVariable/Function later?
now we could always use a GlobalVariable even without opaque pointers right?
probably doesn't really matter
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D104950/new/
https://reviews.llvm.org/D104950
More information about the llvm-commits
mailing list