mirror of
https://github.com/rtic-rs/rtic.git
synced 2024-11-23 20:22:51 +01:00
Merge #257
257: do not zero late resource memory on boot r=korken89 a=japaric this is done using the `.uninit` linker section; this optimization was already being applied to message buffers but I forgot to also apply it to late resources Co-authored-by: Jorge Aparicio <jorge@japaric.io>
This commit is contained in:
commit
7d2fa7014d
1 changed files with 10 additions and 2 deletions
|
@ -32,7 +32,11 @@ pub fn codegen(
|
|||
cross_initialized: false,
|
||||
} => (
|
||||
util::cfg_core(*core, app.args.cores),
|
||||
util::link_section("data", *core),
|
||||
if expr.is_none() {
|
||||
util::link_section_uninit(Some(*core))
|
||||
} else {
|
||||
util::link_section("data", *core)
|
||||
},
|
||||
),
|
||||
|
||||
// shared `static`s and cross-initialized resources need to be in `.shared` memory
|
||||
|
@ -42,7 +46,11 @@ pub fn codegen(
|
|||
} else {
|
||||
None
|
||||
},
|
||||
None,
|
||||
if expr.is_none() {
|
||||
util::link_section_uninit(None)
|
||||
} else {
|
||||
None
|
||||
},
|
||||
),
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue