Andes Workshop

It is currently Thu Mar 28, 2024 11:11 pm

All times are UTC + 8 hours [ DST ]




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: 如何估算需要的stack大小?
PostPosted: Tue Nov 06, 2012 4:00 pm 
Offline
User avatar

Joined: Fri Mar 04, 2011 9:36 pm
Posts: 500
請問是否有方法可以去做使用SRAM 大小的估算(即程式運算過程中所需要用到最大的記憶體量)?

Ans: 沒有tool算,要請user自己處理
可以參考這一篇文章
http://www.heygotimes.com/ext/b2/index?ch=CH06_02
“確認Function Call可否正常運行” 這一段

(1) 以實測的方式來測試需要多少memory,在程式執行之前,
把所有memory填上FF,等到程式跑完之後,
還殘留FF的區域即是沒有用到的memory。

(2) 如果有uart的話。可以在每一個function裡印出$sp數值。
最後從輸出去找最大的$sp值。


Top
 Profile Send private message E-mail  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 12 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group