Commit Graph

26222 Commits

Author SHA1 Message Date
yangguo
538197dada RegExp.prototype is an ordinary object.
R=littledan@chromium.org
BUG=v8:4003
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31730}
2015-11-03 06:18:44 +00:00
mtrofin
c03d7a7f03 [turbofan] Remove redundant code.
When I centralized the treatment of memory operands, I forgot to delete
the old code.

There is a semantic difference between the old and new code. The old
code was handling either memory operands, or ranges that had a spilled
predecessor. The new code handles just memory operands. It may
happen that (using LinearScan) an active range is spilled when trying
to allocate another range (see SplitAndSpillIntersecting). That may make
it a candidate for the old version of the code, however, since we would
have spilled up to a register use, the old code wouldn't have had taken
effect.

Perf data shows this nuance doesn't make a difference in perf.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31729}
2015-11-03 05:34:14 +00:00
zhengxing.li
a080d4c50c X87: fix the deoptimization issue.
On X87 the count of double register number is landed on the top
       of x87 register stack for deoptimization. (chunyang.dai@intle.com)

R=weiliang.lin@intel.com
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31728}
2015-11-03 05:02:01 +00:00
littledan
8a93f12995 test262 roll
R=adamk

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

Cr-Commit-Position: refs/heads/master@{#31727}
2015-11-03 01:31:30 +00:00
bradnelson
b0f7830bef Fixing asm typing issues.
Fixing handling of uint32 to be more correct (previously some uint32's
were being interpreted as int32).
Fixing enforcement type matching in comparisons (previously mismatched
expressions could be compared).

BUG= https://code.google.com/p/v8/issues/detail?id=4203
TEST=test-asm-validator
R=titzer@chromium.org,aseemgarg@chromium.org
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31726}
2015-11-03 00:29:31 +00:00
mlippautz
88b764d7f7 [heap] Use live memory as heuristic for spawning compaction tasks
R=hpayer@chromium.org
BUG=chromium:524425
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31725}
2015-11-03 00:04:47 +00:00
mlippautz
8789eca0fb [heap] Fix helping sweeping for parallel compaction spaces
R=hpayer@chromium.org
BUG=chromium:524425
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31724}
2015-11-02 23:38:33 +00:00
mlippautz
7d7292a692 Revert of Initialize maths result array in JS. (patchset #1 id:1 of https://codereview.chromium.org/1421703004/ )
Reason for revert:
Failed on
  http://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20nosnap/builds/5020

Original issue's description:
> Initialize maths result array in JS.
>
> R=ishell@chromium.org
>
> Committed: https://crrev.com/aa26f5d4a11a1e5655d425ff40ced79c8ecdd55f
> Cr-Commit-Position: refs/heads/master@{#31722}

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

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

Cr-Commit-Position: refs/heads/master@{#31723}
2015-11-02 23:34:05 +00:00
yangguo
aa26f5d4a1 Initialize maths result array in JS.
R=ishell@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31722}
2015-11-02 21:23:28 +00:00
rmcilroy
e4b4dd41ed [Interpreter] Don't compile Api or Builtin id functions through the interpreter.
The Interpreter uses the function_data slot in the shared function info, so
can't be used to compile functions which use that field for other reasons,
such as API functions or functions with builtin function ids.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31721}
2015-11-02 20:38:18 +00:00
mbrandy
5a8da4945c PPC: [es6] Better support for built-ins subclassing.
Port 4490ce8520

Original commit message:
    Create proper initial map for original constructor (new.target) instead of doing prototype
    transition on the base constructor's initial map. This approach fixes in-object slack tracking
    for subclass instances.
    This CL also fixes subclassing from String.

    It also fixes typed array map smashing done during typed array initialization.

R=ishell@chromium.org, joransiu@ca.ibm.com, jyan@ca.ibm.com, michael_dawson@ca.ibm.com, dstence@us.ibm.com
BUG=v8:3101, v8:3330, v8:4419
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31720}
2015-11-02 19:52:14 +00:00
jochen
16ca5c6102 Mark GetCallingContext as soon-to-be deprecated
The calling context is the second top-most non-debugger context on the
stack, but that's not necessarily the actually calling context, e.g.,
when a tail-call was used.

BUG=chromium:541703
R=verwaest@chromium.org
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#31719}
2015-11-02 19:23:13 +00:00
ahaas
a14dd15876 Changed some tests to use the BufferedRawMachineAssemblerTester.
The BufferedRawMachineAssemblerTester takes care of storing and loading
parameters to and from memory for these test cases. By using the
BufferedRawMachineAssemblerTester the test cases become more readible.

R=titzer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31718}
2015-11-02 19:19:50 +00:00
bmeurer
1195b0e24d [turbofan] Initial support for keyed access to fast JSArrays.
This adds some initial support for keyed element access to fast,
non-holey JSArray objects.

Also renames PropertyAccessInfoFactory to AccessInfoFactory and
PropertyAccessMode to AccessMode.

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

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

Cr-Commit-Position: refs/heads/master@{#31717}
2015-11-02 18:30:06 +00:00
ssid
0fa11bfb80 Add boolean to tell if V8 zaps allocated memory
V8 zaps (writes 0xdeadbeef) over the mmapped regions when in debug mode.
This causes more resident size than displayed in tracing. So, This CL
adds an api to tell if zapping is done.

BUG=546492
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#31716}
2015-11-02 18:27:20 +00:00
mythria
77c19034f4 [Interpreter] Removes unnecessary jumps and dead code from If and loops.
Adds an optimization to not emit unnecessary jumps and dead code in If,
For, While, and do-while statments. When the value of condition is known
at compile time, the code is emitted only for the paths that can be taken.
For example, when the condition is known to be true in an if statmenet
only then block is generated.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31715}
2015-11-02 15:24:46 +00:00
yangguo
1df7377477 Merge GlobalObject with JSGlobalObject.
R=jkummerow@chromium.org, mstarzinger@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31714}
2015-11-02 14:58:19 +00:00
mstarzinger
3e73ce4954 [turbofan] Desugar lookup slot optimization in graph builder.
This moves the optimization for variables loads targeting lookup slots
in DYNAMIC_GLOBAL and DYNAMIC_LOCAL mode into the AstGraphBuilder. This
way we implicitly get all optimizations that target global loads and
context loads for free.

R=bmeurer@chromium.org
BUG=v8:4513
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31713}
2015-11-02 13:55:31 +00:00
yangguo
5f4611bc95 Store RNG state on function context.
R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31712}
2015-11-02 13:45:23 +00:00
yangguo
395bd6d70a Remove JSBuiltinsObject.
R=verwaest@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31711}
2015-11-02 13:04:34 +00:00
yangguo
3e98f04d1c Use inline constants instead of typed array for math constants.
R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31710}
2015-11-02 12:21:45 +00:00
ishell
2210cc84de Revert of [es6] Fix Function and GeneratorFunction built-ins subclassing. (patchset #4 id:80001 of https://codereview.chromium.org/1428823002/ )
Reason for revert:
Buildbot failures

Original issue's description:
> [es6] Fix Function and GeneratorFunction built-ins subclassing.
>
> BUG=v8:3101, v8:3330
> LOG=Y
>
> Committed: https://crrev.com/99e7f872d3d0a5fb799dcbafb05537cda491314a
> Cr-Commit-Position: refs/heads/master@{#31708}

TBR=verwaest@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3101, v8:3330

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

Cr-Commit-Position: refs/heads/master@{#31709}
2015-11-02 11:59:14 +00:00
ishell
99e7f872d3 [es6] Fix Function and GeneratorFunction built-ins subclassing.
BUG=v8:3101, v8:3330
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#31708}
2015-11-02 11:45:51 +00:00
Michael Achenbach
e4af8a06fc Whitespace change to test swarming.
Cr-Commit-Position: refs/heads/master@{#31707}
2015-11-02 11:43:39 +00:00
machenbach
52276b36a0 Use msvs toolchain from depot_tools.
This ports some code from chromium for using the bundled
toolchain.

BUG=chromium:548586
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31706}
2015-11-02 10:40:28 +00:00
Michael Achenbach
0c224551fd Whitespace change to test swarming.
Cr-Commit-Position: refs/heads/master@{#31705}
2015-11-02 10:29:20 +00:00
zhengxing.li
62acae2436 X87: Reland "[es6] Better support for built-ins subclassing."
port 4490ce8520 (r31701).

  original commit message:
    Original issue's description:
    > [es6] Better support for built-ins subclassing.
    >
    > Create proper initial map for original constructor (new.target) instead of doing prototype
    > transition on the base constructor's initial map. This approach fixes in-object slack tracking
    > for subclass instances.
    > This CL also fixes subclassing from String.
    >
    > BUG=v8:3101, v8:3330
    > LOG=Y
    >
    > Committed: https://crrev.com/cd5f48302a502154a0106d12e3066bd563c6340c
    > Cr-Commit-Position: refs/heads/master@{#31680}

    It also fixes typed array map smashing done during typed array initialization.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31704}
2015-11-02 10:00:10 +00:00
bmeurer
7fcad712ed [turbofan] Add support for keyed access to named properties.
The compiler can generate a named access for o[x] if x is a compile time
constant that can be turned into a name using ToName (limited to
primitive x values, because other ToName invocations might be observable),
or the KeyedLoadIC/KeyedStoreIC have gather constant name feedback for x
(i.e. the access always goes to the same symbol).

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

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

Cr-Commit-Position: refs/heads/master@{#31703}
2015-11-02 08:55:15 +00:00
yangguo
f8a43459d4 Expose string/regexp related public symbols on harmony flag.
R=littledan@chromium.org
BUG=v8:4305, v8:4343, v8:4344, v8:4345
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31702}
2015-11-02 08:43:02 +00:00
ishell
4490ce8520 Reland "[es6] Better support for built-ins subclassing."
Original issue's description:
> [es6] Better support for built-ins subclassing.
>
> Create proper initial map for original constructor (new.target) instead of doing prototype
> transition on the base constructor's initial map. This approach fixes in-object slack tracking
> for subclass instances.
> This CL also fixes subclassing from String.
>
> BUG=v8:3101, v8:3330
> LOG=Y
>
> Committed: https://crrev.com/cd5f48302a502154a0106d12e3066bd563c6340c
> Cr-Commit-Position: refs/heads/master@{#31680}

It also fixes typed array map smashing done during typed array initialization.

BUG=v8:3101, v8:3330, v8:4419
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#31701}
2015-11-02 08:25:43 +00:00
bmeurer
8954ea1b6f [turbofan] Add support for loading missing properties.
Return undefined for missing properties (or throw an exception in strong
mode). Also do a bit of code cleanup.

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

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

Cr-Commit-Position: refs/heads/master@{#31700}
2015-11-02 07:35:25 +00:00
v8-autoroll
c4243fcc27 Update V8 DEPS.
Rolling v8/buildtools to c2f259809d5ede3275df5ea0842f0431990c4f98

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

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

Cr-Commit-Position: refs/heads/master@{#31699}
2015-10-31 03:21:18 +00:00
ahaas
44b520f57f Implement the BufferedRawMachineAssemblerTester.
This utility makes it possible to test TF graphs that accept parameters of any machine type (even int64 and float64), which are previously problematic due to the complexity of C calling conventions.

R=titzer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31698}
2015-10-30 21:32:49 +00:00
mythria
e66d4f8736 [Interpreter] Merges ToBoolean and JumpIfTrue/False bytecodes
Adds an optimization to emit JumpIfToBooleanTrue/False instead
of ToBoolean followed by JumpIfTrue/False if the value in the
accumulator is not boolean.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31697}
2015-10-30 16:48:33 +00:00
machenbach
7153c7f48c [swarming] Isolate llvm symbolizer and tsan suppressions file.
BUG=chromium:535160
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31696}
2015-10-30 16:21:13 +00:00
bmeurer
17a651917a [turbofan] Add support for transitioning stores to double fields.
This introduces an AllocateMutableHeapNumberStub for the boxed double
field case, where we need to allocate a box in case of a transitioning
store first. We cannot use our inline allocations for this currently,
because mutable HeapNumber objects have certain alignment constraints,
and I don't want to mess up Allocate/AllocateInNewSpace eagerly.

Also refactor the PropertyAccessInfoFactory slightly to split the long
methods into simpler parts.

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

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

Cr-Commit-Position: refs/heads/master@{#31695}
2015-10-30 16:12:07 +00:00
mstarzinger
335a8fc332 [turbofan] Introduce conditional builders into AstGraphBuilder.
This re-introduces the long lost concept of conditional builder methods
into the AstGraphBuilder that are allowed to return {nullptr} when a
certain optimization does not apply. This can be used to separate our
optimizations in the graph builder clearly from code required for
correctness.

R=bmeurer@chromium.org
BUG=v8:4513
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31694}
2015-10-30 15:59:07 +00:00
mstarzinger
0b293d877c Simplify dispatch in FullCodeGenerator::VisitCall a bit.
This makes FullCodeGenerator::VisitCall be independent of the target
architecture. Only the EmitPossiblyEvalCall case was dependent and is
hoisted into an emitter method.

R=rossberg@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31693}
2015-10-30 14:42:16 +00:00
bmeurer
06eb555fa3 [turbofan] Move PropertyAccessInfo and friends to a separate file.
Also changed the way that transitioning stores are represented in
a PropertyAccessInfo: There's no dedicated kind, but DataFields
have an optional transition map.

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

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

Cr-Commit-Position: refs/heads/master@{#31692}
2015-10-30 14:25:22 +00:00
milton.chiang
1d14ebfcc1 Add ARMv8-A to the supporting list of arm platforms
BUG=chrome-os-partner:36669
R=jochen@chromium.org
LOG=N

Signed-off-by: Milton Chiang <milton.chiange@mediatek.com>

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

Cr-Commit-Position: refs/heads/master@{#31691}
2015-10-30 14:17:20 +00:00
baptiste.afsa
ec61253786 Enable ARMv8 32-bit build.
R=danno@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31690}
2015-10-30 14:10:55 +00:00
bmeurer
961fef2dd2 [turbofan] Specialize JSCallFunction based on CallIC feedback.
If the CallIC collected a known target function for a callsite, add
a runtime check to ensure that the feedback remains the same and
specialize the JSCallFunction node to the known target function so that
inlining and typed lowering can pick up the feedback.

R=mstarzinger@chromium.org
BUG=v8:4470, v8:4493
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31689}
2015-10-30 12:57:45 +00:00
rmcilroy
4c05639e41 Remove deprecated API functions from cctests/interpreter
Removes deprecated functions from the following files:
 test/cctest/interpreter/test-bytecode-generator.cc
 test/cctest/interpreter/test-interpreter.cc

BUG=v8:4134
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31688}
2015-10-30 12:56:36 +00:00
rmcilroy
40f8605ff9 [Interpreter] Add switch support.
Adds support for switch statments to the interpreter.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31687}
2015-10-30 12:55:23 +00:00
bmeurer
18b37c7f59 [turbofan] Don't lookup private symbols on prototypes.
R=yangguo@chromium.org
BUG=v8:4470
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31686}
2015-10-30 12:14:42 +00:00
neis
5820adf276 [es6] Partially implement Reflect.set.
Proxies are not properly supported yet.

R=rossberg
BUG=v8:3931
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31685}
2015-10-30 11:48:43 +00:00
bmeurer
08ca3f240c Revert of [es6] Better support for built-ins subclassing. (patchset #8 id:200001 of https://codereview.chromium.org/1427483002/ )
Reason for revert:
Breaks test on win32 nosnap.http://build.chromium.org/p/client.v8/builders/V8%20Win32%20-%20nosnap%20-%20shared/builds/9680

Original issue's description:
> [es6] Better support for built-ins subclassing.
>
> Create proper initial map for original constructor (new.target) instead of doing prototype transition on the base constructor's initial map. This approach fixes in-object slack tracking for subclass instances.
> This CL also fixes subclassing from String.
>
> BUG=v8:3101, v8:3330
> LOG=Y
>
> Committed: https://crrev.com/cd5f48302a502154a0106d12e3066bd563c6340c
> Cr-Commit-Position: refs/heads/master@{#31680}

TBR=verwaest@chromium.org,ulan@chromium.org,ishell@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3101, v8:3330

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

Cr-Commit-Position: refs/heads/master@{#31684}
2015-10-30 11:36:35 +00:00
rmcilroy
6173d504ee [Interpreter] Add wide varients of bytecodes with feedback and constant pool indexes.
Adds wide bytecode varients, which take 16-bit feedback slot and constant
pool entry indexes for the following bytecodes:
  - LoadICSloppyWide
  - LoadICStrictWide
  - KeyedLoadICSloppyWide
  - KeyedLoadICStrictWide
  - StoreICSloppyWide
  - StoreICStrictWide
  - KeyedStoreICSloppyWide
  - KeyedStoreICStrictWide
  - LdaGlobalSloppyWide
  - LdaGlobalStrictWide
  - StaGlobalSloppyWide
  - StaGlobalStrictWide
  - LdaConstantWide

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31683}
2015-10-30 11:17:29 +00:00
machenbach
b1f00106c2 [Swarming] Set up sanitizer environment in v8 test runner.
This is currently hardcoded in the infra-side test runner
setup, but will be removed there, so that swarming triggers
don't need a custom environment.

BUG=chromium:535160
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31682}
2015-10-30 11:08:34 +00:00
mstarzinger
d1805edada Move interpreter cctests into v8::internal::interpreter namespace.
This moves the cctest file for the interpreter to live in the same
namespace as the components it is testing. Hence we can avoid the
forbidden using directives pulling in entire namespaces.

From the Google C++ style guide: "You may not use a using-directive to
make all names from a namespace available". This would be covered by
presubmit linter checks if build/namespaces were not blacklisted.

R=rmcilroy@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31681}
2015-10-30 11:05:47 +00:00