summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Stakenvicius <axs@gentoo.org>2017-02-27 21:00:55 -0500
committerIan Stakenvicius <axs@gentoo.org>2017-02-27 21:01:23 -0500
commit03ca1a66484c7b13c55d43c40fbee116d030087a (patch)
tree537fe3ec3759b93fde798f57a8368fb6652a8dfd /dev-lang/spidermonkey/files/ff45
parentapp-editors/gvim: version bump to 8.0.0386 (diff)
downloadgentoo-03ca1a66484c7b13c55d43c40fbee116d030087a.tar.gz
gentoo-03ca1a66484c7b13c55d43c40fbee116d030087a.tar.bz2
gentoo-03ca1a66484c7b13c55d43c40fbee116d030087a.zip
dev-lang/spidermonkey: add release for v45
Package-Manager: portage-2.3.3
Diffstat (limited to 'dev-lang/spidermonkey/files/ff45')
-rw-r--r--dev-lang/spidermonkey/files/ff45/7000_drop-Wl-build-id_v4.patch17
-rw-r--r--dev-lang/spidermonkey/files/ff45/7003_freebsd_jscpucfg.patch22
-rw-r--r--dev-lang/spidermonkey/files/ff45/8001_hppa_js_configure.patch21
-rw-r--r--dev-lang/spidermonkey/files/ff45/8007_nonejit_ppc64_fix_bug1253216.patch46
-rw-r--r--dev-lang/spidermonkey/files/ff45/8008_nonejit_x86_fix_based_on_bug1253216.patch11
-rw-r--r--dev-lang/spidermonkey/files/ff45/8014_ia64_js.patch248
6 files changed, 365 insertions, 0 deletions
diff --git a/dev-lang/spidermonkey/files/ff45/7000_drop-Wl-build-id_v4.patch b/dev-lang/spidermonkey/files/ff45/7000_drop-Wl-build-id_v4.patch
new file mode 100644
index 00000000000..8a1e1dd9988
--- /dev/null
+++ b/dev-lang/spidermonkey/files/ff45/7000_drop-Wl-build-id_v4.patch
@@ -0,0 +1,17 @@
+--- a/js/src/configure.in 2014-06-05 21:15:27.000000000 -0400
++++ b/js/src/configure.in 2014-06-13 11:01:51.130703283 -0400
+@@ -1156,14 +1156,6 @@
+ AC_MSG_RESULT([no])
+ LDFLAGS=$_SAVE_LDFLAGS)
+
+- AC_MSG_CHECKING([for --build-id option to ld])
+- _SAVE_LDFLAGS=$LDFLAGS
+- LDFLAGS="$LDFLAGS -Wl,--build-id"
+- AC_TRY_LINK(,,AC_MSG_RESULT([yes])
+- [NSPR_LDFLAGS="$NSPR_LDFLAGS -Wl,--build-id"],
+- AC_MSG_RESULT([no])
+- LDFLAGS=$_SAVE_LDFLAGS)
+-
+ # Turn on gcc/clang warnings:
+ # https://gcc.gnu.org/onlinedocs/gcc-4.4.0/gcc/Warning-Options.html
+ #
diff --git a/dev-lang/spidermonkey/files/ff45/7003_freebsd_jscpucfg.patch b/dev-lang/spidermonkey/files/ff45/7003_freebsd_jscpucfg.patch
new file mode 100644
index 00000000000..467bf444144
--- /dev/null
+++ b/dev-lang/spidermonkey/files/ff45/7003_freebsd_jscpucfg.patch
@@ -0,0 +1,22 @@
+--- a/js/src/jscpucfg.h 2012-01-18 17:38:54.409461514 +0100
++++ b/js/src/jscpucfg.h 2012-01-18 17:38:59.522462164 +0100
+@@ -77,6 +77,19 @@
+ #define IS_BIG_ENDIAN 1
+ #endif
+
++#elif defined(__FreeBSD__)
++#include <sys/endian.h>
++
++#if defined(BYTE_ORDER)
++#if BYTE_ORDER == LITTLE_ENDIAN
++#define IS_LITTLE_ENDIAN 1
++#undef IS_BIG_ENDIAN
++#elif BYTE_ORDER == BIG_ENDIAN
++#undef IS_LITTLE_ENDIAN
++#define IS_BIG_ENDIAN 1
++#endif
++#endif
++
+ #elif defined(JS_HAVE_ENDIAN_H)
+ #include <endian.h>
+
diff --git a/dev-lang/spidermonkey/files/ff45/8001_hppa_js_configure.patch b/dev-lang/spidermonkey/files/ff45/8001_hppa_js_configure.patch
new file mode 100644
index 00000000000..a33ab3cd614
--- /dev/null
+++ b/dev-lang/spidermonkey/files/ff45/8001_hppa_js_configure.patch
@@ -0,0 +1,21 @@
+--- a/js/src/configure.in
++++ b/js/src/configure.in
+@@ -958,7 +958,7 @@
+ CPU_ARCH=s390x
+ ;;
+
+-hppa* | parisc)
++hppa* | parisc*)
+ CPU_ARCH=hppa
+ ;;
+
+@@ -2009,6 +2009,9 @@
+ AC_DEFINE(JS_CPU_MIPS)
+ AC_DEFINE(JS_NUNBOX32)
+ ;;
++hppa*)
++ AC_DEFINE(JS_NUNBOX32)
++ ;;
+ esac
+
+ MOZ_ARG_DISABLE_BOOL(ion,
diff --git a/dev-lang/spidermonkey/files/ff45/8007_nonejit_ppc64_fix_bug1253216.patch b/dev-lang/spidermonkey/files/ff45/8007_nonejit_ppc64_fix_bug1253216.patch
new file mode 100644
index 00000000000..26e9373dddf
--- /dev/null
+++ b/dev-lang/spidermonkey/files/ff45/8007_nonejit_ppc64_fix_bug1253216.patch
@@ -0,0 +1,46 @@
+
+# HG changeset patch
+# User Lars T Hansen <lhansen@mozilla.com>
+# Date 1457091735 -3600
+# Node ID 69f237c2cf9131e97372debee01931dbacd064e5
+# Parent 3aa4483740828617001060fe7386051020521e90
+Bug 1253216 - clean up the atomic ops ifdef nest. r=jorendorff
+
+diff --git a/js/src/jit/AtomicOperations.h b/js/src/jit/AtomicOperations.h
+--- a/js/src/jit/AtomicOperations.h
++++ b/js/src/jit/AtomicOperations.h
+@@ -318,21 +318,29 @@ AtomicOperations::isLockfree(int32_t siz
+ } // namespace js
+
+ #if defined(JS_CODEGEN_ARM)
+ # include "jit/arm/AtomicOperations-arm.h"
+ #elif defined(JS_CODEGEN_ARM64)
+ # include "jit/arm64/AtomicOperations-arm64.h"
+ #elif defined(JS_CODEGEN_MIPS32) || defined(JS_CODEGEN_MIPS64)
+ # include "jit/mips-shared/AtomicOperations-mips-shared.h"
+-#elif defined(__ppc64__) || defined(__PPC64_) \
+- || defined(__ppc64le__) || defined(__PPC64LE__) \
+- || defined(__ppc__) || defined(__PPC__)
++#elif defined(__ppc__) || defined(__PPC__)
+ # include "jit/none/AtomicOperations-ppc.h"
+ #elif defined(JS_CODEGEN_NONE)
+-# include "jit/none/AtomicOperations-none.h"
++ // You can disable the JIT with --disable-ion but you must still
++ // provide the atomic operations that will be used by the JS engine.
++ // When the JIT is disabled the operations are simply safe-for-races
++ // C++ realizations of atomics. These operations cannot be written
++ // in portable C++, hence the default here is to crash. See the
++ // top of the file for more guidance.
++# if defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || defined(__PPC64LE__)
++# include "jit/none/AtomicOperations-ppc.h"
++# else
++# include "jit/none/AtomicOperations-none.h" // These MOZ_CRASH() always
++# endif
+ #elif defined(JS_CODEGEN_X86) || defined(JS_CODEGEN_X64)
+ # include "jit/x86-shared/AtomicOperations-x86-shared.h"
+ #else
+ # error "Atomic operations must be defined for this platform"
+ #endif
+
+ #endif // jit_AtomicOperations_h
+
diff --git a/dev-lang/spidermonkey/files/ff45/8008_nonejit_x86_fix_based_on_bug1253216.patch b/dev-lang/spidermonkey/files/ff45/8008_nonejit_x86_fix_based_on_bug1253216.patch
new file mode 100644
index 00000000000..86b27130205
--- /dev/null
+++ b/dev-lang/spidermonkey/files/ff45/8008_nonejit_x86_fix_based_on_bug1253216.patch
@@ -0,0 +1,11 @@
+--- a/js/src/jit/AtomicOperations.h 2016-03-12 13:42:27.914524205 -0500
++++ b/js/src/jit/AtomicOperations.h 2016-03-12 13:42:15.644573630 -0500
+@@ -311,6 +311,8 @@
+ // top of the file for more guidance.
+ # if defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || defined(__PPC64LE__)
+ # include "jit/none/AtomicOperations-ppc.h"
++# elif defined(__i386__) || defined(__x86_64__)
++# include "jit/x86-shared/AtomicOperations-x86-shared.h"
+ # else
+ # include "jit/none/AtomicOperations-none.h" // These MOZ_CRASH() always
+ # endif
diff --git a/dev-lang/spidermonkey/files/ff45/8014_ia64_js.patch b/dev-lang/spidermonkey/files/ff45/8014_ia64_js.patch
new file mode 100644
index 00000000000..73075919a86
--- /dev/null
+++ b/dev-lang/spidermonkey/files/ff45/8014_ia64_js.patch
@@ -0,0 +1,248 @@
+--- a/js/src/jit/AtomicOperations.h 2016-11-08 21:27:30.000000000 +0100
++++ b/js/src/jit/AtomicOperations.h 2016-11-08 22:17:59.280251831 +0100
+@@ -311,6 +311,8 @@
+ // top of the file for more guidance.
+ # if defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || defined(__PPC64LE__)
+ # include "jit/none/AtomicOperations-ppc.h"
++# elif defined(__ia64__)
++# include "jit/none/AtomicOperations-ia64.h"
+ # elif defined(__i386__) || defined(__x86_64__)
+ # include "jit/x86-shared/AtomicOperations-x86-shared.h"
+ # else
+--- /dev/null
++++ b/js/src/jit/none/AtomicOperations-ia64.h 2016-11-08 22:09:41.378809457 +0100
+@@ -0,0 +1,234 @@
++/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
++ * vim: set ts=8 sts=4 et sw=4 tw=99:
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
++
++/* For documentation, see jit/AtomicOperations.h */
++
++#ifndef jit_ia64_AtomicOperations_ia64_h
++#define jit_ia64_AtomicOperations_ia64_h
++
++#include "mozilla/Assertions.h"
++#include "mozilla/Types.h"
++
++#if defined(__GNUC__)
++
++// The default implementation tactic for gcc is to use the newer
++// __atomic intrinsics added for use in C++11 <atomic>. Where that
++// isn't available, we use GCC's older __sync functions instead.
++//
++// ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS is kept as a backward
++// compatible option for older compilers: enable this to use GCC's old
++// __sync functions instead of the newer __atomic functions. This
++// will be required for GCC 4.6.x and earlier, should we need to use
++// those versions.
++
++//#define ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++
++inline bool
++js::jit::AtomicOperations::isLockfree8()
++{
++# ifndef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ MOZ_ASSERT(__atomic_always_lock_free(sizeof(int8_t), 0));
++ MOZ_ASSERT(__atomic_always_lock_free(sizeof(int16_t), 0));
++ MOZ_ASSERT(__atomic_always_lock_free(sizeof(int32_t), 0));
++ MOZ_ASSERT(__atomic_always_lock_free(sizeof(int64_t), 0));
++ return true;
++# else
++ return false;
++# endif
++}
++
++inline void
++js::jit::AtomicOperations::fenceSeqCst()
++{
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ __sync_synchronize();
++# else
++ __atomic_thread_fence(__ATOMIC_SEQ_CST);
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::loadSeqCst(T* addr)
++{
++ MOZ_ASSERT(sizeof(T) < 8 || isLockfree8());
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ __sync_synchronize();
++ T v = *addr;
++ __sync_synchronize();
++# else
++ T v;
++ __atomic_load(addr, &v, __ATOMIC_SEQ_CST);
++# endif
++ return v;
++}
++
++template<typename T>
++inline void
++js::jit::AtomicOperations::storeSeqCst(T* addr, T val)
++{
++ MOZ_ASSERT(sizeof(T) < 8 || isLockfree8());
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ __sync_synchronize();
++ *addr = val;
++ __sync_synchronize();
++# else
++ __atomic_store(addr, &val, __ATOMIC_SEQ_CST);
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::compareExchangeSeqCst(T* addr, T oldval, T newval)
++{
++ MOZ_ASSERT(sizeof(T) < 8 || isLockfree8());
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ return __sync_val_compare_and_swap(addr, oldval, newval);
++# else
++ __atomic_compare_exchange(addr, &oldval, &newval, false, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST);
++ return oldval;
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::fetchAddSeqCst(T* addr, T val)
++{
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ return __sync_fetch_and_add(addr, val);
++# else
++ return __atomic_fetch_add(addr, val, __ATOMIC_SEQ_CST);
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::fetchSubSeqCst(T* addr, T val)
++{
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ return __sync_fetch_and_sub(addr, val);
++# else
++ return __atomic_fetch_sub(addr, val, __ATOMIC_SEQ_CST);
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::fetchAndSeqCst(T* addr, T val)
++{
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ return __sync_fetch_and_and(addr, val);
++# else
++ return __atomic_fetch_and(addr, val, __ATOMIC_SEQ_CST);
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::fetchOrSeqCst(T* addr, T val)
++{
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ return __sync_fetch_and_or(addr, val);
++# else
++ return __atomic_fetch_or(addr, val, __ATOMIC_SEQ_CST);
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::fetchXorSeqCst(T* addr, T val)
++{
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ return __sync_fetch_and_xor(addr, val);
++# else
++ return __atomic_fetch_xor(addr, val, __ATOMIC_SEQ_CST);
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::exchangeSeqCst(T* addr, T val)
++{
++ MOZ_ASSERT(sizeof(T) < 8 || isLockfree8());
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ T v;
++ __sync_synchronize();
++ do {
++ v = *addr;
++ } while (__sync_val_compare_and_swap(addr, v, val) != v);
++ return v;
++# else
++ T v;
++ __atomic_exchange(addr, &val, &v, __ATOMIC_SEQ_CST);
++ return v;
++# endif
++}
++
++template<typename T>
++inline T
++js::jit::AtomicOperations::loadSafeWhenRacy(T* addr)
++{
++ return *addr; // FIXME (1208663): not yet safe
++}
++
++template<typename T>
++inline void
++js::jit::AtomicOperations::storeSafeWhenRacy(T* addr, T val)
++{
++ *addr = val; // FIXME (1208663): not yet safe
++}
++
++inline void
++js::jit::AtomicOperations::memcpySafeWhenRacy(void* dest, const void* src, size_t nbytes)
++{
++ ::memcpy(dest, src, nbytes); // FIXME (1208663): not yet safe
++}
++
++inline void
++js::jit::AtomicOperations::memmoveSafeWhenRacy(void* dest, const void* src, size_t nbytes)
++{
++ ::memmove(dest, src, nbytes); // FIXME (1208663): not yet safe
++}
++
++template<size_t nbytes>
++inline void
++js::jit::RegionLock::acquire(void* addr)
++{
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ while (!__sync_bool_compare_and_swap(&spinlock, 0, 1))
++ ;
++# else
++ uint32_t zero = 0;
++ uint32_t one = 1;
++ while (!__atomic_compare_exchange(&spinlock, &zero, &one, false, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE)) {
++ zero = 0;
++ continue;
++ }
++# endif
++}
++
++template<size_t nbytes>
++inline void
++js::jit::RegionLock::release(void* addr)
++{
++ MOZ_ASSERT(AtomicOperations::loadSeqCst(&spinlock) == 1, "releasing unlocked region lock");
++# ifdef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++ __sync_sub_and_fetch(&spinlock, 1);
++# else
++ uint32_t zero = 0;
++ __atomic_store(&spinlock, &zero, __ATOMIC_SEQ_CST);
++# endif
++}
++
++# undef ATOMICS_IMPLEMENTED_WITH_SYNC_INTRINSICS
++
++#elif defined(ENABLE_SHARED_ARRAY_BUFFER)
++
++# error "Either disable JS shared memory, use GCC, or add code here"
++
++#endif
++
++#endif // jit_ia64_AtomicOperations_ia64_h