-
Notifications
You must be signed in to change notification settings - Fork 15.2k
[X86] isint.ll - cleanup prefixes #161198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
+62
−62
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Use X86 for 32-bit targets, and X64 for 64-bit targets
@llvm/pr-subscribers-backend-x86 Author: Simon Pilgrim (RKSimon) ChangesUse X86 for 32-bit targets, and X64 for 64-bit targets Full diff: https://github.com/llvm/llvm-project/pull/161198.diff 1 Files Affected:
diff --git a/llvm/test/CodeGen/X86/isint.ll b/llvm/test/CodeGen/X86/isint.ll
index 8a56f49a6c755..8c11fe147f0d8 100644
--- a/llvm/test/CodeGen/X86/isint.ll
+++ b/llvm/test/CodeGen/X86/isint.ll
@@ -1,29 +1,29 @@
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
-; RUN: llc < %s -mtriple=x86_64-pc-unknown -mattr=+sse2 | FileCheck -check-prefix=CHECK64 %s
-; RUN: llc < %s -mtriple=i686-pc-unknown -mattr=+sse2 | FileCheck -check-prefix=CHECK32 %s
+; RUN: llc < %s -mtriple=x86_64-pc-unknown -mattr=+sse2 | FileCheck -check-prefix=X64 %s
+; RUN: llc < %s -mtriple=i686-pc-unknown -mattr=+sse2 | FileCheck -check-prefix=X86 %s
; PR19059
define i32 @isint_return(double %d) nounwind {
-; CHECK64-LABEL: isint_return:
-; CHECK64: # %bb.0:
-; CHECK64-NEXT: cvttpd2dq %xmm0, %xmm1
-; CHECK64-NEXT: cvtdq2pd %xmm1, %xmm1
-; CHECK64-NEXT: cmpeqsd %xmm0, %xmm1
-; CHECK64-NEXT: movq %xmm1, %rax
-; CHECK64-NEXT: andl $1, %eax
-; CHECK64-NEXT: # kill: def $eax killed $eax killed $rax
-; CHECK64-NEXT: retq
+; X64-LABEL: isint_return:
+; X64: # %bb.0:
+; X64-NEXT: cvttpd2dq %xmm0, %xmm1
+; X64-NEXT: cvtdq2pd %xmm1, %xmm1
+; X64-NEXT: cmpeqsd %xmm0, %xmm1
+; X64-NEXT: movq %xmm1, %rax
+; X64-NEXT: andl $1, %eax
+; X64-NEXT: # kill: def $eax killed $eax killed $rax
+; X64-NEXT: retq
;
-; CHECK32-LABEL: isint_return:
-; CHECK32: # %bb.0:
-; CHECK32-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
-; CHECK32-NEXT: cvttpd2dq %xmm0, %xmm1
-; CHECK32-NEXT: cvtdq2pd %xmm1, %xmm1
-; CHECK32-NEXT: cmpeqsd %xmm0, %xmm1
-; CHECK32-NEXT: movd %xmm1, %eax
-; CHECK32-NEXT: andl $1, %eax
-; CHECK32-NEXT: retl
+; X86-LABEL: isint_return:
+; X86: # %bb.0:
+; X86-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
+; X86-NEXT: cvttpd2dq %xmm0, %xmm1
+; X86-NEXT: cvtdq2pd %xmm1, %xmm1
+; X86-NEXT: cmpeqsd %xmm0, %xmm1
+; X86-NEXT: movd %xmm1, %eax
+; X86-NEXT: andl $1, %eax
+; X86-NEXT: retl
%i = fptosi double %d to i32
%e = sitofp i32 %i to double
%c = fcmp oeq double %d, %e
@@ -32,24 +32,24 @@ define i32 @isint_return(double %d) nounwind {
}
define i32 @isint_float_return(float %f) nounwind {
-; CHECK64-LABEL: isint_float_return:
-; CHECK64: # %bb.0:
-; CHECK64-NEXT: cvttps2dq %xmm0, %xmm1
-; CHECK64-NEXT: cvtdq2ps %xmm1, %xmm1
-; CHECK64-NEXT: cmpeqss %xmm0, %xmm1
-; CHECK64-NEXT: movd %xmm1, %eax
-; CHECK64-NEXT: andl $1, %eax
-; CHECK64-NEXT: retq
+; X64-LABEL: isint_float_return:
+; X64: # %bb.0:
+; X64-NEXT: cvttps2dq %xmm0, %xmm1
+; X64-NEXT: cvtdq2ps %xmm1, %xmm1
+; X64-NEXT: cmpeqss %xmm0, %xmm1
+; X64-NEXT: movd %xmm1, %eax
+; X64-NEXT: andl $1, %eax
+; X64-NEXT: retq
;
-; CHECK32-LABEL: isint_float_return:
-; CHECK32: # %bb.0:
-; CHECK32-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
-; CHECK32-NEXT: cvttps2dq %xmm0, %xmm1
-; CHECK32-NEXT: cvtdq2ps %xmm1, %xmm1
-; CHECK32-NEXT: cmpeqss %xmm0, %xmm1
-; CHECK32-NEXT: movd %xmm1, %eax
-; CHECK32-NEXT: andl $1, %eax
-; CHECK32-NEXT: retl
+; X86-LABEL: isint_float_return:
+; X86: # %bb.0:
+; X86-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
+; X86-NEXT: cvttps2dq %xmm0, %xmm1
+; X86-NEXT: cvtdq2ps %xmm1, %xmm1
+; X86-NEXT: cmpeqss %xmm0, %xmm1
+; X86-NEXT: movd %xmm1, %eax
+; X86-NEXT: andl $1, %eax
+; X86-NEXT: retl
%i = fptosi float %f to i32
%g = sitofp i32 %i to float
%c = fcmp oeq float %f, %g
@@ -60,32 +60,32 @@ define i32 @isint_float_return(float %f) nounwind {
declare void @foo()
define void @isint_branch(double %d) nounwind {
-; CHECK64-LABEL: isint_branch:
-; CHECK64: # %bb.0:
-; CHECK64-NEXT: cvttpd2dq %xmm0, %xmm1
-; CHECK64-NEXT: cvtdq2pd %xmm1, %xmm1
-; CHECK64-NEXT: ucomisd %xmm1, %xmm0
-; CHECK64-NEXT: jne .LBB2_2
-; CHECK64-NEXT: jp .LBB2_2
-; CHECK64-NEXT: # %bb.1: # %true
-; CHECK64-NEXT: pushq %rax
-; CHECK64-NEXT: callq foo@PLT
-; CHECK64-NEXT: popq %rax
-; CHECK64-NEXT: .LBB2_2: # %false
-; CHECK64-NEXT: retq
+; X64-LABEL: isint_branch:
+; X64: # %bb.0:
+; X64-NEXT: cvttpd2dq %xmm0, %xmm1
+; X64-NEXT: cvtdq2pd %xmm1, %xmm1
+; X64-NEXT: ucomisd %xmm1, %xmm0
+; X64-NEXT: jne .LBB2_2
+; X64-NEXT: jp .LBB2_2
+; X64-NEXT: # %bb.1: # %true
+; X64-NEXT: pushq %rax
+; X64-NEXT: callq foo@PLT
+; X64-NEXT: popq %rax
+; X64-NEXT: .LBB2_2: # %false
+; X64-NEXT: retq
;
-; CHECK32-LABEL: isint_branch:
-; CHECK32: # %bb.0:
-; CHECK32-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
-; CHECK32-NEXT: cvttpd2dq %xmm0, %xmm1
-; CHECK32-NEXT: cvtdq2pd %xmm1, %xmm1
-; CHECK32-NEXT: ucomisd %xmm1, %xmm0
-; CHECK32-NEXT: jne .LBB2_2
-; CHECK32-NEXT: jp .LBB2_2
-; CHECK32-NEXT: # %bb.1: # %true
-; CHECK32-NEXT: calll foo@PLT
-; CHECK32-NEXT: .LBB2_2: # %false
-; CHECK32-NEXT: retl
+; X86-LABEL: isint_branch:
+; X86: # %bb.0:
+; X86-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
+; X86-NEXT: cvttpd2dq %xmm0, %xmm1
+; X86-NEXT: cvtdq2pd %xmm1, %xmm1
+; X86-NEXT: ucomisd %xmm1, %xmm0
+; X86-NEXT: jne .LBB2_2
+; X86-NEXT: jp .LBB2_2
+; X86-NEXT: # %bb.1: # %true
+; X86-NEXT: calll foo@PLT
+; X86-NEXT: .LBB2_2: # %false
+; X86-NEXT: retl
%i = fptosi double %d to i32
%e = sitofp i32 %i to double
%c = fcmp oeq double %d, %e
|
mahesh-attarde
pushed a commit
to mahesh-attarde/llvm-project
that referenced
this pull request
Oct 3, 2025
Use X86 for 32-bit targets, and X64 for 64-bit targets
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Use X86 for 32-bit targets, and X64 for 64-bit targets