public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Claudiu Zissulescu <claziss@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r12-6575] arc: Update stack size computation when accumulator registers are available. Date: Fri, 14 Jan 2022 10:25:05 +0000 (GMT) [thread overview] Message-ID: <20220114102505.0ABDB385DC11@sourceware.org> (raw) https://gcc.gnu.org/g:b3989a7b1069ef9ed56911d96e1ad153e506aabb commit r12-6575-gb3989a7b1069ef9ed56911d96e1ad153e506aabb Author: Claudiu Zissulescu <claziss@synopsys.com> Date: Thu Nov 25 15:38:03 2021 +0200 arc: Update stack size computation when accumulator registers are available. When accumulator registers are available in a processor, they need to be save onto stack durring interrupts. We were already doing so, but the stack size was wrongly computed in the case other than ARC600. gcc/ * config/arc/arc.c (arc_compute_frame_size): Remove condition when computin checking accumulator regs. (arc_expand_prologue): Update comments. (arc_expand_epilogue): Likewise. Signed-off-by: Claudiu Zissulescu <claziss@synopsys.com> Diff: --- gcc/config/arc/arc.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c index 6de364e9ce0..3096a9bef44 100644 --- a/gcc/config/arc/arc.c +++ b/gcc/config/arc/arc.c @@ -2897,9 +2897,8 @@ arc_compute_frame_size (void) cfun, TARGET_DPFP)) reg_size += UNITS_PER_WORD * 2; - /* Check for special MLO/MHI case used by ARC600' MUL64 - extension. */ - if (arc_must_save_register (R58_REG, cfun, TARGET_MUL64_SET)) + /* Check if R58 is used. */ + if (arc_must_save_register (R58_REG, cfun, true)) reg_size += UNITS_PER_WORD * 2; /* 4) Calculate extra size made up of the blink + fp size. */ @@ -3878,7 +3877,7 @@ arc_expand_prologue (void) } } - /* Save ARC600' MUL64 registers. */ + /* Save accumulator registers. */ if (arc_must_save_register (R58_REG, cfun, true)) frame_size_to_allocate -= arc_save_callee_saves (3ULL << 58, false, false, 0, false); @@ -3971,7 +3970,7 @@ arc_expand_epilogue (int sibcall_p) first_offset = 0; } - /* Restore ARC600' MUL64 registers. */ + /* Restore accumulator registers. */ if (arc_must_save_register (R58_REG, cfun, true)) { rtx insn;
reply other threads:[~2022-01-14 10:25 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20220114102505.0ABDB385DC11@sourceware.org \ --to=claziss@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).