Skip to content

Commit 5a646cd

Browse files
committed
Increase TCG_MAX_TEMPS from 512 to 1024.
The MIPS emulator crashes during boot because tcg runs out of temps. Increasing TCG_MAX_TEMPS allows the MIPS emulator to boot completely. The public version of qemu seems to have TCG_MAX_TEMPS set to 2048, so increasing this value in our qemu branch seems reasonable. I tried increasing to 768, but that just allowed the boot process to get farther before crashing. I tested the x86 qemu (on Windows) to see if the additional temps increased the emulator's memory usage. I did not see any change in memory usage. The x86 memory usage is very close to the public version of the emulator. With 1024 temps, the MIPS qemu seems to use slightly more than the public version of the MIPS emulator. Since the emulator won't boot without the increased temps, I can't tell if the additional memory is caused by the increased temps or something else that has changed since the last public release. Change-Id: I33a78f1111fa769c5f79f46e21acdd08bfa11898
1 parent 6a7d588 commit 5a646cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tcg/tcg.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ typedef struct TCGPool {
164164

165165
#define TCG_MAX_LABELS 512
166166

167-
#define TCG_MAX_TEMPS 512
167+
#define TCG_MAX_TEMPS 1024
168168

169169
/* when the size of the arguments of a called function is smaller than
170170
this value, they are statically allocated in the TB stack frame */

0 commit comments

Comments
 (0)