Problem using Lauterbach Debugger with GCC-ARM

Kanwal Preet Singh CHANANA kanwalpreet.singh@st.com
Tue Aug 29 10:25:00 GMT 2006


Hi Vinayak,

Thanks for replying. Now I am able to stop at Image Entry_point but I have to do hardware reset inplace of InTarget Reset option under CPU menu in Trace32 everytime. If I do Intarget Reset, then Trace32 shows wrong Image contents of Flash as well as ROM.

The CMM file which I am using is :-

B::
 TOOLBAR ON
 STATUSBAR ON
 WINPAGE.RESET
 WINCLEAR
 reset
 sys.reset

 sys.o.cflush off
 sys.o.turbo off
 sys.o.enreset off
 setup.imaskasm on
 setup.imaskhll on

 sys.up
 d.load.elf .\Image.out 
 do symbols.cmm
 d.l
 map.bonchip 0x1000000++0x10FFFFF
 b.s Entry_point
sys.up
go

Note: "Image.out" is build using arm-elf-ld.

One more question, what does "/gcc3" indicate in ur CMM file?

Regards,
Kanwal

-----Original Message-----
From: Vinayak Bhalkar [mailto:vinayakbhalkar@Math.net] 
Sent: Tuesday, August 29, 2006 2:51 PM
To: kanwalpreet.singh@st.com
Cc: kraj@mvista.com; gcc-help@gcc.gnu.org; crossgcc@sources.redhat.com
Subject: RE: Problem using Lauterbach Debugger with GCC-ARM


I am using the ARM-GCC toolchain and debugging with Trace-32. Following is the CMM file i am using-

global &board
&board="MCO_ISSUE4"

local &fname
entry &fname

if ("&fname"=="")
  &fname="SampleApplication.elf"

;Setup memory

sys.d
sys.u
r.res
d.s SR:0xFFE00000 %LE %LONG 0x580030A5 ; Setup CS0 to 2 MB flash
d.s SR:0xFFE00004 %LE %LONG 0x480030A5 ; Setup CS1 to 2 MB debug ram
d.s SR:0xFFE00008 %LE %LONG 0x47F03001 ; Setup CS2 to ram
d.s SR:0xFFE0000C %LE %LONG 0x600030A5 ; Setup CS3 to 2 MB secound flash
d.s SR:0xFFE00020 %LE %LONG 0x00000001 ; Enable remap
d.load.elf &fname /gcc3

Regards,
Vinayak

--- kanwalpreet.singh@st.com wrote:

From: Kanwal Preet Singh CHANANA <kanwalpreet.singh@st.com>
To: "'Khem Raj'" <kraj@mvista.com>
Cc: <gcc-help@gcc.gnu.org>, <crossgcc@sources.redhat.com>
Subject: RE: Problem using Lauterbach Debugger with GCC-ARM
Date: Tue, 29 Aug 2006 09:58:29 +0530

Hi,

Khem Raj said the following on 8/28/2006 10:45 AM:
>hmmm jumping from ADS 1.2 to GCC 4 has some ABI differences for ARM 
>binaries. The ABI has changed so you might see these kind of issues. 
>Read about ARM
>EABI from ARM's website. Secondly have you verified that your 
>application works with ARM RCVT or ARM RVDS?

Thanks for valuable suggestions. I know that there are EABI differences between ADSv1.2 & GCC-ARM v4.0.3. 
Secondly, my application is working fine with ADS1.2 & RVDS2.2 with some minor changes in Assembly files related to directives and new Linker script file compatible with ADS & RVDS.

>This may be due to the special thumb symbol types or the mapping symbols 
>used in ARM ADS that  Lauterbach debugger relies on.
>You might want to ask Lauterbach if they support GNU ARM tools.

GCC-ARM doesnot generate the Thumb and ARM mapping symbols used by Lauterbach. I have checked my map file to certify that section addresses are correct according to linker script file.
  
On Lauterbach website, they mention that they support GNU-ARM tool chain but no information is given with respect to configuration files.  

Have anyone used Lauterbach with GCC-ARM? If yes, please send me the batch file(*.cmm) used for debugging.

Regards,
Kanwal



-----Original Message-----
From: Khem Raj [mailto:kraj@mvista.com] 
Sent: Monday, August 28, 2006 10:45 PM
To: Kanwal Preet Singh CHANANA
Cc: gcc-help@gcc.gnu.org; crossgcc@sources.redhat.com
Subject: Re: Problem using Lauterbach Debugger with GCC-ARM




Kanwal Preet Singh CHANANA said the following on 8/28/2006 3:32 AM:
> Hi all,
>
> I am porting my project from ADS1.2 to GCC-ARM v4.0.3.
>
> Initally, I had to do some changes in assembly files as Assembly 
> directives in ADS are different from GCC-ARM
> e.g In ADS we can use "CODE32" directive to represent ARM code but in GCC-Arm,we have to use ".code32" . 
>
> Then I have to change the image section load script file due to 
> differences in format used by ADS & GCC-ARM.
>
> Now I am able to complile & link my sources & obtain a flash.axf 
> (image file) but the image is not working on target.
>   
hmmm jumping from ADS 1.2 to GCC 4 has some ABI differences for ARM 
binaries. The ABI has changed so you might see these kind of issues. 
Read about ARM
EABI from ARM's website. Secondly have you verified that your 
application works with ARM RCVT or ARM RVDS?
> I am using Lauterbach Debugger for debug purpose. With ADS images, 
> Lauterbach successfully works but with GCC-ARM image, it fails to work e.g.
> 1)  I am not able to Setup Breakpoints.  
> 2)  Lauterbach still jumps by offset of 4 bytes instead of 2 bytes in Thumb code.
>   
This may be due to the special thumb symbol types or the mapping symbols 
used in ARM ADS that  Lauterbach debugger relies on.
You might want to ask Lauterbach if they support GNU ARM tools.
> If anybody wants, I can send my build configurations as well as 
> Lauterbach batch file. I have asked for help on this issue earlier 
> also but nobody replied.Please help me out.
>
> Can anybody suggest me a workaround to debug GCC-ARM image using 
> Lauterbach? Can anybody suggest a way by which I can link absolute 
> symbols contained in object file (symbols.o) with my sources using 
> GCC-ARM?
>
> Regards,
> Kanwal
>
>
> --
> For unsubscribe information see http://sourceware.org/lists.html#faq
>
>   

-- 
Khem Raj <kraj@mvista.com>
MontaVista Software Inc.



_____________________________________________________________
Get your free web-based e-mail account from http://www.Math.net
Your online tourguide of Mathematics, with books, links, news,
message boards, and much more!


--
For unsubscribe information see http://sourceware.org/lists.html#faq



More information about the crossgcc mailing list