[PATCH] D122236: [RISCV] Fix crash for initial section alignment with .option norvc
Luís Marques via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 22 09:11:49 PDT 2022
luismarques added inline comments.
================
Comment at: llvm/lib/Target/RISCV/MCTargetDesc/RISCVAsmBackend.cpp:610-611
// Insert the fixup only when linker relaxation enabled.
- if (!STI.getFeatureBits()[RISCV::FeatureRelax])
+ const MCSubtargetInfo *STI = AF.getSubtargetInfo();
+ if (!STI->getFeatureBits()[RISCV::FeatureRelax])
return false;
----------------
This one wasn't needed to fix the crash but, presumably, this check should also be fixed?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D122236/new/
https://reviews.llvm.org/D122236
More information about the llvm-commits
mailing list