Small changes around stack levels. (#15616)
authorSergey Andreenko <seandree@microsoft.com>
Fri, 22 Dec 2017 21:15:41 +0000 (13:15 -0800)
committerGitHub <noreply@github.com>
Fri, 22 Dec 2017 21:15:41 +0000 (13:15 -0800)
* add ifdef for fgThrowHlpBlkStkLevel

* fgFindExcptnTarget should not be called fof dbg code compilation mode.

src/jit/compiler.h
src/jit/compiler.hpp
src/jit/flowgraph.cpp

index 904d993..71cfba0 100644 (file)
@@ -4956,7 +4956,10 @@ private:
     bool fgIsCodeAdded();
 
     bool fgIsThrowHlpBlk(BasicBlock* block);
+
+#if !FEATURE_FIXED_OUT_ARGS
     unsigned fgThrowHlpBlkStkLevel(BasicBlock* block);
+#endif // !FEATURE_FIXED_OUT_ARGS
 
     unsigned fgBigOffsetMorphingTemps[TYP_COUNT];
 
index 83a7ff3..ebd1894 100644 (file)
@@ -3031,6 +3031,8 @@ inline bool Compiler::fgIsThrowHlpBlk(BasicBlock* block)
     return false;
 }
 
+#if !FEATURE_FIXED_OUT_ARGS
+
 /*****************************************************************************
  *
  *  Return the stackLevel of the inserted block that throws exception
@@ -3064,6 +3066,8 @@ inline unsigned Compiler::fgThrowHlpBlkStkLevel(BasicBlock* block)
     return 0;
 }
 
+#endif // !FEATURE_FIXED_OUT_ARGS
+
 /*
     Small inline function to change a given block to a throw block.
 
index b6ae5c0..7dbf463 100644 (file)
@@ -18393,6 +18393,7 @@ BasicBlock* Compiler::fgAddCodeRef(BasicBlock* srcBlk, unsigned refData, Special
 
 Compiler::AddCodeDsc* Compiler::fgFindExcptnTarget(SpecialCodeKind kind, unsigned refData)
 {
+    assert(!opts.compDbgCode);
     if (!(fgExcptnTargetCache[kind] && // Try the cached value first
           fgExcptnTargetCache[kind]->acdData == refData))
     {