Comments (7)
Thanks for opening this issue! I'll take a look. Of course, PRs are more than welcome :)
from riscv-rt.
I’ll have a look at this. Is there a preference for a separate crate again or should it just become a part of the riscv-rt
crate?
from riscv-rt.
I prefer to reduce the number of dependencies, but if you find a handy crate that eases the work, then use it.
If I were you, I'd implement it in assembly.
from riscv-rt.
The conclusion when we deprecated r0
was that this can only soundly be implemented in assembly; cortex-m-rt does so here. I think it's best put into your existing startup routine (here).
from riscv-rt.
I see you feature-gate the RAM initialization. Would you recommend us to do the same for riscv-rt
?
from riscv-rt.
We can get some inspiration from the esp-hal
folks: https://github.com/esp-rs/esp-hal/blob/eeb2d1db6f8ffd250b212bd1bebaddc83d0ea8b0/esp-riscv-rt/src/lib.rs#L294C8-L294C8
from riscv-rt.
I see you feature-gate the RAM initialization. Would you recommend us to do the same for
riscv-rt
?
That was a later addition from users with MCUs that have things like ECC RAM where you have to write to the entire RAM at startup to initialise the memory controller; usually it's enough to just initialise the .data and .bss sections and leave unused RAM alone. Since there's a startup time cost, it made sense to feature-gate this just for users who need it.
I think you could reasonably support the same feature, but just doing .data and .bss is enough for almost all use cases.
from riscv-rt.
Related Issues (20)
- Support for lld HOT 2
- Build on stable
- rust produces a 2.1G executable HOT 7
- build using -mcmodel = medany HOT 18
- Implement multi-core support
- Bizarre warning behavior around #[entry] macro and `&mut FnMut`
- LiteX/VexRiscv support HOT 4
- Execution start address varies. HOT 3
- Update r0 to 1.0 HOT 1
- Relocation R_RISCV_ALIGN linker error
- ELF output contains lots of zero data: linker script issue? HOT 4
- RAM init code violates pointer provenance and aliasing rules HOT 1
- Migration to GitHub Actions HOT 1
- sp may not be aligned to 16 bytes
- Lots of rust-lld errors HOT 3
- New crates.io release HOT 4
- Accessing parameters passed in register by the previous boot stage HOT 8
- Doesn't compile with the latest nightly toolchain. HOT 4
- asm: Startup code traps into an illegal instruction
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from riscv-rt.