You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
_defmt_acquire is defined in defmt-rtt. My guess is that _defmt_acquire gets inlined in the export::acquire BUT a full copy of it stays around because it has both #[no_mangle] on it and we have EXTERN(_defmt_acquire) in the defmt.x linker script.
Unsure how to fix. I wouldn't expect EXTERN to act like KEEP (LLD issue?). Removing EXTERN is likely to cause linker errors in some cases.
I think this issue also applies to other _defmt_* symbols but haven't checked
The text was updated successfully, but these errors were encountered:
(Marking export::acquire inline(never), as it is right now, does seems odd. _defmt_acquire is the "binary interface" and that's what should be kept around as a symbol so marking that one inline(never) makes more sense)
587: tweak inline attributes to remove machine code duplication r=jonas-schievink a=japaric
fixes#586 and saves 140 bytes of Flash in the example (repro case) given therein
Co-authored-by: Jorge Aparicio <jorge.aparicio@ferrous-systems.com>
Steps to reproduce
Start from app-template, configure it to use the
main
branch ofdefmt
then modifyhello
to look like thisAbove
_defmt_acquire
anddefmt::export::acquire
are exact duplicates.defmt::export::acquire
is defined like this:_defmt_acquire
is defined indefmt-rtt
. My guess is that_defmt_acquire
gets inlined in theexport::acquire
BUT a full copy of it stays around because it has both#[no_mangle]
on it and we haveEXTERN(_defmt_acquire)
in thedefmt.x
linker script.Unsure how to fix. I wouldn't expect
EXTERN
to act likeKEEP
(LLD issue?). RemovingEXTERN
is likely to cause linker errors in some cases.I think this issue also applies to other
_defmt_*
symbols but haven't checkedThe text was updated successfully, but these errors were encountered: