29 lines · plain
1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py2# RUN: llc -mtriple=i386-- -run-pass=instruction-select -verify-machineinstrs %s -o - | FileCheck %s3 4# Check that we select a the x86.flags.read.u32 intrinsic into a RDFLAGS5# instruction. Also check that we constrain the register class of the COPY to6# gr32.7 8--- |9 define void @read_flags() { ret void }10 ; CHECK-LABEL: name: read_flags11 ; CHECK: bb.0:12 ; CHECK: [[RDFLAGS32_:%[0-9]+]]:gr32 = RDFLAGS32 implicit-def dead $esp, implicit $esp13 ; CHECK: $eax = COPY [[RDFLAGS32_]]14...15 16---17name: read_flags18legalized: true19regBankSelected: true20 21registers:22 - { id: 0, class: gpr }23 24body: |25 bb.0:26 %0(s32) = G_INTRINSIC_W_SIDE_EFFECTS intrinsic(@llvm.x86.flags.read.u32)27 $eax = COPY %0(s32)28...29