Re: doloop insn generated incorrectly (wrong mode)

2018-10-11 Thread Paul Koning
> On Oct 11, 2018, at 3:11 AM, Segher Boessenkool > wrote: > > Hi! > > On Wed, Oct 10, 2018 at 08:55:12PM -0400, Paul Koning wrote: > > [ snip ] > >> ... >> Why is this happening, and how can I fix it (short of removing the >> doloop_end pattern)? I see a comment in loop-doloop.c about h

Re: doloop insn generated incorrectly (wrong mode)

2018-10-11 Thread Segher Boessenkool
Hi! On Wed, Oct 10, 2018 at 08:55:12PM -0400, Paul Koning wrote: [ snip ] > Note that this isn't permitted by the .md file -- the mode is wrong (QI not > HI). Other targets use an expander and check the mode explicitly in there. See rs6000 or sh for example. > It's not obvious to me how that

doloop insn generated incorrectly (wrong mode)

2018-10-10 Thread Paul Koning
I have a doloop_end pattern in pdp11.md which looks like this: (define_insn_and_split "doloop_end" [(set (pc) (if_then_else (ne (match_operand:HI 0 "nonimmediate_operand" "+r,!m") (const_int 1)) (label_ref (match_operand 1 "" "")) (pc))) (set (m