Jump to content

Recommended Posts

With PIC16 you cant. The stack is only seven deep and is totally inaccesable. The best you can do is to reduce the function call depth. NB using interrupts takes up one stack slot, calling functions in interrupts will take up more. Sourceboost has inbuilt (hidden) functions such as when you access an array in ROM or use the * / and % operators.

 

Hello,

I am a new user of boostC and my first application generates a stack overflow at run time. At linking time i had the message "target call stack depth of 8 may be exceeded". how do i deal with bigger depth ?

Thanks for help

Philippe

Link to post
Share on other sites

Philippe,

"target call stack depth of 8 may be exceeded". how do i deal with bigger depth ?
If you are using BoostC V6.50 or later you can use the linker option -swcs (software call stack). Checkout -swcs option in the boost reference manual.

 

This allows a call depth > than the stack size of the processor. Each additional call depth greater than the hardware stack does use an extra byte of RAM, and the code becomes slightly larger.

 

Regards

Dave

Link to post
Share on other sites

Hello Dave,

Thank you. I have reduced "code depth" by now because i have version 6.40

I will update to 6.50

Philippe

Philippe,
"target call stack depth of 8 may be exceeded". how do i deal with bigger depth ?
If you are using BoostC V6.50 or later you can use the linker option -swcs (software call stack). Checkout -swcs option in the boost reference manual.

 

This allows a call depth > than the stack size of the processor. Each additional call depth greater than the hardware stack does use an extra byte of RAM, and the code becomes slightly larger.

 

Regards

Dave

Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...