Re: question on 16 bit registers with 32 bit pointers

2009-04-13 Thread Michael Meissner
On Sat, Apr 11, 2009 at 01:40:57AM +0100, Dave Korn wrote: Stelian Pop wrote: Do I need to define movsi3(), addsi3() etc. patterns manually or should GCC figure those by itself ? Not sure I understand you. You always need to define movMM3 etc. GCC will correctly select between

Re: question on 16 bit registers with 32 bit pointers

2009-04-13 Thread Dave Korn
Michael Meissner wrote: On Sat, Apr 11, 2009 at 01:40:57AM +0100, Dave Korn wrote: Stelian Pop wrote: Do I need to define movsi3(), addsi3() etc. patterns manually or should GCC figure those by itself ? Not sure I understand you. You always need to define movMM3 etc. GCC will correctly

Re: question on 16 bit registers with 32 bit pointers

2009-04-13 Thread Hans-Peter Nilsson
On Mon, 13 Apr 2009, Dave Korn wrote: Michael Meissner wrote: On Sat, Apr 11, 2009 at 01:40:57AM +0100, Dave Korn wrote: Stelian Pop wrote: Do I need to define movsi3(), addsi3() etc. patterns manually or should GCC figure those by itself ? ... Though if you use expanders that need

question on 16 bit registers with 32 bit pointers

2009-04-10 Thread Stelian Pop
Hi, I'm (still) porting GCC to a 16 bit microcontroller, and I'm having a few issues with the way it handles memory accesses: this microcontroller can function in two modes: in one of them the pointers are on 16 bit (a full register), in the second one the pointers are on 32 bit and are stored in

Re: question on 16 bit registers with 32 bit pointers

2009-04-10 Thread Dave Korn
Stelian Pop wrote: Hi, I'm (still) porting GCC to a 16 bit microcontroller, and I'm having a few issues with the way it handles memory accesses: this microcontroller can function in two modes: in one of them the pointers are on 16 bit (a full register), in the second one the pointers are on

Re: question on 16 bit registers with 32 bit pointers

2009-04-10 Thread Stelian Pop
On Fri, Apr 10, 2009 at 06:29:06PM +0100, Dave Korn wrote: Stelian Pop wrote: Hi, I'm (still) porting GCC to a 16 bit microcontroller, and I'm having a few issues with the way it handles memory accesses: this microcontroller can function in two modes: in one of them the pointers are

Re: question on 16 bit registers with 32 bit pointers

2009-04-10 Thread Dave Korn
Stelian Pop wrote: Do I need to define movsi3(), addsi3() etc. patterns manually or should GCC figure those by itself ? Not sure I understand you. You always need to define movMM3 etc. GCC will correctly select between movhi3 and movsi3 based on your Pmode macro when handling pointers,