View Single Post
11/20/17, 01:29 PM   #11
Uesp
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 15
So with some more digging I have some answers but more questions. I'm not entirely sure the issue is due to the overflow of the constant table but may be related to it somehow.

The following assumes a minimal saved variable file with N entries of true as used previously.
  • Eso (64 bit if it matters) repeatably corrupts data after 131065 entries.
  • Command line Lua 5.1 and 5.2 have no problem loading files larger than 131065 entries.
  • Using "luac" on the file with 131065 entries shows that the constant table is only 131072 in size.
  • Increasing the size up to 262136 works fine with command line 'luac'. Past that it aborts with a "constant table overflow" error message. This works out to the expected 2^18 limit (or exactly 2^18-1).
  • Eso crashes to the desktop when trying to load a file with 262150 entries (it seems to save it fine).

So there's 2 probably related issues here:
  1. Crash due to exceeding the 2^18 constants.
  2. Data corruption starting around 2^17 constants (maybe, still exactly unsure of the trigger).

Hopefully the crash can be avoided by adding some error checking and the cause of the data corruption still need to be confirmed.