Re: [PATCH] expansion: FIx up infinite recusion due to double-word modulo optimization

2020-12-01 Thread Richard Biener
On Tue, 1 Dec 2020, Jakub Jelinek wrote: > Hi! > > Jeff has reported that my earlier patch broke rl78-elf, e.g. with > unsigned short foo (unsigned short x) { return x % 7; } > when compiled with -O2 -mg14. The problem is that rl78 is a BITS_PER_WORD > == 8 target which doesn't have 8-bit modulo

Re: [PATCH] expansion: FIx up infinite recusion due to double-word modulo optimization

2020-12-01 Thread Jeff Law via Gcc-patches
On 12/1/20 2:07 PM, Jakub Jelinek wrote: > Hi! > > Jeff has reported that my earlier patch broke rl78-elf, e.g. with > unsigned short foo (unsigned short x) { return x % 7; } > when compiled with -O2 -mg14. The problem is that rl78 is a BITS_PER_WORD > == 8 target which doesn't have 8-bit modul

[PATCH] expansion: FIx up infinite recusion due to double-word modulo optimization

2020-12-01 Thread Jakub Jelinek via Gcc-patches
Hi! Jeff has reported that my earlier patch broke rl78-elf, e.g. with unsigned short foo (unsigned short x) { return x % 7; } when compiled with -O2 -mg14. The problem is that rl78 is a BITS_PER_WORD == 8 target which doesn't have 8-bit modulo or divmod optab, but has instead 16-bit divmod, so my