= Stack Analysis = [[TOC(Developer/Projects/Open/StackAnalysis, depth=2)]] '''Mentors:''' Joel Sherrill '''Students:''' Past, Present, and Potential Students '''Status:''' Uninitiated. '''Introduction:''' Develop a tool for static analysis of stack usage. GCC can produce a ".su" file when used with the -fstack-use option. [http://www.gnu.org/software/cflow/ cflow] can be used to produce the control flow to analyze a call stack. The goal of this analysis is for a user to be able to specify a user thread entry point and see the stack usage for each method that thread calls as well as a total usage. This should include application code, RTEMS, and newlib. The scripting will be in Python. cflow will need to be added as an RSB recipe. There may be other approaches to solving this problem. At least one is listed in the references. We are looking for a long-term solution which is as target architecture independent as possible and can be used on user applications. '''Goal:''' Concise statement of the overall goal of the project. Refine this initial statement to include: project deliverables (code, docs, testing), required/suggested methodology, standards of quality, possible goal extensions beyond the main objective. '''Requirements:''' List the requirements and level of expertise you estimate are required by the developer tackling this project will have to have: Required level of programming language(s), specific areas of RTEMS or tools, level of familiarity with RTEMS, cross-development, GNU/Linux, etx., development/documentation/testing tools, mathematical/algorithmic background, other desirable skills. '''Resources:''' Current RTEMS developers, papers, etc that may help you in this project. '''Acknowledgements''' * who helped and did work = Miscellaneous Sections = As the project progresses, you will need to add build instructions, etc and this page will evolve from a project description into a HOWTO. = References = * [http://www.gnu.org/software/cflow/ cflow] * [http://stackoverflow.com/questions/6387614/how-to-determine-maximum-stack-usage-in-embedded-system-with-gcc Stack Overflow discussion] * [http://www.kegel.com/stackcheck/ Sure-Fire Stack Reduction Program] presents an overview of the topic along with a Perl script to analyze single method usage by analyzing object dumps * [http://tinyos.stanford.edu/tinyos-wiki/index.php/Stack_Analysis Tool for AVR] '''Other sections:''' If you have more to say about the project that doesn't fit in the proposed sections of this template, feel free to add other sections at will.