Maximising workspace on the ESP32


#1

The first release of uLisp for the ESP8266/ESP32, version 2.4, gives 4096 objects of workspace and a virtual EEPROM size of 4096 bytes, or 512 objects:

  #define WORKSPACESIZE 4096-SDSIZE
  #define EEPROMSIZE 4096

However, after experimenting with different memory settings I’ve found that it’s possible to increase these to 8000 objects and 8192 bytes respectively:

#define WORKSPACESIZE 8000-SDSIZE
#define EEPROMSIZE 8192

I propose to make these the new default settings for the ESP32 in the next release of ESP8266/ESP32 uLisp, unless anyone encounters any problems with these settings.

Increasing WORKSPACESIZE above 8192 objects causes uLisp to crash on startup, which seems curious as the ESP32 nominally has 520 kbytes of memory available, and 8192 objects is just 64 kbytes. Can anyone suggest how to allocate more of this memory to the workspace?