llvm-project/llvm/test/CodeGen/MIR/X86/instr-pcsections.mir
Fangrui Song 40a4cbb0f2 [MIR,test] Change llc -march=x86-64 to -mtriple=x86_64
Similar to 806761a7629df268c8aed49657aeccffa6bca449

-mtriple= specifies the full target triple while -march= merely sets the
architecture part of the default target triple (e.g. Windows, macOS).

Therefore, -march= is error-prone and not recommended for tests without
a target triple. The issue has been benign as these MIR tests do not
utilize object file format specific detail, but it's good to change
these tests to neighbor files that use -mtriple=x86_64
2024-12-15 11:23:08 -08:00

35 lines
697 B
YAML

# RUN: llc -mtriple=x86_64 -run-pass none -o - %s | FileCheck %s
# This test ensures that the MIR parser parses pcsections metadata correctly.
--- |
define i8 @test(ptr %a) {
entry:
%0 = load i8, ptr %a, align 1, !pcsections !0
ret i8 %0
}
!0 = !{!"foo"}
...
---
name: test
alignment: 16
tracksRegLiveness: true
liveins:
- { reg: '$rdi' }
frameInfo:
maxAlignment: 1
maxCallFrameSize: 0
machineFunctionInfo: {}
body: |
bb.0.entry:
liveins: $rdi
; CHECK-LABEL: name: test
; CHECK: MOV{{.*}} pcsections !0
renamable $al = MOV8rm killed renamable $rdi, 1, $noreg, 0, $noreg, pcsections !0
RET64 implicit killed $al
...