GithubHelp home page GithubHelp logo

Comments (2)

japaric avatar japaric commented on September 26, 2024

This sounds like a good idea to me. I think we may only be able to implement this in a "best effort" manner though rather than as something with 100% accuracy.

Impl notes from the top of my head:

  1. look into the core_type field of this probe_rs::Target

    let target = probe_rs::config::registry::get_target_by_name(chip)?;

  2. try to extract the compilation target (e.g. thumbv6m-none-eabi) from this path. Note that probe-run can be invoked like this: probe-run ./my-elf; in that case there's no target information in the path (the None case)

    let elf_path = opts.elf.as_deref().unwrap();

  3. compare (1) and (2) and emit a suggestion or not

    • for M0, target MUST be thumbv6m-none-eabi
    • for M3, target SHOULD be thumbv7m-none-eabi
    • for M4 and M7, target SHOULD be thumbv7em-none-eabi. (thumbv7em-none-eabihf may also be OK but probe-rs has no information about FPU support)
    • for Riscv, I don't think we can give any suggestion as we don't have any info about instruction set support from probe-rs (I vs IMAC vs IMC)

from probe-run.

Urhengulas avatar Urhengulas commented on September 26, 2024

Which compilation should it be in case of CoreType::Armv8m which is Cortex M23 M33?
In the "Platform Support" (link) list I can find thumbv8m.base-none-eabi, thumbv8m.main-none-eabi and thumbv8m.main-none-eabihf. Can it be any of them?

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.