Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-20 Thread Jeff Law
On 09/20/2016 11:11 AM, Segher Boessenkool wrote: On Tue, Sep 20, 2016 at 08:52:46AM -0600, Jeff Law wrote: - JUMP_LABEL can be a return which is not an insn. That also seems like something that should be improved at some point. The JUMP_LABEL field within a JUMP_INSN? That sounds like a

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-20 Thread Segher Boessenkool
On Tue, Sep 20, 2016 at 08:52:46AM -0600, Jeff Law wrote: > >- JUMP_LABEL can be a return which is not an insn. That also seems > > like something that should be improved at some point. > The JUMP_LABEL field within a JUMP_INSN? That sounds like a bug. > >>> > >>>yes, see the

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-20 Thread Jeff Law
On 09/20/2016 04:38 AM, Bernd Schmidt wrote: On 09/20/2016 01:16 AM, Segher Boessenkool wrote: On Mon, Sep 19, 2016 at 06:07:46PM -0400, Trevor Saunders wrote: - JUMP_LABEL can be a return which is not an insn. That also seems like something that should be improved at some point. The

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-20 Thread Bernd Schmidt
On 09/20/2016 01:16 AM, Segher Boessenkool wrote: On Mon, Sep 19, 2016 at 06:07:46PM -0400, Trevor Saunders wrote: - JUMP_LABEL can be a return which is not an insn. That also seems like something that should be improved at some point. The JUMP_LABEL field within a JUMP_INSN? That sounds

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-19 Thread Segher Boessenkool
On Mon, Sep 19, 2016 at 06:07:46PM -0400, Trevor Saunders wrote: > > > - JUMP_LABEL can be a return which is not an insn. That also seems > > > like something that should be improved at some point. > > The JUMP_LABEL field within a JUMP_INSN? That sounds like a bug. > > yes, see the comment

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-19 Thread Trevor Saunders
On Mon, Sep 19, 2016 at 02:49:49PM -0600, Jeff Law wrote: > On 09/16/2016 04:10 AM, Trevor Saunders wrote: > > On Thu, Sep 15, 2016 at 10:27:56AM -0600, Jeff Law wrote: > > > On 09/15/2016 10:10 AM, Trevor Saunders wrote: > > > > On Thu, Sep 15, 2016 at 12:52:59PM +0200, Bernd Schmidt wrote: > > >

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-19 Thread Jeff Law
On 09/16/2016 04:10 AM, Trevor Saunders wrote: On Thu, Sep 15, 2016 at 10:27:56AM -0600, Jeff Law wrote: On 09/15/2016 10:10 AM, Trevor Saunders wrote: On Thu, Sep 15, 2016 at 12:52:59PM +0200, Bernd Schmidt wrote: On 09/14/2016 09:21 PM, tbsaunde+...@tbsaunde.org wrote: Basically $subject.

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-16 Thread Jeff Law
On 09/16/2016 04:10 AM, Bernd Schmidt wrote: On 09/16/2016 12:10 PM, Trevor Saunders wrote: ok, going through all the casts added here I see the following reasons for them. - in md files operands is a array of rtx, we should probably have a different way to pass insns to the C code here.

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-16 Thread Trevor Saunders
On Fri, Sep 16, 2016 at 12:10:51PM +0200, Bernd Schmidt wrote: > On 09/16/2016 12:10 PM, Trevor Saunders wrote: > > ok, going through all the casts added here I see the following reasons > > for them. > > > > - in md files operands is a array of rtx, we should probably have a > > different way

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-16 Thread Bernd Schmidt
On 09/16/2016 12:10 PM, Trevor Saunders wrote: ok, going through all the casts added here I see the following reasons for them. - in md files operands is a array of rtx, we should probably have a different way to pass insns to the C code here. That seems worth investigating incrementally.

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-16 Thread Trevor Saunders
On Thu, Sep 15, 2016 at 10:27:56AM -0600, Jeff Law wrote: > On 09/15/2016 10:10 AM, Trevor Saunders wrote: > > On Thu, Sep 15, 2016 at 12:52:59PM +0200, Bernd Schmidt wrote: > > > On 09/14/2016 09:21 PM, tbsaunde+...@tbsaunde.org wrote: > > > > > > > Basically $subject. First change variable's

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-15 Thread Trevor Saunders
On Thu, Sep 15, 2016 at 10:27:56AM -0600, Jeff Law wrote: > On 09/15/2016 10:10 AM, Trevor Saunders wrote: > > On Thu, Sep 15, 2016 at 12:52:59PM +0200, Bernd Schmidt wrote: > > > On 09/14/2016 09:21 PM, tbsaunde+...@tbsaunde.org wrote: > > > > > > > Basically $subject. First change variable's

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-15 Thread Jeff Law
On 09/15/2016 10:10 AM, Trevor Saunders wrote: On Thu, Sep 15, 2016 at 12:52:59PM +0200, Bernd Schmidt wrote: On 09/14/2016 09:21 PM, tbsaunde+...@tbsaunde.org wrote: Basically $subject. First change variable's type to rtx_insn * where possible. Then change the functions and fixup callers

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-15 Thread Trevor Saunders
On Thu, Sep 15, 2016 at 12:52:59PM +0200, Bernd Schmidt wrote: > On 09/14/2016 09:21 PM, tbsaunde+...@tbsaunde.org wrote: > > > Basically $subject. First change variable's type to rtx_insn * where > > possible. > > Then change the functions and fixup callers where it is still necessary to > >

Re: [PATCH 0/8] make next_*_insn take rtx_insn * arguments

2016-09-15 Thread Bernd Schmidt
On 09/14/2016 09:21 PM, tbsaunde+...@tbsaunde.org wrote: Basically $subject. First change variable's type to rtx_insn * where possible. Then change the functions and fixup callers where it is still necessary to cast. #2, #4 and #8 look good and can be applied if they work independently of