X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fjit%2Fcompiler.h;h=b9bace42c52c72dcdc82c4390fb47260110f3d03;hb=fadf7ebeb07f41c41a7409401efade42dbc760c4;hp=6a5872ad9c38033e6575dcff6f50c29cf471df40;hpb=7a547bc9cd166c6f3c91c1f1cc13dfa549fb5c7a;p=platform%2Fupstream%2Fcoreclr.git diff --git a/src/jit/compiler.h b/src/jit/compiler.h index 6a5872a..b9bace4 100644 --- a/src/jit/compiler.h +++ b/src/jit/compiler.h @@ -917,7 +917,7 @@ struct ArrayInfo // partition a compilation. enum Phases { -#define CompPhaseNameMacro(enum_nm, string_nm, short_nm, hasChildren, parent) enum_nm, +#define CompPhaseNameMacro(enum_nm, string_nm, short_nm, hasChildren, parent, measureIR) enum_nm, #include "compphases.h" PHASE_NUMBER_OF }; @@ -952,6 +952,7 @@ struct CompTimeInfo static bool PhaseHasChildren[]; static int PhaseParent[]; + static bool PhaseReportsIRSize[]; unsigned m_byteCodeBytes; unsigned __int64 m_totalCycles; @@ -961,6 +962,9 @@ struct CompTimeInfo unsigned __int64 m_CLRinvokesByPhase[PHASE_NUMBER_OF]; unsigned __int64 m_CLRcyclesByPhase[PHASE_NUMBER_OF]; #endif + + unsigned m_nodeCountAfterPhase[PHASE_NUMBER_OF]; + // For better documentation, we call EndPhase on // non-leaf phases. We should also call EndPhase on the // last leaf subphase; obviously, the elapsed cycles between the EndPhase @@ -1077,7 +1081,7 @@ public: static void PrintCsvHeader(); // Ends the current phase (argument is for a redundant check). - void EndPhase(Phases phase); + void EndPhase(Compiler* compiler, Phases phase); #if MEASURE_CLRAPI_CALLS // Start and end a timed CLR API call. @@ -2138,9 +2142,10 @@ public: bool gtIsStaticFieldPtrToBoxedStruct(var_types fieldNodeType, CORINFO_FIELD_HANDLE fldHnd); // Return true if call is a recursive call; return false otherwise. + // Note when inlining, this looks for calls back to the root method. bool gtIsRecursiveCall(GenTreeCall* call) { - return (call->gtCallMethHnd == info.compMethodHnd); + return (call->gtCallMethHnd == impInlineRoot()->info.compMethodHnd); } //------------------------------------------------------------------------- @@ -3470,6 +3475,8 @@ public: void fgInsertBBafter(BasicBlock* insertAfterBlk, BasicBlock* newBlk); void fgUnlinkBlock(BasicBlock* block); + unsigned fgMeasureIR(); + #if OPT_BOOL_OPS // Used to detect multiple logical "not" assignments. bool fgMultipleNots; #endif @@ -7796,8 +7803,11 @@ public: bool genFPopt; // Can we do frame-pointer-omission optimization? bool altJit; // True if we are an altjit and are compiling this method +#ifdef OPT_CONFIG + bool optRepeat; // Repeat optimizer phases k times +#endif + #ifdef DEBUG - bool optRepeat; // Repeat optimizer phases k times bool compProcedureSplittingEH; // Separate cold code from hot code for functions with EH bool dspCode; // Display native code generated bool dspEHTable; // Display the EH table reported to the VM