[PATCH] D132262: RISCV: adjust relocation emission

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 22 15:47:38 PDT 2022


MaskRay accepted this revision.
MaskRay added inline comments.
This revision is now accepted and ready to land.


================
Comment at: llvm/test/MC/RISCV/riscv64-64b-pcrel.s:1
-# RUN: llvm-mc -triple riscv64-unknown-linux-gnu -filetype obj -o - %s \
+# RUN: not llvm-mc -triple riscv64-unknown-linux-gnu -filetype obj -o - %s 2>%t.log \
 # RUN:   | llvm-readobj -r - | FileCheck %s
----------------
You can guard negative tests with macros so that the positive tests can use `llvm-mc` return code of 0.

llvm-mc supports `--defsym`. I have added some tests using `--defsym ERR=1`.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D132262/new/

https://reviews.llvm.org/D132262



More information about the llvm-commits mailing list