[llvm] [RISCV] Bugfix for FCLASS incorrect regbankselect (PR #118021)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 29 07:43:28 PST 2024


================
@@ -1,10 +1,10 @@
 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
-# RUN: llc -mtriple=riscv32 -mattr=+d,+zfh -run-pass=regbankselect \
-# RUN:   -disable-gisel-legality-check -simplify-mir -verify-machineinstrs %s \
-# RUN:   -o - | FileCheck %s --check-prefixes=CHECK
-# RUN: llc -mtriple=riscv64 -mattr=+d,+zfh -run-pass=regbankselect \
-# RUN:   -disable-gisel-legality-check -simplify-mir -verify-machineinstrs %s \
-# RUN:   -o - | FileCheck %s --check-prefixes=CHECK
+# RUN: sed 's/XLen/32/g' %s | llc -mtriple=riscv32 -mattr=+d,+zfh -run-pass=regbankselect \
+# RUN:   -disable-gisel-legality-check -simplify-mir -verify-machineinstrs  -x mir \
+# RUN:   -o - | FileCheck %s --check-prefixes=CHECK-RV32
+# RUN: sed 's/XLen/64/g' %s | llc -mtriple=riscv64 -mattr=+d,+zfh -run-pass=regbankselect \
+# RUN:   -disable-gisel-legality-check -simplify-mir -verify-machineinstrs -x mir \
+# RUN:   -o - | FileCheck %s --check-prefixes=CHECK-RV64
----------------
arsenm wrote:

I think this is less maintainable than just duplicating the test. Does update_mir_test_checks even understand how to run the pre-sed command? It doesn't really parse and execute the command 

Also really should have end to end IR tests. Pure mir tests are overused at this point 

https://github.com/llvm/llvm-project/pull/118021


More information about the llvm-commits mailing list