Commit Graph

21622 Commits

Author SHA1 Message Date
vogelheim
a0bdb103b6 Default-enable external startup data for Linux for stand-alone builds.
Notes:
- Other platforms to follow later.
- This follows Chromium practice, that mostly uses this feature these days.
- The statically linked-in startup data will stay. So whoever prefers
  the old way just needs to set the flag differently.

Reland crrev.com/959693002, once crrev.com/960883003 is in.

R=machenbach@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26980}
2015-03-04 12:22:01 +00:00
erikcorry
a820568b1f ARM: Load undefined receiver sentinel without constant pool
Each call to emit_32 uses 5 constant pool slots:
* the "emit_32" string
* undefined (the receiver)
* the argument (heap number)
* the load IC
* the call IC

This change cuts that down 20% to 4, by loading the undefined from the heap roots.

R=verwaest@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26979}
2015-03-04 11:02:28 +00:00
vogelheim
2525e8f402 Fix Initialize & Dispose for external snapshot. Make sure v8::V8::(Initialize|Dispose) can be called in any order.
This is a follow-on to crrev.com/960883003, which fixed a memory leak in this code, but uncovered another, more subtle bug:

Previously, the code expected you would v8::V8::Initialize once, and v8::V8::Dispose once. The first bug was that in this case the holder_ variable would point to deallocated memory. The second bug was that once the snapshot was disposed, there was no way to get it back on a future Initialize. These are uncovered by the InitializeAndDisposeMultiple test case.

The fix is to keep memory to the raw snapshot and to then cleanly build & destroy the tables in Initialize & Dispose. Since sometimes setNativesBlob is called just after Initialize, that situation must be handled, too.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#26978}
2015-03-04 10:38:00 +00:00
mvstanton
d232dcfd6a The Global Load IC doesn't yet play well with --vector-ics.
Until this is addressed, we can simply use the regular IC, as we do
in times of serialization.

R=verwaest@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26977}
2015-03-04 09:41:19 +00:00
thakis
30b995fc1b When using ninja and clang, make sure diagnostics are colored.
BUG=none
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#26976}
2015-03-04 05:56:13 +00:00
thakis
b97df83752 Use Rotate*() functions instead of doing this manually.
Shouldn't make a difference in practice, but it's a bit more readable and it
gets the case of a 0 shift correct without undefined behavior.

BUG=463436
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#26975}
2015-03-04 05:53:33 +00:00
hans
721fdb56e0 ARM assembler: fix undefined behaviour in fits_shifter
Bit-shifts have undefined behaviour if the shift amount is greater
or equal to the width of the type.

In this case the code would do imm32 >> 32 when rot == 0.

A newer version of Clang unrolled the loop, optimized the first
iteration away, causing the test suite to fail with:

  #
  # Fatal error in ../src/arm/assembler-arm.cc, line 1212
  # Check failed: !rn.is(ip).
  #

as well as crashing when running Chromium tests on Android (at least
we think this was the cause, see the bug).

BUG=463436, 444089
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#26974}
2015-03-04 03:13:40 +00:00
bmeurer
3709b9254e Revert of [x86] Use better left operand heuristic for Float64Add and Float64Mul. (patchset #1 id:1 of https://codereview.chromium.org/958583003/)
Reason for revert:
Tanks on Atom and Haswell

Original issue's description:
> [x86] Use better left operand heuristic for Float64Add and Float64Mul.
>
> R=dcarney@chromium.org
>
> Committed: https://crrev.com/9da259fb1f4ecfefeb2cf7efbe449d8aa1904032
> Cr-Commit-Position: refs/heads/master@{#26849}

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

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

Cr-Commit-Position: refs/heads/master@{#26973}
2015-03-03 19:18:50 +00:00
dslomov
1604bd46bf Implement subclassing Arrays.
R=mvstanton@chromium.org,arv@chromium.org,rossberg@chromium.org
BUG=v8:3930
LOG=Y

Committed: https://crrev.com/6898da1a28d64d1fb2962804ba566f6d618ffc70
Cr-Commit-Position: refs/heads/master@{#26960}

Committed: https://crrev.com/8d29cc11a56e77297792fe100986a80b65de0051
Cr-Commit-Position: refs/heads/master@{#26963}

Committed: https://crrev.com/0705045b50a29cf1273e9e6b86fe6a627d8dcb43
Cr-Commit-Position: refs/heads/master@{#26966}

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

Cr-Commit-Position: refs/heads/master@{#26972}
2015-03-03 18:45:02 +00:00
rossberg
054989bd04 [es6] Fix for-const loops
R=dslomov@chromium.org
BUG=3983
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#26971}
2015-03-03 18:34:40 +00:00
mstarzinger
b1d2097dca [turbofan] Disable test-run-jsexceptions/DeoptFinallyReturn
Reason for disabling failure on ARM64 simulator in no-snap mode.

TBR=dslomov@chromium.org
TEST=cctest/test-run-jsexceptions/DeoptFinallyReturn
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#26970}
2015-03-03 18:32:44 +00:00
dslomov
9ff21de548 Revert of Implement subclassing Arrays. (patchset #8 id:130001 of https://codereview.chromium.org/975463002/)
Reason for revert:
Arm compilation again.

Aaaarrrrrghhhhhh!!!

Original issue's description:
> Implement subclassing Arrays.
>
> R=mvstanton@chromium.org,arv@chromium.org,rossberg@chromium.org
> BUG=v8:3930
> LOG=Y
>
> Committed: https://crrev.com/6898da1a28d64d1fb2962804ba566f6d618ffc70
> Cr-Commit-Position: refs/heads/master@{#26960}
>
> Committed: https://crrev.com/8d29cc11a56e77297792fe100986a80b65de0051
> Cr-Commit-Position: refs/heads/master@{#26963}
>
> Committed: https://crrev.com/0705045b50a29cf1273e9e6b86fe6a627d8dcb43
> Cr-Commit-Position: refs/heads/master@{#26966}

TBR=arv@chromium.org,mvstanton@chromium.org,rossberg@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3930

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

Cr-Commit-Position: refs/heads/master@{#26969}
2015-03-03 17:48:12 +00:00
mstarzinger
d016387e81 [turbofan] Add test coverage for deopt within try-catch.
This just contains test, no fixes. Note that some of the tests are
still disabled because they either fail or we don't want ClusterFuzz
to pick up the flag yet.

R=jarin@chromium.org
TEST=cctest/test-run-jsexceptions/Deopt,mjsunit/compiler/try-deopt

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

Cr-Commit-Position: refs/heads/master@{#26968}
2015-03-03 17:23:42 +00:00
balazs.kilvady
978c7a8280 MIPS: Move stack unwinding logic into the runtime.
Port 4acbc93dbf

BUG=

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

Cr-Commit-Position: refs/heads/master@{#26967}
2015-03-03 17:15:22 +00:00
dslomov
0705045b50 Implement subclassing Arrays.
R=mvstanton@chromium.org,arv@chromium.org,rossberg@chromium.org
BUG=v8:3930
LOG=Y

Committed: https://crrev.com/6898da1a28d64d1fb2962804ba566f6d618ffc70
Cr-Commit-Position: refs/heads/master@{#26960}

Committed: https://crrev.com/8d29cc11a56e77297792fe100986a80b65de0051
Cr-Commit-Position: refs/heads/master@{#26963}

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

Cr-Commit-Position: refs/heads/master@{#26966}
2015-03-03 17:14:14 +00:00
dslomov
7bf9ef1e39 Revert of Implement subclassing Arrays. (patchset #7 id:110001 of https://codereview.chromium.org/975463002/)
Reason for revert:
Arm buildre complains again (why v8_linux_arm_dbg does not complain?)

Original issue's description:
> Implement subclassing Arrays.
>
> R=mvstanton@chromium.org,arv@chromium.org,rossberg@chromium.org
> BUG=v8:3930
> LOG=Y
>
> Committed: https://crrev.com/6898da1a28d64d1fb2962804ba566f6d618ffc70
> Cr-Commit-Position: refs/heads/master@{#26960}
>
> Committed: https://crrev.com/8d29cc11a56e77297792fe100986a80b65de0051
> Cr-Commit-Position: refs/heads/master@{#26963}

TBR=arv@chromium.org,mvstanton@chromium.org,rossberg@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3930

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

Cr-Commit-Position: refs/heads/master@{#26965}
2015-03-03 16:41:52 +00:00
yangguo
32979cf6d8 Use locker when creating snapshot if necessary.
R=vogelheim@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26964}
2015-03-03 16:14:15 +00:00
dslomov
8d29cc11a5 Implement subclassing Arrays.
R=mvstanton@chromium.org,arv@chromium.org,rossberg@chromium.org
BUG=v8:3930
LOG=Y

Committed: https://crrev.com/6898da1a28d64d1fb2962804ba566f6d618ffc70
Cr-Commit-Position: refs/heads/master@{#26960}

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

Cr-Commit-Position: refs/heads/master@{#26963}
2015-03-03 16:10:41 +00:00
verwaest
a8b538ddf9 Speed up identifier, keyword and smi parsing
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26962}
2015-03-03 15:27:53 +00:00
mvstanton
01e2ba6e19 Revert of Implement subclassing Arrays. (patchset #6 id:90001 of https://codereview.chromium.org/975463002/)
Reason for revert:
ARM build failure...

Original issue's description:
> Implement subclassing Arrays.
>
> R=mvstanton@chromium.org,arv@chromium.org,rossberg@chromium.org
> BUG=v8:3930
> LOG=Y
>
> Committed: https://crrev.com/6898da1a28d64d1fb2962804ba566f6d618ffc70
> Cr-Commit-Position: refs/heads/master@{#26960}

TBR=arv@chromium.org,rossberg@chromium.org,dslomov@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3930

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

Cr-Commit-Position: refs/heads/master@{#26961}
2015-03-03 14:56:09 +00:00
dslomov
6898da1a28 Implement subclassing Arrays.
R=mvstanton@chromium.org,arv@chromium.org,rossberg@chromium.org
BUG=v8:3930
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#26960}
2015-03-03 13:40:39 +00:00
bmeurer
a19cfb0ea5 [turbofan] Support inlining of unguarded loops.
Also allow inlining of native functions.

R=mstarzinger@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26959}
2015-03-03 13:09:53 +00:00
jarin
d0b8839b35 [turbofan] Take type into account when determining Word32 phi representation.
BUG=
R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26958}
2015-03-03 12:23:21 +00:00
mstarzinger
4acbc93dbf Move stack unwinding logic into the runtime.
R=jarin@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26957}
2015-03-03 12:03:14 +00:00
verwaest
84b36933c5 Speed up parsing of smis
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26956}
2015-03-03 11:05:03 +00:00
sejunho
a6f5fca5e6 Fix preparing log file name.
Problem:
Excuting with flags as "--prof --logfile-per-isolate --logfile=/path/to/filename"
expected file name: /path/to/isolate-<isolate id>-filename
current result: isolate-<isolate id>-/path/to/filename

This patch makes the file name we expected.

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

Cr-Commit-Position: refs/heads/master@{#26955}
2015-03-03 11:03:49 +00:00
rmcilroy
7611aace3e Don't apply pointer multipler to heap sizes on Android.
Android doesn't have swap space so if the heap goes over the physical memory
size the system will just kill us. Applying the Heap::kPointerMultipler
to heap size could cause the max heap size to be larger than physical memory.
Instead use the defaults which are based on actual physical memory configured
by Api::ConfigureDefaults().

BUG=432909
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#26954}
2015-03-03 10:19:03 +00:00
loislo
cbda41c88a CpuProfiler: do not calculate positions if it is not necessary (TryInline part).
TryInline needed position only for the case when we track positions.
We can drop the position argument and use the current position from GraphBuilder.
The only problem that it doesn't match with the inline point.
The reason of that was the fact that builder had moved the position forward by
visiting arguments expressions.

I fixed this by restoring the current positon in HOptimizedGraphBuilderWithPositions::Visit*

BUG=452067
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#26953}
2015-03-03 08:42:41 +00:00
dcarney
6130b02524 convert more object functions to return maybes
R=svenpanne@chromium.org

BUG=v8:3929
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#26952}
2015-03-03 07:14:45 +00:00
michael_dawson
a3465838bc Contribution of PowerPC port (continuation of 422063005) - currency
Contribution of PowerPC port (continuation of 422063005, 817143002,
866843003, and 901083004. This patch updates the ppc directories
to make them current with changes in common code, removes the
optimization to use the ool constant pool, and excludes tests that
don't pass under the ppc simulator given a 240s timeout.

Subsequent patches will cover:
   - remaining optimizations for PPC
   - remaining AIX changes not resolved by 4.8 compiler (4.8 is only recently available for AIX)
   - incremental updates required to ppc directories due to platform specific changes made
    in google repos while we complete the above steps.

	modified:   src/compiler/ppc/code-generator-ppc.cc
	modified:   src/ic/ppc/handler-compiler-ppc.cc
	modified:   src/ppc/assembler-ppc-inl.h
	modified:   src/ppc/assembler-ppc.cc
	modified:   src/ppc/assembler-ppc.h
	modified:   src/ppc/builtins-ppc.cc
	modified:   src/ppc/code-stubs-ppc.cc
	modified:   src/ppc/debug-ppc.cc
	modified:   src/ppc/deoptimizer-ppc.cc
	modified:   src/ppc/frames-ppc.cc
	modified:   src/ppc/frames-ppc.h
	modified:   src/ppc/full-codegen-ppc.cc
	modified:   src/ppc/lithium-codegen-ppc.cc
	modified:   src/ppc/lithium-ppc.cc
	modified:   src/ppc/lithium-ppc.h
	modified:   src/ppc/macro-assembler-ppc.cc
	modified:   src/ppc/macro-assembler-ppc.h
	modified:   test/cctest/cctest.status
	modified:   test/mjsunit/mjsunit.status

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

BUG=

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

Cr-Commit-Position: refs/heads/master@{#26951}
2015-03-03 07:05:00 +00:00
weiliang.lin
11d97bf531 [x64] Use movaps instead of movsd for the move between double registers.
Review URL: https://codereview.chromium.org/972053002

Cr-Commit-Position: refs/heads/master@{#26950}
2015-03-03 06:34:25 +00:00
bmeurer
8df194c14a [turbofan] Fix ControlFlowOptimizer to also handle non-control nodes in the control chain.
Review URL: https://codereview.chromium.org/971223002

Cr-Commit-Position: refs/heads/master@{#26949}
2015-03-03 06:11:52 +00:00
chunyang.dai
38d303c5ca X87: Prefill with correct contextual load ICs in fullcodegen.
port 7ee31a2348 (r26941).

original commit message:

  Compute correct contextual load ICs in fullcodegen.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#26948}
2015-03-03 05:56:10 +00:00
yangguo
ea02c3339d Tweak memory management in the serializer.
R=vogelheim@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26947}
2015-03-02 19:57:53 +00:00
Balazs Kilvady
363dbde912 MIPS: Compute correct contextual load ICs in fullcodegen.
Port 7ee31a2348

BUG=
R=dusan.milosavljevic@imgtec.com

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

Cr-Commit-Position: refs/heads/master@{#26946}
2015-03-02 17:17:42 +00:00
Dan Carney
1b7cc089ac fix webkit tests
r26943 just moved the problem around

TBR=svenpanne@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26945}
2015-03-02 15:49:48 +00:00
Jaroslav Sevcik
964f6a3eb8 [turbofan] Normalize union of representation and range to a range.
BUG=
R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26944}
2015-03-02 14:35:26 +00:00
Dan Carney
5f49fef325 check for null context on execution entry
blink is incorrectly calling api functions without a context.  we need this to find those places

R=svenpanne@chromium.org

BUG=v8:3929
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#26943}
2015-03-02 14:17:20 +00:00
Benedikt Meurer
e1c2c9016e [turbofan] Strength reduction of Word32And with Int32Mul.
- (x * (K << L)) & (-1 << L) => x * (K << L)
- ((K << L) * x) & (-1 << L) => x * (K << L)

R=dcarney@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26942}
2015-03-02 13:54:09 +00:00
Toon Verwaest
7ee31a2348 Compute correct contextual load ICs in fullcodegen.
BUG=
R=dcarney@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26941}
2015-03-02 13:36:58 +00:00
Dan Carney
1fcedda668 convert object::* to return maybe values
BUG=v8:3929
LOG=y
R=svenpanne@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26940}
2015-03-02 13:13:31 +00:00
Benedikt Meurer
5f3914fc19 [turbofan] Use the typer to statically detect Smis.
R=rossberg@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26939}
2015-03-02 13:10:42 +00:00
Jaroslav Sevcik
f0b11873a3 [turbofan] Fix deferred replacement in simplified lowering.
Deferred replacement must also replace in the pending node vector.

BUG=chromium:463056
LOG=n
R=bmeurer@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26938}
2015-03-02 12:49:49 +00:00
Sven Panne
602d0dab93 Removed funky Maybe constructor and made fields private.
BUG=v8:3929
LOG=y
R=dcarney@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26937}
2015-03-02 12:22:37 +00:00
Sven Panne
30637108dd Polish Maybe API a bit, removing useless creativity and fixing some signatures.
BUG=v8:3929
LOG=y
R=dcarney@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26936}
2015-03-02 11:27:05 +00:00
Benedikt Meurer
502898ef60 [x86] Improve code generation for context materialization.
On Intel targets, it is cheaper to load the context from the frame
instead of loading the context as a constant (which usually involves a
PropertyCell because the context is in new space when we compile the
function).

R=jarin@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26935}
2015-03-02 09:09:42 +00:00
Benedikt Meurer
155278d6f2 [turbofan] Skip write barriers when storing smi.
On 64-bit targets, we can skip the write barrier for Store nodes if the
input is ChangeInt32ToTagged, because the value being stored is
definitely represented as a smi then.

R=jarin@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26934}
2015-03-02 09:09:08 +00:00
arv
c791d84112 Revert of ES6: Make function name configurable (patchset #10 id:220001 of https://codereview.chromium.org/960343002/)
Reason for revert:
Breaks Chrome browser test that checks Object.name

[16509:16509:0228/030150:INFO:CONSOLE(43)] "Uncaught Error: Clobbered Object.name getter", source: http://www.chromium.org:33611/assertions.js (43)

http://build.chromium.org/p/client.v8/builders/Linux%20Tests%20%28dbg%29%281%29/builds/2328/steps/browser_tests/logs/stdio

Original issue's description:
> ES6: Make function name configurable
>
> This is partially based on r21609 but that CL was incomplete.
>
> Function name is still non writable so one has to use defineProperty
> to change the actual value.
>
> BUG=v8:3333
> LOG=N
> R=adamk, mstarzinger@chromium.org
>
> Committed: https://crrev.com/f7790f7670c8d859455a98fcb90ff1b66af1eca7
> Cr-Commit-Position: refs/heads/master@{#26924}

TBR=adamk@chromium.org,mstarzinger@chromium.org,verwaest@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:3333

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

Cr-Commit-Position: refs/heads/master@{#26933}
2015-03-02 00:19:01 +00:00
cdai2
8b33fa6069 X87: Disallow subclassing Arrays.
port 290ee378ea (r26931).

original commit message:

UG=
R=weiliang.lin@intel.com

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

Cr-Commit-Position: refs/heads/master@{#26932}
2015-02-28 08:29:29 +00:00
dslomov
290ee378ea Disallow subclassing Arrays.
R=rossberg@chromium.org,arv@chromium.org
BUG=v8:3930
LOG=Y

Committed: https://crrev.com/87f3e08e72510ee5544e82bb7ad39b2b5f001ad3
Cr-Commit-Position: refs/heads/master@{#26925}

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

Cr-Commit-Position: refs/heads/master@{#26931}
2015-02-28 00:28:35 +00:00