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
74425e26
Commit
74425e26
authored
Mar 24, 2006
by
Michael Beck
Browse files
create sub esp, imm instead off add esp -imm instructions
parent
91c4099f
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/be/ia32/ia32_emitter.c
View file @
74425e26
...
...
@@ -1186,12 +1186,14 @@ void emit_be_Call(const ir_node *irn, ia32_emit_env_t *emit_env) {
void
emit_be_IncSP
(
const
ir_node
*
irn
,
ia32_emit_env_t
*
emit_env
)
{
FILE
*
F
=
emit_env
->
out
;
unsigned
offs
=
be_get_IncSP_offset
(
irn
);
be_stack_dir_t
dir
=
be_get_IncSP_direction
(
irn
);
char
cmd_buf
[
SNPRINTF_BUF_LEN
],
cmnt_buf
[
SNPRINTF_BUF_LEN
];
if
(
offs
)
{
lc_esnprintf
(
ia32_get_arg_env
(),
cmd_buf
,
SNPRINTF_BUF_LEN
,
"add %1S,%s%u"
,
irn
,
(
dir
==
be_stack_dir_along
)
?
" -"
:
" "
,
offs
);
be_stack_dir_t
dir
=
be_get_IncSP_direction
(
irn
);
if
(
dir
==
be_stack_dir_along
)
lc_esnprintf
(
ia32_get_arg_env
(),
cmd_buf
,
SNPRINTF_BUF_LEN
,
"sub %1S, %u"
,
irn
,
offs
);
else
lc_esnprintf
(
ia32_get_arg_env
(),
cmd_buf
,
SNPRINTF_BUF_LEN
,
"add %1S, %u"
,
irn
,
offs
);
lc_esnprintf
(
ia32_get_arg_env
(),
cmnt_buf
,
SNPRINTF_BUF_LEN
,
"/* %+F (IncSP) */"
,
irn
);
}
else
{
...
...
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