summaryrefslogtreecommitdiffstats
path: root/llvm/test/Verifier/test_g_add.mir
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test/Verifier/test_g_add.mir')
-rw-r--r--llvm/test/Verifier/test_g_add.mir11
1 files changed, 10 insertions, 1 deletions
diff --git a/llvm/test/Verifier/test_g_add.mir b/llvm/test/Verifier/test_g_add.mir
index 54c470adc8a..9cd990bb8cc 100644
--- a/llvm/test/Verifier/test_g_add.mir
+++ b/llvm/test/Verifier/test_g_add.mir
@@ -1,4 +1,4 @@
-#RUN: not llc -o - -global-isel -run-pass=none -verify-machineinstrs %s 2>&1 | FileCheck %s
+#RUN: not llc -march=aarch64 -o - -global-isel -run-pass=none -verify-machineinstrs %s 2>&1 | FileCheck %s
# REQUIRES: global-isel, aarch64-registered-target
---
@@ -25,4 +25,13 @@ body: |
; CHECK: Bad machine code: Explicit definition marked as use
G_ADD %0, %1
+ ; CHECK: Bad machine code: generic instruction must use register operands
+ %5:_(s32) = G_ADD %0, 1
+
+ %6:_(s64) = G_CONSTANT i64 0
+
+ ; CHECK: Bad machine code: Type mismatch in generic instruction
+ ; CHECK: Bad machine code: Generic virtual register does not allow subregister index
+ %8:_(s32) = G_ADD %6.sub_32:_(s64), %0
+
...
OpenPOWER on IntegriCloud