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
17f0e0cb
Commit
17f0e0cb
authored
Jan 11, 2015
by
Christoph Mallon
Browse files
amd64: Rename push_rbp to push_reg and add an operand for the value, which it pushes.
parent
6d7f9e79
Changes
2
Show whitespace changes
Inline
Side-by-side
ir/be/amd64/amd64_spec.pl
View file @
17f0e0cb
...
...
@@ -219,15 +219,15 @@ push_am => {
emit
=>
"
push%M %A
",
},
push_r
bp
=>
{
push_r
eg
=>
{
op_flags
=>
[
"
uses_memory
"
],
state
=>
"
exc_pinned
",
in_reqs
=>
[
"
rsp
"
],
in_reqs
=>
[
"
rsp
"
,
"
gp
"
],
out_reqs
=>
[
"
rsp:I|S
"
],
ins
=>
[
"
stack
"
],
ins
=>
[
"
stack
"
,
"
val
"
],
outs
=>
[
"
stack
"
],
fixed
=>
"
amd64_op_mode_t op_mode = AMD64_OP_NONE;
\n
",
emit
=>
"
pushq %
%rbp
",
emit
=>
"
pushq %
^S1
",
},
pop_am
=>
{
...
...
ir/be/amd64/bearch_amd64.c
View file @
17f0e0cb
...
...
@@ -93,7 +93,7 @@ static int amd64_get_sp_bias(const ir_node *node)
if
(
is_amd64_push_am
(
node
))
{
const
amd64_addr_attr_t
*
attr
=
get_amd64_addr_attr_const
(
node
);
return
get_insn_mode_bytes
(
attr
->
insn_mode
);
}
else
if
(
is_amd64_push_r
bp
(
node
))
{
}
else
if
(
is_amd64_push_r
eg
(
node
))
{
/* 64-bit register size */
return
AMD64_REGISTER_SIZE
;
}
else
if
(
is_amd64_pop_am
(
node
))
{
...
...
@@ -569,8 +569,8 @@ static void introduce_prologue(ir_graph *const irg)
if
(
!
layout
->
sp_relative
)
{
/* push rbp */
ir_node
*
const
initial_bp
=
be_get_initial_reg_value
(
irg
,
bp
);
ir_node
*
push
=
new_bd_amd64_push_r
bp
(
NULL
,
block
,
initial_sp
);
ir_node
*
curr_sp
=
new_r_Proj
(
push
,
mode_gp
,
pn_amd64_push_r
bp
_stack
);
ir_node
*
const
push
=
new_bd_amd64_push_r
eg
(
NULL
,
block
,
initial_sp
,
initial_bp
);
ir_node
*
const
curr_sp
=
new_r_Proj
(
push
,
mode_gp
,
pn_amd64_push_r
eg
_stack
);
arch_set_irn_register
(
curr_sp
,
sp
);
sched_add_after
(
start
,
push
);
...
...
Write
Preview
Supports
Markdown
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