I ran out of ram (actually I think I am out of stack) so in my pursuit to get stuff out of iram1 I found I can store bytes in irom0
if I only access them as words so I've updated frozen.py to convert strings into 32 bit word arrays that I store in irom0 with the linker command file and simply unpacking them when I read them at run time. (I have also hooked tokenize into the frozen builder to strip out all the comments).
I may be misreading the spec sheet for the flash that is on the quad SPI but as far as I can tell it's 4MByte (not 4MBit)!
According the the code I should be able to run the lexer in as in py/lexerstr.c on the code as I stream it out of the rom as words with the str_buf_next_byte callback.
ESP8266 Frozen modules in irom0 !
Re: ESP8266 Frozen modules in irom0 !
And reporting that it all works. Kudos to the guys, the simple 'mp_lexer_new' callback with a context interface make it quite simple to lex and run python.