From: Joshua Lamorie Date: Tue, 16 Mar 2004 10:43:21 -0500 Subject: [U-Boot-Users] v2p4 porting troubles References: <009401c40b03$8800ae90$cb01a8c0@xiphos.ca> Message-ID: <004101c40b6d$69274aa0$cb01a8c0@xiphos.ca> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Gidday again, In further investigating this problem we have seen a pattern. The failure constantly occurs when the instruction is compiled as... stw rX,0(r0) where X is 1-31. We see that instead of writing the data to the address pointed to by r0, it writes the data to address 0x0 of physical memory (we have virtual memory disabled). When I look at the PowerPC Processor Reference Guide (pp. 80-82), it mentions that for the addressing modes Register-Indirect with Immediate Index, Register-Indirect with Index, and Register Indirect, if rA is set to 0 (refering also to r0) then an index of 0 is used instead of the value of r0. So if this is the problem, why is our compiler making code that does this? I'm new to PPC assembler, so perhaps I'm interpreting this incorrectly. Can you recommend a toolchain that would be better than the one we're currently using? (listed below) Thanks in advance. Joshua Lamorie Director of Brownian Motion Control Xiphos Technologies Inc. ----- Original Message ----- [snip] > The Linux tools compile... > > stw r9,0(r0) > > However, the LEDs respond with blankity nothingness. Using XMD, we swap > around these general purpose (according to how we read the docs) registers > (r8,r10, r1 etc.) , and sometimes it works and sometimes it doesn't. [snip] > We are using crosstools-0.26, with gcc-3.3-20040112 and glibc-2.3.2