[Tinyos-devel] stack depth checking
John Regehr
regehr at cs.utah.edu
Tue Apr 14 09:42:21 PDT 2009
Sure, I will add msp430 support, but it may take a few weeks before I can
get around to it. Less than a day of hacking should do it.
John
On Tue, 14 Apr 2009, Michiel Konstapel wrote:
> Incredibly useful tool, nice to have it integrated into the build
> system. If only it supported the MSP430... Would that be hard to add?
> I'd look into it, if I remembered where I put my stash of Copious Free
> Time (TM) ;)
> Michiel
>
> -----Original Message-----
> From: tinyos-devel-bounces at millennium.berkeley.edu
> [mailto:tinyos-devel-bounces at millennium.berkeley.edu] On Behalf Of John
> Regehr
> Sent: zaterdag 11 april 2009 1:02
> To: tinyos-devel at millennium.berkeley.edu
> Subject: [Tinyos-devel] stack depth checking
>
> I have checked a stack depth estimator into CVS.
>
> You can run it directly like this:
>
> tinyos-2.x/tools/tinyos/safe/tos-ramsize platform elf-file
>
> Alternatively, run "make install" in the tools directory and then invoke
>
> the stack checker from the makefile like this:
>
> make platform stack-check
>
> Example output is provided below. According to this estimate,
> MultihopOscilloscope on MicaZ has only 73 bytes of buffer space between
> the
> maximum stack depth and the static memory segments.
>
> Limitations (to be addressed soon, hopefully):
> - only AVR platforms supported
> - no documentation
> - TOSThreads not supported
>
> Feedback is appreciated.
>
> John Regehr
>
>
>
>
> [regehr at babel MultihopOscilloscope]$ make micaz stack-check
> mkdir -p build/micaz
> compiling MultihopOscilloscopeAppC to a micaz binary
> ncc -o build/micaz/main.exe -Os -fnesc-separator=__ -Wall -Wshadow
> -Wnesc-all -target=micaz -fnesc-cfile=build/micaz/app.c -board=micasb
> -DDEFINED_TOS_AM_GROUP=0x22 --param max-inline-insns-single=100000
> -I/home/regehr/z/tinyos-2.x/tos/lib/net/
> -I/home/regehr/z/tinyos-2.x/tos/lib/net/ctp
> -I/home/regehr/z/tinyos-2.x/tos/lib/net/4bitle
> -DIDENT_APPNAME=\"MultihopOscillo\" -DIDENT_USERNAME=\"regehr\"
> -DIDENT_HOSTNAME=\"babel\" -DIDENT_USERHASH=0xaa57ee96L
> -DIDENT_TIMESTAMP=0x49dfcce5L -DIDENT_UIDHASH=0xaf618fc1L
> -fnesc-dump=wiring -fnesc-dump='interfaces(!abstract())'
> -fnesc-dump='referenced(interfacedefs, components)'
> -fnesc-dumpfile=build/micaz/wiring-check.xml MultihopOscilloscopeAppC.nc
> -lm
> /home/regehr/z/tinyos-2.x/tos/chips/cc2420/lpl/DummyLplC.nc:39:2:
> warning:
> #warning "*** LOW POWER COMMUNICATIONS DISABLED ***"
>
> BSS segment size is 3421, data segment size is 24
> The upper bound on stack size is 578
> The upper bound on RAM usage is 4023
> There are 73 unused bytes of RAM
>
> compiled MultihopOscilloscopeAppC to build/micaz/main.exe
> 25458 bytes in ROM
> 3445 bytes in RAM
> avr-objcopy --output-target=srec build/micaz/main.exe
> build/micaz/main.srec
> avr-objcopy --output-target=ihex build/micaz/main.exe
> build/micaz/main.ihex
> writing TOS image
> [regehr at babel MultihopOscilloscope]$
>
> _______________________________________________
> Tinyos-devel mailing list
> Tinyos-devel at millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-deve
> l
>
More information about the Tinyos-devel
mailing list