1 # RUN: llc -mtriple aarch64-- -run-pass irtranslator -simplify-mir %s -o %t \
2 # RUN: -verify-machineinstrs; llc -mtriple aarch64-- -run-pass legalizer \
3 # RUN: -simplify-mir %t -x mir -o - -verify-machineinstrs | FileCheck %s
5 # Test that MIRParser is able to deserialize back MIR MIRPrinter serialized,
6 # specifically overloaded intrinsic names in this case which aren't required
7 # to encode all the concrete arg types in the name at MIR level.
10 define i32 @int_aarch64_sdiv(i32 %a, i32 %b) nounwind readnone ssp {
11 ; CHECK-LABEL: name: int_aarch64_sdiv
12 ; CHECK: liveins: $w0, $w1
13 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $w0
14 ; CHECK: [[COPY1:%[0-9]+]]:_(s32) = COPY $w1
15 ; CHECK: [[INT:%[0-9]+]]:_(s32) = G_INTRINSIC intrinsic(@llvm.aarch64.sdiv), [[COPY]](s32), [[COPY1]](s32)
16 ; CHECK: $w0 = COPY [[INT]](s32)
17 ; CHECK: RET_ReallyLR implicit $w0
19 %sdiv = call i32 @llvm.aarch64.sdiv.i32(i32 %a, i32 %b)
23 declare i32 @llvm.aarch64.sdiv.i32(i32, i32) nounwind readnone