Commit Graph

26528 Commits

Author SHA1 Message Date
mstarzinger
bb7a5eb2d8 [heap] Separate out optimized code map processing.
This separates the post-processing step for optimized code maps out of
the CodeFlusher. It uses the complete SharedFunctionInfo::Iterator to
visit all candidates instead of gathering candidates during marking.

Gathering candidates during marking no longer makes sense, now that the
majority of SharedFunctionInfo objects will hold such an optimized code
map. Also it reduces complexity of the implementation. Also conflating
this mechanism with "code flushing" was confusing.

This reverts commit b6644e8491.

R=ulan@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31836}
2015-11-05 17:30:20 +00:00
pkotwicz
fa4bd0b9ab Add v8_external_startup_data GN rule
The new GN rule will enable removal of code which copies natives_blob.bin and
snapshot_blob.bin in Android GN code (for instance "copy_content_shell_assets").

BUG=547162
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#31835}
2015-11-05 17:29:07 +00:00
adamk
80a1e004f4 Revert "Revert of [es6] Implement destructuring binding in try/catch"
Reland try/catch destructuring with a fix for the MemorySanitizer failure:
initialization_pos needs to be initialized in the DeclarationDescriptor.

This is a one line fix to http://crrev.com/a316db995e6e4253664920652ed4e5a38b2caeba

BUG=v8:811
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#31834}
2015-11-05 17:27:57 +00:00
hablich
760eb0a9f4 [Release] Make release scripts aware of packed tags
We are creating a lot of tags. The result is that git 'packs'
some of them. Our parsers in the release script cannot handle
this.

R=machenbach@chromium.org
LONG=N
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#31833}
2015-11-05 17:27:18 +00:00
hablich
b6644e8491 Revert of [heap] Separate out optimized code map processing. (patchset #3 id:40001 of https://codereview.chromium.org/1426953006/ )
Reason for revert:
Breaks build: https://uberchromegw.corp.google.com/i/client.v8/builders/V8%20Linux%20-%20nosnap%20-%20debug/builds/3565

Original issue's description:
> [heap] Separate out optimized code map processing.
>
> This separates the post-processing step for optimized code maps out of
> the CodeFlusher. It uses the complete SharedFunctionInfo::Iterator to
> visit all candidates instead of gathering candidates during marking.
>
> Gathering candidates during marking no longer makes sense, now that the
> majority of SharedFunctionInfo objects will hold such an optimized code
> map. Also it reduces complexity of the implementation. Also conflating
> this mechanism with "code flushing" was confusing.
>
> R=ulan@chromium.org
>
> Committed: https://crrev.com/8ad6168d197dd167235c9d342ec7ce37b0daa88b
> Cr-Commit-Position: refs/heads/master@{#31830}

TBR=ulan@chromium.org,yangguo@chromium.org,mvstanton@chromium.org,mstarzinger@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#31832}
2015-11-05 16:29:14 +00:00
mbrandy
6413ef4e63 PPC: [runtime] Fix ES6 9.2.1 [[Call]] when encountering a classConstructor.
Port ab84025977

Also:
- Fix big-endian compiler hints BYTE_OFFSET macro.
- Clean up PPC code access to compiler hints -- which required some new
  SharedFunctionInfo fields to encapsulate kCompilerHintsSmiTagSize.

Original commit message:
    The current implementation of classes throws the TypeError at the wrong
    point, after activating a new context when directly calling a class
    constructor. According to the spec, the TypeError has to be thrown
    in the caller context.

R=bmeurer@chromium.org, cbruni@chromium.org, joransiu@ca.ibm.com, jyan@ca.ibm.com, michael_dawson@ca.ibm.com, dstence@us.ibm.com
LOG=N
BUG=v8:4428

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

Cr-Commit-Position: refs/heads/master@{#31831}
2015-11-05 14:51:51 +00:00
mstarzinger
8ad6168d19 [heap] Separate out optimized code map processing.
This separates the post-processing step for optimized code maps out of
the CodeFlusher. It uses the complete SharedFunctionInfo::Iterator to
visit all candidates instead of gathering candidates during marking.

Gathering candidates during marking no longer makes sense, now that the
majority of SharedFunctionInfo objects will hold such an optimized code
map. Also it reduces complexity of the implementation. Also conflating
this mechanism with "code flushing" was confusing.

R=ulan@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31830}
2015-11-05 14:32:55 +00:00
ishell
e8cab885ed Move both dynamic and static object body visiting logic to BodyDescriptorBase class.
Review URL: https://codereview.chromium.org/1416243009

Cr-Commit-Position: refs/heads/master@{#31829}
2015-11-05 14:02:49 +00:00
bmeurer
9c8f4f91aa [runtime] Remove the unused weird %Likely and %Unlikely intrinsics.
These intrinsics are completely unused and there doesn't seem to an
actual use case for it in the future.

R=mstarzinger@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31828}
2015-11-05 13:52:31 +00:00
bmeurer
dc3c84812a [turbofan] Introduce a Function type and optimize based on it.
This inserts a new bit set type Function, which is used to represent
JSFunctions, and uses that type in typed lowering to optimize calls
to use the CallFunction builtin directly. Also allows for better typing
of the typeof operator, which can infern "function" for JSFunctions
properly.

R=jarin@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31827}
2015-11-05 13:30:56 +00:00
verwaest
4ab1b05d5e Remove receiver conversion from function prologue
Depends on https://codereview.chromium.org/1407373007/
After that CL, all receiver conversion is handled by the call builtin.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31826}
2015-11-05 13:23:51 +00:00
mstarzinger
faf0238b45 [turbofan] Tiny cleanup in RawMachineAssembler constructor.
R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31825}
2015-11-05 13:16:02 +00:00
yangguo
2237ba0dba Implement flag and source getters on RegExp.prototype.
R=littledan@chromium.org
BUG=v8:3715, v8:4528
LOG=Y

Committed: https://crrev.com/60e8877e161fe6175e19fafce2d6ed1c3999cdb1
Cr-Commit-Position: refs/heads/master@{#31753}

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

Committed: https://crrev.com/85494e90bb63a3a9e19a1bf862cb6bfcb0162ee9
Cr-Commit-Position: refs/heads/master@{#31782}

Committed: https://crrev.com/152163c1646b45f5fc5d31a4ec2eb55d7f4a2ffc
Cr-Commit-Position: refs/heads/master@{#31804}

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

Cr-Commit-Position: refs/heads/master@{#31824}
2015-11-05 13:08:55 +00:00
verwaest
44c44521ae Remove CallFunctionStub, always call through the Call builtin (also from CallIC).
This fixes receiver conversion since the Call builtin does it correctly.

BUG=v8:4526
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31823}
2015-11-05 12:46:01 +00:00
bmeurer
de9ebd82d0 [runtime] Remove obsolete %_StringAdd intrinsic.
The %_StringAdd intrinsic is not used anymore, so no need to keep the
code around.

R=yangguo@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31822}
2015-11-05 12:16:59 +00:00
bmeurer
a210c3757e [runtime] Remove the very dangerous %_CallFunction intrinsic.
The %_CallFunction doesn't implement the call sequence properly, it
doesn't do the receiver wrapping, nor does it check for
classConstructor. Also the eager deoptimization for %_CallFunction was
seriously b0rked (we must have been lucky with TurboFan so far).

R=yangguo@chromium.org
BUG=v8:4413
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31821}
2015-11-05 11:48:21 +00:00
bmeurer
8d780560bd [turbofan] Add support for relevant ES6 type conversion intrinsics.
TurboFan didn't fully support the relevant ES6 type conversion
intrinsics like %_ToNumber, %_ToLength, %_ToName, %_ToString and
%_ToInteger until now, we always went to the runtime instead.  These
intrinsics are now well supported in TurboFan, and we are even able to
generate quite decent code in some cases.

R=jarin@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31820}
2015-11-05 09:51:28 +00:00
ishell
82a54b38e7 Using override keyword in ObjectVisitor class hierarchy.
Review URL: https://codereview.chromium.org/1425013006

Cr-Commit-Position: refs/heads/master@{#31819}
2015-11-05 09:32:38 +00:00
yangguo
ca49355aba Revert of Implement flag and source getters on RegExp.prototype. (patchset #6 id:110001 of https://codereview.chromium.org/1419823010/ )
Reason for revert:
browser_tests failure with --gtest_filter=ExternallyConnectableMessagingTest.EnablingAndDisabling

Original issue's description:
> Implement flag and source getters on RegExp.prototype.
>
> R=littledan@chromium.org
> BUG=v8:3715, v8:4528
> LOG=Y
>
> Committed: https://crrev.com/60e8877e161fe6175e19fafce2d6ed1c3999cdb1
> Cr-Commit-Position: refs/heads/master@{#31753}
>
> Committed: https://crrev.com/b5c80a31ad266eb38a0cf2ff756be59c66d34aa5
> Cr-Commit-Position: refs/heads/master@{#31773}
>
> Committed: https://crrev.com/85494e90bb63a3a9e19a1bf862cb6bfcb0162ee9
> Cr-Commit-Position: refs/heads/master@{#31782}
>
> Committed: https://crrev.com/152163c1646b45f5fc5d31a4ec2eb55d7f4a2ffc
> Cr-Commit-Position: refs/heads/master@{#31804}

TBR=littledan@chromium.org,jochen@chromium.org,ulan@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3715, v8:4528

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

Cr-Commit-Position: refs/heads/master@{#31818}
2015-11-05 09:08:51 +00:00
yangguo
d9511fa9df Revert of Use in-object fields instead of private symbols for regexp slots. (patchset #4 id:60001 of https://codereview.chromium.org/1428203003/ )
Reason for revert:
browser_tests failure with --gtest_filter=ExternallyConnectableMessagingTest.EnablingAndDisabling

Original issue's description:
> Use in-object fields instead of private symbols for regexp slots.
>
> R=bmeurer@chromium.org
>
> Committed: https://crrev.com/5a1e42c039ac3379ebe1e7e34fb8163e1ec1493e
> Cr-Commit-Position: refs/heads/master@{#31791}
>
> Committed: https://crrev.com/bf5c9af92ac0a5b7f020ac968d3d42ed06aa6144
> Cr-Commit-Position: refs/heads/master@{#31805}

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

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

Cr-Commit-Position: refs/heads/master@{#31817}
2015-11-05 09:07:39 +00:00
caitpotter88
096125deaa [es6] allow any LeftHandSideExpression in for-of loops
Fix an earlier regression which forbid non-VariableProxy LHS from being
used in for-of loops. Like for-in loops, the spec allows any LHS to be used,
with the sole exception that ObjectLiterals and ArrayLiterals must be valid
AssignmentPatterns.

Also fixes a bug in TurboFan which resulted in incorrectly replacing a variable load with a constant value in some instances, due to the AstLoopAssignmentAnalyzer failing to record the assignment to ForOfStatement's value.

BUG=v8:4418, v8:2720
LOG=N
R=wingo@igalia.com, littledan@chromium.org, adamk@chromium.org, bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31816}
2015-11-05 06:47:56 +00:00
zhengxing.li
8c1a433038 X87: [runtime] Fix ES6 9.2.1 [[Call]] when encountering a classConstructor.
port ab84025977 (r31790).

  original commit message:
  The current implementation of classes throws the TypeError at the wrong
  point, after activating a new context when directly calling a class
  constructor. According to the spec, the TypeError has to be thrown
  in the caller context.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31815}
2015-11-05 05:11:57 +00:00
ofrobots
7b704c4f9b [heap] inline allocation steps refactor
Expose the steps for incremental marking and idle scavenge more directly in
NewSpace. Adjust the NewSpace and Heap interfaces to allow callers to be more
clear about how they are interacting with inline allocation steps. This refactor
prepares the ground for more consumers of inline allocation steps (e.g. sampling
heap profiler.)

R=hpayer@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31814}
2015-11-05 04:45:33 +00:00
v8-autoroll
ac75fe1a9b Update V8 DEPS.
Rolling v8/third_party/icu to 42c58d4e49f2250039f0e98d43e0b76e8f5ca024

TBR=machenbach@chromium.org,vogelheim@chromium.org,hablich@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31813}
2015-11-05 04:19:39 +00:00
chunyang.dai
fd0d9cf2c5 X87: fix a check error for deoptimization.
This CL is a fix for https://codereview.chromium.org/1411223010. (X87: fix
   the deoptimization issue.).

   ArchDeoptimize instruction may contains duplicated x87 double register as input
   parameters. So the scope check is not correct.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31812}
2015-11-05 02:51:53 +00:00
paul.lind
532ee45a2f Fix big-endian after [runtime] Fix ES6 9.2.1 [[Call]] when encountering a classConstructor.
Fix typos in big-endian BYTE_OFFSET macro.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31811}
2015-11-05 02:48:29 +00:00
littledan
5d44bf0263 Ship Harmony ToLength
This patch moves ES2015 ToLength semantics on array operations, etc
to from staging to shipping.

R=adamk
BUG=v8:3087
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#31810}
2015-11-05 00:45:05 +00:00
littledan
755fcc5fc6 Avoid creating indexed elements at index maxUint32
The maximum indexed element size is maxUint32-1, not maxUint32, because
the maximum length of elements is maxUint32. This patch tweaks the limit
to switch to named properties as appropriate.

BUG=v8:4516
LOG=Y
R=adamk

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

Cr-Commit-Position: refs/heads/master@{#31809}
2015-11-05 00:43:46 +00:00
chunyang.dai
5736eb0ccb X87: Change the test case for X87 float operations
The CL https://codereview.chromium.org/1409013004 added / changed some test cases.
       Some new test cases use CheckFloatEq(...) and CheckDoubleEq(...) function for result
       check. When GCC compiling the CheckFloatEq() and CheckDoubleEq() function, those inlined
       functions has different behavior comparing with GCC ia32 build and x87 build. The major
       difference is sse float register still has single precision rounding semantic. While X87
       register has no such rounding precsion semantic when directly use register value. The V8
       turbofan JITTed has exactly same result in both X87 and IA32 port.

       So we add the following sentence to do type case to keep the same precision.
          float expect = *i * *j; // *i + *j, etc.

       For test case "RunFloat64MulAndFloat64Add1 / RunFloat64MulAndFloat64Add2 / RunFloat64MulAndFloat64Sub1
       / RunFloat64MulAndFloat64Sub2", the expected result calcaulated by GCC has difference precsion
       when comparing with V8 turbofan result for X87 platform. (Turbofan X87 result is the same as
       IA32 GCC and IA32 Turbofan). So we have to disable those four cases for X87 port.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31808}
2015-11-05 00:15:30 +00:00
paul.lind
0bc51ef620 Fix signed-compare error with gcc 4.9.2.
From 41f3e782d9.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31807}
2015-11-04 22:06:50 +00:00
dusan.m.milosavljevic
8ae7c9abc3 MIPS: [turbofan] Properly implement Float64/32 Min/Max instructions.
TEST=cctest/test-run-machops/Float(64|32)MaxP, Float(64|32)MinP,
       unittests/InstructionSelectorTest.Float64Min|Max
BUG=v8:4206
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31806}
2015-11-04 21:03:25 +00:00
yangguo
bf5c9af92a Use in-object fields instead of private symbols for regexp slots.
R=bmeurer@chromium.org

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

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

Cr-Commit-Position: refs/heads/master@{#31805}
2015-11-04 20:44:50 +00:00
yangguo
152163c164 Implement flag and source getters on RegExp.prototype.
R=littledan@chromium.org
BUG=v8:3715, v8:4528
LOG=Y

Committed: https://crrev.com/60e8877e161fe6175e19fafce2d6ed1c3999cdb1
Cr-Commit-Position: refs/heads/master@{#31753}

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

Committed: https://crrev.com/85494e90bb63a3a9e19a1bf862cb6bfcb0162ee9
Cr-Commit-Position: refs/heads/master@{#31782}

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

Cr-Commit-Position: refs/heads/master@{#31804}
2015-11-04 20:42:33 +00:00
rmcilroy
5486eb6b3d [Interpreter] Fix U16() calls in test-bytecode-generator for big endian.
Avoid double incrementing the variable in the U16() macro.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31803}
2015-11-04 19:39:28 +00:00
caitpotter88
55e1cfebfd [parser] early error when declaration Pattern missing Initializer
Emit an early error when BindingPatterns are used in a VariableDeclaration
or LexicalBinding without an Initializer.

BUG=v8:4532
LOG=N
R=adamk@chromium.org, rossberg@chromium.org, wingo@igalia.com

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

Cr-Commit-Position: refs/heads/master@{#31802}
2015-11-04 19:26:40 +00:00
hablich
a77aa3a2b4 Revert of Implement flag and source getters on RegExp.prototype. (patchset #6 id:110001 of https://codereview.chromium.org/1419823010/ )
Reason for revert:
Breaks Chromium tests and blocks the roll: http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_rel_ng/builds/124490

Original issue's description:
> Implement flag and source getters on RegExp.prototype.
>
> R=littledan@chromium.org
> BUG=v8:3715, v8:4528
> LOG=Y
>
> Committed: https://crrev.com/60e8877e161fe6175e19fafce2d6ed1c3999cdb1
> Cr-Commit-Position: refs/heads/master@{#31753}
>
> Committed: https://crrev.com/b5c80a31ad266eb38a0cf2ff756be59c66d34aa5
> Cr-Commit-Position: refs/heads/master@{#31773}
>
> Committed: https://crrev.com/85494e90bb63a3a9e19a1bf862cb6bfcb0162ee9
> Cr-Commit-Position: refs/heads/master@{#31782}

TBR=littledan@chromium.org,jochen@chromium.org,ulan@chromium.org,yangguo@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3715, v8:4528

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

Cr-Commit-Position: refs/heads/master@{#31801}
2015-11-04 18:34:27 +00:00
hablich
626fd5f0b9 Revert of Use in-object fields instead of private symbols for regexp slots. (patchset #4 id:60001 of https://codereview.chromium.org/1428203003/ )
Reason for revert:
A clean revert of https://codereview.chromium.org/1419823010/ was not possible because of this CL. Thus, I am also reverting this CL.

Original issue's description:
> Use in-object fields instead of private symbols for regexp slots.
>
> R=bmeurer@chromium.org
>
> Committed: https://crrev.com/5a1e42c039ac3379ebe1e7e34fb8163e1ec1493e
> Cr-Commit-Position: refs/heads/master@{#31791}

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

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

Cr-Commit-Position: refs/heads/master@{#31800}
2015-11-04 18:33:12 +00:00
mstarzinger
e3f4047814 [turbofan] Deprecate RawMachineAssembler::CallFunctionStub0.
This deprecates the ability of the raw machine assembler to utilize the
CallFunctionStub in preparation of the stub itself being deprecated. We
only used this to test instruction selection of calls to stubs that can
deoptimize, the test has been adapted.

R=verwaest@chromium.org
TEST=unittests/InstructionSelectorTest

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

Cr-Commit-Position: refs/heads/master@{#31799}
2015-11-04 17:17:13 +00:00
adamk
f687c4f4e6 Revert of [es6] Implement destructuring binding in try/catch (patchset #3 id:40001 of https://codereview.chromium.org/1417483014/ )
Reason for revert:
MSAN errors on arm64: http://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20arm64%20-%20sim%20-%20MSAN/builds/5123/

Original issue's description:
> [es6] Implement destructuring binding in try/catch
>
> The approach is to desugar
>
>   try { ... }
>   catch ({x, y}) { ... }
>
> into
>
>   try { ... }
>   catch (.catch) {
>     let x = .catch.x;
>     let y = .catch.y;
>     ...
>   }
>
> using the PatternRewriter's normal facilities. This has the side benefit
> of throwing the appropriate variable conflict errors for declarations
> made inside the catch block.
>
> No change is made to non-destructured cases, which will hopefully save
> us some work if https://github.com/tc39/ecma262/issues/150 is adopted
> in the spec.
>
> There's one big problem with this patch, which is a lack of PreParser
> support for the redeclaration errors. But it seems we're already lacking
> good PreParser support for such errors, so I'm not sure that should
> block this moving forward.
>
> BUG=v8:811
> LOG=y
>
> Committed: https://crrev.com/a316db995e6e4253664920652ed4e5a38b2caeba
> Cr-Commit-Position: refs/heads/master@{#31797}

TBR=rossberg@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:811

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

Cr-Commit-Position: refs/heads/master@{#31798}
2015-11-04 16:39:59 +00:00
adamk
a316db995e [es6] Implement destructuring binding in try/catch
The approach is to desugar

  try { ... }
  catch ({x, y}) { ... }

into

  try { ... }
  catch (.catch) {
    let x = .catch.x;
    let y = .catch.y;
    ...
  }

using the PatternRewriter's normal facilities. This has the side benefit
of throwing the appropriate variable conflict errors for declarations
made inside the catch block.

No change is made to non-destructured cases, which will hopefully save
us some work if https://github.com/tc39/ecma262/issues/150 is adopted
in the spec.

There's one big problem with this patch, which is a lack of PreParser
support for the redeclaration errors. But it seems we're already lacking
good PreParser support for such errors, so I'm not sure that should
block this moving forward.

BUG=v8:811
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#31797}
2015-11-04 16:06:38 +00:00
jarin
19bad2a68c [turbofan] Move CallBuffer from header to cc file.
Review URL: https://codereview.chromium.org/1425183003

Cr-Commit-Position: refs/heads/master@{#31796}
2015-11-04 15:21:28 +00:00
mbrandy
9d1317e61c PPC: [turbofan] Added the RoundInt64ToFloat64 instruction to TurboFan.
Port 870e908d88

R=ahaas@chromium.org, joransiu@ca.ibm.com, jyan@ca.ibm.com, michael_dawson@ca.ibm.com, dstence@us.ibm.com
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31795}
2015-11-04 15:17:07 +00:00
bmeurer
309c36f5a9 [turbofan] Remove use of CallFunctionStub from TurboFan.
Use the Call builtin instead, which does the right thing(TM)
always, especially since the CallFunctionStub is going away.

R=jarin@chromium.org
BUG=v8:4413
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31794}
2015-11-04 15:04:53 +00:00
jarin
305546e1a6 [turbofan] Remove a bit of dead code from simplified lowering.
Review URL: https://codereview.chromium.org/1413153013

Cr-Commit-Position: refs/heads/master@{#31793}
2015-11-04 14:58:51 +00:00
mstarzinger
7890dc4f69 Remove several JSFunction delegator functions.
This removes several methods from JSFunction that just delegate to
SharedFunctionInfo. These methods are especially dangerous when they
hide the fact that they potentially affect all function instances
deriving from the same underlying SharedFunctionInfo.

R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31792}
2015-11-04 14:56:37 +00:00
yangguo
5a1e42c039 Use in-object fields instead of private symbols for regexp slots.
R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31791}
2015-11-04 14:45:39 +00:00
cbruni
ab84025977 [runtime] Fix ES6 9.2.1 [[Call]] when encountering a classConstructor.
The current implementation of classes throws the TypeError at the wrong
point, after activating a new context when directly calling a class
constructor. According to the spec, the TypeError has to be thrown
in the caller context.

LOG=N
BUG=v8:4428

Committed: https://crrev.com/6a06bc0a774933719f62009d81b3f1686d83bb90
Cr-Commit-Position: refs/heads/master@{#31786}

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

Cr-Commit-Position: refs/heads/master@{#31790}
2015-11-04 14:30:09 +00:00
bmeurer
30aca03ad1 [turbofan] Implement the call protocol properly for direct calls.
The callees are expected to properly set the number of actual
arguments passed to the callee, which is now represented correctly
in the TurboFan graphs by a new Parameter right before the context
Parameter.  Currently this is only being used for outgoing calls.

Note that this requires disabling two of the TF code stub tests,
because of the JavaScript graphs are not automagically compatible
with abitrary (incoming) code stub interface descriptors.  If we
want to support JS code stubs at all, then we need to find a sane
way to feed in this information.

Drive-by-fix: Don't insert a direct call to a classConstructor.

R=mstarzinger@chromium.org
BUG=v8:4413, v8:4428
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31789}
2015-11-04 14:08:59 +00:00
cbruni
e7154a0b78 [runtime] Support Symbols in KeyAccumulator
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31788}
2015-11-04 14:05:36 +00:00
cbruni
f1bb688e80 Revert of [runtime] Fix ES6 9.2.1 [[Call]] when encountering a classConstructor. (patchset #20 id:370001 of https://codereview.chromium.org/1418623007/ )
Reason for revert:
failing build bot

Original issue's description:
> [runtime] Fix ES6 9.2.1 [[Call]] when encountering a classConstructor.
>
> The current implementation of classes throws the TypeError at the wrong
> point, after activating a new context when directly calling a class
> constructor. According to the spec, the TypeError has to be thrown
> in the caller context.
>
> LOG=N
> BUG=v8:4428
>
> Committed: https://crrev.com/6a06bc0a774933719f62009d81b3f1686d83bb90
> Cr-Commit-Position: refs/heads/master@{#31786}

TBR=bmeurer@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:4428

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

Cr-Commit-Position: refs/heads/master@{#31787}
2015-11-04 13:56:44 +00:00