[llvm] [GlobalISel] Add a update_givaluetracking_test_checks.py script (PR #140296)
David Green via llvm-commits
llvm-commits at lists.llvm.org
Wed May 21 03:25:55 PDT 2025
================
@@ -0,0 +1,28 @@
+# NOTE: Assertions have been autogenerated by utils/update_givaluetracking_test_checks.py UTC_ARGS: --version 5
+# RUN: llc -mtriple aarch64 -passes="print<gisel-value-tracking>" %s -filetype=null 2>&1 | FileCheck %s
+
+---
+name: Cst
+body: |
+ bb.1:
+ %0:_(s8) = G_CONSTANT i8 1
+ %1:_(s8) = COPY %0
+...
+---
+name: CstWithClass
+body: |
+ bb.1:
+ ; Note: This comment should not be removed, the check lines below should be updated
+ ; CHECK-LABEL: name: @CstWithClass
+ ; CHECK-NEXT: %1:_ KnownBits:???????????????????????????????? SignBits:1
+ ; CHECK-NEXT: %named:_ KnownBits:00000000000000000000000000000000???????????????????????????????? SignBits:32
+ ; CHECK-NEXT: %3:_ KnownBits:???????????????????????????????? SignBits:1
+ ; CHECK-NEXT: %4:_ KnownBits:00000000000000000000000000000000 SignBits:32
----------------
davemgreen wrote:
Good point - I hadn't noticed that here but had seen it in another case where it renumbered the digits (there was one missing in that case, which just led me to renumber them). I think they get renumbered during loading the IR - the anonymous numbers get lost and recreated from the register order.
I've just renumbered them in the latest patch. I hope others writing tests would do the same (if the IR they are using is not already numbered correctly). Do you have a suggestion how this could be handled better, or do you think it is Ok as is?
https://github.com/llvm/llvm-project/pull/140296
More information about the llvm-commits
mailing list