Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
8f454e9f
Commit
8f454e9f
authored
Jul 24, 2014
by
Jiong Wang
Committed by
Marcus Shawcroft
Jul 24, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[AArch64] Optimize epilogue in the presence of an outgoing args area.
From-SVN: r212976
parent
8ae9698d
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
17 deletions
+21
-17
gcc/ChangeLog
+5
-0
gcc/config/aarch64/aarch64.c
+7
-17
gcc/testsuite/ChangeLog
+5
-0
gcc/testsuite/gcc.target/aarch64/test_frame_12.c
+4
-0
No files found.
gcc/ChangeLog
View file @
8f454e9f
2014
-
07
-
24
Jiong
Wang
<
jiong
.
wang
@
arm
.
com
>
*
config
/
aarch64
/
aarch64
.
c
(
aarch64_expand_epilogue
):
Don
't
subtract outgoing area size when restoring stack_pointer_rtx.
2014-07-24 Nick Clifton <nickc@redhat.com>
* config/rx/rx.md (stack_push): Adjust RTL to account for the fact
...
...
gcc/config/aarch64/aarch64.c
View file @
8f454e9f
...
...
@@ -2363,7 +2363,8 @@ aarch64_expand_epilogue (bool for_sibcall)
{
insn
=
emit_insn
(
gen_add3_insn
(
stack_pointer_rtx
,
hard_frame_pointer_rtx
,
GEN_INT
(
-
fp_offset
)));
GEN_INT
(
0
)));
offset
=
offset
-
fp_offset
;
RTX_FRAME_RELATED_P
(
insn
)
=
1
;
/* As SP is set to (FP - fp_offset), according to the rules in
dwarf2cfi.c:dwarf2out_frame_debug_expr, CFA should be calculated
...
...
@@ -2371,27 +2372,16 @@ aarch64_expand_epilogue (bool for_sibcall)
cfa_reg
=
stack_pointer_rtx
;
}
aarch64_restore_callee_saves
(
DFmode
,
fp_offset
,
V0_REGNUM
,
V31_REGNUM
);
aarch64_restore_callee_saves
(
DFmode
,
frame_pointer_needed
?
0
:
fp_offset
,
V0_REGNUM
,
V31_REGNUM
);
if
(
offset
>
0
)
{
if
(
frame_pointer_needed
)
{
if
(
fp_offset
)
{
aarch64_restore_callee_saves
(
DImode
,
fp_offset
,
R0_REGNUM
,
R30_REGNUM
);
insn
=
emit_insn
(
gen_add2_insn
(
stack_pointer_rtx
,
GEN_INT
(
offset
)));
RTX_FRAME_RELATED_P
(
insn
)
=
1
;
}
else
{
aarch64_restore_callee_saves
(
DImode
,
fp_offset
,
R0_REGNUM
,
R28_REGNUM
);
aarch64_popwb_pair_reg
(
DImode
,
R29_REGNUM
,
R30_REGNUM
,
offset
,
cfa_reg
);
}
aarch64_restore_callee_saves
(
DImode
,
0
,
R0_REGNUM
,
R28_REGNUM
);
aarch64_popwb_pair_reg
(
DImode
,
R29_REGNUM
,
R30_REGNUM
,
offset
,
cfa_reg
);
}
else
{
...
...
gcc/testsuite/ChangeLog
View file @
8f454e9f
2014
-
07
-
24
Jiong
Wang
<
jiong
.
wang
@
arm
.
com
>
*
gcc
.
target
/
aarch64
/
test_frame_12
.
c
:
Match
optimized
instruction
sequences
.
2014
-
07
-
24
Marek
Polacek
<
polacek
@
redhat
.
com
>
PR
c
/
57653
...
...
gcc/testsuite/gcc.target/aarch64/test_frame_12.c
View file @
8f454e9f
...
...
@@ -12,4 +12,8 @@ t_frame_pattern_outgoing (test12, 400, , 8, a[8])
t_frame_run
(
test12
)
/* { dg-final { scan-assembler-times "sub\tsp, sp, #\[0-9\]+" 1 } } */
/* Check epilogue using write-back. */
/* { dg-final { scan-assembler-times "ldp\tx29, x30, \\\[sp\\\], \[0-9\]+" 3 } } */
/* { dg-final { cleanup-saved-temps } } */
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