Skip to content

[RyuJIT/ARM32] CoreRT failed with assert in Object::ValidateInner !CREATE_CHECK_STRING(pMT && pMT->Validate()) #8892

@sergign60

Description

@sergign60

create_arm_env.zip

To reproduce this you need to clone the latest coreclr, corefx, corert, build all of them for armel (tizen), create runtime environment with the (edited) script from the attachment, push it to a device and execute the following commands:

cd env_dir
export COMPlus_AltJit=*
./corerun ilc.dll --verbose  @Hello.ilc.rsp

needed jit diffs

diff --git a/src/jit/compiler.cpp b/src/jit/compiler.cpp
index 552a6dff9..008966b8b 100644
--- a/src/jit/compiler.cpp
+++ b/src/jit/compiler.cpp
@@ -2738,6 +2738,15 @@ void Compiler::compInitOptions(JitFlags* jitFlags)
     }
 
 #ifdef ALT_JIT
+
+#ifdef _TARGET_ARM_
+    if (IsTargetAbi(CORINFO_CORERT_ABI))
+      {
+        opts.altJit = true;
+        // altJitVal = "*";
+      }
+#endif
+
     if (pfAltJit->contains(info.compMethodName, info.compClassName, &info.compMethodInfo->args))
     {
         opts.altJit = true;
@@ -2763,6 +2772,15 @@ void Compiler::compInitOptions(JitFlags* jitFlags)
     }
 
 #ifdef ALT_JIT
+
+#ifdef _TARGET_ARM_
+    if (IsTargetAbi(CORINFO_CORERT_ABI))
+    {
+        opts.altJit = true;
+        altJitVal = "*";
+    }
+#endif
+
     // In release mode, you either get all methods or no methods. You must use "*" as the parameter, or we ignore it.
     // You don't get to give a regular expression of methods to match.
     // (Partially, this is because we haven't computed and stored the method and class name except in debug, and it

Also you probably may need to turn off jit version control in CoreRT

diff --git a/src/Native/jitinterface/jitwrapper.cpp b/src/Native/jitinterface/jitwrapper.cpp
index ec926d46..a66279af 100644
--- a/src/Native/jitinterface/jitwrapper.cpp
+++ b/src/Native/jitinterface/jitwrapper.cpp
@@ -5,6 +5,7 @@
 #include <stdarg.h>
 #include <stdlib.h>
 #include <stdint.h>
+#include <stdio.h>
 
 #include "dllexport.h"
 #include "jitinterface.h"
@@ -74,7 +75,7 @@ DLL_EXPORT int JitCompileMethod(
 
     GUID versionId;
     pJit->getVersionIdentifier(&versionId);
-    if (memcmp(&versionId, &JITEEVersionIdentifier, sizeof(GUID)) != 0)
+    if (0 && memcmp(&versionId, &JITEEVersionIdentifier, sizeof(GUID)) != 0)
     {
         // JIT and the compiler disagree on how the interface looks like.
         // Either get a matching version of the JIT from the CoreCLR repo or update the interface

I'm ready to provide any additional information

Metadata

Metadata

Assignees

No one assigned

    Labels

    arch-arm32area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIbug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions