This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 3/7] [ARC] Update can_follow_jump hook helper.
- From: Andrew Burgess <andrew dot burgess at embecosm dot com>
- To: Claudiu Zissulescu <Claudiu dot Zissulescu at synopsys dot com>
- Cc: gcc-patches at gcc dot gnu dot org, Francois dot Bedard at synopsys dot com, sandra at codesourcery dot com
- Date: Tue, 15 Aug 2017 14:39:01 +0100
- Subject: Re: [PATCH 3/7] [ARC] Update can_follow_jump hook helper.
- Authentication-results: sourceware.org; auth=none
- References: <1500885779-12930-1-git-send-email-claziss@synopsys.com> <1500885779-12930-4-git-send-email-claziss@synopsys.com>
* Claudiu Zissulescu <Claudiu.Zissulescu@synopsys.com> [2017-07-24 10:42:55 +0200]:
> From: claziss <claziss@synopsys.com>
>
> Short branches cannot be used to jump between hot/cold
> sections. Update the hook.
>
> gcc/
> 2017-04-26 Claudiu Zissulescu <claziss@synopsys.com>
>
> * config/arc/arc.c (arc_can_follow_jump): Check for short
> branches.
This looks fine.
Thanks,
Andrew
> ---
> gcc/config/arc/arc.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
> index cf52df8..3980a0f 100644
> --- a/gcc/config/arc/arc.c
> +++ b/gcc/config/arc/arc.c
> @@ -9941,6 +9941,9 @@ arc_can_follow_jump (const rtx_insn *follower, const rtx_insn *followee)
> if (CROSSING_JUMP_P (followee))
> switch (get_attr_type (u.r))
> {
> + case TYPE_BRANCH:
> + if (get_attr_length (u.r) != 2)
> + break;
> case TYPE_BRCC:
> case TYPE_BRCC_NO_DELAY_SLOT:
> return false;
> --
> 1.9.1
>