author | Nathan Froyd <froydnj@mozilla.com> |
Tue, 17 Apr 2012 14:00:20 -0400 | |
changeset 93153 | de945dddcadfb2e055f8944ba6fd1bf66aa40d20 |
parent 93152 | 32a8564667a5469168dd39230d635744720f0766 |
child 93154 | 5ea56995db762cb854f76b156c2c6a1679c76fd3 |
push id | 22611 |
push user | eakhgari@mozilla.com |
push date | Fri, 04 May 2012 20:23:57 +0000 |
treeherder | mozilla-central@dc93a3faa54e [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | bhackett |
bugs | 746238 |
milestone | 15.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
|
js/src/jsinfer.h | file | annotate | diff | comparison | revisions |
--- a/js/src/jsinfer.h +++ b/js/src/jsinfer.h @@ -929,18 +929,18 @@ struct TypeCallsite { JSScript *script; jsbytecode *pc; /* Whether this is a 'NEW' call. */ bool isNew; /* Types of each argument to the call. */ + unsigned argumentCount; TypeSet **argumentTypes; - unsigned argumentCount; /* Types of the this variable. */ TypeSet *thisTypes; /* Type set receiving the return value of this call. */ TypeSet *returnTypes; inline TypeCallsite(JSContext *cx, JSScript *script, jsbytecode *pc, @@ -1145,28 +1145,47 @@ struct RecompileInfo bool operator == (const RecompileInfo &o) const { return script == o.script && constructing == o.constructing && chunkIndex == o.chunkIndex; } }; /* Type information for a compartment. */ struct TypeCompartment { + /* Constraint solving worklist structures. */ + + /* + * Worklist of types which need to be propagated to constraints. We use a + * worklist to avoid blowing the native stack. + */ + struct PendingWork + { + TypeConstraint *constraint; + TypeSet *source; + Type type; + }; + PendingWork *pendingArray; + unsigned pendingCount; + unsigned pendingCapacity; + + /* Whether we are currently resolving the pending worklist. */ + bool resolving; + /* Whether type inference is enabled in this compartment. */ bool inferenceEnabled; - /* Number of scripts in this compartment. */ - unsigned scriptCount; - /* * Bit set if all current types must be marked as unknown, and all scripts * recompiled. Caused by OOM failure within inference operations. */ bool pendingNukeTypes; + /* Number of scripts in this compartment. */ + unsigned scriptCount; + /* Pending recompilations to perform before execution of JIT code can resume. */ Vector<RecompileInfo> *pendingRecompiles; /* * Number of recompilation events and inline frame expansions that have * occurred in this compartment. If these change, code should not count on * compiled code or the current stack being intact. */ @@ -1186,35 +1205,16 @@ struct TypeCompartment /* Tables for determining types of singleton/JSON objects. */ ArrayTypeTable *arrayTypeTable; ObjectTypeTable *objectTypeTable; void fixArrayType(JSContext *cx, JSObject *obj); void fixObjectType(JSContext *cx, JSObject *obj); - /* Constraint solving worklist structures. */ - - /* - * Worklist of types which need to be propagated to constraints. We use a - * worklist to avoid blowing the native stack. - */ - struct PendingWork - { - TypeConstraint *constraint; - TypeSet *source; - Type type; - }; - PendingWork *pendingArray; - unsigned pendingCount; - unsigned pendingCapacity; - - /* Whether we are currently resolving the pending worklist. */ - bool resolving; - /* Logging fields */ /* Counts of stack type sets with some number of possible operand types. */ static const unsigned TYPE_COUNT_LIMIT = 4; unsigned typeCounts[TYPE_COUNT_LIMIT]; unsigned typeCountOver; void init(JSContext *cx);