Bug 960109 - convert JSJitInfo fields to bitfields; r=bz,efaust
authorNathan Froyd <froydnj@mozilla.com>
Thu, 16 Jan 2014 16:30:35 -0500
changeset 164102 2a3b16b9246af3316e7792f0bb016d9f8b2ffca7
parent 164101 0ad15bf4348290b29b394fa14511633b10168c95
child 164103 21cef8b355cea6e7785ef61567e1ea4f752f305b
push id26026
push userphilringnalda@gmail.com
push dateSat, 18 Jan 2014 23:17:27 +0000
treeherdermozilla-central@61fd0f987cf2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz, efaust
bugs960109
milestone29.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 960109 - convert JSJitInfo fields to bitfields; r=bz,efaust
dom/bindings/Codegen.py
js/src/jit/IonBuilder.cpp
js/src/jit/MIR.cpp
js/src/jit/MIR.h
js/src/jsfriendapi.h
js/src/shell/js.cpp
--- a/dom/bindings/Codegen.py
+++ b/dom/bindings/Codegen.py
@@ -5900,17 +5900,17 @@ class CGGenericMethod(CGAbstractBindingM
         CGAbstractBindingMethod.__init__(self, descriptor, name,
                                          args,
                                          unwrapFailureCode=unwrapFailureCode,
                                          allowCrossOriginThis=allowCrossOriginThis)
 
     def generate_code(self):
         return CGIndenter(CGGeneric(
             "const JSJitInfo *info = FUNCTION_VALUE_TO_JITINFO(JS_CALLEE(cx, vp));\n"
-            "MOZ_ASSERT(info->type == JSJitInfo::Method);\n"
+            "MOZ_ASSERT(info->type() == JSJitInfo::Method);\n"
             "JSJitMethodOp method = info->method;\n"
             "return method(cx, obj, self, JSJitMethodCallArgs(args));"))
 
 class CGSpecializedMethod(CGAbstractStaticMethod):
     """
     A class for generating the C++ code for a specialized method that the JIT
     can call with lower overhead.
     """
@@ -6105,17 +6105,17 @@ class CGGenericGetter(CGAbstractBindingM
                 descriptor.interface.identifier.name)
         CGAbstractBindingMethod.__init__(self, descriptor, name, args,
                                          unwrapFailureCode,
                                          allowCrossOriginThis=allowCrossOriginThis)
 
     def generate_code(self):
         return CGIndenter(CGGeneric(
             "const JSJitInfo *info = FUNCTION_VALUE_TO_JITINFO(JS_CALLEE(cx, vp));\n"
-            "MOZ_ASSERT(info->type == JSJitInfo::Getter);\n"
+            "MOZ_ASSERT(info->type() == JSJitInfo::Getter);\n"
             "JSJitGetterOp getter = info->getter;\n"
             "return getter(cx, obj, self, JSJitGetterCallArgs(args));"))
 
 class CGSpecializedGetter(CGAbstractStaticMethod):
     """
     A class for generating the code for a specialized attribute getter
     that the JIT can call with lower overhead.
     """
@@ -6221,17 +6221,17 @@ class CGGenericSetter(CGAbstractBindingM
                                          allowCrossOriginThis=allowCrossOriginThis)
 
     def generate_code(self):
         return CGIndenter(CGGeneric(
                 "if (args.length() == 0) {\n"
                 '  return ThrowErrorMessage(cx, MSG_MISSING_ARGUMENTS, "%s attribute setter");\n'
                 "}\n"
                 "const JSJitInfo *info = FUNCTION_VALUE_TO_JITINFO(JS_CALLEE(cx, vp));\n"
-                "MOZ_ASSERT(info->type == JSJitInfo::Setter);\n"
+                "MOZ_ASSERT(info->type() == JSJitInfo::Setter);\n"
                 "JSJitSetterOp setter = info->setter;\n"
                 "if (!setter(cx, obj, self, JSJitSetterCallArgs(args))) {\n"
                 "  return false;\n"
                 "}\n"
                 "args.rval().set(JSVAL_VOID);\n"
                 "return true;" % self.descriptor.interface.identifier.name))
 
 class CGSpecializedSetter(CGAbstractStaticMethod):
@@ -6352,26 +6352,26 @@ class CGMemberJITInfo(CGThing):
                             "")
         def jitInfoInitializer(isTypedMethod):
             typedMethodStr = toStringBool(isTypedMethod)
             return ("{\n"
                     " { %s },\n"
                     "  %s,\n"
                     "  %s,\n"
                     "  JSJitInfo::%s,\n"
+                    "  JSJitInfo::%s, /* aliasSet.  Not relevant for setters. */\n"
                     "  %s,  /* returnType.  Not relevant for setters. */\n"
                     "  %s,  /* isInfallible. False in setters. */\n"
                     "  %s,  /* isMovable.  Not relevant for setters. */\n"
                     "  %s,  /* isInSlot.  Only relevant for getters. */\n"
                     "  %s,  /* isTypedMethod.  Only relevant for methods. */\n"
-                    "  %s,  /* Reserved slot index, if we're stored in a slot, else 0. */\n"
-                    "  JSJitInfo::%s  /* aliasSet.  Not relevant for setters. */\n"
-                    "}" % (opName, protoID, depth, opType,
+                    "  %s   /* Reserved slot index, if we're stored in a slot, else 0. */\n"
+                    "}" % (opName, protoID, depth, opType, aliasSet,
                            returnType, failstr, movablestr, slotStr,
-                           typedMethodStr, slotIndex, aliasSet))
+                           typedMethodStr, slotIndex))
         if args is not None:
             argTypes = "%s_argTypes" % infoName
             args = [CGMemberJITInfo.getJSArgType(arg.type) for arg in args]
             args.append("JSJitInfo::ArgTypeListEnd")
             argTypesDecl = (
                 "static const JSJitInfo::ArgType %s[] = { %s };\n" %
                 (argTypes, ", ".join(args)))
             return ("\n"
--- a/js/src/jit/IonBuilder.cpp
+++ b/js/src/jit/IonBuilder.cpp
@@ -5087,17 +5087,17 @@ IonBuilder::testShouldDOMCall(types::Typ
 
     // If all the DOM objects flowing through are legal with this
     // property, we can bake in a call to the bottom half of the DOM
     // accessor
     DOMInstanceClassMatchesProto instanceChecker =
         compartment->runtime()->DOMcallbacks()->instanceClassMatchesProto;
 
     const JSJitInfo *jinfo = func->jitInfo();
-    if (jinfo->type != opType)
+    if (jinfo->type() != opType)
         return false;
 
     for (unsigned i = 0; i < inTypes->getObjectCount(); i++) {
         types::TypeObjectKey *curType = inTypes->getObject(i);
         if (!curType)
             continue;
 
         if (!curType->hasTenuredProto())
@@ -5238,26 +5238,26 @@ IonBuilder::makeCallHelper(JSFunction *t
     return call;
 }
 
 static bool
 DOMCallNeedsBarrier(const JSJitInfo* jitinfo, types::TemporaryTypeSet *types)
 {
     // If the return type of our DOM native is in "types" already, we don't
     // actually need a barrier.
-    if (jitinfo->returnType == JSVAL_TYPE_UNKNOWN)
+    if (jitinfo->returnType() == JSVAL_TYPE_UNKNOWN)
         return true;
 
     // JSVAL_TYPE_OBJECT doesn't tell us much; we still have to barrier on the
     // actual type of the object.
-    if (jitinfo->returnType == JSVAL_TYPE_OBJECT)
+    if (jitinfo->returnType() == JSVAL_TYPE_OBJECT)
         return true;
 
     // No need for a barrier if we're already expecting the type we'll produce.
-    return jitinfo->returnType != types->getKnownTypeTag();
+    return jitinfo->returnType() != types->getKnownTypeTag();
 }
 
 bool
 IonBuilder::makeCall(JSFunction *target, CallInfo &callInfo, bool cloneAtCallsite)
 {
     // Constructor calls to non-constructors should throw. We don't want to use
     // CallKnown in this case.
     JS_ASSERT_IF(callInfo.constructing() && target,
@@ -6220,22 +6220,22 @@ IonBuilder::pushDOMTypeBarrier(MInstruct
     // Need to be a bit careful: if jitinfo->returnType is JSVAL_TYPE_DOUBLE but
     // types->getKnownTypeTag() is JSVAL_TYPE_INT32, then don't unconditionally
     // unbox as a double.  Instead, go ahead and barrier on having an int type,
     // since we know we need a barrier anyway due to the type mismatch.  This is
     // the only situation in which TI actually has more information about the
     // JSValueType than codegen can, short of jitinfo->returnType just being
     // JSVAL_TYPE_UNKNOWN.
     MDefinition* replace = ins;
-    if (jitinfo->returnType != JSVAL_TYPE_DOUBLE ||
+    if (jitinfo->returnType() != JSVAL_TYPE_DOUBLE ||
         observed->getKnownTypeTag() != JSVAL_TYPE_INT32) {
-        JS_ASSERT(jitinfo->returnType == JSVAL_TYPE_UNKNOWN ||
+        JS_ASSERT(jitinfo->returnType() == JSVAL_TYPE_UNKNOWN ||
                   observed->getKnownTypeTag() == JSVAL_TYPE_UNKNOWN ||
-                  jitinfo->returnType == observed->getKnownTypeTag());
-        replace = ensureDefiniteType(ins, jitinfo->returnType);
+                  jitinfo->returnType() == observed->getKnownTypeTag());
+        replace = ensureDefiniteType(ins, jitinfo->returnType());
         if (replace != ins) {
             current->pop();
             current->push(replace);
         }
     } else {
         JS_ASSERT(barrier);
     }
 
@@ -8830,17 +8830,17 @@ IonBuilder::setPropTryCommonDOMSetter(bo
     if (!isDOM)
         return true;
 
     types::TemporaryTypeSet *objTypes = obj->resultTypeSet();
     if (!testShouldDOMCall(objTypes, setter, JSJitInfo::Setter))
         return true;
 
     // Emit SetDOMProperty.
-    JS_ASSERT(setter->jitInfo()->type == JSJitInfo::Setter);
+    JS_ASSERT(setter->jitInfo()->type() == JSJitInfo::Setter);
     MSetDOMProperty *set = MSetDOMProperty::New(alloc(), setter->jitInfo()->setter, obj, value);
 
     current->add(set);
     current->push(value);
 
     if (!resumeAfter(set))
         return false;
 
--- a/js/src/jit/MIR.cpp
+++ b/js/src/jit/MIR.cpp
@@ -666,21 +666,21 @@ MCall::New(TempAllocator &alloc, JSFunct
 AliasSet
 MCallDOMNative::getAliasSet() const
 {
     JS_ASSERT(getSingleTarget() && getSingleTarget()->isNative());
 
     const JSJitInfo *jitInfo = getSingleTarget()->jitInfo();
     JS_ASSERT(jitInfo);
 
-    JS_ASSERT(jitInfo->aliasSet != JSJitInfo::AliasNone);
+    JS_ASSERT(jitInfo->aliasSet() != JSJitInfo::AliasNone);
     // If we don't know anything about the types of our arguments, we have to
     // assume that type-coercions can have side-effects, so we need to alias
     // everything.
-    if (jitInfo->aliasSet != JSJitInfo::AliasDOMSets || !jitInfo->isTypedMethodJitInfo())
+    if (jitInfo->aliasSet() != JSJitInfo::AliasDOMSets || !jitInfo->isTypedMethodJitInfo())
         return AliasSet::Store(AliasSet::Any);
 
     uint32_t argIndex = 0;
     const JSTypedMethodJitInfo *methodInfo =
         reinterpret_cast<const JSTypedMethodJitInfo*>(jitInfo);
     for (const JSJitInfo::ArgType *argType = methodInfo->argTypes;
          *argType != JSJitInfo::ArgTypeListEnd;
          ++argType, ++argIndex)
@@ -718,17 +718,17 @@ MCallDOMNative::computeMovable()
     // effectful.  The jitinfo can't check for the latter, since it depends on
     // the types of our arguments.
     JS_ASSERT(getSingleTarget() && getSingleTarget()->isNative());
 
     const JSJitInfo *jitInfo = getSingleTarget()->jitInfo();
     JS_ASSERT(jitInfo);
 
     JS_ASSERT_IF(jitInfo->isMovable,
-                 jitInfo->aliasSet != JSJitInfo::AliasEverything);
+                 jitInfo->aliasSet() != JSJitInfo::AliasEverything);
 
     if (jitInfo->isMovable && !isEffectful())
         setMovable();
 }
 
 bool
 MCallDOMNative::congruentTo(MDefinition *ins) const
 {
--- a/js/src/jit/MIR.h
+++ b/js/src/jit/MIR.h
@@ -7913,26 +7913,26 @@ class MGetDOMProperty
 {
     const JSJitInfo *info_;
 
   protected:
     MGetDOMProperty(const JSJitInfo *jitinfo, MDefinition *obj, MDefinition *guard)
       : info_(jitinfo)
     {
         JS_ASSERT(jitinfo);
-        JS_ASSERT(jitinfo->type == JSJitInfo::Getter);
+        JS_ASSERT(jitinfo->type() == JSJitInfo::Getter);
 
         setOperand(0, obj);
 
         // Pin the guard as an operand if we want to hoist later
         setOperand(1, guard);
 
         // We are movable iff the jitinfo says we can be.
         if (isDomMovable()) {
-            JS_ASSERT(jitinfo->aliasSet != JSJitInfo::AliasEverything);
+            JS_ASSERT(jitinfo->aliasSet() != JSJitInfo::AliasEverything);
             setMovable();
         }
 
         setResultType(MIRType_Value);
     }
 
     const JSJitInfo *info() const {
         return info_;
@@ -7952,17 +7952,17 @@ class MGetDOMProperty
     }
     bool isInfallible() const {
         return info_->isInfallible;
     }
     bool isDomMovable() const {
         return info_->isMovable;
     }
     JSJitInfo::AliasSet domAliasSet() const {
-        return info_->aliasSet;
+        return info_->aliasSet();
     }
     size_t domMemberSlotIndex() const {
         MOZ_ASSERT(info_->isInSlot);
         return info_->slotIndex;
     }
     MDefinition *object() {
         return getOperand(0);
     }
--- a/js/src/jsfriendapi.h
+++ b/js/src/jsfriendapi.h
@@ -1443,21 +1443,23 @@ typedef bool
 typedef bool
 (* JSJitSetterOp)(JSContext *cx, JS::HandleObject thisObj,
                   void *specializedThis, JSJitSetterCallArgs args);
 typedef bool
 (* JSJitMethodOp)(JSContext *cx, JS::HandleObject thisObj,
                   void *specializedThis, const JSJitMethodCallArgs& args);
 
 struct JSJitInfo {
-    enum OpType MOZ_ENUM_TYPE(uint8_t) {
+    enum OpType {
         Getter,
         Setter,
         Method,
-        ParallelNative
+        ParallelNative,
+        // Must be last
+        OpTypeCount
     };
 
     enum ArgType {
         // Basic types
         String = (1 << 0),
         Integer = (1 << 1), // Only 32-bit or less
         Double = (1 << 2), // Maybe we want to add Float sometime too
         Boolean = (1 << 3),
@@ -1471,95 +1473,142 @@ struct JSJitInfo {
         Primitive = Numeric | Boolean | Null | String,
         ObjectOrNull = Object | Null,
         Any = ObjectOrNull | Primitive,
 
         // Our sentinel value.
         ArgTypeListEnd = (1 << 31)
     };
 
-    enum AliasSet MOZ_ENUM_TYPE(uint8_t) {
+    enum AliasSet {
         // An enum that describes what this getter/setter/method aliases.  This
         // determines what things can be hoisted past this call, and if this
         // call is movable what it can be hoisted past.
 
         // Alias nothing: a constant value, getting it can't affect any other
         // values, nothing can affect it.
         AliasNone,
 
         // Alias things that can modify the DOM but nothing else.  Doing the
         // call can't affect the behavior of any other function.
         AliasDOMSets,
 
         // Alias the world.  Calling this can change arbitrary values anywhere
         // in the system.  Most things fall in this bucket.
-        AliasEverything
+        AliasEverything,
+
+        // Must be last.
+        AliasSetCount
     };
 
     bool hasParallelNative() const
     {
-        return type == ParallelNative;
+        return type() == ParallelNative;
     }
 
     bool isDOMJitInfo() const
     {
-        return type != ParallelNative;
+        return type() != ParallelNative;
     }
 
     bool isTypedMethodJitInfo() const
     {
         return isTypedMethod;
     }
 
+    OpType type() const
+    {
+        return OpType(type_);
+    }
+
+    AliasSet aliasSet() const
+    {
+        return AliasSet(aliasSet_);
+    }
+
+    JSValueType returnType() const
+    {
+        return JSValueType(returnType_);
+    }
+
     union {
         JSJitGetterOp getter;
         JSJitSetterOp setter;
         JSJitMethodOp method;
         /* An alternative native that's safe to call in parallel mode. */
         JSParallelNative parallelNative;
     };
 
     uint16_t protoID;
     uint16_t depth;
-    // type not being ParallelNative means this is a DOM method.  If you
-    // change that, come up with a different way of implementing
+
+    // These fields are carefully packed to take up 4 bytes.  If you need more
+    // bits for whatever reason, please see if you can steal bits from existing
+    // fields before adding more members to this structure.
+
+#define JITINFO_OP_TYPE_BITS 4
+#define JITINFO_ALIAS_SET_BITS 4
+#define JITINFO_RETURN_TYPE_BITS 8
+
+    // If this field is not ParallelNative, then this is a DOM method.
+    // If you change that, come up with a different way of implementing
     // isDOMJitInfo().
-    OpType type;
-    JSValueType returnType; /* The return type tag.  Might be JSVAL_TYPE_UNKNOWN */
-    uint16_t isInfallible : 1; /* Is op fallible? False in setters. */
-    uint16_t isMovable : 1;    /* Is op movable?  To be movable the op must
+    uint32_t type_ : JITINFO_OP_TYPE_BITS;
+
+    // The alias set for this op.  This is a _minimal_ alias set; in
+    // particular for a method it does not include whatever argument
+    // conversions might do.  That's covered by argTypes and runtime
+    // analysis of the actual argument types being passed in.
+    uint32_t aliasSet_ : JITINFO_ALIAS_SET_BITS;
+
+    // The return type tag.  Might be JSVAL_TYPE_UNKNOWN.
+    uint32_t returnType_ : JITINFO_RETURN_TYPE_BITS;
+
+    static_assert(OpTypeCount <= (1 << JITINFO_OP_TYPE_BITS),
+                  "Not enough space for OpType");
+    static_assert(AliasSetCount <= (1 << JITINFO_ALIAS_SET_BITS),
+                  "Not enough space for AliasSet");
+    static_assert((sizeof(JSValueType) * 8) <= JITINFO_RETURN_TYPE_BITS,
+                  "Not enough space for JSValueType");
+
+#undef JITINFO_RETURN_TYPE_BITS
+#undef JITINFO_ALIAS_SET_BITS
+#undef JITINFO_OP_TYPE_BITS
+
+    uint32_t isInfallible : 1; /* Is op fallible? False in setters. */
+    uint32_t isMovable : 1;    /* Is op movable?  To be movable the op must
                                   not AliasEverything, but even that might
                                   not be enough (e.g. in cases when it can
                                   throw). */
     // XXXbz should we have a JSValueType for the type of the member?
-    uint16_t isInSlot : 1;     /* True if this is a getter that can get a member
+    uint32_t isInSlot : 1;     /* True if this is a getter that can get a member
                                   from a slot of the "this" object directly. */
-    uint16_t isTypedMethod : 1; /* True if this is an instance of
+    uint32_t isTypedMethod : 1; /* True if this is an instance of
                                    JSTypedMethodJitInfo. */
-    uint16_t slotIndex : 12;   /* If isInSlot is true, the index of the slot to
+    uint32_t slotIndex : 12;   /* If isInSlot is true, the index of the slot to
                                   get the value from.  Otherwise 0. */
 
-    AliasSet aliasSet;      /* The alias set for this op.  This is a _minimal_
-                               alias set; in particular for a method it does not
-                               include whatever argument conversions might do.
-                               That's covered by argTypes and runtime analysis
-                               of the actual argument types being passed in. */
-
 private:
     static void staticAsserts()
     {
         JS_STATIC_ASSERT(Any & String);
         JS_STATIC_ASSERT(Any & Integer);
         JS_STATIC_ASSERT(Any & Double);
         JS_STATIC_ASSERT(Any & Boolean);
         JS_STATIC_ASSERT(Any & Object);
         JS_STATIC_ASSERT(Any & Null);
     }
 };
 
+static_assert(sizeof(JSJitInfo) == (sizeof(void*) + 2 * sizeof(uint32_t)),
+              "There are several thousand instances of JSJitInfo stored in "
+              "a binary. Please don't increase its space requirements without "
+              "verifying that there is no other way forward (better packing, "
+              "smaller datatypes for fields, subclassing, etc.).");
+
 struct JSTypedMethodJitInfo
 {
     // We use C-style inheritance here, rather than C++ style inheritance
     // because not all compilers support brace-initialization for non-aggregate
     // classes. Using C++ style inheritance and constructors instead of
     // brace-initialization would also force the creation of static
     // constructors (on some compilers) when JSJitInfo and JSTypedMethodJitInfo
     // structures are declared. Since there can be several thousand of these
@@ -1599,17 +1648,17 @@ inline int CheckIsParallelNative(JSParal
  * a datum of the type of the union's first member.)
  *
  * Presumably this has something to do with template instantiation.
  * Initializing with a normal function pointer seems to work fine. Hence
  * the ugliness that you see before you.
  */
 #define JS_JITINFO_NATIVE_PARALLEL(infoName, parallelOp)                \
     const JSJitInfo infoName =                                          \
-        {{JS_CAST_PARALLEL_NATIVE_TO(parallelOp, JSJitGetterOp)},0,0,JSJitInfo::ParallelNative,JSVAL_TYPE_MISSING,false,false,false,false,0,JSJitInfo::AliasEverything}
+        {{JS_CAST_PARALLEL_NATIVE_TO(parallelOp, JSJitGetterOp)},0,0,JSJitInfo::ParallelNative,JSJitInfo::AliasEverything,JSVAL_TYPE_MISSING,false,false,false,false,0}
 
 #define JS_JITINFO_NATIVE_PARALLEL_THREADSAFE(infoName, wrapperName, serialOp) \
     bool wrapperName##_ParallelNativeThreadSafeWrapper(js::ForkJoinSlice *slice, unsigned argc, \
                                                        JS::Value *vp)   \
     {                                                                   \
         return JSParallelNativeThreadSafeWrapper<serialOp>(slice, argc, vp); \
     }                                                                   \
     JS_JITINFO_NATIVE_PARALLEL(infoName, wrapperName##_ParallelNativeThreadSafeWrapper)
--- a/js/src/shell/js.cpp
+++ b/js/src/shell/js.cpp
@@ -4828,52 +4828,52 @@ dom_doFoo(JSContext* cx, HandleObject ob
     args.rval().setInt32(args.length());
     return true;
 }
 
 static const JSJitInfo dom_x_getterinfo = {
     { (JSJitGetterOp)dom_get_x },
     0,        /* protoID */
     0,        /* depth */
+    JSJitInfo::AliasNone, /* aliasSet */
     JSJitInfo::Getter,
     JSVAL_TYPE_UNKNOWN, /* returnType */
     true,     /* isInfallible. False in setters. */
     true,     /* isMovable */
     false,    /* isInSlot */
     false,    /* isTypedMethod */
-    0,        /* slotIndex */
-    JSJitInfo::AliasNone /* aliasSet */
+    0         /* slotIndex */
 };
 
 static const JSJitInfo dom_x_setterinfo = {
     { (JSJitGetterOp)dom_set_x },
     0,        /* protoID */
     0,        /* depth */
     JSJitInfo::Setter,
+    JSJitInfo::AliasEverything, /* aliasSet */
     JSVAL_TYPE_UNKNOWN, /* returnType */
     false,    /* isInfallible. False in setters. */
     false,    /* isMovable. */
     false,    /* isInSlot */
     false,    /* isTypedMethod */
-    0,        /* slotIndex */
-    JSJitInfo::AliasEverything /* aliasSet */
+    0         /* slotIndex */
 };
 
 static const JSJitInfo doFoo_methodinfo = {
     { (JSJitGetterOp)dom_doFoo },
     0,        /* protoID */
     0,        /* depth */
     JSJitInfo::Method,
+    JSJitInfo::AliasEverything, /* aliasSet */
     JSVAL_TYPE_UNKNOWN, /* returnType */
     false,    /* isInfallible. False in setters. */
     false,    /* isMovable */
     false,    /* isInSlot */
     false,    /* isTypedMethod */
-    0,        /* slotIndex */
-    JSJitInfo::AliasEverything /* aliasSet */
+    0         /* slotIndex */
 };
 
 static const JSPropertySpec dom_props[] = {
     {"x", 0,
      JSPROP_SHARED | JSPROP_ENUMERATE | JSPROP_NATIVE_ACCESSORS,
      { (JSPropertyOp)dom_genericGetter, &dom_x_getterinfo },
      { (JSStrictPropertyOp)dom_genericSetter, &dom_x_setterinfo }
     },
@@ -4920,17 +4920,17 @@ dom_genericGetter(JSContext *cx, unsigne
     if (JS_GetClass(obj) != &dom_class) {
         args.rval().set(UndefinedValue());
         return true;
     }
 
     JS::Value val = js::GetReservedSlot(obj, DOM_OBJECT_SLOT);
 
     const JSJitInfo *info = FUNCTION_VALUE_TO_JITINFO(JS_CALLEE(cx, vp));
-    MOZ_ASSERT(info->type == JSJitInfo::Getter);
+    MOZ_ASSERT(info->type() == JSJitInfo::Getter);
     JSJitGetterOp getter = info->getter;
     return getter(cx, obj, val.toPrivate(), JSJitGetterCallArgs(args));
 }
 
 static bool
 dom_genericSetter(JSContext* cx, unsigned argc, JS::Value* vp)
 {
     CallArgs args = CallArgsFromVp(argc, vp);
@@ -4943,17 +4943,17 @@ dom_genericSetter(JSContext* cx, unsigne
     if (JS_GetClass(obj) != &dom_class) {
         args.rval().set(UndefinedValue());
         return true;
     }
 
     JS::Value val = js::GetReservedSlot(obj, DOM_OBJECT_SLOT);
 
     const JSJitInfo *info = FUNCTION_VALUE_TO_JITINFO(JS_CALLEE(cx, vp));
-    MOZ_ASSERT(info->type == JSJitInfo::Setter);
+    MOZ_ASSERT(info->type() == JSJitInfo::Setter);
     JSJitSetterOp setter = info->setter;
     if (!setter(cx, obj, val.toPrivate(), JSJitSetterCallArgs(args)))
         return false;
     args.rval().set(UndefinedValue());
     return true;
 }
 
 static bool
@@ -4967,17 +4967,17 @@ dom_genericMethod(JSContext* cx, unsigne
     if (JS_GetClass(obj) != &dom_class) {
         args.rval().set(UndefinedValue());
         return true;
     }
 
     JS::Value val = js::GetReservedSlot(obj, DOM_OBJECT_SLOT);
 
     const JSJitInfo *info = FUNCTION_VALUE_TO_JITINFO(JS_CALLEE(cx, vp));
-    MOZ_ASSERT(info->type == JSJitInfo::Method);
+    MOZ_ASSERT(info->type() == JSJitInfo::Method);
     JSJitMethodOp method = info->method;
     return method(cx, obj, val.toPrivate(), JSJitMethodCallArgs(args));
 }
 
 static void
 InitDOMObject(HandleObject obj)
 {
     /* Fow now just initialize to a constant we can check. */