Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
llvm-epi
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Roger Ferrer
llvm-epi
Commits
9449ec95
Commit
9449ec95
authored
12 years ago
by
Evan Cheng
Browse files
Options
Downloads
Patches
Plain Diff
Forgot the test case before.
llvm-svn: 173988
parent
d2ca4e2e
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
llvm/test/CodeGen/X86/sincos-opt.ll
+40
-0
40 additions, 0 deletions
llvm/test/CodeGen/X86/sincos-opt.ll
with
40 additions
and
0 deletions
llvm/test/CodeGen/X86/sincos-opt.ll
0 → 100644
+
40
−
0
View file @
9449ec95
; RUN: llc < %s -mtriple=x86_64-apple-macosx10.9.0 -mcpu=core2 | FileCheck %s --check-prefix=SINCOS
; RUN: llc < %s -mtriple=x86_64-apple-macosx10.8.0 -mcpu=core2 | FileCheck %s --check-prefix=NOOPT
; Combine sin / cos into a single call.
; rdar://13087969
define
float
@test1
(
float
%x
)
nounwind
{
entry:
; SINCOS: test1:
; SINCOS: callq ___sincosf_stret
; SINCOS: addss %xmm1, %xmm0
; NOOPT: test1
; NOOPT: callq _cosf
; NOOPT: callq _sinf
%call
=
tail
call
float
@sinf
(
float
%x
)
nounwind
readnone
%call1
=
tail
call
float
@cosf
(
float
%x
)
nounwind
readnone
%add
=
fadd
float
%call
,
%call1
ret
float
%add
}
define
double
@test2
(
double
%x
)
nounwind
{
entry:
; SINCOS: test2:
; SINCOS: callq ___sincos_stret
; SINCOS: addsd %xmm1, %xmm0
; NOOPT: test2
; NOOPT: callq _cos
; NOOPT: callq _sin
%call
=
tail
call
double
@sin
(
double
%x
)
nounwind
readnone
%call1
=
tail
call
double
@cos
(
double
%x
)
nounwind
readnone
%add
=
fadd
double
%call
,
%call1
ret
double
%add
}
declare
float
@sinf
(
float
)
readonly
declare
double
@sin
(
double
)
readonly
declare
float
@cosf
(
float
)
readonly
declare
double
@cos
(
double
)
readonly
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment