Commit 92fe1827 authored by fpizlo@apple.com's avatar fpizlo@apple.com
Browse files

DFG should not attempt to get rare case counts for op_mod on ARM

https://bugs.webkit.org/show_bug.cgi?id=84218

Reviewed by Geoff Garen.

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::makeSafe):
* dfg/DFGCommon.h:
(JSC::DFG::isX86):
(DFG):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@114478 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent cccce03d
2012-04-17 Filip Pizlo <fpizlo@apple.com>
DFG should not attempt to get rare case counts for op_mod on ARM
https://bugs.webkit.org/show_bug.cgi?id=84218
Reviewed by Geoff Garen.
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::makeSafe):
* dfg/DFGCommon.h:
(JSC::DFG::isX86):
(DFG):
2012-04-17 Myles Maxfield <mmaxfield@google.com>
 
BumpPointerAllocator assumes page size is less than MINIMUM_BUMP_POOL_SIZE
......@@ -721,7 +721,15 @@ private:
NodeIndex makeSafe(NodeIndex nodeIndex)
{
if (!m_inlineStackTop->m_profiledBlock->likelyToTakeSlowCase(m_currentIndex)
Node& node = m_graph[nodeIndex];
bool likelyToTakeSlowCase;
if (!isX86() && node.op() == ArithMod)
likelyToTakeSlowCase = false;
else
likelyToTakeSlowCase = m_inlineStackTop->m_profiledBlock->likelyToTakeSlowCase(m_currentIndex);
if (!likelyToTakeSlowCase
&& !m_inlineStackTop->m_exitProfile.hasExitSite(m_currentIndex, Overflow)
&& !m_inlineStackTop->m_exitProfile.hasExitSite(m_currentIndex, NegativeZero))
return nodeIndex;
......@@ -732,7 +740,7 @@ private:
case ArithSub:
case ArithNegate:
case ValueAdd:
case ArithMod: // for ArithMode "MayOverflow" means we tried to divide by zero, or we saw double.
case ArithMod: // for ArithMod "MayOverflow" means we tried to divide by zero, or we saw double.
m_graph[nodeIndex].mergeFlags(NodeMayOverflow);
break;
......
......@@ -114,6 +114,15 @@ inline const char* useKindToString(UseKind useKind)
}
}
inline bool isX86()
{
#if CPU(X86_64) || CPU(X86)
return true;
#else
return false;
#endif
}
} } // namespace JSC::DFG
#endif // ENABLE(DFG_JIT)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment