-
Notifications
You must be signed in to change notification settings - Fork 6.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
usb: device: next: increased RAM and flash footprint with "device_next" USB stack #83309
Comments
These are the numbers when building the same sample with logging disabled:
|
Numbers for the
|
@henrikbrixandersen @jfischer-no Some number crunching on the frdm_k64f. First thing I did was to add to the usbd_next_prj.conf CONFIG_INPUT_MODE_SYNCHRONOUS so that it is in alignment with the default prj.confg. It caused some minor differences that initially confused me. Key differences between new and legacy:
Overall, on the frdm_k64, the new model .text/.rodata is +11609 and .data/.bss is +3168. Attached are the spreadsheets I generated for the two target builds for your pleasure and digging. |
Is your enhancement proposal related to a problem? Please describe.
The
device_next
USB stack comes with a significant increase in both RAM and flash footprint compared to the "legacy" stack. The impact is especially hard on smaller USB MCUs with e.g. 16k RAM and 64k flash (smaller STM32 parts) where the increase can prevent existing firmware applications from switching to the new stack.Describe the solution you'd like
While the design and implementation of the
device_next
is much superior to the "legacy" stack, it would be nice if the RAM and flash footprint could be reduced to be more friendly towards more resource constrained MCUs.Describe alternatives you've considered
None.
Additional context
As an example, the
samples/subsys/usb/hid-mouse/
sample compiled for thefrdm_k64f
board increases significantly in RAM and flash footprint when built for thedevice_next
stack, but the problem is not limited to this sample/board.The text was updated successfully, but these errors were encountered: