### COMPlus Variables
- COMPlus_JitDump={method-list} – lots of info about what the JIT is doing
- COMPlus_JitDisasm={method-list} – disassembly listing of each method
-- COMPlus_JitDiffableDasm – avoid printing pointer values that can change from one invocation to the next, so that the disassembly can be more easily diffed.
+- COMPlus_JitDisasmDiffable – avoid printing pointer values that can change from one invocation to the next, so that the disassembly can be more easily diffed.
- COMPlus_JITGCDump={method-list} – this dumps the GC information.
- COMPlus_JitUnwindDump={method-list} – dumps the unwind tables.
- COMPlus_JitEHDump={method-list} – dumps the exception handling tables.
* `COMPlus_JitDump`={method-list} – dump lots of useful information about what the JIT is doing. See [Reading a JitDump](ryujit-overview.md#reading-a-jitdump) for more on how to analyze this data.
* `COMPlus_JitDumpASCII`={1 or 0} - Specifies whether the JIT dump should be ASCII only (Defaults to 1). Disabling this generates more readable expression trees.
* `COMPlus_JitDisasm`={method-list} – dump a disassembly listing of each method.
-* `COMPlus_JitDiffableDasm` – set to 1 to tell the JIT to avoid printing things like pointer values that can change from one invocation to the next, so that the disassembly can be more easily compared.
+* `COMPlus_JitDisasmDiffable` – set to 1 to tell the JIT to avoid printing things like pointer values that can change from one invocation to the next, so that the disassembly can be more easily compared.
* `COMPlus_JitGCDump`={method-list} – dump the GC information.
* `COMPlus_JitUnwindDump`={method-list} – dump the unwind tables.
* `COMPlus_JitEHDump`={method-list} – dump the exception handling tables.
opts.compJitEarlyExpandMDArrays = (JitConfig.JitEarlyExpandMDArrays() != 0);
- opts.disAsm = false;
- opts.disDiffable = false;
- opts.dspDiffable = false;
+ opts.disAsm = false;
+ opts.disDiffable = false;
+ opts.dspDiffable = false;
+ opts.disAlignment = false;
#ifdef DEBUG
opts.dspInstrs = false;
opts.dspLines = false;
opts.dmpHex = false;
opts.disAsmSpilled = false;
opts.disAddr = false;
- opts.disAlignment = false;
opts.dspCode = false;
opts.dspEHTable = false;
opts.dspDebugInfo = false;
opts.doLateDisasm = true;
#endif // LATE_DISASM
- // This one applies to both Ngen/Jit Disasm output: COMPlus_JitDiffableDasm=1
- if (JitConfig.DiffableDasm() != 0)
- {
- opts.disDiffable = true;
- opts.dspDiffable = true;
- }
-
// This one applies to both Ngen/Jit Disasm output: COMPlus_JitDasmWithAddress=1
if (JitConfig.JitDasmWithAddress() != 0)
{
opts.disAddr = true;
}
-
- if (JitConfig.JitDasmWithAlignmentBoundaries() != 0)
- {
- opts.disAlignment = true;
- }
-
if (JitConfig.JitLongAddress() != 0)
{
opts.compLongAddress = true;
}
#endif // !DEBUG
+#ifndef DEBUG
+ if (opts.disAsm)
+#endif
+ {
+ if (JitConfig.JitDisasmWithAlignmentBoundaries())
+ {
+ opts.disAlignment = true;
+ }
+ if (JitConfig.JitDisasmDiffable())
+ {
+ opts.disDiffable = true;
+ opts.dspDiffable = true;
+ }
+ }
+
+// These are left for backward compatibility, to be removed
+#ifdef DEBUG
+ if (JitConfig.JitDasmWithAlignmentBoundaries())
+ {
+ opts.disAlignment = true;
+ }
+ if (JitConfig.JitDiffableDasm())
+ {
+ opts.disDiffable = true;
+ opts.dspDiffable = true;
+ }
+#endif // DEBUG
+
//-------------------------------------------------------------------------
#ifdef DEBUG
bool optRepeat; // Repeat optimizer phases k times
#endif
- bool disAsm; // Display native code as it is generated
- bool dspDiffable; // Makes the Jit Dump 'diff-able' (currently uses same COMPlus_* flag as disDiffable)
- bool disDiffable; // Makes the Disassembly code 'diff-able'
+ bool disAsm; // Display native code as it is generated
+ bool dspDiffable; // Makes the Jit Dump 'diff-able' (currently uses same COMPlus_* flag as disDiffable)
+ bool disDiffable; // Makes the Disassembly code 'diff-able'
+ bool disAlignment; // Display alignment boundaries in disassembly code
#ifdef DEBUG
bool compProcedureSplittingEH; // Separate cold code from hot code for functions with EH
bool dspCode; // Display native code generated
bool disAsmSpilled; // Display native code when any register spilling occurs
bool disasmWithGC; // Display GC info interleaved with disassembly.
bool disAddr; // Display process address next to each instruction in disassembly code
- bool disAlignment; // Display alignment boundaries in disassembly code
bool disAsm2; // Display native code after it is generated using external disassembler
bool dspOrder; // Display names of each of the methods that we ngen/jit
bool dspUnwind; // Display the unwind info output
for (unsigned cnt = ig->igInsCnt; cnt > 0; cnt--)
{
#ifdef DEBUG
- size_t curInstrAddr = (size_t)cp;
- instrDesc* curInstrDesc = id;
-
if ((emitComp->opts.disAsm || emitComp->verbose) && (JitConfig.JitDisasmWithDebugInfo() != 0) &&
(id->idCodeSize() > 0))
{
++nextMapping;
}
}
-
#endif
-
size_t insSize = emitIssue1Instr(ig, id, &cp);
emitAdvanceInstrDesc(&id, insSize);
+ }
-#ifdef DEBUG
- // Print the alignment boundary
- if ((emitComp->opts.disAsm || emitComp->verbose) && (emitComp->opts.disAddr || emitComp->opts.disAlignment))
+ // Print the alignment boundary
+ if ((emitComp->opts.disAsm INDEBUG(|| emitComp->verbose)) &&
+ (INDEBUG(emitComp->opts.disAddr ||) emitComp->opts.disAlignment))
+ {
+ for (unsigned cnt = ig->igInsCnt; cnt > 0; cnt--)
{
+ size_t curInstrAddr = (size_t)cp;
+ instrDesc* curInstrDesc = id;
+
size_t afterInstrAddr = (size_t)cp;
instruction curIns = curInstrDesc->idIns();
bool isJccAffectedIns = false;
}
}
}
-#endif // DEBUG
}
#ifdef DEBUG
// particular token value.
CONFIG_INTEGER(DebugBreakOnVerificationFailure, W("DebugBreakOnVerificationFailure"), 0) // Halts the jit on
// verification failure
-CONFIG_INTEGER(DiffableDasm, W("JitDiffableDasm"), 0) // Make the disassembly diff-able
CONFIG_INTEGER(JitDasmWithAddress, W("JitDasmWithAddress"), 0) // Print the process address next to each instruction of
// the disassembly
CONFIG_INTEGER(DisplayLoopHoistStats, W("JitLoopHoistStats"), 0) // Display JIT loop hoisting statistics
W("JitUnrollLoopMaxIterationCount"),
DEFAULT_UNROLL_LOOP_MAX_ITERATION_COUNT)
-// Print the alignment boundaries in disassembly.
-CONFIG_INTEGER(JitDasmWithAlignmentBoundaries, W("JitDasmWithAlignmentBoundaries"), 0)
-
CONFIG_INTEGER(JitDirectAlloc, W("JitDirectAlloc"), 0)
CONFIG_INTEGER(JitDoubleAlign, W("JitDoubleAlign"), 1)
CONFIG_INTEGER(JitDumpASCII, W("JitDumpASCII"), 1) // Uses only ASCII characters in tree dumps
CONFIG_METHODSET(JitBreak, W("JitBreak")) // Stops in the importer when compiling a specified method
CONFIG_METHODSET(JitDebugBreak, W("JitDebugBreak"))
-CONFIG_METHODSET(JitDisasm, W("JitDisasm")) // Dumps disassembly for specified method
CONFIG_STRING(JitDisasmAssemblies, W("JitDisasmAssemblies")) // Only show JitDisasm and related info for methods
// from this semicolon-delimited list of assemblies.
CONFIG_INTEGER(JitDisasmWithGC, W("JitDisasmWithGC"), 0) // Dump interleaved GC Info for any method disassembled.
/// JIT Hardware Intrinsics
///
CONFIG_INTEGER(EnableIncompleteISAClass, W("EnableIncompleteISAClass"), 0) // Enable testing not-yet-implemented
- // intrinsic classes
-
-#else // defined(DEBUG)
+#endif // defined(DEBUG)
-// JitDisasm is supported in Release too
-CONFIG_METHODSET(JitDisasm, W("JitDisasm"))
-#endif // !defined(DEBUG)
+CONFIG_METHODSET(JitDisasm, W("JitDisasm")) // Print codegen for given methods
+CONFIG_INTEGER(JitDisasmDiffable, W("JitDisasmDiffable"), 0) // Make the disassembly diff-able
+CONFIG_INTEGER(JitDisasmSummary, W("JitDisasmSummary"), 0) // Prints all jitted methods to the console
+CONFIG_INTEGER(JitDisasmWithAlignmentBoundaries, W("JitDisasmWithAlignmentBoundaries"), 0) // Print the alignment
+ // boundaries.
+CONFIG_STRING(JitStdOutFile, W("JitStdOutFile")) // If set, sends JIT's stdout output to this file.
-CONFIG_INTEGER(JitDisasmSummary, W("JitDisasmSummary"), 0) // Prints all jitted methods to the console
-CONFIG_STRING(JitStdOutFile, W("JitStdOutFile")) // If set, sends JIT's stdout output to this file.
+// These are supported for backward compatibility, to be removed:
+#ifdef DEBUG
+CONFIG_INTEGER(JitDiffableDasm, W("JitDiffableDasm"), 0)
+CONFIG_INTEGER(JitDasmWithAlignmentBoundaries, W("JitDasmWithAlignmentBoundaries"), 0)
+#endif
CONFIG_INTEGER(RichDebugInfo, W("RichDebugInfo"), 0) // If 1, keep rich debug info and report it back to the EE
"DOTNET_JitDisasm": "*",
"DOTNET_JitUnwindDump": "*",
"DOTNET_JitEHDump": "*",
- "DOTNET_JitDiffableDasm": "1",
+ "DOTNET_JitDiffableDasm": "1", # to be removed
+ "DOTNET_JitDisasmDiffable": "1",
"DOTNET_JitDisasmWithGC": "1"
}
W("EnableExtraSuperPmiQueries"),
W("JitDisasm"),
W("JitDump"),
- W("JitDasmWithAlignmentBoundaries"),
+ W("JitDasmWithAlignmentBoundaries"), // to be removed
+ W("JitDisasmWithAlignmentBoundaries"),
W("JitDumpASCII"),
W("JitHashBreak"),
W("JitHashDump"),