1#RUN: not --crash llc -o - -march=arm64 -run-pass=none -verify-machineinstrs %s 2>&1 | FileCheck %s
2# REQUIRES: aarch64-registered-target
3
4---
5name:            test_gep
6legalized:       true
7regBankSelected: false
8selected:        false
9tracksRegLiveness: true
10liveins:
11body:             |
12  bb.0:
13
14    %0:_(p0) = G_IMPLICIT_DEF
15    %1:_(s64) = G_IMPLICIT_DEF
16
17    ; CHECK:  Bad machine code: Type mismatch in generic instruction
18    %2:_(s64) = G_PTR_ADD %0, %1
19
20    ; CHECK:  Bad machine code: Type mismatch in generic instruction
21    %3:_(p0) = G_PTR_ADD %1, %1
22
23    ; CHECK: Bad machine code: gep offset operand must not be a pointer
24    %4:_(p0) = G_PTR_ADD %0, %0
25
26    ; CHECK: Bad machine code: Type mismatch in generic instruction
27    %5:_(p1) = G_PTR_ADD %0, %1
28
29    ; CHECK: Bad machine code: gep first operand must be a pointer
30    %6:_(s64) = G_PTR_ADD %1, %1
31
32...
33