Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
1323e590
Commit
1323e590
authored
Oct 06, 2006
by
Christian Würdig
Browse files
fixed requirements for ShrD and ShlD
parent
516482fa
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/be/ia32/ia32_spec.pl
View file @
1323e590
...
...
@@ -435,7 +435,15 @@ $comment_string = "/*";
"
irn_flags
"
=>
"
R
",
"
comment
"
=>
"
construct ShlD: ShlD(a, b, c) = a, b << count (shift left count bits from b into a)
",
"
cmp_attr
"
=>
"
return ia32_compare_immop_attr(attr_a, attr_b);
\n
",
"
reg_req
"
=>
{
"
in
"
=>
[
"
gp
",
"
gp
",
"
gp
",
"
gp
",
"
ecx
",
"
none
"
],
"
out
"
=>
[
"
!ecx in_r3 !in_r4
"
]
},
# Out requirements is: different from all in
# This is because, out must be different from LowPart and ShiftCount.
# We could say "!ecx !in_r4" but it can occur, that all values live through
# this Shift and the only value dying is the ShiftCount. Then there would be a
# register missing, as result must not be ecx and all other registers are
# occupied. What we should write is "!in_r4 !in_r5", but this is not supported
# (and probably never will). So we create artificial interferences of the result
# with all inputs, so the spiller can always assure a free register.
"
reg_req
"
=>
{
"
in
"
=>
[
"
gp
",
"
gp
",
"
gp
",
"
gp
",
"
ecx
",
"
none
"
],
"
out
"
=>
[
"
!in
"
]
},
"
emit
"
=>
'
if (get_ia32_immop_type(n) == ia32_ImmNone) {
...
...
@@ -484,7 +492,15 @@ else {
"
irn_flags
"
=>
"
R
",
"
comment
"
=>
"
construct ShrD: ShrD(a, b, c) = a, b >> count (shift rigth count bits from a into b)
",
"
cmp_attr
"
=>
"
return ia32_compare_immop_attr(attr_a, attr_b);
\n
",
"
reg_req
"
=>
{
"
in
"
=>
[
"
gp
",
"
gp
",
"
gp
",
"
gp
",
"
ecx
",
"
none
"
],
"
out
"
=>
[
"
!ecx in_r3 !in_r4
"
]
},
# Out requirements is: different from all in
# This is because, out must be different from LowPart and ShiftCount.
# We could say "!ecx !in_r4" but it can occur, that all values live through
# this Shift and the only value dying is the ShiftCount. Then there would be a
# register missing, as result must not be ecx and all other registers are
# occupied. What we should write is "!in_r4 !in_r5", but this is not supported
# (and probably never will). So we create artificial interferences of the result
# with all inputs, so the spiller can always assure a free register.
"
reg_req
"
=>
{
"
in
"
=>
[
"
gp
",
"
gp
",
"
gp
",
"
gp
",
"
ecx
",
"
none
"
],
"
out
"
=>
[
"
!in
"
]
},
"
emit
"
=>
'
if (get_ia32_immop_type(n) == ia32_ImmNone) {
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment