llvm-project/llvm/test/CodeGen/X86/strictfp-inlineasm.ll
David Green 22968f5b4a
[DAG] Add strictfp implicit def reg after metadata. (#168282)
This prevents a machine verifier error, where it "Expected implicit
register after groups".

Fixes #158661
2025-11-17 10:57:21 +00:00

28 lines
811 B
LLVM

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 6
; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=+sse2 -verify-machineinstrs | FileCheck %s --check-prefixes=X86
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+sse2 -verify-machineinstrs | FileCheck %s --check-prefixes=X64
define i32 @foo() strictfp {
; X86-LABEL: foo:
; X86: # %bb.0: # %entry
; X86-NEXT: movl $1, %eax
; X86-NEXT: #APP
; X86-NEXT: #NO_APP
; X86-NEXT: movl $-1, %eax
; X86-NEXT: retl
;
; X64-LABEL: foo:
; X64: # %bb.0: # %entry
; X64-NEXT: movl $1, %eax
; X64-NEXT: #APP
; X64-NEXT: #NO_APP
; X64-NEXT: movl $-1, %eax
; X64-NEXT: retq
entry:
tail call void asm sideeffect "", "r"(i32 1) #1, !srcloc !0
ret i32 -1
}
!0 = !{i64 87}