bug 445391 - re-enable OJI for Firefox 3.1, the configure changes is from jst, r=jst,crowder, sr=benjamin

This commit is contained in:
Igor Bukanov 2008-07-29 19:53:03 +02:00
parent e4428cafe9
commit dcdf0df942
8 changed files with 49 additions and 37 deletions

View File

@ -4359,7 +4359,7 @@ MOZ_NO_INSPECTOR_APIS=
MOZ_NO_XPCOM_OBSOLETE=
MOZ_NO_FAST_LOAD=
MOZ_MEDIA=
MOZ_OJI=
MOZ_OJI=1
MOZ_PERMISSIONS=1
MOZ_PLACES=
MOZ_PLAINTEXT_EDITOR_ONLY=
@ -5162,10 +5162,10 @@ MOZ_ARG_DISABLE_BOOL(plugins,
dnl ========================================================
dnl = Open JVM Interface (OJI) support
dnl ========================================================
MOZ_ARG_ENABLE_BOOL(oji,
[ --enable-oji Enable Open JVM Integration support],
MOZ_OJI=1,
MOZ_OJI=)
MOZ_ARG_DISABLE_BOOL(oji,
[ --disable-oji Disable Open JVM Integration support],
MOZ_OJI=,
MOZ_OJI=1)
if test -n "$MOZ_OJI"; then
AC_DEFINE(OJI)
fi

View File

@ -561,7 +561,7 @@ ClearDoubleArenaFlags(JSGCArenaInfo *a)
bitmap[DOUBLES_ARENA_BITMAP_WORDS - 1] = mask << nused;
}
static JS_INLINE JSBool
static JS_ALWAYS_INLINE JSBool
IsMarkedDouble(JSGCArenaInfo *a, uint32 index)
{
jsbitmap *bitmap;

View File

@ -93,13 +93,13 @@ struct JSStackFrame {
#endif
};
static inline jsval *
static JS_INLINE jsval *
StackBase(JSStackFrame *fp)
{
return fp->slots + fp->script->nfixed;
}
static inline uintN
static JS_INLINE uintN
GlobalVarCount(JSStackFrame *fp)
{
uintN n;

View File

@ -71,7 +71,7 @@ _InterlockedCompareExchange(long *volatile dest, long exchange, long comp);
JS_END_EXTERN_C
#pragma intrinsic(_InterlockedCompareExchange)
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwapHelper(jsword *w, jsword ov, jsword nv)
{
_InterlockedCompareExchange(w, nv, ov);
@ -80,7 +80,7 @@ NativeCompareAndSwapHelper(jsword *w, jsword ov, jsword nv)
}
}
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
{
return (NativeCompareAndSwapHelper(w, ov, nv) & 1);
@ -90,7 +90,7 @@ NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
#include <libkern/OSAtomic.h>
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
{
/* Details on these functions available in the manpage for atomic */
@ -104,7 +104,7 @@ NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
#elif defined(__GNUC__) && defined(__i386__)
/* Note: This fails on 386 cpus, cmpxchgl is a >= 486 instruction */
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
{
unsigned int res;
@ -121,7 +121,7 @@ NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
}
#elif defined(__GNUC__) && defined(__x86_64__)
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
{
unsigned int res;
@ -139,7 +139,7 @@ NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
#elif defined(SOLARIS) && defined(sparc) && defined(ULTRA_SPARC)
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
{
#if defined(__GNUC__)
@ -167,7 +167,7 @@ mov 0,%0\n\
#include <sys/atomic_op.h>
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
{
return !_check_lock((atomic_p)w, ov, nv);
@ -184,7 +184,7 @@ typedef int (__kernel_cmpxchg_t)(int oldval, int newval, volatile int *ptr);
JS_STATIC_ASSERT(sizeof(jsword) == sizeof(int));
static JS_INLINE int
static JS_ALWAYS_INLINE int
NativeCompareAndSwap(jsword *w, jsword ov, jsword nv)
{
volatile int *vp = (volatile int *) w;
@ -916,14 +916,14 @@ js_CleanupLocks()
#ifdef NSPR_LOCK
static JS_INLINE void
static JS_ALWAYS_INLINE void
ThinLock(JSThinLock *tl, jsword me)
{
JS_ACQUIRE_LOCK((JSLock *) tl->fat);
tl->owner = me;
}
static JS_INLINE void
static JS_ALWAYS_INLINE void
ThinUnlock(JSThinLock *tl, jsword /*me*/)
{
tl->owner = 0;
@ -1047,7 +1047,7 @@ js_Dequeue(JSThinLock *tl)
js_ResumeThread(tl);
}
static JS_INLINE void
static JS_ALWAYS_INLINE void
ThinLock(JSThinLock *tl, jsword me)
{
JS_ASSERT(CURRENT_THREAD_IS_ME(me));
@ -1061,7 +1061,7 @@ ThinLock(JSThinLock *tl, jsword me)
#endif
}
static JS_INLINE void
static JS_ALWAYS_INLINE void
ThinUnlock(JSThinLock *tl, jsword me)
{
JS_ASSERT(CURRENT_THREAD_IS_ME(me));

View File

@ -238,7 +238,7 @@ GetCompactIndexWidth(size_t index)
return width;
}
static JS_INLINE jsbytecode *
static JS_ALWAYS_INLINE jsbytecode *
WriteCompactIndex(jsbytecode *pc, size_t index)
{
size_t next;
@ -251,7 +251,7 @@ WriteCompactIndex(jsbytecode *pc, size_t index)
return pc;
}
static JS_INLINE jsbytecode *
static JS_ALWAYS_INLINE jsbytecode *
ReadCompactIndex(jsbytecode *pc, size_t *result)
{
size_t nextByte;
@ -354,7 +354,7 @@ typedef struct REGlobalData {
* code point value is less than decimal 128, then return ch.
* 6. Return cu.
*/
static JS_INLINE uintN
static JS_ALWAYS_INLINE uintN
upcase(uintN ch)
{
uintN cu;
@ -370,7 +370,7 @@ upcase(uintN ch)
return (cu < 128) ? ch : cu;
}
static JS_INLINE uintN
static JS_ALWAYS_INLINE uintN
downcase(uintN ch)
{
JS_ASSERT((uintN) (jschar) ch == ch);
@ -2164,7 +2164,7 @@ FlatNMatcher(REGlobalData *gData, REMatchState *x, jschar *matchChars,
}
#endif
static JS_INLINE REMatchState *
static JS_ALWAYS_INLINE REMatchState *
FlatNIMatcher(REGlobalData *gData, REMatchState *x, jschar *matchChars,
size_t length)
{
@ -2529,7 +2529,7 @@ ReallocStateStack(REGlobalData *gData)
* true, then update the current state's cp. Always update startpc to the next
* op.
*/
static JS_INLINE REMatchState *
static JS_ALWAYS_INLINE REMatchState *
SimpleMatch(REGlobalData *gData, REMatchState *x, REOp op,
jsbytecode **startpc, JSBool updatecp)
{
@ -2738,7 +2738,7 @@ SimpleMatch(REGlobalData *gData, REMatchState *x, REOp op,
return NULL;
}
static JS_INLINE REMatchState *
static JS_ALWAYS_INLINE REMatchState *
ExecuteREBytecode(REGlobalData *gData, REMatchState *x)
{
REMatchState *result = NULL;

View File

@ -984,7 +984,7 @@ NewToken(JSTokenStream *ts, ptrdiff_t adjust)
return tp;
}
static JS_INLINE JSBool
static JS_ALWAYS_INLINE JSBool
ScanAsSpace(jschar c)
{
/* Treat little- and big-endian BOMs as whitespace for compatibility. */

View File

@ -112,7 +112,7 @@ struct JSScript {
#endif
};
static inline uintN
static JS_INLINE uintN
StackDepth(JSScript *script)
{
return script->nslots - script->nfixed;

View File

@ -161,16 +161,28 @@
#define JS_FRIEND_API(t) JS_PUBLIC_API(t)
#define JS_FRIEND_DATA(t) JS_PUBLIC_DATA(t)
#if defined(_MSC_VER)
# define JS_INLINE __forceinline
#elif defined(__GNUC__)
# ifndef DEBUG
# define JS_INLINE __attribute__((always_inline))
#ifndef JS_INLINE
# if defined __cplusplus
# define JS_INLINE inline
# elif defined _MSC_VER
# define JS_INLINE __inline
# elif defined __GNUC__
# define JS_INLINE __inline__
# else
# define JS_INLINE inline
# define JS_INLINE inline
# endif
#endif
#ifndef JS_ALWAYS_INLINE
# if defined DEBUG
# define JS_ALWAYS_INLINE JS_INLINE
# elif defined _MSC_VER
# define JS_ALWAYS_INLINE __forceinline
# elif defined __GNUC__
# define JS_ALWAYS_INLINE __attribute__((always_inline))
# else
# define JS_ALWAYS_INLINE JS_INLINE
# endif
#else
# define JS_INLINE
#endif
/***********************************************************************