Title: [149050] trunk/Source/_javascript_Core
Revision
149050
Author
gga...@apple.com
Date
2013-04-24 11:16:22 -0700 (Wed, 24 Apr 2013)

Log Message

32-bit build fix.

Unreviewed.

* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compilePeepHoleBooleanBranch): Explicitly
truncate to 32-bit to avoid compiler warnings. It's safe to truncate
because the payload of a boolean is the low bits on both 64-bit and 32-bit.

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (149049 => 149050)


--- trunk/Source/_javascript_Core/ChangeLog	2013-04-24 18:06:53 UTC (rev 149049)
+++ trunk/Source/_javascript_Core/ChangeLog	2013-04-24 18:16:22 UTC (rev 149050)
@@ -1,3 +1,14 @@
+2013-04-24  Geoffrey Garen  <gga...@apple.com>
+
+        32-bit build fix.
+
+        Unreviewed.
+
+        * dfg/DFGSpeculativeJIT.cpp:
+        (JSC::DFG::SpeculativeJIT::compilePeepHoleBooleanBranch): Explicitly
+        truncate to 32-bit to avoid compiler warnings. It's safe to truncate
+        because the payload of a boolean is the low bits on both 64-bit and 32-bit.
+
 2013-04-23  Geoffrey Garen  <gga...@apple.com>
 
         Filled out more cases of branch folding in the DFG

Modified: trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT.cpp (149049 => 149050)


--- trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT.cpp	2013-04-24 18:06:53 UTC (rev 149049)
+++ trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT.cpp	2013-04-24 18:16:22 UTC (rev 149050)
@@ -1486,11 +1486,11 @@
     if (isBooleanConstant(node->child1().node())) {
         bool imm = valueOfBooleanConstant(node->child1().node());
         SpeculateBooleanOperand op2(this, node->child2());
-        branch32(condition, JITCompiler::Imm32(JSValue::encode(jsBoolean(imm))), op2.gpr(), taken);
+        branch32(condition, JITCompiler::Imm32(static_cast<int32_t>(JSValue::encode(jsBoolean(imm)))), op2.gpr(), taken);
     } else if (isBooleanConstant(node->child2().node())) {
         SpeculateBooleanOperand op1(this, node->child1());
         bool imm = valueOfBooleanConstant(node->child2().node());
-        branch32(condition, op1.gpr(), JITCompiler::Imm32(JSValue::encode(jsBoolean(imm))), taken);
+        branch32(condition, op1.gpr(), JITCompiler::Imm32(static_cast<int32_t>(JSValue::encode(jsBoolean(imm)))), taken);
     } else {
         SpeculateBooleanOperand op1(this, node->child1());
         SpeculateBooleanOperand op2(this, node->child2());
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to