[PATCH] D80763: [X86] Fix a nullptr defrence in X86Subtarget::classifyLocalReference when compiling with -mcmodel=medium -fpic and using a constant pool
Eric Christopher via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu May 28 15:25:37 PDT 2020
echristo accepted this revision.
echristo added a comment.
This revision is now accepted and ready to land.
Accepting, couple of options as to some other directions as well if you want to go there.
================
Comment at: llvm/lib/Target/X86/X86Subtarget.cpp:91
case CodeModel::Medium:
- if (isa<Function>(GV))
+ if (isa_and_nonnull<Function>(GV))
return X86II::MO_NO_FLAG; // All code is RIP-relative
----------------
Seems reasonable to either comment your commit message here or try to fix the nullptr into classifyLocalReference and assert nonnull?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D80763/new/
https://reviews.llvm.org/D80763
More information about the llvm-commits
mailing list