Skip to content
This repository was archived by the owner on May 9, 2023. It is now read-only.

Commit cd5c69c

Browse files
committed
Add timer debug to deobfuscation cache
1 parent 5427312 commit cd5c69c

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/Core/Reflection/Il2CppReflection.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,14 +67,19 @@ public static bool Il2CppTypeNotNull(Type type, out IntPtr il2cppPtr)
6767

6868
private static void BuildDeobfuscationCache()
6969
{
70+
float start = UnityEngine.Time.realtimeSinceStartup;
71+
7072
foreach (var asm in AppDomain.CurrentDomain.GetAssemblies())
7173
{
7274
foreach (var type in asm.TryGetTypes())
7375
TryCacheDeobfuscatedType(type);
7476
}
7577

7678
if (DeobfuscatedTypes.Count > 0)
77-
ExplorerCore.Log($"Built IL2CPP deobfuscation cache, initial count: {DeobfuscatedTypes.Count}");
79+
{
80+
ExplorerCore.Log($"Built deobfuscation cache in {UnityEngine.Time.realtimeSinceStartup - start} seconds, " +
81+
$"initial count: {DeobfuscatedTypes.Count} ");
82+
}
7883
}
7984

8085
private static void TryCacheDeobfuscatedType(Type type)

0 commit comments

Comments
 (0)