Analyze stack for MPC5604B with Codewarrior 2.7

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Analyze stack for MPC5604B with Codewarrior 2.7

ソリューションへジャンプ
1,359件の閲覧回数
MicroTang
Contributor III

Dear All,

 

I am using Freescale C/C++ Compiler for Embedded PowerPC (version 4.3 build 182) to build my project on MPC5604B. I can read stack information from MAP file, e.g..

 

_stack_addr 40003000

_stack_end  40002a00

 

Does it mean stack bottom is $40002a00 and stack pointer is initialized to 0x4000300? I checked my code, it seems that r1 is used to save stack pointer and the stack grows from high address to low address. Is it right? If there are any documents (notes, manual, guide, etc) describe more details about how does the compiler use the stack of MPC5604B?

 

Thanks in advance for your help!

 

Best Regards

Michael Tang

ラベル(1)
タグ(1)
0 件の賞賛
返信
1 解決策
1,090件の閲覧回数
stanish
NXP Employee
NXP Employee

Hi MicroTang,

 

You are right the register dedicated to stack pointer is r1 and stack grows downward from high addresses.

This is defined in PPC EABI specification available here:

 

http://www.freescale.com/files/32bit/doc/ref_manual/E500ABIUG.pdf

 

Stanish

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
1,091件の閲覧回数
stanish
NXP Employee
NXP Employee

Hi MicroTang,

 

You are right the register dedicated to stack pointer is r1 and stack grows downward from high addresses.

This is defined in PPC EABI specification available here:

 

http://www.freescale.com/files/32bit/doc/ref_manual/E500ABIUG.pdf

 

Stanish

0 件の賞賛
返信
1,090件の閲覧回数
MicroTang
Contributor III

Hello, Stanish

 

Thanks for your kindly help!

 

Best Regards

Michael

0 件の賞賛
返信