]> git.ipfire.org Git - thirdparty/LuaJIT.git/commitdiff
Fix lua_cpcall(). Duplicate save corrupted C frame chain.
authorMike Pall <mike>
Fri, 6 Aug 2010 12:34:54 +0000 (14:34 +0200)
committerMike Pall <mike>
Fri, 6 Aug 2010 12:34:54 +0000 (14:34 +0200)
src/buildvm_x64.h
src/buildvm_x64win.h
src/buildvm_x86.dasc
src/buildvm_x86.h

index 9962d4b053e7a089c5b0d68ff9521ce5490f6145..9672731d8a306ef4292e113fdc5c3896f3746701 100644 (file)
@@ -41,8 +41,8 @@ static const unsigned char build_actionlist[14080] = {
   139,90,252,252,137,68,36,4,252,247,195,237,15,132,244,13,255,252,233,244,
   14,248,25,85,83,65,87,65,86,72,131,252,236,40,187,237,137,76,36,20,252,233,
   244,247,248,26,85,83,65,87,65,86,72,131,252,236,40,187,237,248,1,137,84,36,
-  16,137,252,253,137,124,36,24,137,252,241,248,2,76,139,189,233,76,137,124,
-  36,32,137,108,36,28,72,137,165,233,68,139,181,233,65,129,198,239,248,3,65,
+  16,137,252,253,137,124,36,24,137,252,241,76,139,189,233,76,137,124,36,32,
+  137,108,36,28,72,137,165,233,248,2,68,139,181,233,65,129,198,239,248,3,65,
   199,134,233,237,139,149,233,1,203,41,211,139,133,233,41,200,193,232,3,131,
   192,1,248,27,255,139,105,252,248,129,121,253,252,252,239,15,133,244,28,248,
   29,137,202,137,90,252,252,139,157,233,139,11,15,182,252,233,15,182,205,131,
index eaefbe0b12f1436566f8d8501fffbba4141c6fe4..fbf233ad0e8cf3366113038d6ab2fdff1c532837 100644 (file)
@@ -40,8 +40,8 @@ static const unsigned char build_actionlist[14029] = {
   133,233,41,200,193,232,3,131,192,1,41,209,139,114,252,252,137,68,36,84,252,
   247,198,237,15,132,244,13,255,252,233,244,14,248,25,85,87,86,83,72,131,252,
   236,40,190,237,68,137,76,36,92,252,233,244,247,248,26,85,87,86,83,72,131,
-  252,236,40,190,237,248,1,68,137,68,36,88,137,205,137,76,36,96,137,209,248,
-  2,72,139,189,233,72,137,124,36,104,137,108,36,100,72,137,165,233,139,157,
+  252,236,40,190,237,248,1,68,137,68,36,88,137,205,137,76,36,96,137,209,72,
+  139,189,233,72,137,124,36,104,137,108,36,100,72,137,165,233,248,2,139,157,
   233,129,195,239,248,3,199,131,233,237,139,149,233,1,206,41,214,139,133,233,
   41,200,193,232,3,131,192,1,248,27,255,139,105,252,248,129,121,253,252,252,
   239,15,133,244,28,248,29,137,202,137,114,252,252,139,181,233,139,14,15,182,
index 493820b6138d85b5f51798fc2139f3aed9eef84d..f293cd2391a4025f23ff7c7cc319405bd235669c 100644 (file)
@@ -650,7 +650,6 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   |  mov RA, INARG_BASE                        // Caveat: overlaps SAVE_CFRAME!
   |.endif
   |
-  |2:  // Entry point for vm_cpcall below (RA = base, RB = L, PC = ftype).
   |  mov KBASEa, L:RB->cframe          // Add our C frame to cframe chain.
   |  mov SAVE_CFRAME, KBASEa
   |  mov SAVE_PC, L:RB                 // Any value outside of bytecode is ok.
@@ -660,6 +659,7 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   |  mov L:RB->cframe, esp
   |.endif
   |
+  |2:  // Entry point for vm_cpcall below (RA = base, RB = L, PC = ftype).
   |  mov DISPATCH, L:RB->glref         // Setup pointer to dispatch table.
   |  add DISPATCH, GG_G2DISP
   |
index e7f0da64173dc995ae5a54d8b03ed146fd5f4767..547cd0d26828c126ac1acffb9cd1497781f60707 100644 (file)
@@ -39,16 +39,16 @@ static const unsigned char build_actionlist[15234] = {
   133,233,41,200,193,232,3,131,192,1,41,209,139,114,252,252,137,68,36,20,252,
   247,198,237,15,132,244,13,255,252,233,244,14,248,25,85,87,86,83,131,252,236,
   28,190,237,252,233,244,247,248,26,85,87,86,83,131,252,236,28,190,237,248,
-  1,139,108,36,48,139,76,36,52,248,2,139,189,233,137,124,36,52,137,108,36,24,
-  137,165,233,139,157,233,129,195,239,248,3,199,131,233,237,139,149,233,1,206,
-  41,214,139,133,233,41,200,193,232,3,131,192,1,248,27,255,139,105,252,248,
-  129,121,253,252,252,239,15,133,244,28,248,29,137,202,137,114,252,252,139,
-  181,233,139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,171,248,30,
-  85,87,86,83,131,252,236,28,139,108,36,48,139,68,36,56,139,76,36,52,139,84,
-  36,60,137,108,36,24,139,189,233,43,189,233,199,68,36,60,0,0,0,0,137,124,36,
-  56,137,68,36,8,137,76,36,4,137,44,36,139,189,233,137,124,36,52,137,165,233,
-  252,255,210,133,192,15,132,244,15,137,193,190,237,252,233,244,2,248,11,1,
-  209,131,230,252,248,137,213,41,252,242,199,68,193,252,252,237,137,200,139,
+  1,139,108,36,48,139,76,36,52,139,189,233,137,124,36,52,137,108,36,24,137,
+  165,233,248,2,139,157,233,129,195,239,248,3,199,131,233,237,139,149,233,1,
+  206,41,214,139,133,233,41,200,193,232,3,131,192,1,248,27,255,139,105,252,
+  248,129,121,253,252,252,239,15,133,244,28,248,29,137,202,137,114,252,252,
+  139,181,233,139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,171,248,
+  30,85,87,86,83,131,252,236,28,139,108,36,48,139,68,36,56,139,76,36,52,139,
+  84,36,60,137,108,36,24,139,189,233,43,189,233,199,68,36,60,0,0,0,0,137,124,
+  36,56,137,68,36,8,137,76,36,4,137,44,36,139,189,233,137,124,36,52,137,165,
+  233,252,255,210,133,192,15,132,244,15,137,193,190,237,252,233,244,2,248,11,
+  1,209,131,230,252,248,137,213,41,252,242,199,68,193,252,252,237,137,200,139,
   117,252,244,139,77,252,240,139,122,252,248,139,191,233,139,191,233,252,255,
   225,248,31,255,15,182,78,252,255,131,252,237,16,141,12,202,41,252,233,15,
   132,244,32,252,247,217,193,252,233,3,137,76,36,8,139,72,4,139,0,137,77,4,