Feature Request: Ability to exclude settings-only strings from app runtime resources

TL;DR If you load even one resource at run-time, then the entire resource index is loaded, including all your settings strings that the app doesn't need. This wastes a lot of memory that could make our apps more useful to end users.

--

This is something I mentioned over a year ago, and I promise this is the last time I'll bring it up, in case it isn't feasible or practical.

Apparently, if an app (e.g. data field) loads at least one resource at run-time (e.g. string, font, json data), then the entire resource table index (but not contents) is permanently loaded into memory, including Rez_Strings.

This is somewhat understandable, except that for apps which have a lot of settings, there are going to be a lot of settings strings. But 99% of the time, an app does not need any of those strings at run-time.

For example, I have a data field app which happens to have lots of settings. In all, I have about 88 settings strings, which seem to consume 984 bytes of global memory in Rez_Strings, according to the simulator memory viewer.

It's a shame to think of some of the useful features that my app only supports for 645M, Fenix 5 Plus, etc., which seemingly could've easily been added for 935, Fenix 5, 735XT, etc, if only those 984 bytes of memory had been free.

Unless I am missing something, my app does not need those strings at all, during run-time. Only the Garmin app store needs those strings, so it can push them to GC Express / GC Mobile which will display the settings to the user. Somewhat analogously, I would not expect the contents of the <fitContributions> element to take up run-time memory, since the app doesn't care about that stuff.

Therefore, I would like to propose the following two feature requests:
1) Ability to exclude settings-only strings from run-time resources. Maybe settings-only strings can have a different parent element, like <settings-strings>
2) Ability to unload resource table at run-time


As I mentioned before, sometimes you only need resources at init time. And sometimes your app consumes more memory at run-time than at init-time (e.g. because you have loaded resources). Therefore, it would be very useful to be able to unload the resource table, which could reduce your peak memory consumption and possibly allow you to include more code in your app. But I can understand why this may never happen, especially for older devices.

OTOH, I think 1) could be implemented without even updating the firmware/VM on the device. CIQ2 devices could instantly become more useful to devs and users.

Thanks for reading.

EDIT: Removing some strings from the resource file also seems to reduce the application code and data usage, so it seems like the impact is even more significant.