This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Add XINSN macro and use it within NEXT_INSN/PREV_INSN (was Re: [PATCH] Force rtl templates to be inlined)
- From: Jakub Jelinek <jakub at redhat dot com>
- To: David Malcolm <dmalcolm at redhat dot com>
- Cc: Andi Kleen <andi at firstfloor dot org>, gcc-patches at gcc dot gnu dot org, Andi Kleen <ak at linux dot intel dot com>
- Date: Thu, 4 Sep 2014 22:22:15 +0200
- Subject: Re: [PATCH] Add XINSN macro and use it within NEXT_INSN/PREV_INSN (was Re: [PATCH] Force rtl templates to be inlined)
- Authentication-results: sourceware.org; auth=none
- References: <1409641427-29875-1-git-send-email-andi at firstfloor dot org> <1409669743 dot 19403 dot 13 dot camel at surprise> <20140902175037 dot GA4120 at two dot firstfloor dot org> <1409861057 dot 19403 dot 19 dot camel at surprise>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Thu, Sep 04, 2014 at 04:04:17PM -0400, David Malcolm wrote:
> --- a/gcc/rtl.h
> +++ b/gcc/rtl.h
> @@ -195,6 +195,7 @@ union rtunion
> unsigned int rt_uint;
> const char *rt_str;
> rtx rt_rtx;
> + rtx_insn *rt_insn;
> rtvec rt_rtvec;
> enum machine_mode rt_type;
> addr_diff_vec_flags rt_addr_diff_vec_flags;
> @@ -1208,6 +1209,7 @@ extern void rtl_check_failed_flag (const char *, const_rtx, const char *,
> #define XUINT(RTX, N) (RTL_CHECK2 (RTX, N, 'i', 'n').rt_uint)
> #define XSTR(RTX, N) (RTL_CHECK2 (RTX, N, 's', 'S').rt_str)
> #define XEXP(RTX, N) (RTL_CHECK2 (RTX, N, 'e', 'u').rt_rtx)
Shouldn't XEXP be changed into RTL_CHECK1 (RTX, N, 'e').rt_rtx
then and the accessors of first operand of INSN_LIST and only operand of
LABEL_REF be changed to XINSN too? Of course doesn't have to be done
immediately, can be done as a followup.
> +#define XINSN(RTX, N) (RTL_CHECK1 (RTX, N, 'u').rt_insn)
> #define XVEC(RTX, N) (RTL_CHECK2 (RTX, N, 'E', 'V').rt_rtvec)
> #define XMODE(RTX, N) (RTL_CHECK1 (RTX, N, 'M').rt_type)
> #define XTREE(RTX, N) (RTL_CHECK1 (RTX, N, 't').rt_tree)
Jakub