The XIP SPI flash on Fomu is slow, which results in certain operations
taking a long time. This becomes a problem for time-critical operations
such as USB.
Move various calls into RAM to improve performance.
This includes the call to __modsi3 and __udivsi3 which are used by the
supervisor handler to determine if periodic callbacks need to be run.
This finishes fixing #3841
Signed-off-by: Sean Cross <sean@xobs.io>
The SPI flash on current Fomu firmware is slow. Circuitpython runs
XIP from SPI flash, and so execution time can also be slow. Ordinarily
this isn't a problem, however certain operations are time-sensitive.
In particular, USB function needs to be handled quickly in order to
prevent the host from re-enumerating the device.
Place several critical TinyUSB structures into RAM, as well as several
hot functions that are frequently called. This reduces execution time
at the expense of system memory, and greatly improves system stability.
Signed-off-by: Sean Cross <sean@xobs.io>