"length" troubles (was: Re: [PATCH] V6, #1 of 17: Use ADJUST_INSN_LENGTH for prefixed instructions)

2019-10-31 Thread Segher Boessenkool
On Wed, Oct 23, 2019 at 04:42:19PM -0500, Segher Boessenkool wrote: > On Wed, Oct 23, 2019 at 05:00:58PM -0400, Michael Meissner wrote: > > On Tue, Oct 22, 2019 at 05:27:19PM -0500, Segher Boessenkool wrote: > > > On Wed, Oct 16, 2019 at 09:35:33AM -0400, Michael Meissner wrote: > > > > - int n =

Re: [PATCH] V6, #1 of 17: Use ADJUST_INSN_LENGTH for prefixed instructions

2019-10-23 Thread Segher Boessenkool
On Wed, Oct 23, 2019 at 05:00:58PM -0400, Michael Meissner wrote: > On Tue, Oct 22, 2019 at 05:27:19PM -0500, Segher Boessenkool wrote: > > On Wed, Oct 16, 2019 at 09:35:33AM -0400, Michael Meissner wrote: > > > - int n = get_attr_length (insn) / 4; > > > + /* If the insn tells us how many insns

Re: [PATCH] V6, #1 of 17: Use ADJUST_INSN_LENGTH for prefixed instructions

2019-10-23 Thread Michael Meissner
On Tue, Oct 22, 2019 at 05:27:19PM -0500, Segher Boessenkool wrote: > Hi! > > On Wed, Oct 16, 2019 at 09:35:33AM -0400, Michael Meissner wrote: > > This patch uses the target hook ADJUST_INSN_LENGTH to change the length of > > instructions that contain prefixed memory/add instructions. > > That

Re: [PATCH] V6, #1 of 17: Use ADJUST_INSN_LENGTH for prefixed instructions

2019-10-22 Thread Segher Boessenkool
Hi! On Wed, Oct 16, 2019 at 09:35:33AM -0400, Michael Meissner wrote: > This patch uses the target hook ADJUST_INSN_LENGTH to change the length of > instructions that contain prefixed memory/add instructions. That made this amazingly hard to review. But it might well be worth it, thankfully :-)

[PATCH] V6, #1 of 17: Use ADJUST_INSN_LENGTH for prefixed instructions

2019-10-16 Thread Michael Meissner
This patch uses the target hook ADJUST_INSN_LENGTH to change the length of instructions that contain prefixed memory/add instructions. There are 2 new insn attributes: 1) num_insns: If non-zero, returns the number of machine instructions in an insn. This simplifies the calculations in