GithubHelp home page GithubHelp logo

Comments (4)

japaric avatar japaric commented on September 26, 2024 1

even while it still runs

I would be against this particular variant. Polling a second memory block can easily halve the throughput of the log stream data and probe-rs's RTT implementation is already rather slow.

It is currently unclear how this interacts with program that use the heap.

I don't think there are strong guidelines but either a chunk of .bss memory will be used as the heap or the .heap section defined in cortex-m-rt will be sized accordingly and the whole section will be passed to the memory allocator.


Related feature: optionally we can "paint" all the potential stack memory with a known pattern and once the program has finished we look for the "watermark" level and report the max stack usage for this particular program run.

from probe-run.

jonas-schievink avatar jonas-schievink commented on September 26, 2024

It seems that c-m-rt places the heap start symbol __sheap right after .uninit in RAM, but not inside any section:

https://github.com/rust-embedded/cortex-m-rt/blob/3ce46b3c19158cb9be4f9d2a3c00d5723e62ded5/link.x.in#L139-L141

That means there's no section we can use to detect presence of a heap. Can we detect whether the symbol was referenced by looking for it in the ELF file or will it always be there?

from probe-run.

jonas-schievink avatar jonas-schievink commented on September 26, 2024

I guess for compatibility with other runtimes we could look for any symbol that points to the first address after .uninit. There shouldn't be any reason to refer to that address unless you use a heap.

from probe-run.

jonas-schievink avatar jonas-schievink commented on September 26, 2024

Looks like __sheap is always present even when it's not used by anything :/

from probe-run.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.