Bug 993174 - SpiderMonkey: Fix missing declarations under --disable-unified-compilation. r=mrosenberg, a=NPOTB
authorDan Gohman <sunfish@mozilla.com>
Tue, 08 Apr 2014 06:53:42 -0700
changeset 192305 46fdf6041673
parent 192304 d3ccc8465e4b
child 192306 54f0d0bea5e6
push id3566
push userryanvm@gmail.com
push date2014-05-20 13:28 +0000
Treeherderresults
reviewersmrosenberg, NPOTB
bugs993174
milestone30.0
Bug 993174 - SpiderMonkey: Fix missing declarations under --disable-unified-compilation. r=mrosenberg, a=NPOTB
js/src/jit/arm/Simulator-arm.cpp
--- a/js/src/jit/arm/Simulator-arm.cpp
+++ b/js/src/jit/arm/Simulator-arm.cpp
@@ -32,16 +32,35 @@
 #include "mozilla/FloatingPoint.h"
 #include "mozilla/Likely.h"
 #include "mozilla/MathAlgorithms.h"
 
 #include "jit/arm/Assembler-arm.h"
 #include "jit/AsmJS.h"
 #include "vm/Runtime.h"
 
+extern "C" {
+
+int64_t
+__aeabi_idivmod(int x, int y)
+{
+    uint32_t lo = uint32_t(x / y);
+    uint32_t hi = uint32_t(x % y);
+    return (int64_t(hi) << 32) | lo;
+}
+
+int64_t
+__aeabi_uidivmod(int x, int y)
+{
+    uint32_t lo = uint32_t(x) / uint32_t(y);
+    uint32_t hi = uint32_t(x) % uint32_t(y);
+    return (int64_t(hi) << 32) | lo;
+}
+}
+
 namespace js {
 namespace jit {
 
 // Load/store multiple addressing mode.
 enum BlockAddrMode {
     // Alias modes for comparison when writeback does not matter.
     da_x         = (0|0|0) << 21,  // Decrement after.
     ia_x         = (0|4|0) << 21,  // Increment after.
@@ -4266,27 +4285,8 @@ JSRuntime::simulatorRuntime() const
 }
 
 void
 JSRuntime::setSimulatorRuntime(js::jit::SimulatorRuntime *srt)
 {
     MOZ_ASSERT(!simulatorRuntime_);
     simulatorRuntime_ = srt;
 }
-
-extern "C" {
-
-int64_t
-__aeabi_idivmod(int x, int y)
-{
-    uint32_t lo = uint32_t(x / y);
-    uint32_t hi = uint32_t(x % y);
-    return (int64_t(hi) << 32) | lo;
-}
-
-int64_t
-__aeabi_uidivmod(int x, int y)
-{
-    uint32_t lo = uint32_t(x) / uint32_t(y);
-    uint32_t hi = uint32_t(x) % uint32_t(y);
-    return (int64_t(hi) << 32) | lo;
-}
-}