Commit Graph

22989 Commits

Author SHA1 Message Date
ulan
32c73eae60 Do not sample memory histograms in short idle notifications.
BUG=chromium:485472
LOG=NO
TBR=jochen@chromium.org

Review URL: https://codereview.chromium.org/1128363003

Cr-Commit-Position: refs/heads/master@{#28297}
2015-05-07 12:51:05 +00:00
domenic
c93aff4ac6 Make V8 extras a separate type of native
Instead of making them an extra option that gets passed in and compiled
at the end of the natives file for a given run of js2c, we now make them a
separate run of js2c with a separate natives file output.

This natives file output is then compiled in the bootstrapper. It is not part
of the snapshot (yet), but instead is treated similar to the experimental
natives, just without any of the complexity that comes from tieing the
behavior to flags. We also don't add counterparts to
InitializeExperimentalGlobal and InstallExperimentalNativeFunctions, yet.

R=yangguo@chromium.org, jochen@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1129743003

Cr-Commit-Position: refs/heads/master@{#28296}
2015-05-07 12:44:10 +00:00
kozyatinskiy
112f8dc97a [V8] Reland https://codereview.chromium.org/1121833003/
Chromium tests were prepared in https://codereview.chromium.org/1118743003/ and https://codereview.chromium.org/1135493002/.
Blink tests in https://codereview.chromium.org/1115193002/

LOG=Y
BUG=chromium:480652
R=yangguo@chromium.org

Review URL: https://codereview.chromium.org/1127363002

Cr-Commit-Position: refs/heads/master@{#28295}
2015-05-07 11:49:09 +00:00
ishell
0e499bfe4a [grokdump] Annoying line wrapping fixed.
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/1136443002

Cr-Commit-Position: refs/heads/master@{#28294}
2015-05-07 10:43:41 +00:00
yangguo
976b6b2ce5 Skip test-heap/NoWeakHashTableLeakWithIncrementalMarking for no-snap builds.
TBR=machenbach@chromium.org
NOTREECHECKS=true

Review URL: https://codereview.chromium.org/1130183002

Cr-Commit-Position: refs/heads/master@{#28293}
2015-05-07 10:25:41 +00:00
ulan
d77839fd01 Add aggregated memory histograms.
This introduces V8.MemoryHeapCommitted and V8.MemoryHeapUsed histograms.

In contrast to the existing memory histograms, the new histograms are uniform in time, i.e. their samples happen at regular time intervals. The --histogram-interval specifies the length of the interval.

We implement this by linearly interpolating memory stats between GC and idle notification events.

BUG=chromium:485472
LOG=NO

Review URL: https://codereview.chromium.org/1125683004

Cr-Commit-Position: refs/heads/master@{#28292}
2015-05-07 10:03:41 +00:00
yangguo
f8db4327ad Migrate error messages, part 9.
R=mvstanton@chromium.org

Review URL: https://codereview.chromium.org/1130783002

Cr-Commit-Position: refs/heads/master@{#28291}
2015-05-07 10:00:23 +00:00
Michael Achenbach
eaf0a6b1cf Whitespace CL for perf changes.
Cr-Commit-Position: refs/heads/master@{#28290}
2015-05-07 09:43:42 +00:00
v8-autoroll
0d4fbfc00b Update V8 DEPS.
Rolling v8/tools/clang to 52a578929068131eb73e907fdd6e2600e0d3180c

TBR=machenbach@chromium.org

Review URL: https://codereview.chromium.org/1133463003

Cr-Commit-Position: refs/heads/master@{#28289}
2015-05-07 09:13:08 +00:00
machenbach
e137650825 Revert of Use CLOCK_REALTIME_COARSE when available. (patchset #3 id:40001 of https://codereview.chromium.org/1125003002/)
Reason for revert:
[Sheriff] This causes layout test crashes:
http://build.chromium.org/p/client.v8/builders/V8-Blink%20Linux%2064%20%28dbg%29/builds/2735

You can add the trybot v8_linux_layout_dbg on reland.

Original issue's description:
> Use CLOCK_REALTIME_COARSE when available.
>
> On systems that have CLOCK_REALTIME_COARSE with good enough resolution, we can
> avoid making a system call to get the current time; it's serviced from the vDSO.
>
> BUG=
> LOG=N
>
> Committed: https://crrev.com/537ed7500c087786f28f51ff5222f1c2113776d3
> Cr-Commit-Position: refs/heads/master@{#28280}

TBR=jochen@chromium.org,deanm@chromium.org,bmeurer@chromium.org,ben@strongloop.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/1130083003

Cr-Commit-Position: refs/heads/master@{#28288}
2015-05-07 08:51:42 +00:00
yangguo
2f9411df89 Revert of Revert of Wrap runtime.js in a function. (patchset #1 id:1 of https://codereview.chromium.org/1123353004/)
Reason for revert:
Failing test has been fixed.

Original issue's description:
> Revert of Wrap runtime.js in a function. (patchset #2 id:20001 of https://codereview.chromium.org/1126213002/)
>
> Reason for revert:
> [Sheriff] Breaks nosnap:
> http://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20nosnap/builds/2872
>
> Original issue's description:
> > Wrap runtime.js in a function.
> >
> > R=jkummerow@chromium.org
> >
> > Committed: https://crrev.com/65c56d49b2d671ac9e379de726bff3eb03a508c1
> > Cr-Commit-Position: refs/heads/master@{#28275}
>
> TBR=jkummerow@chromium.org,yangguo@chromium.org
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
>
> Committed: https://crrev.com/62bd294f909ff448d0f876a3d745966a24cdc3f7
> Cr-Commit-Position: refs/heads/master@{#28277}

TBR=jkummerow@chromium.org,machenbach@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/1131843002

Cr-Commit-Position: refs/heads/master@{#28287}
2015-05-07 08:39:53 +00:00
yangguo
47e1c27649 Run test-heap/NoWeakHashTableLeakWithIncrementalMarking with a clean slate.
R=jkummerow@chromium.org

Review URL: https://codereview.chromium.org/1132493002

Cr-Commit-Position: refs/heads/master@{#28286}
2015-05-07 08:37:55 +00:00
machenbach
36f5f40074 Revert of Remove Scope::scope_uses_this_ flag (patchset #1 id:1 of https://codereview.chromium.org/1129823002/)
Reason for revert:
The reason for reverting is: [Sheriff] Need to fix compilation after this revert:
5cab6be83a

Original issue's description:
> Remove Scope::scope_uses_this_ flag
>
> Use of the "this" variable is now tracked using scopes, like any other variable.
>
> R=arv@chromium.org
> LOG=N
> BUG=
>
> Committed: https://crrev.com/afba55965118d9ba57e53c729f52be2340e626e0
> Cr-Commit-Position: refs/heads/master@{#28268}

TBR=arv@chromium.org,wingo@igalia.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/1131713004

Cr-Commit-Position: refs/heads/master@{#28285}
2015-05-07 07:47:11 +00:00
machenbach
b8ff13111a Revert of Remove Scope::scope_uses_arguments_ flag (patchset #1 id:1 of https://codereview.chromium.org/1124233002/)
Reason for revert:
[Sheriff] Need to fix compilation after this revert:
5cab6be83a

Original issue's description:
> Remove Scope::scope_uses_arguments_ flag
>
> Use of arguments is tracked as a variable, like any other variable.
>
> R=arv@chromium.org
> LOG=N
> BUG=
>
> Committed: https://crrev.com/d4ea33f480243fb5b7d2cca6edddcaa3e9478e29
> Cr-Commit-Position: refs/heads/master@{#28271}

TBR=arv@chromium.org,wingo@igalia.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/1134453002

Cr-Commit-Position: refs/heads/master@{#28284}
2015-05-07 07:42:29 +00:00
machenbach
5cab6be83a Revert of Resolve references to "this" the same way as normal variables (patchset #2 id:20001 of https://codereview.chromium.org/1130733003/)
Reason for revert:
[Sheriff] Breaks jetstream benchmark with errors like this:

>>> Running suite: JetStream/bigfib.cpp
>>> Stdout (#1):
undefined:93: ReferenceError: this is not defined
  this['Module'] = Module;
  ^
ReferenceError: this is not defined
    at eval (eval at __run (runner.js:13:3), <anonymous>:93:3)
    at eval (native)
    at __run (runner.js:13:3)
    at Object.runSimpleBenchmark (runner.js:44:31)
    at runner.js:97:13

Original issue's description:
> Resolve references to "this" the same way as normal variables
>
> Make the parser handle references to "this" as unresolved variables, so the
> same logic as for the rest of function parameters is used for the receiver.
> Minor additions to the code generation handle copying the receiver to the
> context, along with the rest of the function parameters.
>
> Based on work by Adrian Perez de Castro <aperez@igalia.com>.
>
> BUG=v8:2700
> LOG=N
>
> Committed: https://crrev.com/06a792b7cc2db33ffce7244c044a9c05afbb6116
> Cr-Commit-Position: refs/heads/master@{#28263}

TBR=rossberg@chromium.org,arv@chromium.org,wingo@igalia.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:2700

Review URL: https://codereview.chromium.org/1129723003

Cr-Commit-Position: refs/heads/master@{#28283}
2015-05-07 07:20:49 +00:00
yangguo
d4f014f676 Fix typo in test-heap/NoWeakHashTableLeakWithIncrementalMarking
NOTRY=true
TBR=mvstanton@chromium.org

Review URL: https://codereview.chromium.org/1130123002

Cr-Commit-Position: refs/heads/master@{#28282}
2015-05-07 06:13:01 +00:00
jochen
e5ad1b1d53 Make sure fixed typed array is always double aligned for doubles
Allows for getting rid of the special casing for float64 and is probably
faster.

BUG=v8:3996
R=verwaest@chromium.org,dslomov@chromium.org,plind44@gmail.com
LOG=n

Review URL: https://codereview.chromium.org/1128433006

Cr-Commit-Position: refs/heads/master@{#28281}
2015-05-07 05:44:49 +00:00
ben
537ed7500c Use CLOCK_REALTIME_COARSE when available.
On systems that have CLOCK_REALTIME_COARSE with good enough resolution, we can
avoid making a system call to get the current time; it's serviced from the vDSO.

BUG=
LOG=N

Review URL: https://codereview.chromium.org/1125003002

Cr-Commit-Position: refs/heads/master@{#28280}
2015-05-07 05:06:04 +00:00
chunyang.dai
4b0565262a X87: Optimize the typeof operator.
port 7798548a8f (r28260)

original commit message:

    typeof was implemented as a runtime function. Calling it in
    optimized code with a non-constant input becomes burdensome.

BUG=

Review URL: https://codereview.chromium.org/1124263005

Cr-Commit-Position: refs/heads/master@{#28279}
2015-05-07 04:01:45 +00:00
chunyang.dai
c3529ce501 X87: Resolve references to "this" the same way as normal variables
port 06a792b7cc (r28263).

original commit message:

    Make the parser handle references to "this" as unresolved variables, so the
    same logic as for the rest of function parameters is used for the receiver.
    Minor additions to the code generation handle copying the receiver to the
    context, along with the rest of the function parameters.

    Based on work by Adrian Perez de Castro <aperez@igalia.com>

BUG=

Review URL: https://codereview.chromium.org/1124393002

Cr-Commit-Position: refs/heads/master@{#28278}
2015-05-07 04:00:01 +00:00
machenbach
62bd294f90 Revert of Wrap runtime.js in a function. (patchset #2 id:20001 of https://codereview.chromium.org/1126213002/)
Reason for revert:
[Sheriff] Breaks nosnap:
http://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20nosnap/builds/2872

Original issue's description:
> Wrap runtime.js in a function.
>
> R=jkummerow@chromium.org
>
> Committed: https://crrev.com/65c56d49b2d671ac9e379de726bff3eb03a508c1
> Cr-Commit-Position: refs/heads/master@{#28275}

TBR=jkummerow@chromium.org,yangguo@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/1123353004

Cr-Commit-Position: refs/heads/master@{#28277}
2015-05-06 20:03:11 +00:00
scottmg
addbe75e19 Shard v8_base.lib on Windows to avoid 2G .lib limit
R=jochen@chromium.org
BUG=chromium:485155
LOG=y

Review URL: https://codereview.chromium.org/1124293002

Cr-Commit-Position: refs/heads/master@{#28276}
2015-05-06 19:40:09 +00:00
yangguo
65c56d49b2 Wrap runtime.js in a function.
R=jkummerow@chromium.org

Review URL: https://codereview.chromium.org/1126213002

Cr-Commit-Position: refs/heads/master@{#28275}
2015-05-06 19:25:00 +00:00
hpayer
d0423746d6 Respect double alignment in Mark-compact collector.
BUG=chromium:436911
LOG=n

Review URL: https://codereview.chromium.org/1130833002

Cr-Commit-Position: refs/heads/master@{#28274}
2015-05-06 17:26:04 +00:00
mbrandy
04b0a96b2b PPC: Optimize the typeof operator.
Port 7798548a8f

Original commit message:
typeof was implemented as a runtime function. Calling it in
optimized code with a non-constant input becomes burdensome.

R=mvstanton@chromium.org, dstence@us.ibm.com, michael_dawson@ca.ibm.com
BUG=

Review URL: https://codereview.chromium.org/1124243002

Cr-Commit-Position: refs/heads/master@{#28273}
2015-05-06 16:45:56 +00:00
mbrandy
e0ec097b2f PPC: Resolve references to "this" the same way as normal variables
Port 18619d3551

Original commit message:
Make the parser handle references to "this" as unresolved variables, so the
same logic as for the rest of function parameters is used for the receiver.
Minor additions to the code generation handle copying the receiver to the
context, along with the rest of the function parameters.

Based on work by Adrian Perez de Castro <aperez@igalia.com>.

R=wingo@igalia.com, dstence@us.ibm.com,  michael_dawson@ca.ibm.com
BUG=

Review URL: https://codereview.chromium.org/1129803003

Cr-Commit-Position: refs/heads/master@{#28272}
2015-05-06 16:30:08 +00:00
wingo
d4ea33f480 Remove Scope::scope_uses_arguments_ flag
Use of arguments is tracked as a variable, like any other variable.

R=arv@chromium.org
LOG=N
BUG=

Review URL: https://codereview.chromium.org/1124233002

Cr-Commit-Position: refs/heads/master@{#28271}
2015-05-06 16:25:21 +00:00
caitpotter88
fda20efb2f [es6] implement Object.assign
BUG=v8:4007
LOG=N
R=arv@chromium.org, rossberg@chromium.org

Review URL: https://codereview.chromium.org/548833002

Cr-Commit-Position: refs/heads/master@{#28270}
2015-05-06 16:17:50 +00:00
mbrandy
c7e02041b0 PPC: Handle the case when derived constructor is [[Call]]ed with 0 args.
Port cf53fed972

Original commit message:
ArgumentsAdaptorStub for derived constructor (the one that needs
new.target) works in this way:
 - If the constructor is invoked via the Construct stub, we know that
   actual arguments always include new.target. ``arguments`` object
   however should not include a new.target, therefore we remove it.
   We achieve this by decrementing the argument count.
 - If the constructor is invoked as a call, we do not care for a correct
   ``arguments`` array since the constructor will immediately throw on
   entrance.
The bug is that the call could actually pass 0 actual arguments, but I
decrement unconditionally :(. The fix is to detect this case and avoid
decrementing. ``arguments`` is bogus, but it is ok as constructor
throws.

Long-term we should just remove mucking about with arguments for
new.target and just get it from the stack.

R=dslomov@chromium.org, dstence@us.ibm.com, michael_dawson@ca.ibm.com
BUG=

Review URL: https://codereview.chromium.org/1125223002

Cr-Commit-Position: refs/heads/master@{#28269}
2015-05-06 16:14:09 +00:00
wingo
afba559651 Remove Scope::scope_uses_this_ flag
Use of the "this" variable is now tracked using scopes, like any other variable.

R=arv@chromium.org
LOG=N
BUG=

Review URL: https://codereview.chromium.org/1129823002

Cr-Commit-Position: refs/heads/master@{#28268}
2015-05-06 15:50:06 +00:00
hpayer
ba6d917457 Only double align in scavenger on non-64 bit platforms.
BUG=chromium:436911
LOG=n

Review URL: https://codereview.chromium.org/1128923002

Cr-Commit-Position: refs/heads/master@{#28267}
2015-05-06 15:47:32 +00:00
conradw
382435480d [es6] Fix symbol comparison on some architectures
https://codereview.chromium.org/1125783002 did not handle all cases for some
architectures. These cases are now covered, and tests have been extended to
check them.

BUG=v8:4073
LOG=N

Review URL: https://codereview.chromium.org/1128143002

Cr-Commit-Position: refs/heads/master@{#28266}
2015-05-06 15:04:47 +00:00
hpayer
74654d3098 Revert of New insertion write barrier. (patchset #3 id:200001 of https://codereview.chromium.org/1073953006/)
Reason for revert:
Various performance regressions.

Original issue's description:
> New insertion write barrier.
>
> BUG=
>
> Committed: https://crrev.com/6e9e2c08292b553602c74b16b8ccff4e4ccac003
> Cr-Commit-Position: refs/heads/master@{#28199}

TBR=ulan@chromium.org,erikcorry@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/1131583002

Cr-Commit-Position: refs/heads/master@{#28265}
2015-05-06 14:35:05 +00:00
mvstanton
9f55ccb828 Function apply(): make all architectures use an IC for performance.
BUG=
R=yangguo@chromium.org

Review URL: https://codereview.chromium.org/1116943002

Cr-Commit-Position: refs/heads/master@{#28264}
2015-05-06 14:32:07 +00:00
wingo
06a792b7cc Resolve references to "this" the same way as normal variables
Make the parser handle references to "this" as unresolved variables, so the
same logic as for the rest of function parameters is used for the receiver.
Minor additions to the code generation handle copying the receiver to the
context, along with the rest of the function parameters.

Based on work by Adrian Perez de Castro <aperez@igalia.com>.

BUG=v8:2700
LOG=N

Review URL: https://codereview.chromium.org/1130733003

Cr-Commit-Position: refs/heads/master@{#28263}
2015-05-06 14:18:08 +00:00
hpayer
fe0e49dfc5 Move double alignment logic into memory allocator.
BUG=chromium:436911

Review URL: https://codereview.chromium.org/1127993002

Cr-Commit-Position: refs/heads/master@{#28262}
2015-05-06 14:11:54 +00:00
ben
6618793e87 Add ObjectTemplate::New() taking FunctionTemplate.
I know the bug has been closed but this seems like a simple addition that may
be useful in other ways as well.

BUG=v8:2180
LOG=N

Review URL: https://codereview.chromium.org/1128553002

Cr-Commit-Position: refs/heads/master@{#28261}
2015-05-06 14:10:44 +00:00
mvstanton
7798548a8f Optimize the typeof operator.
typeof was implemented as a runtime function. Calling it in
optimized code with a non-constant input becomes burdensome.

BUG=

Review URL: https://codereview.chromium.org/1114563003

Cr-Commit-Position: refs/heads/master@{#28260}
2015-05-06 13:31:13 +00:00
bmeurer
203438d9bc [turbofan] Connect non-terminating loops via Terminate.
This revives the Terminate operator and removes the weird Always
operator. As a first step we let the ControlReducer connect non
terminating loops via Terminate. The next step will be to change the
graph builder to insert Terminate nodes into every loop.

Review URL: https://codereview.chromium.org/1123213002

Cr-Commit-Position: refs/heads/master@{#28259}
2015-05-06 12:51:44 +00:00
jochen
6fb1e76d6f Manage size of lists used in global handles
Make sure all lists are either regularly cleared or trimmed

R=hpayer@chromium.org
BUG=none
LOG=n

Review URL: https://codereview.chromium.org/1123213003

Cr-Commit-Position: refs/heads/master@{#28258}
2015-05-06 12:43:29 +00:00
titzer
6d26ec0b4c Implement IdentityMap<V>, a robust, GC-safe object-identity HashMap.
R=hpayer@chromium.org, erikcorry@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1105693002

Cr-Commit-Position: refs/heads/master@{#28257}
2015-05-06 12:40:29 +00:00
rossberg
272818d7ff Ship string unicode escapes
R=yangguo@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1130723002

Cr-Commit-Position: refs/heads/master@{#28256}
2015-05-06 12:07:59 +00:00
verwaest
5f9c0df436 Remove GetDefaultReceiver, pass in undefined to sloppy-mode functions instead.
Review URL: https://codereview.chromium.org/1116003005

Cr-Commit-Position: refs/heads/master@{#28255}
2015-05-06 11:58:37 +00:00
ben
8ceb90356b Fix FreeBSD build.
Fix the following build error:

    ../deps/v8/src/compiler/graph-visualizer.h:23:1:
    error: 'FILE' does not name a type

See https://github.com/iojs/io.js/issues/1637 for background.

BUG=v8:4079
LOG=N

Review URL: https://codereview.chromium.org/1128053002

Cr-Commit-Position: refs/heads/master@{#28254}
2015-05-06 10:57:10 +00:00
conradw
97bee8e964 [strong] Fix inlining issue
The Hydrogen representation for binops was never changed to care about the
language mode. We thought this was ok, but it turns out we need to keep track
of it to make sure inlining doesn't mess with the "strongness" of binops.

Also added more rigorous inlining testing.

BUG=v8:3956
LOG=N

Review URL: https://codereview.chromium.org/1123043002

Cr-Commit-Position: refs/heads/master@{#28253}
2015-05-06 10:40:38 +00:00
vogelheim
be9570027f Implement a 'trial parse' step, that will abort pre-parsing excessively
long and trivial functions, so that they can be eagerly compiled after all.
This essentially allows the parser to renege on its earlier decision to
lazy-parse, if additional information suggests it was a bad decision.

BUG=chromium:470930
LOG=Y

Review URL: https://codereview.chromium.org/1102523003

Cr-Commit-Position: refs/heads/master@{#28252}
2015-05-06 10:21:27 +00:00
bmeurer
7b33409ba3 [turbofan] Add support for advanced reducers.
An AdvancedReducer is basically a regular Reducer with an editor
that can perform graph editing operations beyond changing or
replacing the node that is currently being reduced. The GraphReducer
is the default implementation of the AdvancedReducer::Editor interface.

The ControlReducerImpl is now just an AdvancedReducer, which
temporarily requires a Finish method in the reducer to implement
the dead node trimming until we move that to the GraphReducer
(which in turn requires that all loops are connected to End).

Review URL: https://codereview.chromium.org/1122423003

Cr-Commit-Position: refs/heads/master@{#28251}
2015-05-06 10:12:52 +00:00
yangguo
a5de69f4f8 Migrate error messages, part 8.
R=mvstanton@chromium.org

Review URL: https://codereview.chromium.org/1118273004

Cr-Commit-Position: refs/heads/master@{#28250}
2015-05-06 07:52:05 +00:00
machenbach
f192f4cadd [test] Mark test as flaky.
TBR=yangguo@chromium.org
NOTRY=true

Review URL: https://codereview.chromium.org/1125123002

Cr-Commit-Position: refs/heads/master@{#28249}
2015-05-06 07:34:01 +00:00
yangguo
8b6c2a805d Mark mjsunit/allocation-site-info.js as NO_VARIANTS.
NOTRY=true
TBR=machenbach@chromium.org
BUG=4078
LOG=N

Review URL: https://codereview.chromium.org/1123183003

Cr-Commit-Position: refs/heads/master@{#28248}
2015-05-06 07:20:57 +00:00