[PATCH] D132994: [RISC-V][HWASAN] Don't explicitly load GOT entry to call hwasan mismatch routine
Luís Marques via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 4 10:46:04 PST 2023
luismarques accepted this revision.
luismarques added a comment.
This revision is now accepted and ready to land.
LGTM.
================
Comment at: llvm/lib/Target/RISCV/RISCVAsmPrinter.cpp:275-276
OutContext.getOrCreateSymbol("__hwasan_tag_mismatch_v2");
+ // Annotate symbol as one having incompatible calling convention, so
+ // run-time linkers can instead eagerly bind this function
+ RISCVTargetStreamer &RTS =
----------------
Nit: missing period.
================
Comment at: llvm/lib/Target/RISCV/RISCVAsmPrinter.cpp:277-278
+ // run-time linkers can instead eagerly bind this function
+ RISCVTargetStreamer &RTS =
+ static_cast<RISCVTargetStreamer &>(*OutStreamer->getTargetStreamer());
+ RTS.emitDirectiveVariantCC(*HwasanTagMismatchV2Sym);
----------------
Nit. You can use `auto` for the variable since the type is obvious from the cast.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D132994/new/
https://reviews.llvm.org/D132994
More information about the llvm-commits
mailing list