Skip to content

Commit

Permalink
CogVM source as per VMMaker.oscog-eem.3168
Browse files Browse the repository at this point in the history
CogARMv8Compiler: add logging of which lines set or clear executability via
pthread_jit_write_protect_np.  Hence find that Cogit>>freeUnmarkedMachineCode
was not enabling executability.

StackToRegisterMappingCogit: Fix assert failures on first pass of
embedded block compilations.
  • Loading branch information
eliotmiranda committed Feb 23, 2022
1 parent f659405 commit f2dc60a
Show file tree
Hide file tree
Showing 24 changed files with 1,806 additions and 491 deletions.
2 changes: 1 addition & 1 deletion src/spur32.cog.lowcode/cogit.h
@@ -1,5 +1,5 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/


Expand Down
14 changes: 10 additions & 4 deletions src/spur32.cog.lowcode/cogitARMv5.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
from
StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526 " __DATE__ ;
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -12210,6 +12210,10 @@ freeUnmarkedMachineCode(void)
if (freedMethod) {
unlinkSendsToFree();
}
/* begin ensureExecutableCodeZone */
# if !DUAL_MAPPED_CODE_ZONE

# endif
}


Expand Down Expand Up @@ -45886,7 +45890,9 @@ mergeWithFixupIfRequired(BytecodeFixup *fixup)
&& (simSpillBase > methodOrBlockNumArgs)));
if (needsFrame
&& (simSpillBase > 0)) {
assert((((simStackAt(simSpillBase - 1))->spilled)) == 1);
assert(((((simStackAt(simSpillBase - 1))->spilled)) == 1)
|| ((maybeCompilingFirstPassOfBlockWithInitialPushNil())
&& (simSpillBase > methodOrBlockNumArgs)));
assert((simSpillBase > simStackPtr)
|| ((((simStackAt(simSpillBase))->spilled)) == 0));
}
Expand Down
14 changes: 10 additions & 4 deletions src/spur32.cog.lowcode/cogitIA32.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
from
StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526 " __DATE__ ;
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -11988,6 +11988,10 @@ freeUnmarkedMachineCode(void)
if (freedMethod) {
unlinkSendsToFree();
}
/* begin ensureExecutableCodeZone */
# if !DUAL_MAPPED_CODE_ZONE

# endif
}


Expand Down Expand Up @@ -42537,7 +42541,9 @@ mergeWithFixupIfRequired(BytecodeFixup *fixup)
&& (simSpillBase > methodOrBlockNumArgs)));
if (needsFrame
&& (simSpillBase > 0)) {
assert((((simStackAt(simSpillBase - 1))->spilled)) == 1);
assert(((((simStackAt(simSpillBase - 1))->spilled)) == 1)
|| ((maybeCompilingFirstPassOfBlockWithInitialPushNil())
&& (simSpillBase > methodOrBlockNumArgs)));
assert((simSpillBase > simStackPtr)
|| ((((simStackAt(simSpillBase))->spilled)) == 0));
}
Expand Down
2 changes: 1 addition & 1 deletion src/spur32.cog/cogit.h
@@ -1,5 +1,5 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/


Expand Down
14 changes: 10 additions & 4 deletions src/spur32.cog/cogitARMv5.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
from
StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526 " __DATE__ ;
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -11758,6 +11758,10 @@ freeUnmarkedMachineCode(void)
if (freedMethod) {
unlinkSendsToFree();
}
/* begin ensureExecutableCodeZone */
# if !DUAL_MAPPED_CODE_ZONE

# endif
}


Expand Down Expand Up @@ -32647,7 +32651,9 @@ mergeWithFixupIfRequired(BytecodeFixup *fixup)
&& (simSpillBase > methodOrBlockNumArgs)));
if (needsFrame
&& (simSpillBase > 0)) {
assert((((simStackAt(simSpillBase - 1))->spilled)) == 1);
assert(((((simStackAt(simSpillBase - 1))->spilled)) == 1)
|| ((maybeCompilingFirstPassOfBlockWithInitialPushNil())
&& (simSpillBase > methodOrBlockNumArgs)));
assert((simSpillBase > simStackPtr)
|| ((((simStackAt(simSpillBase))->spilled)) == 0));
}
Expand Down
14 changes: 10 additions & 4 deletions src/spur32.cog/cogitIA32.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
from
StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526 " __DATE__ ;
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -11403,6 +11403,10 @@ freeUnmarkedMachineCode(void)
if (freedMethod) {
unlinkSendsToFree();
}
/* begin ensureExecutableCodeZone */
# if !DUAL_MAPPED_CODE_ZONE

# endif
}


Expand Down Expand Up @@ -30009,7 +30013,9 @@ mergeWithFixupIfRequired(BytecodeFixup *fixup)
&& (simSpillBase > methodOrBlockNumArgs)));
if (needsFrame
&& (simSpillBase > 0)) {
assert((((simStackAt(simSpillBase - 1))->spilled)) == 1);
assert(((((simStackAt(simSpillBase - 1))->spilled)) == 1)
|| ((maybeCompilingFirstPassOfBlockWithInitialPushNil())
&& (simSpillBase > methodOrBlockNumArgs)));
assert((simSpillBase > simStackPtr)
|| ((((simStackAt(simSpillBase))->spilled)) == 0));
}
Expand Down
2 changes: 1 addition & 1 deletion src/spur32.sista/cogit.h
@@ -1,5 +1,5 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/


Expand Down
14 changes: 10 additions & 4 deletions src/spur32.sista/cogitARMv5.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
from
SistaCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
SistaCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/
static char __buildInfo[] = "SistaCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526 " __DATE__ ;
static char __buildInfo[] = "SistaCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -11920,6 +11920,10 @@ freeUnmarkedMachineCode(void)
if (freedMethod) {
unlinkSendsToFree();
}
/* begin ensureExecutableCodeZone */
# if !DUAL_MAPPED_CODE_ZONE

# endif
}


Expand Down Expand Up @@ -38917,7 +38921,9 @@ mergeWithFixupIfRequired(BytecodeFixup *fixup)
&& (simSpillBase > methodOrBlockNumArgs)));
if (needsFrame
&& (simSpillBase > 0)) {
assert((((simStackAt(simSpillBase - 1))->spilled)) == 1);
assert(((((simStackAt(simSpillBase - 1))->spilled)) == 1)
|| ((maybeCompilingFirstPassOfBlockWithInitialPushNil())
&& (simSpillBase > methodOrBlockNumArgs)));
assert((simSpillBase > simStackPtr)
|| ((((simStackAt(simSpillBase))->spilled)) == 0));
}
Expand Down
14 changes: 10 additions & 4 deletions src/spur32.sista/cogitIA32.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
from
SistaCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
SistaCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/
static char __buildInfo[] = "SistaCogit VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526 " __DATE__ ;
static char __buildInfo[] = "SistaCogit VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -11563,6 +11563,10 @@ freeUnmarkedMachineCode(void)
if (freedMethod) {
unlinkSendsToFree();
}
/* begin ensureExecutableCodeZone */
# if !DUAL_MAPPED_CODE_ZONE

# endif
}


Expand Down Expand Up @@ -35920,7 +35924,9 @@ mergeWithFixupIfRequired(BytecodeFixup *fixup)
&& (simSpillBase > methodOrBlockNumArgs)));
if (needsFrame
&& (simSpillBase > 0)) {
assert((((simStackAt(simSpillBase - 1))->spilled)) == 1);
assert(((((simStackAt(simSpillBase - 1))->spilled)) == 1)
|| ((maybeCompilingFirstPassOfBlockWithInitialPushNil())
&& (simSpillBase > methodOrBlockNumArgs)));
assert((simSpillBase > simStackPtr)
|| ((((simStackAt(simSpillBase))->spilled)) == 0));
}
Expand Down
2 changes: 1 addition & 1 deletion src/spur64.cog.lowcode/cogit.h
@@ -1,5 +1,5 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.3166 uuid: bda1c176-bedf-4490-bb95-90d3851c1526
CCodeGenerator VMMaker.oscog-eem.3168 uuid: a0f1436f-0a54-429c-a61e-271ce020741a
*/


Expand Down

0 comments on commit f2dc60a

Please sign in to comment.