Commit Graph

703 Commits

Author SHA1 Message Date
yangguo
57ee3c0f6e Revert of Implement SharedArrayBuffer (patchset #7 id:120001 of https://codereview.chromium.org/1136553006/)
Reason for revert:
breaks build

Original issue's description:
> Implement SharedArrayBuffer.
>
> This adds a new external type (v8::SharedArrayBuffer) that uses a JSArrayBuffer under the hood. It can be distinguished from an ArrayBuffer by the newly-added is_shared() bit.
>
> Currently there is no difference in functionality between a SharedArrayBuffer and an ArrayBuffer. However, a future CL will add the Atomics API, which is only available on an SharedArrayBuffer. All non-atomic accesses are identical to ArrayBuffer accesses.
>
> BUG=
>
> Committed: https://crrev.com/57170bff7baf341c666252a7f6a49e9c08d51263
> Cr-Commit-Position: refs/heads/master@{#28588}

TBR=jarin@chromium.org,jochen@chromium.org,binji@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

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

Cr-Commit-Position: refs/heads/master@{#28589}
2015-05-22 12:17:49 +00:00
binji
57170bff7b Implement SharedArrayBuffer.
This adds a new external type (v8::SharedArrayBuffer) that uses a JSArrayBuffer under the hood. It can be distinguished from an ArrayBuffer by the newly-added is_shared() bit.

Currently there is no difference in functionality between a SharedArrayBuffer and an ArrayBuffer. However, a future CL will add the Atomics API, which is only available on an SharedArrayBuffer. All non-atomic accesses are identical to ArrayBuffer accesses.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#28588}
2015-05-22 12:06:44 +00:00
yangguo
e56585077b Use shared container to manage imports/exports.
Also changed string.js and math.js to adapt this change.

R=jkummerow@chromium.org

Committed: https://crrev.com/e25058b0b7b9831162579564fc8935d568c1ecdd
Cr-Commit-Position: refs/heads/master@{#28521}

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

Cr-Commit-Position: refs/heads/master@{#28533}
2015-05-21 06:15:19 +00:00
jkummerow
1ec5561685 Revert of Use shared container to manage imports/exports. (patchset #2 id:20001 of https://codereview.chromium.org/1143993003/)
Reason for revert:
Breaks nosnap bots

Original issue's description:
> Use shared container to manage imports/exports.
>
> Also changed string.js and math.js to adapt this change.
>
> R=jkummerow@chromium.org
>
> Committed: https://crrev.com/e25058b0b7b9831162579564fc8935d568c1ecdd
> Cr-Commit-Position: refs/heads/master@{#28521}

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

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

Cr-Commit-Position: refs/heads/master@{#28523}
2015-05-20 15:59:37 +00:00
yangguo
e25058b0b7 Use shared container to manage imports/exports.
Also changed string.js and math.js to adapt this change.

R=jkummerow@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#28521}
2015-05-20 14:58:43 +00:00
arv
834a8e9f63 [es6] Iterators and generators should "extend" %IteratorPrototype%
All the builtin iterators as well as the generator objects have an
object called %IteratorPrototype% in the spec between them and
%ObjectPrototype%.

BUG=v8:3568
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#28426}
2015-05-15 15:09:38 +00:00
dslomov
7f6ae2300b [destructuring] Adapting PatternRewriter to work in C-style for-statements.
BUG=v8:811
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#28417}
2015-05-15 09:56:24 +00:00
dslomov
5bbe7992db [destructuring] Implement basic binding destructuring infrastructure
This patch:
  - Refactors Parser::ParseVariableDeclarations
  - Introduces Parser::PatternMatcher class
  - Implements matching a single variable pattern
  - Implements rudimentary matching against object literal pattern
    as a proof of concept

R=arv@chromium.org,rossberg@chromium.org
BUG=v8:811
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#28345}
2015-05-11 16:28:22 +00:00
titzer
256ae73652 [turbofan] Extract frame-states.h from common-operator.h
R=jarin@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#28330}
2015-05-11 08:02:58 +00:00
domenic
570fca61fc Re-land: 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 need counterparts to
InitializeExperimentalGlobal and InstallExperimentalNativeFunctions (yet?).

This fixes the issue with https://codereview.chromium.org/1129743003 by making
the dummy file that is generated for snapshots with no extras (or no experimental
features) nonempty.

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

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

Cr-Commit-Position: refs/heads/master@{#28311}
2015-05-08 08:44:51 +00:00
domenic
010c515d0f Revert of Make V8 extras a separate type of native (patchset #4 id:60001 of https://codereview.chromium.org/1129743003/)
Reason for revert:
https://build.chromium.org/p/client.v8/builders/V8-Blink%20Linux%2064%20%28dbg%29/builds/2745

Original issue's description:
> 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=
>
> Committed: https://crrev.com/c93aff4ac63ad9ffb6318e750335208de32b7902
> Cr-Commit-Position: refs/heads/master@{#28296}

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

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

Cr-Commit-Position: refs/heads/master@{#28299}
2015-05-07 14:26:44 +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
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
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
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
bmeurer
d21de2a48b [turbofan] Fix tail call optimization.
Tail calls are matched on the graph, with a dedicated tail call
optimization that is actually testable. The instruction selection can
still fall back to a regular if the platform constraints don't allow to
emit a tail call (i.e. the return locations of caller and callee differ
or the callee takes non-register parameters, which is a restriction that
will be removed in the future).

Also explicitly limit tail call optimization to stubs for now and drop
the global flag.

BUG=v8:4076
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#28219}
2015-05-05 09:43:02 +00:00
titzer
acdb5336a9 Extract Signature from src/compiler/machine-type.h to src/signature.h
R=bmeurer@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#28191}
2015-05-04 10:11:54 +00:00
svenpanne
bc7f79a670 Calculate blocks needing a frame and frame (de)construction sites.
Review URL: https://codereview.chromium.org/1053123006

Cr-Commit-Position: refs/heads/master@{#28120}
2015-04-29 05:54:52 +00:00
domenic
8a89a4a5ce Allow extra library files to be snapshotted
BUG=
R=jochen@chromium.org, yangguo@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#28110}
2015-04-28 14:56:07 +00:00
svenpanne
4d3044e161 Removed src/{isolate,property-details,utils}-inl.h
Baby steps towards saner #includes...

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

Cr-Commit-Position: refs/heads/master@{#27958}
2015-04-21 10:21:37 +00:00
svenpanne
314e73d1ec Import Reversed adapter from Chromium and use it in v8.
Review URL: https://codereview.chromium.org/1098863003

Cr-Commit-Position: refs/heads/master@{#27947}
2015-04-20 16:24:37 +00:00
titzer
f557d75360 Reland "Refactor compilation dependency handling."
R=mstarzinger@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#27945}
2015-04-20 15:21:44 +00:00
machenbach
e3c2ba776a Revert of Refactor compilation dependency handling. (patchset #4 id:60001 of https://codereview.chromium.org/1095433002/)
Reason for revert:
[Sheriff] Causes crashes in laout tests:
http://build.chromium.org/p/client.v8/builders/V8-Blink%20Linux%2064%20%28dbg%29/builds/2543

Extra bisect run:
http://build.chromium.org/p/client.v8/builders/V8-Blink%20Linux%2064%20%28dbg%29/builds/2548

Original issue's description:
> Refactor compilation dependency handling.
>
> Extract a new data structure CompilationDependencies and move (most) logic there.
>
> R=mstarzinger@chromium.org,verwaest@chromium.org
> BUG=
>
> Committed: https://crrev.com/b882479f1c84a48961b8aec81fa1bb1225034784
> Cr-Commit-Position: refs/heads/master@{#27892}

TBR=mstarzinger@chromium.org,verwaest@chromium.org,titzer@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

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

Cr-Commit-Position: refs/heads/master@{#27904}
2015-04-17 07:47:09 +00:00
titzer
b882479f1c Refactor compilation dependency handling.
Extract a new data structure CompilationDependencies and move (most) logic there.

R=mstarzinger@chromium.org,verwaest@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#27892}
2015-04-16 16:04:34 +00:00
yangguo
a5ac029058 Start migrating error message templates to the runtime.
Currently done with two templates, one used from native js, one from runtime.

R=verwaest@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#27864}
2015-04-16 07:01:16 +00:00
bmeurer
d641cc457c [turbofan] Split ControlEquivalence implementation and add trace flag.
Split interface and implementation of ControlEquivalence and add a
dedicated trace flag --trace-turbo-ceq to make it reusable outside the
scheduler.

R=jarin@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#27862}
2015-04-16 06:04:36 +00:00
jochen
e683048416 Reland "Remove support for thread-based recompilation"
Original issue's description:
> Remove support for thread-based recompilation
>
> BUG=v8:3608
> R=yangguo@chromium.org
> LOG=y
>
> Committed: https://crrev.com/ed5db223a19dfe126af01
> Cr-Commit-Position: refs/heads/master@{#27619}

BUG=v8:3608
R=yangguo@chromium.org
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#27821}
2015-04-14 13:57:29 +00:00
jochen
cf663c487f Revert of Reland "Remove support for thread-based recompilation" (patchset #1 id:1 of https://codereview.chromium.org/1059853004/)
Reason for revert:
still times out

Original issue's description:
> Reland "Remove support for thread-based recompilation"
>
> Original issue's description:
> > Remove support for thread-based recompilation
> >
> > BUG=v8:3608
> > R=yangguo@chromium.org
> > LOG=y
> >
> > Committed: https://crrev.com/ed5db223a19dfe126af012e894582251aa3635d7
> > Cr-Commit-Position: refs/heads/master@{#27619}
>
> BUG=v8:3608
> R=yangguo@chromium.org
> LOG=y
>
> Committed: https://crrev.com/f1ceccb8b8b352a91e6366e3e3103f1db0df6afb
> Cr-Commit-Position: refs/heads/master@{#27813}

TBR=yangguo@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3608

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

Cr-Commit-Position: refs/heads/master@{#27816}
2015-04-14 12:29:26 +00:00
jochen
f1ceccb8b8 Reland "Remove support for thread-based recompilation"
Original issue's description:
> Remove support for thread-based recompilation
>
> BUG=v8:3608
> R=yangguo@chromium.org
> LOG=y
>
> Committed: https://crrev.com/ed5db223a19dfe126af012e894582251aa3635d7
> Cr-Commit-Position: refs/heads/master@{#27619}

BUG=v8:3608
R=yangguo@chromium.org
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#27813}
2015-04-14 10:26:41 +00:00
caitpotter88
74c381221c [es6] implement spread calls
BUG=v8:3018
R=
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#27714}
2015-04-09 19:37:19 +00:00
yangguo
c4081d2503 Revert of Remove support for thread-based recompilation (patchset #1 id:1 of https://codereview.chromium.org/966653002/)
Reason for revert:
speculative revert due to gc-stress timeouts.

Original issue's description:
> Remove support for thread-based recompilation
>
> BUG=v8:3608
> R=yangguo@chromium.org
> LOG=y
>
> Committed: https://crrev.com/ed5db223a19dfe126af012e894582251aa3635d7
> Cr-Commit-Position: refs/heads/master@{#27619}

TBR=jochen@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
BUG=v8:3608
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#27654}
2015-04-08 10:29:33 +00:00
Jochen Eisinger
ed5db223a1 Remove support for thread-based recompilation
BUG=v8:3608
R=yangguo@chromium.org
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#27619}
2015-04-07 10:59:57 +00:00
rmcilroy
11c4e2f2f7 Fix libdl dependency on Android and remove librt hack.
The libdl library is already included on target builds of Android and needs
to be added to the build command line with a particular order to avoid
undefined references in other libraries. Fix this by only explicitly including
it in host builds and relying on the implicit inclusion on target builds.

Also remove the librt hack which is not longer necessary due to the AOSP build
bot having been removed.

BUG=chromium:469973
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#27535}
2015-03-31 12:08:21 +00:00
vogelheim
ee9c738929 Re-work the 'external snapshot' related build rules.
This prepares for re-landing crrev.com/956373002

This pulls all decision about the snapshot [no|internal|external] into one rule. Previously, this logic was in separate places and not /quite/ the same, which causes build problems.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#27523}
2015-03-30 14:54:27 +00:00
yangguo
019096f829 Serializer: move to a subfolder and clean up includes.
R=jochen@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#27501}
2015-03-27 15:29:07 +00:00
titzer
78abf9d9d9 [turbofan]: Integrate basic type feedback for property accesses.
BUG=

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

Cr-Commit-Position: refs/heads/master@{#27470}
2015-03-26 09:38:25 +00:00
caitpotter88
fd51f615eb [es6] remove --harmony-templates flag
BUG=v8:3230
R=dslomov@chromium.org, arv@chromium.org
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#27352}
2015-03-23 07:01:48 +00:00
dslomov
af04fdfec8 Remove harmony-strings flag.
String functions are shipping since 4.1/Chrome M41, it is time to unflag.

R=yanngguo@chromium.org,rossberg@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#27337}
2015-03-20 10:43:38 +00:00
jochen
843634994f Use libdl to get symbols for backtraces
With this patch, it'll look like this:

$ out/x64.optdebug/d8 --expose-trigger-failure test/mjsunit/mjsunit.js test/mjsunit/verify-assert-false.js

==== C stack trace ===============================

 1: V8_Fatal
 2: v8::internal::FunctionCallbackArguments::Call(void (*)(v8::FunctionCallbackInfo<v8::Value> const&))
 3: 0x727ced
 4: 0x72b6ba
 5: 0x188c7f607f9b

BUG=none
R=svenpanne@chromium.org
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#27318}
2015-03-19 15:43:35 +00:00
caitpotter88
d21fd15467 [es6] implement Reflect.apply() & Reflect.construct()
BUG=v8:3900
LOG=N
R=dslomov@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#27316}
2015-03-19 14:47:27 +00:00
jarin
ca3abde2fa [turbofan] Variable liveness analysis for deopt.
This change introduces a liveness analyzer for local variables in frame states.

The main idea is to use the AstGraphBuilder::Environment class to build the control flow graph, and record local variable loads, stores and checkpoints in the CFG basic blocks (LivenessAnalyzerBlock class).

After the graph building finishes, we run a simple data flow analysis over the CFG to figure out liveness of each local variable at each checkpoint. Finally, we run a pass over all the checkpoints and replace dead local variables in the frame states with the 'undefined' value.

Performance numbers for Embenchen are below.

----------- box2d.js
Current --turbo-deoptimization: EmbenchenBox2d(RunTime): 11265 ms.
d8-master --turbo-deoptimization: EmbenchenBox2d(RunTime): 11768 ms.
d8-master: EmbenchenBox2d(RunTime): 10996 ms.
----------- bullet.js
Current --turbo-deoptimization: EmbenchenBullet(RunTime): 17049 ms.
d8-master --turbo-deoptimization: EmbenchenBullet(RunTime): 17384 ms.
d8-master: EmbenchenBullet(RunTime): 16153 ms.
----------- copy.js
Current --turbo-deoptimization: EmbenchenCopy(RunTime): 4877 ms.
d8-master --turbo-deoptimization: EmbenchenCopy(RunTime): 4938 ms.
d8-master: EmbenchenCopy(RunTime): 4940 ms.
----------- corrections.js
Current --turbo-deoptimization: EmbenchenCorrections(RunTime): 7068 ms.
d8-master --turbo-deoptimization: EmbenchenCorrections(RunTime): 6718 ms.
d8-master: EmbenchenCorrections(RunTime): 6858 ms.
----------- fannkuch.js
Current --turbo-deoptimization: EmbenchenFannkuch(RunTime): 4167 ms.
d8-master --turbo-deoptimization: EmbenchenFannkuch(RunTime): 4608 ms.
d8-master: EmbenchenFannkuch(RunTime): 4149 ms.
----------- fasta.js
Current --turbo-deoptimization: EmbenchenFasta(RunTime): 9981 ms.
d8-master --turbo-deoptimization: EmbenchenFasta(RunTime): 9848 ms.
d8-master: EmbenchenFasta(RunTime): 9640 ms.
----------- lua_binarytrees.js
Current --turbo-deoptimization: EmbenchenLuaBinaryTrees(RunTime): 11571 ms.
d8-master --turbo-deoptimization: EmbenchenLuaBinaryTrees(RunTime): 13089 ms.
d8-master: EmbenchenLuaBinaryTrees(RunTime): 10957 ms.
----------- memops.js
Current --turbo-deoptimization: EmbenchenMemOps(RunTime): 7766 ms.
d8-master --turbo-deoptimization: EmbenchenMemOps(RunTime): 7346 ms.
d8-master: EmbenchenMemOps(RunTime): 7738 ms.
----------- primes.js
Current --turbo-deoptimization: EmbenchenPrimes(RunTime): 7459 ms.
d8-master --turbo-deoptimization: EmbenchenPrimes(RunTime): 7453 ms.
d8-master: EmbenchenPrimes(RunTime): 7451 ms.
----------- skinning.js
Current --turbo-deoptimization: EmbenchenSkinning(RunTime): 15564 ms.
d8-master --turbo-deoptimization: EmbenchenSkinning(RunTime): 15611 ms.
d8-master: EmbenchenSkinning(RunTime): 15583 ms.
----------- zlib.js
Current --turbo-deoptimization: EmbenchenZLib(RunTime): 10825 ms.
d8-master --turbo-deoptimization: EmbenchenZLib(RunTime): 11180 ms.
d8-master: EmbenchenZLib(RunTime): 10823 ms.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#27232}
2015-03-17 09:38:43 +00:00
jarin
cd67e97a7e [turbofan] Cache for reusing parts of value vector nodes in frame states.
Instead of the current approach of storing flat vectors in frame states (and possibly reusing the last vector in AST graph builder), this change list builds a tree for the values and tries to reuse the nodes for different frame states. At the moment, we only use this for the local variable part of frame state, but nothing prevents us from using this for all parts.

This change provides two new classes: one for creating the tree (StateValuesCache) and one for iterating the trees (StateValuesAccess).

BUG=

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

Cr-Commit-Position: refs/heads/master@{#27222}
2015-03-16 13:43:13 +00:00
yangguo
67bc45c278 Hide Math function implementations in a closure.
R=jkummerow@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#27072}
2015-03-09 13:25:44 +00:00
marja
238ad54d0f Move compilation error handling into a separate class.
In addition to Parser, other phases (such as scope analysis) need to handle
compilation errors in the future. PendingCompilationErrorHandled takes care of
error handling in a unified way.

Split from https://codereview.chromium.org/943543002/ .

R=rossberg@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26853}
2015-02-25 14:18:34 +00:00
bmeurer
dcf193f18c [turbofan] Strength reduction for inline comparisons.
Perform strength reduction on machine operators with inline comparisons:

  CMP & 1 => CMP
  1 & CMP => CMP
  CMP << 31 >> 31 => CMP

Also strength reduce the following constructs:

  x + (0 - y) => x - y
  (0 - y) + x => x - y

R=dcarney@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26817}
2015-02-24 12:26:29 +00:00
loislo
9b02dc5b5f CpuProfiler: move StringsStorage class to separate source and header files.
Mechanical change.

This will break dependency between profiler-generator and heap-profiler-generator.
Later this will help us to reuse SourcePosition in cpu-profiler.

BUG=452067
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#26780}
2015-02-20 15:16:00 +00:00
Benedikt Meurer
9e6181d5c3 [turbofan] Finally get rid of the generic algorithm.
R=svenpanne@chromium.org

Committed: https://crrev.com/5bbe693e4817011b6a496c638c9f09026fd3dac9
Cr-Commit-Position: refs/heads/master@{#26760}

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

Cr-Commit-Position: refs/heads/master@{#26767}
2015-02-20 10:12:00 +00:00
machenbach
c7810004bb Revert of [turbofan] Finally get rid of the generic algorithm. (patchset #2 id:20001 of https://codereview.chromium.org/944803002/)
Reason for revert:
Breaks dbg builds.

Original issue's description:
> [turbofan] Finally get rid of the generic algorithm.
>
> R=svenpanne@chromium.org
>
> Committed: https://crrev.com/5bbe693e4817011b6a496c638c9f09026fd3dac9
> Cr-Commit-Position: refs/heads/master@{#26760}

TBR=svenpanne@chromium.org,bmeurer@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#26763}
2015-02-20 09:14:44 +00:00
Benedikt Meurer
5bbe693e48 [turbofan] Finally get rid of the generic algorithm.
R=svenpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26760}
2015-02-20 08:42:51 +00:00
adamk
27e8a455df Rename Interface to ModuleDescriptor
ModuleDescriptor will end up holding the set of data described in the
spec as a "Module record". This introduces a little bit of confusion
with ModuleInfo, but I hope that'll become clearer over time.

Also removed the interface-printing flags. We probably want
Module-printing flags, but that can wait until we have more
Module-related structures.

BUG=v8:1569
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#26728}
2015-02-18 18:25:21 +00:00
bmeurer
acd9c46ca7 [turbofan] Optimize certain chains of Branch into a Switch.
This adds a new ControlFlowOptimizer that - for now - recognizes chains
of Branches generated by the SwitchBuilder for a subset of javascript
switches into Switch nodes. Those Switch nodes are then lowered to
either table or lookup switches.

Also rename Case to IfValue (and introduce IfDefault) for consistency.

BUG=v8:3872
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#26691}
2015-02-17 13:29:46 +00:00
Dmitry Lomov
7866f00508 Remove --experimental-classes flag and related dead code.
R=arv@chromium.org
BUG=v8:3834
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#26631}
2015-02-12 20:07:15 +00:00
bmeurer
3336d2e11e [turbofan] Merge node-aux-data-inl.h into node-aux-data.h.
Google style guide forbids -inl.h headers.

R=svenpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26611}
2015-02-12 13:01:29 +00:00
arv
68e4897586 Remove Function.prototype.toMethod
Function.prototype.toMethod was removed from ES6.

This removes the function and updates the tests to either
use %ToMethod or a dedicated syntax (using concise method
or a class).

BUG=v8:3330
LOG=N
R=dslomov@chromium.org, adamk

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

Cr-Commit-Position: refs/heads/master@{#26559}
2015-02-10 22:13:43 +00:00
dcarney
8064582626 Move the contents of api-natives.js to c++
R=verwaest@chromium.org

BUG=

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

Cr-Commit-Position: refs/heads/master@{#26426}
2015-02-04 13:01:44 +00:00
titzer
2379d34bdc [turbofan] Put StructuredGraphBuilder out of its misery and merge its remnants back into the AstGraphBuilder.
R=mstarzinger@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26387}
2015-02-02 19:10:02 +00:00
michael_dawson
f1ba8d8f86 Contribution of PowerPC port (continuation of 422063005) - AIX Common1
Contribution of PowerPC port (continuation of 422063005 and 817143002). This patch covers
the key changes needed to the common files needed to support AIX. Subsequent
patches will cover:
- changes to update the ppc directories so they are current with the changes
in the rest of the project.
- remaining AIX changes not resolved by 4.8 compiler
- individual optimizations for PPC

This is based off of the GitHub repository
https://github.com/andrewlow/v8ppc

R=danno@chromium.org, svenpanne@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26343}
2015-01-30 08:02:08 +00:00
bmeurer
1df5fed50a [turbofan] Cleanup the NodeProperties.
R=svenpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26316}
2015-01-29 09:18:09 +00:00
bmeurer
d0f3e5302c Minor refactoring for Zone class and friends.
R=svenpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26315}
2015-01-29 07:41:52 +00:00
titzer
3937dd679b [turbofan] Remove GenericAlgorithm from verifier and graph replay.
R=mstarzinger@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26280}
2015-01-26 18:35:13 +00:00
bmeurer
4f1597a92d [turbofan] Add new JSIntrinsicsLowering reducer.
The lowering of intrinsics is therefore now decoupled from the general
inlining logic.

TEST=cctest,unittests
R=svenpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26263}
2015-01-26 09:06:03 +00:00
titzer
3442a5f9e0 [turbofan] First version of loop peeling.
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26149}
2015-01-20 09:45:17 +00:00
machenbach
12adf1474d Revert of Reland Auto-generate v8 version based on tags. (patchset #1 id:1 of https://codereview.chromium.org/843913009/)
Reason for revert:
The gclient hook of v8 is not executed on this builder:

http://build.chromium.org/p/tryserver.chromium.linux/builders/android_aosp/builds/49765

Original issue's description:
> Reland Auto-generate v8 version based on tags.
>
> This relands the CL
> https://codereview.chromium.org/797503007/.
>
> It runs the version generation two times. First during
> runhooks as a fallback for recipes that loose git context
> (e.g. android_aosp). Second during compilation like in the
> original CL. In case of failures, the result from the
> runhooks call will be reused.
>
> BUG=chromium:446166
> LOG=n
>
> Committed: https://crrev.com/d3d6e38b2cba73b52bd5ed00f4441a7db3284a19
> Cr-Commit-Position: refs/heads/master@{#26120}

TBR=jochen@chromium.org,jkummerow@chromium.org,tandrii@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=chromium:446166

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

Cr-Commit-Position: refs/heads/master@{#26121}
2015-01-18 15:43:21 +00:00
machenbach
d3d6e38b2c Reland Auto-generate v8 version based on tags.
This relands the CL
https://codereview.chromium.org/797503007/.

It runs the version generation two times. First during
runhooks as a fallback for recipes that loose git context
(e.g. android_aosp). Second during compilation like in the
original CL. In case of failures, the result from the
runhooks call will be reused.

BUG=chromium:446166
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#26120}
2015-01-18 11:25:58 +00:00
bmeurer
835cc463a8 [turbofan] Initial attempt to cleanup Node and related classes.
- Make Node::Inputs and Node::Uses mostly STL compliant.
- Get rid of some pre-C++11 crappiness.
- Start moving unit tests from cctest to unittests.
- TrimInputCount() now tries to reserve inputs slots for
  later appending.
- Fix numerous style guide violations.

TEST=cctest,unittests
R=dcarney@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26098}
2015-01-16 11:04:22 +00:00
Sven Panne
e4c5b84652 Contribution of PowerPC port (continuation of 422063005)
Contribution of PowerPC port (continuation of 422063005). The inital patch
covers the core changes to the common files.  Subsequent patches will cover
changes to common files to support AIX and to update the ppc directories so
they are current with the changes in the rest of the project.

This is based off of the GitHub repository
https://github.com/andrewlow/v8ppc

BUG=
R=svenpanne@chromium.org, danno@chromium.org, sevnpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26091}
2015-01-16 07:42:15 +00:00
machenbach
28d99ef77f Revert of Auto-generate v8 version based on tags. (patchset #5 id:80001 of https://codereview.chromium.org/797503007/)
Reason for revert:
Blocks roll on android_aosp:
https://codereview.chromium.org/851953005/

Original issue's description:
> Auto-generate v8 version based on tags.
>
> BUG=chromium:446166
> LOG=y
>
> Committed: https://crrev.com/b301b85be895c6fcd1edfe2fd1e60b5abd0ac64d
> Cr-Commit-Position: refs/heads/master@{#26062}

TBR=jochen@chromium.org,jkummerow@chromium.org,tandrii@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=chromium:446166

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

Cr-Commit-Position: refs/heads/master@{#26067}
2015-01-15 08:01:11 +00:00
machenbach
b301b85be8 Auto-generate v8 version based on tags.
BUG=chromium:446166
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#26062}
2015-01-14 16:43:42 +00:00
yangguo
39cd762c6c Embed custom script into the snapshot.
R=vogelheim@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26029}
2015-01-12 15:26:31 +00:00
titzer
159b14172f [turbofan] Implement OSR for outer loops.
R=bmeurer@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26020}
2015-01-12 11:39:58 +00:00
bmeurer
e53845d41c [turbofan] Cleanup Graph and related classes.
- Move NodeMarker to its own file, and introduce a non
  templatized base class.
- Cleanup the include hell.
- Sanitize the Node construction methods now that we
  got rid of that GenericNode/GenericGraph stuff.
- Protect against NodeId overflow in Graph.
- Various minor cleanups.

TEST=cctest,mjsunit,unittests

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

Cr-Commit-Position: refs/heads/master@{#25977}
2015-01-07 14:42:49 +00:00
bmeurer
4a8623c637 [turbofan] Turn IrOpcode::Mnemonic() into a table lookup.
R=ishell@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25939}
2014-12-23 19:24:15 +00:00
bmeurer
4f9193e047 [turbofan] Cache float32 constants on the JSGraph level.
Also slightly refactor the NodeCache and CommonNodeCache classes to
reduce inherent overhead of caching.

TEST=cctest

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

Cr-Commit-Position: refs/heads/master@{#25937}
2014-12-23 14:12:21 +00:00
bmeurer
eeec886e5f [turbofan] Deinlinify OperatorProperties implementation.
TEST=cctest,unittests
R=jochen@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25935}
2014-12-23 12:50:51 +00:00
Benedikt Meurer
ee98a1d760 [turbofan] Introduce CommonOperatorReducer.
The CommonOperatorReducer currently takes care of redundant Phis,
EffectPhis and Selects. This functionality overlaps with ControlReducer,
but is required to make certain optimizations effective, since the
ControlReducer only runs really early and really late in the pipeline
and therefore other reducers aren't reapplied properly after redundant
phi/select elimination.

TEST=unittests
R=hpayer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25922}
2014-12-22 13:06:43 +00:00
titzer
0f619463f2 [turbofan] First version of loop analysis: loop finder on the soup of nodes.
R=bmeurer@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#25837}
2014-12-16 09:36:40 +00:00
Benedikt Meurer
54a31b628d [base] Add iterator_range helper class.
TEST=unittests
R=titzer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25834}
2014-12-16 07:32:03 +00:00
mathiasb
33f0cf5acd Implement the RegExp.prototype.flags getter
TEST=mjsunit/harmony
BUG=v8:3751
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#25762}
2014-12-10 20:41:10 +00:00
yangguo
7cff32a9bd Reland "Use same blob format for internal and external snapshots."
Review URL: https://codereview.chromium.org/791723004

Cr-Commit-Position: refs/heads/master@{#25741}
2014-12-10 11:46:55 +00:00
d
4161b54d58 Add Array.prototype.includes
Requires adding a SameValueZero implementation.

LOG=Y
BUG=v8:3575
R=dslomov@chromium.org, arv@chromium.org
TEST=added to test262

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

Cr-Commit-Position: refs/heads/master@{#25735}
2014-12-10 08:58:15 +00:00
machenbach
da6dbe78bc Revert of Use same blob format for internal and external snapshots. (patchset #2 id:20001 of https://codereview.chromium.org/787033002/)
Reason for revert:
[sheriff] breaks http://build.chromium.org/p/client.v8/builders/V8-Blink%20Linux%2064%20%28dbg%29/builds/1293

Original issue's description:
> Use same blob format for internal and external snapshots.
>
> R=vogelheim@chromium.org

TBR=vogelheim@chromium.org,yangguo@chromium.org
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#25729}
2014-12-09 16:19:57 +00:00
yangguo
03ba4becbf Use same blob format for internal and external snapshots.
R=vogelheim@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25727}
2014-12-09 15:12:27 +00:00
Benedikt Meurer
b3ace35209 [turbofan] Redundant load elimination.
This is an initial version of redundant load elimination, currently
limited to LoadField operators, and implemented by walking the effect
chain.

TEST=unittests
R=svenpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25673}
2014-12-05 07:59:18 +00:00
mstarzinger
f9e4527f32 Restrict floating control to minimal control-connected component.
R=jarin@chromium.org
TEST=cctest/test-scheduler/NestedFloatingDiamondWithChain

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

Cr-Commit-Position: refs/heads/master@{#25621}
2014-12-02 15:56:30 +00:00
mstarzinger
0672b64d1c Make generic algorithm a little less generic.
R=titzer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25620}
2014-12-02 15:38:00 +00:00
dslomov
9e02e98771 Introduce a kill-switch for shipping features.
R=rossberg@chromium.org
TBR=hpayer@chromium.org

Committed: d628562086

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

Cr-Commit-Position: refs/heads/master@{#25577}
2014-11-28 20:07:18 +00:00
dslomov
557bf53b79 Revert of Introduce a kill-switch for shipping features. (patchset #2 id:20001 of https://codereview.chromium.org/763273002/)
Reason for revert:
Reverted for breaking nosnap: http://chromegw.corp.google.com/i/client.v8/builders/V8%20Linux%20-%20nosnap/builds/1003/steps/Check/logs/Threading3

Original issue's description:
> Introduce a kill-switch for shipping features.
>
> R=rossberg@chromium.org
>
> Committed: d628562086

TBR=rossberg@chromium.org
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#25574}
2014-11-28 18:27:55 +00:00
mstarzinger
70093d719c De-generify the GenericNode.
R=titzer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25572}
2014-11-28 15:21:44 +00:00
Dmitry Lomov
d628562086 Introduce a kill-switch for shipping features.
R=rossberg@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25570}
2014-11-28 14:32:17 +00:00
mstarzinger
02210179d6 De-generify the GenericGraph.
R=titzer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25569}
2014-11-28 14:21:13 +00:00
dslomov
65aa17b9c3 harmony-classes: Implement 'super(...)' call syntactic restriction.
R=rossberg@chromium.org,arv@chromium.org
BUG=v8:3330
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#25555}
2014-11-28 04:08:58 +00:00
dslomov
cd4cc1ba36 Ship harmony-strings
R=rossberg@chromium.org, yangguo@chromium.org
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#25536}
2014-11-27 10:17:18 +00:00
dcarney
60af073ad8 [turbofan] add initial move optimizer
R=bmeurer@chromium.org

BUG=

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

Cr-Commit-Position: refs/heads/master@{#25533}
2014-11-27 09:21:06 +00:00
titzer
da22163d35 [turbofan] Implement jump threading after register allocation.
R=dcarney@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#25521}
2014-11-26 12:41:55 +00:00
baixo
009fe698ee The file snapshot_blob_host.bin was supposed to be generated when building the host toolset. However, the file snapshot_blob.bin was being generated instead, under every set of conditions.
Because of this, every time we build the host toolset, snapshot_blob_host.bin is not found. This causes the target (v8_external_snapshot) that generates such file to be run. This target generates snapshot_blob.bin instead of snapshot_blob_host.bin. This in turn causes all the targets that depend on snapshot_blob.bin to run again.

After this, we still don't have snapshot_blob_host.bin. So the next time we build, the whole process described above happens again.

BUG=421063

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

Cr-Commit-Position: refs/heads/master@{#25480}
2014-11-24 12:43:32 +00:00
yangguo
9b8d40594a Rip out bzip compression for native sources.
R=vogelheim@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25464}
2014-11-21 12:45:20 +00:00
Dusan Milosavljevic
ae9130ebbb MIPS64: Add turbofan support for mips64.
TEST=
BUG=
R=danno@chromium.org, paul.lind@imgtec.com

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

Cr-Commit-Position: refs/heads/master@{#25424}
2014-11-19 15:44:46 +00:00
caitpotter88
353b696467 Implement ES6 Template Literals
BUG=v8:3230

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

Cr-Commit-Position: refs/heads/master@{#25362}
2014-11-14 18:53:52 +00:00
jochen@chromium.org
063eb94825 Link against librt on solaris for semaphore and scheduler symbols
BUG=v8:3358
R=svenpanne@chromium.org
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#25299}
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@25299 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-11-12 14:48:23 +00:00
yangguo@chromium.org
9f86e34e54 Fix gn build.
TBR=ishell@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#25277}
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@25277 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-11-12 08:12:17 +00:00