On 10 September 2007 08:55, Tomas Svensson wrote: > I am porting gcc to a new target architecture, and have come across a > problem when the make process tries to compile libgcc. The error I get > is included below. > > It seems that gcc has emitted rtl describing a memory reference (mem > (plus (mem (plus (reg ..) (const_int ..))) (const_int ..))), which > should not have been permitted by GO_IF_LEGITIMATE_ADDRESS since it > only allows (mem (plus (reg ..) (const ..))), and forbids a second > level of memory reference. > > I am (obviously) no gcc-expert by far, and have no idea how to tackle > this problem. Has anyone had a similar problem, or any pointers as to > how I can solve it?
Either step through in a debugger, or bung loads of printfs into G_I_L_A, and see what it does when it gets given a chance to forbid the bad RTL. You might also want to check that LEGITIMIZE_ADDRESS and even LEGITIMIZE_RELOAD_ADDRESS aren't doing anything unsane to it. cheers, DaveK -- Can't think of a witty .sigline today....