lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Am Mo., 31. Juli 2023 um 10:58 Uhr schrieb Bogdan Marinescu
<bogdan.marinescu@gmail.com>:
> I never thought about that, because I thought that internal alignment is preserved by default. Apparently things just worked, which admittedly is quite rare :)

If I want to load a binary Lua code from Flash-ROM, and I want to keep
all the Code in ROM, do you estimate that this could be done with
"minor changes" in lundump.c, e. g. mainly in the static function
LoadStringN of this c file? So then I would need a "pimped up" TString
object, which supports the possibility that this constant code string
is kept in Flash-ROM and TString mainly only saves the Flash ROM
pointer?

Or would such a modification be much more elaborate? (how many Lua
code line changes do you estimate? More "< 100" or more "> 1000" :) ?