Commit Graph

299 Commits

Author SHA1 Message Date
Jakob Gruber
e5ecb24859 Revert "Reland: Reimplement Object.entries/values as CSA to optimize performance."
This reverts commit 03e9d415c2.

Reason for revert: Correctness issues, see https://crbug.com/804159.

Bug: chromium:804159

Original change's description:
> Reland: Reimplement Object.entries/values as CSA to optimize performance.
> 
> Add Object.entries/values builtins to debug-evaluate.cc whitelist macro.
> This fix revert commit of https://chromium-review.googlesource.com/c/v8/v8/+/859937
> Original is https://chromium-review.googlesource.com/c/v8/v8/+/810504
> >> Reimplements Object.entries/values as CSA to optimize performance. See more detail about https://bugs.chromium.org/p/v8/issues/ Issue 6804.
> 
> This reverts commit 1b49f725ac.
> 
> Bug: v8:6804
> Change-Id: I57e8b66e1c4ece2abb52e1630a97fbfd4070d810
> Reviewed-on: https://chromium-review.googlesource.com/860679
> Commit-Queue: Yang Guo <yangguo@chromium.org>
> Reviewed-by: Yang Guo <yangguo@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#50492}

TBR=yangguo@chromium.org,cbruni@chromium.org,jgruber@chromium.org,ishell@chromium.org,brn@b6n.ch

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: v8:6804
Change-Id: I39b1854ca7c2f57819ba377f84560356d3756bfb
Reviewed-on: https://chromium-review.googlesource.com/877886
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50746}
2018-01-22 09:47:43 +00:00
Qingyan Li
473d747dbe [snapshot]: Fix missing Cast in {Private, Signature, AccessorSignature}
R=yangguo@chromium.org

Bug: v8:7306
Cq-Include-Trybots: master.tryserver.chromium.linux:linux_chromium_rel_ng
Change-Id: I40037ebb66a856b52454c50d17b4c8a51aab7a84
Reviewed-on: https://chromium-review.googlesource.com/866215
Commit-Queue: Yang Guo <yangguo@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50618}
2018-01-16 12:07:41 +00:00
Taketoshi Aono
03e9d415c2 Reland: Reimplement Object.entries/values as CSA to optimize performance.
Add Object.entries/values builtins to debug-evaluate.cc whitelist macro.
This fix revert commit of https://chromium-review.googlesource.com/c/v8/v8/+/859937
Original is https://chromium-review.googlesource.com/c/v8/v8/+/810504
>> Reimplements Object.entries/values as CSA to optimize performance. See more detail about https://bugs.chromium.org/p/v8/issues/ Issue 6804.

This reverts commit 1b49f725ac.

Bug: v8:6804
Change-Id: I57e8b66e1c4ece2abb52e1630a97fbfd4070d810
Reviewed-on: https://chromium-review.googlesource.com/860679
Commit-Queue: Yang Guo <yangguo@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50492}
2018-01-11 07:04:00 +00:00
Yang Guo
1b49f725ac Revert "Reimplement Object.entries/values as CSA to optimize performance."
This reverts commit d30a8fa9b4.

Reason for revert: no-snap test failures here
https://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20nosnap%20-%20debug/builds/17068
You need to update the whitelist in src/debug/debug-evaluate.cc.
I'm a bit surprised this only happens in no-snap builds.


Original change's description:
> Reimplement Object.entries/values as CSA to optimize performance.
> 
> This implementation based on runtime implementation.
> 
> Bug: v8:6804
> Change-Id: Ib8bfcc4648e44a999789237effc0275c5e4d9936
> Reviewed-on: https://chromium-review.googlesource.com/810504
> Commit-Queue: Camillo Bruni <cbruni@chromium.org>
> Reviewed-by: Camillo Bruni <cbruni@chromium.org>
> Reviewed-by: Jakob Gruber <jgruber@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#50477}

TBR=cbruni@chromium.org,jgruber@chromium.org,ishell@chromium.org,brn@b6n.ch

Change-Id: I1a0c8e3c054a57ca4d15f7a064ff4b28ca133b16
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:6804
Reviewed-on: https://chromium-review.googlesource.com/859937
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50478}
2018-01-10 13:34:53 +00:00
Taketoshi Aono
d30a8fa9b4 Reimplement Object.entries/values as CSA to optimize performance.
This implementation based on runtime implementation.

Bug: v8:6804
Change-Id: Ib8bfcc4648e44a999789237effc0275c5e4d9936
Reviewed-on: https://chromium-review.googlesource.com/810504
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50477}
2018-01-10 12:27:00 +00:00
Timothy Gu
ddfbbc5537 [builtins] Port Proxy.revocable() to CSA
Bug: v8:7245
Change-Id: Ia8931037021b935e776230a6a50c580ad82efba8
Reviewed-on: https://chromium-review.googlesource.com/844065
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50394}
2018-01-07 10:20:13 +00:00
Franziska Hinkelmann
971875ca4d Revert "[api] Prefer Descriptor interceptor over Getter in GetPropertyAttributes"
This reverts commit d5fbf7c5c3.

Reason for revert: Performance regression, see https://bugs.chromium.org/p/chromium/issues/detail?id=798279

Original change's description:
> [api] Prefer Descriptor interceptor over Getter in GetPropertyAttributes
> 
> Also fix GetPropertyDescriptorWithInterceptor so that it only calls the
> interceptor once.
> 
> R=​ahaas@chromium.org, franzih@chromium.org
> 
> Bug: node:17480, node:17481
> Change-Id: I2c3813f80df2962ec909bae7267884ce0b8ccbef
> Reviewed-on: https://chromium-review.googlesource.com/816515
> Commit-Queue: Franziska Hinkelmann <franzih@chromium.org>
> Reviewed-by: Franziska Hinkelmann <franzih@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#50260}

TBR=timothygu99@gmail.com,ahaas@chromium.org,franzih@chromium.org,sergiyb@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: node:17480, node:17481
Change-Id: I4997e0f3a330d719026e56dd83c1bb999b986bcf
Reviewed-on: https://chromium-review.googlesource.com/850355
Reviewed-by: Franziska Hinkelmann <franzih@chromium.org>
Commit-Queue: Franziska Hinkelmann <franzih@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50362}
2018-01-04 15:12:20 +00:00
Timothy Gu
d5fbf7c5c3 [api] Prefer Descriptor interceptor over Getter in GetPropertyAttributes
Also fix GetPropertyDescriptorWithInterceptor so that it only calls the
interceptor once.

R=ahaas@chromium.org, franzih@chromium.org

Bug: node:17480, node:17481
Change-Id: I2c3813f80df2962ec909bae7267884ce0b8ccbef
Reviewed-on: https://chromium-review.googlesource.com/816515
Commit-Queue: Franziska Hinkelmann <franzih@chromium.org>
Reviewed-by: Franziska Hinkelmann <franzih@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50260}
2017-12-21 11:57:18 +00:00
marcin
6e174eb826 Remove initial whitespace & empty lines to decrease JS files size
Patch will decrease size of JS files included into Chrome APK
(about 11 KB now)

Bug: 
Change-Id: I701c9904fbf22fd295199f255601dea6524a3766
Reviewed-on: https://chromium-review.googlesource.com/821071
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Marcin Wiącek <marcin@mwiacek.com>
Cr-Commit-Position: refs/heads/master@{#50179}
2017-12-19 00:04:19 +00:00
Mikhail Gusarov
f987549009 [build] Do not fail build if source dir has 'debug' in it.
If the source checkout had 'debug' somewhere in the path name, then
IsDebuggerFile() marked all modules as debug ones, which triggered
an assertion during snapshot generation.

Bug: 
Change-Id: I93537efca9152c5469bb760f32ca53b06351f7a4
Reviewed-on: https://chromium-review.googlesource.com/809205
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49980}
2017-12-10 22:26:34 +00:00
jgruber
c1f2966d4c Reland "[coverage] add coverage for binary expressions"
This is a reland of 4d3bc552b5
Original change's description:
> [coverage] add coverage for binary expressions
> 
> Adds block-level coverage tracking for binary && and ||
> expressions. Introduces a BinaryOperation source-range
> for tracking the operations themselves and an Expression
> source-range, used for tracking NaryLogical expressions.
> 
> This builds on work by jgruber@chromium.org in
> the issue.
> 
> TBR=marja@chromium.org
> R=jgruber@chromium.org, rmcilroy@chromium.org
> 
> Bug: v8:6660
> Change-Id: I83a81f13a3514a734c06948b2d3e91138fb00e18
> Reviewed-on: https://chromium-review.googlesource.com/754564
> Commit-Queue: Jakob Gruber <jgruber@chromium.org>
> Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
> Reviewed-by: Jakob Gruber <jgruber@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#49304}

Bug: v8:6660
Change-Id: I1c8571660d6c501d526886867bd841c49d5c44fd
Reviewed-on: https://chromium-review.googlesource.com/778288
Reviewed-by: Marja Hölttä <marja@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49613}
2017-11-24 08:44:23 +00:00
Sylvestre Ledru
e9d602250f Remove a useless declaration: preload_characters cannot be > 4 as we have a Min() above
Bug: 
Change-Id: I553d6481a485a87c0246424270d63297400ceabe
Reviewed-on: https://chromium-review.googlesource.com/579909
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49476}
2017-11-20 10:37:40 +00:00
Anna Henningsen
09b53eef4c [api] Make running scripts in AddMessageListener callback work in debug mode
The existance of an `AllowJavascriptExecutionDebugOnly` scope in
`Isolate::ReportPendingMessages()` indicates that the API supports
running arbitrary JS code in a `AddMessageListener` callback.

Currently, this can fail in debug mode: The
`!isolate->external_caught_exception()` condition is checked when
entering API methods inside such a handler. However, if there is
a verbose `TryCatch` active when the exception occurs, this
check fails, and when calling `ToString()` on the exception object
leaves a pending exception itself, the flag is re-set to `true`.

Fix this problem by clearing the flag and the pending exception if
there was one during `ToString()`. This matches the code a few lines
up in `messages.cc`, so the exception state is now consistent
during the callback.

This currently makes a Node.js test fail in debug mode
(`parallel/test-error-reporting`).

Bug: node:7144
Bug: node:17016
Change-Id: I060d00fea3e9a497f4df34c6ff8d6e29ebe96321
Reviewed-on: https://chromium-review.googlesource.com/718096
Commit-Queue: Yang Guo <yangguo@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49466}
2017-11-18 23:39:29 +00:00
Jakob Gruber
9037639eb1 Revert "[coverage] add coverage for binary expressions"
This reverts commit 4d3bc552b5.

Reason for revert: https://crbug.com/785778

Original change's description:
> [coverage] add coverage for binary expressions
> 
> Adds block-level coverage tracking for binary && and ||
> expressions. Introduces a BinaryOperation source-range
> for tracking the operations themselves and an Expression
> source-range, used for tracking NaryLogical expressions.
> 
> This builds on work by jgruber@chromium.org in
> the issue.
> 
> TBR=marja@chromium.org
> R=​jgruber@chromium.org, rmcilroy@chromium.org
> 
> Bug: v8:6660
> Change-Id: I83a81f13a3514a734c06948b2d3e91138fb00e18
> Reviewed-on: https://chromium-review.googlesource.com/754564
> Commit-Queue: Jakob Gruber <jgruber@chromium.org>
> Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
> Reviewed-by: Jakob Gruber <jgruber@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#49304}

TBR=rmcilroy@chromium.org,marja@chromium.org,jgruber@chromium.org,ben@npmjs.com

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: v8:6660
Change-Id: Ie017c528604b2e01400f527511413eaea5786198
Reviewed-on: https://chromium-review.googlesource.com/776768
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49454}
2017-11-17 17:05:39 +00:00
Benjamin
4d3bc552b5 [coverage] add coverage for binary expressions
Adds block-level coverage tracking for binary && and ||
expressions. Introduces a BinaryOperation source-range
for tracking the operations themselves and an Expression
source-range, used for tracking NaryLogical expressions.

This builds on work by jgruber@chromium.org in
the issue.

TBR=marja@chromium.org
R=jgruber@chromium.org, rmcilroy@chromium.org

Bug: v8:6660
Change-Id: I83a81f13a3514a734c06948b2d3e91138fb00e18
Reviewed-on: https://chromium-review.googlesource.com/754564
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49304}
2017-11-10 17:41:51 +00:00
cjihrig
14ddbc1899 Update postmortem metadata jobs
This commit updates the jobs for generating postmortem
metadata. I96a8a7cdded6f7c37b6f1da659d63df9e3a5de2b moved
the Code class to a new file without updating the postmortem
jobs. This resulted in some constants used by Node.js to
disappear, leading to build failures on SmartOS.

See: https://github.com/nodejs/node-v8/issues/21
Bug: 
Change-Id: Icf5f59fe464d933c4f5a3f622b08c01bc43c6a80
Reviewed-on: https://chromium-review.googlesource.com/741919
Commit-Queue: Yang Guo <yangguo@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49168}
2017-11-07 08:07:29 +00:00
Jan Krems
8683248625 [modules] Optimize import.meta in the interpreter
Use an intrinsic for GetImportMetaObject and generate bytecode for the
case where import.meta has been initialized already. This way the
runtime method will only be called once per module.

Bug: v8:6693
Change-Id: If661e88e6accfb1c5795e37a80582d04f6dd87dd
Reviewed-on: https://chromium-review.googlesource.com/716536
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#48801}
2017-10-20 20:31:49 +00:00
Kris Selden
7fc550b758 [profiler] Add missing node type name.
Bug: v8:6968
Change-Id: Ibb19e96b6ce8ad56356ab6c4fb6bbc588bbb7420
Reviewed-on: https://chromium-review.googlesource.com/729248
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#48799}
2017-10-20 19:18:37 +00:00
ccyongwang
39b2227bbd fix compile error when use PersistentValueMap.
In PersistentValueMap, SetWeak function should supply WeakCallbackType arguments.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_chromium_rel_ng
Change-Id: I70a59e90b7ea0a10f695419e57ae9bfb8d5ba852
Reviewed-on: https://chromium-review.googlesource.com/684002
Commit-Queue: Marja Hölttä <marja@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#48529}
2017-10-13 10:23:57 +00:00
Niklas Hambüchen
4f8a70adca [asm.js] Fix infinite loop in parser on parse error.
The code in `AsmJsScanner::Next()` checks for both
end of input and parse error:

  if (token_ == kEndOfInput || token_ == kParseError) {
    return;
  }

but until now the code in the parsing loop only checked
for `kEndOfInput`, resulting in an infinite loop on
`kParseError`.

R=bradnelson@chromium.org, mstarzinger@chromium.org

Bug: chromium:771428
Change-Id: I9170f090503590b3b9b949a0d00ab4daef85bf66
Reviewed-on: https://chromium-review.googlesource.com/699994
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#48290}
2017-10-04 16:13:39 +00:00
Mostyn Bramley-Moore
e52b4a6284 Update AUTHORS file for Vewd Software
Formerly known as Opera TV.

Change-Id: If141d86e744f3ea9dc9605f6d2b35fc78d291a69
Reviewed-on: https://chromium-review.googlesource.com/683175
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Mostyn Bramley-Moore <mostynb@vewd.com>
Cr-Commit-Position: refs/heads/master@{#48212}
2017-09-28 17:25:36 +00:00
Mateusz Czeladka
fe598532ec Pass Isolate pointer to String::Utf8Value/Value constructors
As part of J2V8 development (https://github.com/eclipsesource/J2V8),
we realized that we had a subtle bug in how Isolate scope was created
and it's lifetime managed, see:
https://github.com/eclipsesource/J2V8/issues/313.

Mentioned above bug was fixed, however, what we also noticed is that
V8 API has been constantly and slowly moving to such an API, in which
one has to pass Isolate explicitly to methods and/or constructors. We
found two more places that might have been overlooked. This contribution
adds passing of Isolate pointer explicitly to constructors of
String::Utf8Value and String::Value classes.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_chromium_rel_ng;master.tryserver.v8:v8_linux_noi18n_rel_ng
Change-Id: I61984285f152aba5ca922100cf3df913a9cb2cea
Reviewed-on: https://chromium-review.googlesource.com/593309
Commit-Queue: Adam Klein <adamk@chromium.org>
Reviewed-by: Adam Klein <adamk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#47656}
2017-08-28 18:17:08 +00:00
peterwmwong
415c72dd9a [builtins] Port String.prototype.includes to CSA
- Convert S.p.includes builtin from CPP to TFJ
  - Fast paths S.p.includes(str) and S.p.includes(str, smi)
- Add Runtime kStringIncludes
- Add StringIncludesIndexOfAssembler (Generate is based on
  StringPrototypeIndexOf builtin)
- S.p.includes and S.p.indexOf both use StringIncludesIndexOfAssembler

Quick measurements show 3x improvement for S.p.includes(str).
More about the measurements: https://gist.github.com/peterwmwong/7a2a96f3171a52f16ca8125a089f38e7

Bug: v8:6680
Change-Id: I79cb8dbe2b79e6df15aa734e128eee25c7e6aaf5
Reviewed-on: https://chromium-review.googlesource.com/620150
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#47546}
2017-08-23 11:04:16 +00:00
Vladan Djeric
2f897f5625 Update AUTHORS file for Facebook organization
We are unblocking contributors from @fb.com and @oculus.com to contribute to Chromium. Our primary contributor group is still specified in our Facebook CLA group and should be consulted before allowing any contributions.

Bug: 
Change-Id: I21ee84a29382f034184d053b77b02c78e6055791
Reviewed-on: https://chromium-review.googlesource.com/558708
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#46997}
2017-07-31 08:53:21 +00:00
Jaime Bernardo
3bef2af6ef [build] Set MSVS .obj folders in gyp for v8_base
Building on Windows with gyp fails depending on the result from
sharding the src/v8.gyp:v8_base target. If two source files with the
same name are in the same shard, their output object file path would
conflict with one another. One example of this conflict is v8_base's
runtime/runtime.cc and the V8 inspector's protocol/Runtime.cpp that
is generated at build time, for which the files runtime.obj and
Runtime.obj would be created, but MSVS overwrites one of them with
the other.

Dividing the .obj output path by the original source's extension
prevents this overwrite.

Refs: https://github.com/nodejs/node/pull/13959
Bug: 
Change-Id: I158e6178f2511297899ee50ea159f574916f903f
Reviewed-on: https://chromium-review.googlesource.com/556599
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#46354}
2017-06-30 12:40:19 +00:00
Jaideep Bajwa
12b2c5ec10 Update AUTHOR file with ibm's new email format
R=marja@chromium.org, mstarzinger@chromium.org
BUG=
LOG=N

Change-Id: Ida5496ac957343c63177697c39e502d952881a26
Reviewed-on: https://chromium-review.googlesource.com/535755
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Jaideep Bajwa <bjaideep@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#46103}
2017-06-21 15:20:06 +00:00
Wiktor Garbacz
f4f723e818 [parsing] Fix past the end position for streaming streams.
Also, as this is hard to track down, always DCHECK position after ReadBlock().

Change-Id: Ie32c3a311dd8df91f651b6d82ccacc7c95e6fde0
Reviewed-on: https://chromium-review.googlesource.com/528196
Commit-Queue: Marja Hölttä <marja@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Reviewed-by: Daniel Vogelheim <vogelheim@chromium.org>
Cr-Commit-Position: refs/heads/master@{#45811}
2017-06-09 11:35:24 +00:00
loorongjie
024c4ff0de Migrate Number constants and undefined to C++
BUG=v8:6005
R=bmeurer@chromium.org

Review-Url: https://codereview.chromium.org/2715793004
Cr-Commit-Position: refs/heads/master@{#43438}
2017-02-27 08:20:45 +00:00
cwhan.tunz
48dff523f7 Throw when a holey property is set in Array.sort
Do not allow that holey properties are defined in Array sort.
Throw a type error if the array is not extensible and there are holey
properties in the middle of the array.

BUG=v8:4888

Review-Url: https://codereview.chromium.org/2664173002
Cr-Commit-Position: refs/heads/master@{#43126}
2017-02-11 13:00:40 +00:00
bakkot
bf9e013bbc [counters] Add UseCounters for 'f() = 0' syntax
This syntax was formerly legal per ECMAScript, but has been a
SyntaxError for some time now. V8 deviates from spec in that it
is instead a runtime error; we'd like to know if we can get
away with removing it (at least in sloppy mode) or if the spec
should be changed.

c.f. https://github.com/tc39/ecma262/issues/257#issuecomment-195106880

Also add self to authors file

BUG=v8:4480

Review-Url: https://codereview.chromium.org/2599253002
Cr-Commit-Position: refs/heads/master@{#41960}
2016-12-27 17:48:40 +00:00
qiuyi.zqy
9ca022fab2 Return false in TryNumberToSize if the number is 1 << 64.
Currently when the number passed to TryNumberToSize is 1 << 64,
it gets away with a bug caused by rounding of mantissa.
Then the number will be casted to 0 and TryNumberToSize
will return true. This patch fix this by making the range check
more accurate.

BUG=v8:5712

Review-Url: https://codereview.chromium.org/2548243004
Cr-Commit-Position: refs/heads/master@{#41578}
2016-12-08 09:20:30 +00:00
henrique.ferreiro
2c38023be3 [cleanup] #undef DECLARE_ERROR instead of non-existent DEFINE_ERROR
The latter was left from a previous commit and not updated later to reflect the new name.

Review-Url: https://codereview.chromium.org/2447023004
Cr-Commit-Position: refs/heads/master@{#40620}
2016-10-27 12:36:36 +00:00
rob
cb2a39d367 Avoid using stale InspectedContext pointers
BUG=657568
TEST=Manually, see bug report

Review-Url: https://codereview.chromium.org/2432163004
Cr-Commit-Position: refs/heads/master@{#40605}
2016-10-26 20:27:12 +00:00
sander
f87d19c42e [crankshaft] Eliminate unnecessary ToNumber call
This is a fix for a regression that started ~6 months ago when
https://codereview.chromium.org/1757013002 landed. This patch will remove the
unnecessary Change/CallWithDescriptor/Change opcodes causing the regression.

BUG=v8:5373
R=bmeurer@chromium.org

Review-Url: https://codereview.chromium.org/2423923002
Cr-Commit-Position: refs/heads/master@{#40345}
2016-10-17 09:27:39 +00:00
dgozman
130d0486c0 [inspector] Initial import of v8_inspector.
Attempt #2, formatted and disabled lint for src/inspector.

BUG=chromium:635948
NOPRESUBMIT=true (for grammar check in license code)

Review-Url: https://codereview.chromium.org/2292573002
Cr-Commit-Position: refs/heads/master@{#39107}
2016-09-01 20:28:33 +00:00
machenbach
081d4870d0 Revert of [inspector] Initial import of v8_inspector. (patchset #3 id:40001 of https://codereview.chromium.org/2292573002/ )
Reason for revert:
Presubmit

Original issue's description:
> [inspector] Initial import of v8_inspector.
>
> BUG=chromium:635948
> NOPRESUBMIT=true (for code style)
>
> Committed: https://crrev.com/e29594ea3c5c41de0844e71f7a82c990a8da71ee
> Cr-Commit-Position: refs/heads/master@{#39057}

TBR=jochen@chromium.org,pfeldman@chromium.org,dgozman@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=chromium:635948

Review-Url: https://codereview.chromium.org/2300823002
Cr-Commit-Position: refs/heads/master@{#39058}
2016-08-31 21:48:40 +00:00
dgozman
e29594ea3c [inspector] Initial import of v8_inspector.
BUG=chromium:635948
NOPRESUBMIT=true (for code style)

Review-Url: https://codereview.chromium.org/2292573002
Cr-Commit-Position: refs/heads/master@{#39057}
2016-08-31 21:34:59 +00:00
mic.besace
38de91a5da Solaris/OpenBSD/FreeBSD: [heap] Uncommit unused large object page memory.
Port d61a5c376b

Original commit message:

    As a first step I uncommit the memory on the main thread. Also
    to measure impact and stability of that optimization. In a
    follow-up CL, the uncommitting should be moved on the concurrent thread.

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

Review-Url: https://codereview.chromium.org/2245703002
Cr-Commit-Position: refs/heads/master@{#38654}
2016-08-16 12:00:53 +00:00
daniel.bevenius
f810ccc867 Updating the code example in FunctionTemplate class documentation
Currently the code example in the FunctionTemplate class documentation
is out of date. This commit updates the examples so they compile and run
without error.

BUG=

Review-Url: https://codereview.chromium.org/2127523003
Cr-Commit-Position: refs/heads/master@{#37741}
2016-07-14 06:34:26 +00:00
diaoyuanjie
1d26ed290b [turbofan] Fixed segmentation fault while printing TurboFan node
Graph trimmer can set Input as null and subsequent
printing call could cause segmentation fault.

R=bmeurer@chromium.org, jarin@chromium.org

Review-Url: https://codereview.chromium.org/2134443002
Cr-Commit-Position: refs/heads/master@{#37658}
2016-07-11 20:43:00 +00:00
honggyu.kp
c52685a516 gdb-v8-support.py: Fix old style print statement
Since python3 does not use the old print statement, it may not be able
to load gdb-v8-support.py script in gdb as below:

  (gdb) source tools/gdb-v8-support.py
    File "tools/gdb-v8-support.py", line 170
      print result
                 ^
  SyntaxError: Missing parentheses in call to 'print'

This fixes print statement for both python2 and python3.

R=jochen@chromium.org
BUG=

Review-Url: https://codereview.chromium.org/2084163004
Cr-Commit-Position: refs/heads/master@{#37488}
2016-07-03 07:11:47 +00:00
oleksandr.chekhovskyi
2f6be682ac Parser: Report use counts once per feature
Reporting use counts by invoking a callback once per occurrence has
a large overhead cost in certain situations, for example when it needs
to be dispatched to a different thread (which is the case for Web Workers).

Parsing large scripts can produce a lot of occurrences (strict/sloppy mode
once per function).

Chromium (the only known user of UseCounters so far) does not actually care
about number of occurrences, but simply whether they happened at least once.
This commit changes behavior to report features at most once, which dramatically
improves performance for impacted use cases, and should not affect the only
known real world usage.

R=littledan@chromium.org
BUG=chromium:614775

Review-Url: https://codereview.chromium.org/2062203002
Cr-Commit-Position: refs/heads/master@{#36979}
2016-06-14 21:41:31 +00:00
nexus226
726d3be8ae tools: Fix a syntax error in plot-timer-events
This fixes a syntax error in plot-timer-events script.

Before:
  $ out/x64.release/d8 --prof --log-timer-events script.js
  $ tools/plot-timer-events v8.log
  tools/plot-timer-events: 75: tools/plot-timer-events: options+=1343: not found
  --distortion=
  Cmdline args: [options] [log-file-name]
  Default log file name is "v8.log".
    ...

After:
  $ out/x64.release/d8 --prof --log-timer-events script.js
  $ tools/plot-timer-events v8.log
  $ ls timer-events.png
  timer-events.png

BUG=

Review-Url: https://codereview.chromium.org/1961873002
Cr-Commit-Position: refs/heads/master@{#36434}
2016-05-23 10:19:47 +00:00
addaleax
6336cc6b2b Fix testing of the VEX.L (128/256-bit) flag in the x64 disassembler
The current code for testing the VEX.L flag, indicating whether
128-bit or 256-bit registers are being accessed, was erroneous
and always returned true (i.e. indicated 128-bit registers).

This patch fixes this behaviour and checks the flag correctly.

Ref: https://github.com/nodejs/node/issues/6151

BUG=

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

Cr-Commit-Position: refs/heads/master@{#35506}
2016-04-15 06:24:29 +00:00
jbriance
0b557da25f [arm/Linux] Don't rely on KUSER_HELPERS feature
ARM specific CONFIG_KUSER_HELPERS kernel feature for Linux can be disabled,
and in this case, we shouldn't crash. Use a __sync_synchronize() call
instead for Linux platforms.

BUG=chromium:599051
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#35170}
2016-03-31 15:56:01 +00:00
m0609.shim
c0aa9054ce Fix histogram timer to generate ProfViz compatible log.
After histrogram timer added time recaling functionality,
some events, e.g. parse, histogram timer generates event log ending with 'MicroSeconds'.

Since ProfViz can't recorgnize it, this patch cuts off 'MicroSeconds' postfix.

R=vogelheim@chromium.org, yangguo@chromium.org
BUG=chromium:
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#34710}
2016-03-11 10:05:24 +00:00
demoneaux
26f617f1bc Optimize JSON stringifying when replacer and space are falsey.
Most libraries use `JSON.stringify` with all three arguments [1] to allow for
configuration, even if `replacer` and `space` are falsey, causing the
optimized native stringifying to be missed. This commit allows for the common
case where `replacer` and `space` are not used to be fast.

[1]: https://github.com/hapijs/hapi/pull/3014

BUG=v8:4730
LOG=N

R=yangguo@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#34174}
2016-02-20 07:55:57 +00:00
xaxxon
b6c9b70356 Make handle ctors explicit
Without this change, the v8::Local<> constructor will be picked up by the
compiler as an option for an implicit cast for any pointer type.  This leads
to bad error messages when accidentally passing an erroneous pointer type to
a function wanting a Local<> (complains about a pointer assignment in Local<>'s
constructor as opposed to a bad type for the parameter of the function being
called) and also causes ambiguity errors where none should exist when calling
overloaded functions (for example a function taking either a std::string or a
v8::Local<v8::Script> cannot be called with a const char * because the compiler
sees both types as being constructable with a const char *).

R=jochen@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#33602}
2016-01-29 09:12:51 +00:00
bangfu.tao
8cb0c0b927 Bug fix: A bug in android-sync tool
BUG=
A bug in android-sync.sh, which caused the android_arm.release.check
unittests crash on device. It is fixed by adding:
  sync_file "$OUTDIR/$ARCH_MODE/natives_blob.bin"
  sync_file "$OUTDIR/$ARCH_MODE/snapshot_blob.bin"

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

Cr-Commit-Position: refs/heads/master@{#33578}
2016-01-28 11:06:27 +00:00
akodat
aeb8073c4a Add Isolate::DiscardThreadSpecificMetadata method to embedder API.
If many threads use the same Isolate (or many Isolates) and then
terminate, their PerIsolateThreadData objects are never cleaned
up, resulting in a slow memory leak and, worse, the
PerIsolateThreadData chain getting larger and larger, adversely
affecting performance.

In this situation, embedders will now be encouraged to apply
DiscardThreadSpecificMetadata against any Isolate a thread is
done with, especially if the thread is about to terminate.

Note that it is harmless to run DiscardThreadSpecificMetadata
against an Isolate for which a thread has no thread data and
per-Isolate thread data can be reestablished if a thread starts
using an Isolate again after running DiscardThreadSpecificMetadata
against it.

It is, however, an embedder error to run
DiscardThreadSpecificMetadata against an Isolate in thread with a
Locker for the Isolate in the stack or against an Entered Isolate.

This change cannot cause any change in behavior in existing apps
as the only added coded can only be reached via the new
DiscardThreadSpecificMetadata method.

R=Jakob, jochen
BUG=

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

Cr-Commit-Position: refs/heads/master@{#32909}
2015-12-16 15:49:49 +00:00
develar
b201a7b93f Export BreakEvent and CompileEvent
R=yangguo@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#32861}
2015-12-15 11:47:51 +00:00
evan.lucas
bc2e393b4c [tools] Make gen-postmortem-metadata.py more reliable
Instead of basing matches off of whitespace, walk the inheritance chain and include any classes that inherit from Object.

R=machenbach@chromium.org,jkummerow@chromium.org
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#31964}
2015-11-12 14:48:04 +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
franziska.hinkelmann
8ed0454332 Emit better error message about writable properties
Section 8.10.5 9a specifies that a property descriptor cannot both have
accessors and specify the writability of the property. The previous
error message was misleading because it referred to writable rather
than specifying the writability (which includes writable: false).

BUG=v8:2536
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31273}
2015-10-14 19:22:27 +00:00
stefan.penner
ab9898980e Don’t smash globals used by the test helper itself.
Since https://codereview.chromium.org/366103005 the promise tests null out
various globals, to ensure the promise implementation doesn’t itself rely
on functions patchable by monkeys.

Unfortunately, doing so breaks test assertion failures which rely on
those globals.

This isn’t the ideal solution, but does improve the current state.

R=littledan@chromium.org,domenic@chromium.org
LOG=N
BUG=

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

Cr-Commit-Position: refs/heads/master@{#30922}
2015-09-24 21:47:17 +00:00
thechargingvolcano
4e05854068 Remove unused function in presubmit script
FilterFiles function is defined but unused in the code.

BUG=

R=machenbach@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#30882}
2015-09-23 10:52:45 +00:00
dusan.m.milosavljevic
49a40c2203 MIPS:[turbofan] Improve boolean materialization compares.
Additionally, improve immediate operand matching for branches
to avoid duplicated constant loading.

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

Cr-Commit-Position: refs/heads/master@{#30604}
2015-09-06 12:01:45 +00:00
karl
24d481165c Reland: Speedup stringsearch for two byte strings
Uses the lower byte with memchr which is
significantly faster than a naive compare

Performance difference with bench (http://hastebin.com/xuxexataso.js):

old                             new

single character                single character
Κ found at 922                  Κ found at 922
3324                            616
㎡ found at 13217               ㎡ found at 13217
42366                           4931
က found at 4096                 က found at 4096
13369                           9836
＀ found at 65280                ＀ found at 65280
207472                          36149
ᆬ found at 65445                ᆬ found at 65445
209344                          36666
  found at 8197                   found at 8197
26731                           11757
倂 found at 20482               倂 found at 20482
66071                           17193

linear search                   linear search
ΚΛ found at 922                 ΚΛ found at 922
4112                            504
㎡㎢ found at 13217             ㎡㎢ found at 13217
55105                           5119
ᆬᆭ found at 65445               ᆬᆭ found at 65445
268016                          35496

linear + bmh search             linear + bmh search
ΚΛΜΝΞΟΠΡ found at 922           ΚΛΜΝΞΟΠΡ found at 922
2897                            522
ᆬᆭᄃᄄᄅᆰᆱᆲ found at 65445         ᆬᆭᄃᄄᄅᆰᆱᆲ found at 65445
167687                          35283

BUG=

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

Cr-Commit-Position: refs/heads/master@{#30597}
2015-09-04 19:58:44 +00:00
machenbach
df966cd287 Revert of Speedup stringsearch for two byte strings (patchset #3 id:40001 of https://codereview.chromium.org/1303033012/ )
Reason for revert:
[Sheriff] Breaks fuzzer and msan:
http://build.chromium.org/p/client.v8/builders/V8%20Fuzzer/builds/4773

Repro with:
tools/fuzz-harness.sh out/Debug/d8
(in a ninja Debug build)

Msan:
http://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20arm64%20-%20sim%20-%20MSAN/builds/4097

Original issue's description:
> Speedup stringsearch for two byte strings
>
> Uses the lower byte with memchr which is
> significantly faster than a naive compare
>
> Performance difference with bench (http://hastebin.com/xuxexataso.js):
>
> old                             new
>
> single character                single character
> Κ found at 922                  Κ found at 922
> 3324                            616
> ㎡ found at 13217               ㎡ found at 13217
> 42366                           4931
> က found at 4096                 က found at 4096
> 13369                           9836
> ＀ found at 65280                ＀ found at 65280
> 207472                          36149
> ᆬ found at 65445                ᆬ found at 65445
> 209344                          36666
>   found at 8197                   found at 8197
> 26731                           11757
> 倂 found at 20482               倂 found at 20482
> 66071                           17193
>
> linear search                   linear search
> ΚΛ found at 922                 ΚΛ found at 922
> 4112                            504
> ㎡㎢ found at 13217             ㎡㎢ found at 13217
> 55105                           5119
> ᆬᆭ found at 65445               ᆬᆭ found at 65445
> 268016                          35496
>
> linear + bmh search             linear + bmh search
> ΚΛΜΝΞΟΠΡ found at 922           ΚΛΜΝΞΟΠΡ found at 922
> 2897                            522
> ᆬᆭᄃᄄᄅᆰᆱᆲ found at 65445         ᆬᆭᄃᄄᄅᆰᆱᆲ found at 65445
> 167687                          158465
>
> Committed: https://crrev.com/fced280f37588f8a232a414201276e053117e9ea
> Cr-Commit-Position: refs/heads/master@{#30587}

TBR=danno@chromium.org,mstarzinger@chromium.org,jkummerow@chromium.org,karl@skomski.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#30588}
2015-09-04 13:00:35 +00:00
karl
fced280f37 Speedup stringsearch for two byte strings
Uses the lower byte with memchr which is
significantly faster than a naive compare

Performance difference with bench (http://hastebin.com/xuxexataso.js):

old                             new

single character                single character
Κ found at 922                  Κ found at 922
3324                            616
㎡ found at 13217               ㎡ found at 13217
42366                           4931
က found at 4096                 က found at 4096
13369                           9836
＀ found at 65280                ＀ found at 65280
207472                          36149
ᆬ found at 65445                ᆬ found at 65445
209344                          36666
  found at 8197                   found at 8197
26731                           11757
倂 found at 20482               倂 found at 20482
66071                           17193

linear search                   linear search
ΚΛ found at 922                 ΚΛ found at 922
4112                            504
㎡㎢ found at 13217             ㎡㎢ found at 13217
55105                           5119
ᆬᆭ found at 65445               ᆬᆭ found at 65445
268016                          35496

linear + bmh search             linear + bmh search
ΚΛΜΝΞΟΠΡ found at 922           ΚΛΜΝΞΟΠΡ found at 922
2897                            522
ᆬᆭᄃᄄᄅᆰᆱᆲ found at 65445         ᆬᆭᄃᄄᄅᆰᆱᆲ found at 65445
167687                          158465

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

Cr-Commit-Position: refs/heads/master@{#30587}
2015-09-04 12:37:48 +00:00
saper
75e43a6681 Use static_cast<> for NULL (clang 3.7)
The following errors come up when compiling v8
 with clang 3.7 on FreeBSD/amd64:

src/runtime/runtime-i18n.cc:629:37: error: reinterpret_cast from
'nullptr_t' to 'v8::internal::Smi *' is not allowed
  local_object->SetInternalField(1, reinterpret_cast<Smi*>(NULL));
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

test/cctest/test-heap.cc:131:20: error: reinterpret_cast from
      'nullptr_t' to 'v8::internal::Object *' is not allowed
  Handle<Object> n(reinterpret_cast<Object*>(NULL), isolate);
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
test/cctest/test-heap.cc:1989:18: error: reinterpret_cast from
      'nullptr_t' to 'Address' (aka 'unsigned char *') is not
      allowed
  Address base = reinterpret_cast<Address>(NULL);
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+add myself to the AUTHORS file.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#30103}
2015-08-11 07:48:59 +00:00
hichris123
ddb5c2d999 Make NumberFormat use the ICU currency data, fix bug in NumberFormat
NumberFormat previously just used a min of 0 digits after the decimal and a max of 3. This CL changes it so that we use the ICU currency data, and set the min and max to the number of numbers after the decimal point for each currency.

This CL also fixes a small bug where if the minimum fraction digits is above 3 but the maximum fraction digits isn't set, then it returns with only three numbers after the decimal point.

BUG=435465,473104,304722
LOG=Y

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

Cr-Commit-Position: refs/heads/master@{#29734}
2015-07-17 15:08:08 +00:00
machenbach
d05cb6b30f Revert of Added constructor call on object in InstantiateObject method (patchset #5 id:80001 of https://codereview.chromium.org/1137693003/)
Reason for revert:
[Sheriff] This breaks layout test expectations:
http://build.chromium.org/p/client.v8.fyi/builders/V8-Blink%20Linux%2032/builds/437

See:
https://storage.googleapis.com/chromium-layout-test-archives/V8-Blink_Linux_32/437/layout-test-results/fast/dom/create-element-after-stack-overflow-pretty-diff.html

Please land a needsmanualrebaseline change on the blink-side before relanding this, if the change was intended.

Please include a blink trybot on relanding this.

Original issue's description:
> Added constructor call on object in InstantiateObject method
>
> I found after upgrading from 4.2.2 where apinatives.js still
> existed to 4.4.56 where everything had been converted to C++ in
> api-natives.cc, my constructors for ObjectTemplate instantiated objects
> were no longer being called.  After investigation, I noticed in
> apinatives.js that a new call would handle that, but there was no
> corresponding constructor call in api-natives.cc (or anywhere else
> along the chain of InstantiateObject), so I added a call to
> Execution::Call to actually construct the object.  Forgive me if that
> isn't the right place to add it (InitializeBody in objects-inl.h also
> looked like a good place), or if there's a reason constructors are
> not being called.
>
> I also added myself to the AUTHORS file in this CL.
>
> Committed: https://crrev.com/e61a957b2a9726294cdd2802a6a2b6e3a9ef657d
> Cr-Commit-Position: refs/heads/master@{#29076}

TBR=verwaest@chromium.org,svenpanne@chromium.org,dtalley@gmail.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#29085}
2015-06-17 12:20:59 +00:00
dtalley
e61a957b2a Added constructor call on object in InstantiateObject method
I found after upgrading from 4.2.2 where apinatives.js still
existed to 4.4.56 where everything had been converted to C++ in
api-natives.cc, my constructors for ObjectTemplate instantiated objects
were no longer being called.  After investigation, I noticed in
apinatives.js that a new call would handle that, but there was no
corresponding constructor call in api-natives.cc (or anywhere else
along the chain of InstantiateObject), so I added a call to
Execution::Call to actually construct the object.  Forgive me if that
isn't the right place to add it (InitializeBody in objects-inl.h also
looked like a good place), or if there's a reason constructors are
not being called.

I also added myself to the AUTHORS file in this CL.

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

Cr-Commit-Position: refs/heads/master@{#29076}
2015-06-17 10:24:10 +00:00
mike
3badfdcd50 Re-write duplicated assertions
The modified assertions targeted the property descriptor for the
template object's first "cooked" value. The code immediately preceeding
these statements asserts these values.

Update the assertions to instead target the property descriptor for the
template object's first "raw" value (which are otherwise untested).

BUG=

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

Cr-Commit-Position: refs/heads/master@{#27566}
2015-04-01 15:13:21 +00:00
johan
68d5f916d8 Fix build on solaris platforms
e8b9f2d7 introduced a different cast which broke building on Illumos.
Revert to previous behavior for V8_OS_SOLARIS only.

Found on SmartOS while building with gcc 4.9.0.

edit1: adding jochen to reviewers since he was assigned through the issue tracker and danno since he seems to do a fair amount of cross-platform work

edit2: removing BUG reference because I don't understand what LOG needs to contain (and it seems to link to chromium and not the v8 repo). Please edit commit message as appropriate.

BUG=3935
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#27163}
2015-03-12 15:12:45 +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
Yang Guo
22dd076478 Add StrongLoop, Inc. to AUTHORS.
TBR=marja@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#26509}
2015-02-09 06:56:48 +00:00
cwhan.tunz
4bf1f54282 shell.cc race condition
BUG=v8:3850
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#26375}
2015-02-02 08:08:31 +00:00
dtc-v8
531f7ab1d2 [turbofan] Better narrow the derived type for the right shift operation.
Currently the derived type of a right shift does not narrow the input
type based on the actual shift amount - well it does some narrowing
but more can be down. For patterns such as u32[i>>2], which is very
common is asm.js code, this limits the ability to later prove that an
index bounds check is unnecessary which can have a significant
performance impact.

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

Cr-Commit-Position: refs/heads/master@{#26270}
2015-01-26 14:11:36 +00:00
marja.holtta
5a1176017b Restore the sanity of AUTHORS. CLA OK.
NOTRY=true
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26100}
2015-01-16 12:01:24 +00:00
marja
0fa7d4385f Saner AUTHORS, part 2: Adding AUTHORS based on "Patch from" / "Patch by" lines.
Notes:
- All the added authors have signed the CLA.
- Updated 2 AUTHORS lines to match the e-mail addresses used for signing the CLA.
- In addition, checked that all authors in the AUTHORS file after this change
  have signed the CLA.
- Whenever it was possible to guess, based on the e-mail address, that the
  contribution was made under a corporate CLA, added the company and the
  wildcard instead of the individual.

BUG=
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#26054}
2015-01-14 13:23:47 +00:00
marja
925eded364 Saner AUTHORS, part 1: Corporate CLLAs and wildcards.
Updating AUTHORS for companies who have signed CCLA.

Changes:
- Added wildcard rules for company e-mail addresses
- Removed individual e-mail addresses for contributors who are under a corporate
  CLLA (the copyright holder in this case is the company, not the individual
  authors). Domains affected by this change: intel.com, arm.com, codeaurora.org.

In addition, added a wildcard rule for Chromium (which was not previously
listed at all).

R=danno
NOTRY=true
BUG=

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

Cr-Commit-Position: refs/heads/master@{#26039}
2015-01-13 11:58:46 +00:00
yangguo@chromium.org
d913faaf6d Improve String.repeat.
Adapted from patch contributed by Isiah Meadows <impinball@gmail.com>.

R=jkummerow@chromium.org

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

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24687 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-17 10:01:38 +00:00
dslomov@chromium.org
2fd8a7f6b8 Convert obj ToObject in Object.keys()
BUG=v8:3587
LOG=Y
R=arv@chromium.org, dslomov@chromium.org

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

Patch from Caitlin Potter <caitpotter88@gmail.com>.

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24495 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-09 13:19:02 +00:00
paul.lind@imgtec.com
eb3e3ce240 Update AUTHORS file.
BUG=
R=danno@chromium.org

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

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24294 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-09-29 16:51:54 +00:00
dslomov@chromium.org
ef14bcfebe Revert "Convert obj ToObject in Object.keys()"
This reverts commit r24260 for breaking test262 tests.

TBR=arv@chromium.org

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

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24264 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-09-29 07:30:41 +00:00
dslomov@chromium.org
4e116f383b Convert obj ToObject in Object.keys()
BUG=v8:3587
LOG=Y
R=arv@chromium.org, dslomov@chromium.org

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

Patch from Caitlin Potter <caitpotter88@gmail.com>.

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24260 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-09-29 07:07:16 +00:00
yangguo@chromium.org
327d843d59 fix and update debug-debugger.js
added `switch` statement is missing `break`s

R=yangguo@chromium.org

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

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@23441 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-08-27 09:51:51 +00:00
danno@chromium.org
9c485e182b Introduce x87 port
Support x87-only platform (ia32 without SSE)

R=danno@chromium.org

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

Patch from Weiliang Lin <weiliang.lin@intel.com>.

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21469 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-05-23 16:37:27 +00:00
jacob.bramley@arm.com
558de62ff0 Add ARM contributors to AUTHORS.
BUG=
R=ulan@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19315 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-02-12 11:54:34 +00:00
bmeurer@chromium.org
c050e2c715 Add Opera Software ASA to AUTHORS
Contributed by Mathias Bynens <mathiasb@opera.com>.

BUG=
LOG=N
R=bmeurer@chromium.org, jarin@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18976 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-01-31 09:18:43 +00:00
bmeurer@chromium.org
0899da3697 Add support for the QNX operating system.
This patch contains contributions from the following members of the
BlackBerry Web Technologies team:

Eli Fidler <efidler@blackberry.com>
Konrad Piascik <kpiascik@blackberry.com>
Jeff Rogers <jrogers@blackberry.com>
Cosmin Truta <ctruta@blackberry.com>
Peter Wang <peter.wang@torchmobile.com.cn>
Xiaobo Wang <xiaobwang@blackberry.com>
Ming Xie <mxie@blackberry.com>
Leo Yang <leoyang@blackberry.com>

R=bmeurer@chromium.org, jkummerow@chromium.org

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

Patch from Cosmin Truta <ctruta@blackberry.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18430 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-01-02 07:04:05 +00:00
bmeurer@chromium.org
a4c072ed47 Fix a crash when generating forward jumps to labels at very high assembly offsets
The first jump to a specific label was marked as jump to absolute
position -4. This value was stored in the assembly as a branch to a
offset (-4 - (instruction offset + 8)). The offset is only 24 bit
long on ARM. Thus instruction offsets higher than 2^23 - 12 would overflow
the offset.

Fix by denoting the first jump to a label by storing the jump
instruction location as the target. This will result in offset of -8,
which of course always fits in the branch instruction.

BUG=2736
TEST=cctest/test-assembler-arm/17
R=bmeurer@chromium.org, svenpanne@chromium.org

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

Patch from Kimmo Kinnunen <kkinnunen@nvidia.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15997 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-08-01 08:13:08 +00:00
yangguo@chromium.org
4d1362720f Add methods to allow resuming execution after calling TerminateExecution().
R=mvstanton@chromium.org
BUG=v8:2361

Review URL: https://chromiumcodereview.appspot.com/14401008

Patch from Andrew Paprocki <andrew@ishiboo.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14378 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-04-22 15:01:45 +00:00
danno@chromium.org
ed3809c318 Maintain API compatibility with older versions of V8.
Revert "Allow recording individual samples in addition to the aggregated CPU profiles"
Revert "Isolatify CPU profiler"
Revert "Isolatify HeapProfiler"
Revert "Deprecate HeapSnapshot type"
Revert "Isolatify CPU profiler public API"
Revert "MSVS compilation fix after r14006"
Revert "Add methods to allow resuming execution after calling TerminateExecution()."

R=jkummerow@chromium.org,mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14031 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-03-21 14:42:17 +00:00
yangguo@chromium.org
53adf3b19c Add methods to allow resuming execution after calling TerminateExecution().
Two new methods are added to allow embedders to determine that execution
should be resumed at a particular point in the stack without being forced
to unwind all JS frames.

* V8::CancelTerminateExecution() -- When execution is terminated via a call
  to V8::TerminateExecution(), this method can be called to clear the
  termination exception so that the engine can continue to be used.

* TryCatch::HasTerminated() -- When a TryCatch has caught a termination
  exception, HasTerminated() will return true to indicate it is valid to
  call V8::ResumeExecution() if desired.

A test case is added to cctest/test-thread-termination.cc.

BUG=v8:2361

Patch from Andrew Paprocki <andrew@ishiboo.com>.

Review URL: https://chromiumcodereview.appspot.com/11142013
Patch from Andrew Paprocki <andrew@ishiboo.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14022 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-03-21 10:47:34 +00:00
yangguo@chromium.org
a50259f75c Add Makefile options to build for the Raspberry Pi (armv7=0, arm_fpu=vfp2).
With these Makefile changes, it is possible to build V8 on the Raspberry Pi with the following make invocation:

make native armv7=false vfp3=off hardfp=on disassembler=on console=readline snapshot=on gdbjit=on strictaliasing=off

R=danno@chromium.org
BUG=

Review URL: https://chromiumcodereview.appspot.com/11722003
Patch from Luis Reis <luis.m.reis@gmail.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13297 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-01-03 08:56:05 +00:00
yangguo@chromium.org
e24b98312b Revert r13218 due to windows test failures.
R=verwaest@chromium.org
BUG=

Review URL: https://chromiumcodereview.appspot.com/11568014

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13219 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-12-13 17:21:15 +00:00
yangguo@chromium.org
4cd41edcd9 Add methods to allow resuming execution after calling TerminateExecution().
Two new methods are added to allow embedders to determine that execution
should be resumed at a particular point in the stack without being forced
to unwind all JS frames.

* V8::ResumeExecution() -- When execution is terminated via a call to
  V8::TerminateExecution(), this method can be called to clear the
  termination exception so that the engine can continue to be used.

* TryCatch::HasTerminated() -- When a TryCatch has caught a termination
  exception, HasTerminated() will return true to indicate it is valid to
  call V8::ResumeExecution() if desired.

A test case is added to cctest/test-thread-termination.cc.

BUG=v8:2361

Patch from Andrew Paprocki <andrew@ishiboo.com>.

Review URL: https://chromiumcodereview.appspot.com/11142013
Patch from Andrew Paprocki <andrew@ishiboo.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13218 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-12-13 16:38:49 +00:00
danno@chromium.org
e96d49047b Remove redundant jump to deoptimization (the jump already exists in DoCheckMapCommon)
BUG=none
TEST=none

Review URL: https://codereview.chromium.org/11265044
Patch from Rajeev Krithivasan <rkrithiv@codeaurora.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12828 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-10-29 11:45:40 +00:00
mstarzinger@chromium.org
e119459af2 Set kChangesNewSpacePromotion for HStringAdd
TEST=none
BUG=none

Review URL: https://codereview.chromium.org/11143006
Patch from Derek J Conrod <dconrod@codeaurora.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12822 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-10-25 15:23:39 +00:00
ulan@chromium.org
cb7645b43b Enable shared library on android
This change fixed link errors in building shared library
for android. crtbegin_so.o is added to resolve dso_handle
and exclude-libs option is removed for shared library.

Review URL: https://chromiumcodereview.appspot.com/11262003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12806 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-10-24 12:11:15 +00:00
mikhail.naganov@gmail.com
1e5cf45e3a Fix path to d8 and properly quote strings so it works with dash(1)
Patch by Sandro Santilli <strk@keybit.net>

Review URL: https://chromiumcodereview.appspot.com/10825032

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12200 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-07-26 10:03:30 +00:00
yangguo@chromium.org
4d1d1eb53e Fix building with GCC 3.x
R=yangguo@chromium.org
BUG=v8:2016, v8:2017
TEST=

Review URL: https://chromiumcodereview.appspot.com/10823034
Patch from James Pike <g00gle@chilon.net>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12199 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-07-26 09:18:09 +00:00
jkummerow@chromium.org
ada84adaac Make android.check work
Review URL: https://chromiumcodereview.appspot.com/10779011
Patch from Haitao Feng <haitao.feng@intel.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12101 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-07-16 16:22:28 +00:00
jkummerow@chromium.org
da5b44cbd1 Add support for Mac OS X 64bit builds with GYP
Note that in order to build for 64bits mode, you'll have
to specify the target architecture explicitely, the default
is still 32bits for Mac OS X.

Example with make and gcc:

$ export GYP_GENERATORS=make
$ make dependencies
$ make -j 8 library=shared x64.release

Example with make and clang:

$ export GYP_GENERATORS=make
$ export CC=/usr/bin/clang
$ export CXX=/usr/bin/clang++
$ export GYP_DEFINES="clang=1"
$ make dependencies
$ make -j 8 library=shared x64.release

Example with xcode:

$ export GYP_GENERATORS=xcode
$ build/gyp_v8 -Dtarget_arch=x64
$ xcodebuild -project build/all.xcodeproj -configuration Release

Contributed by Filipe David Manana <fdmanana@gmail.com>

BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com/9808065

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11199 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-03-30 15:01:11 +00:00
vegorov@chromium.org
de9120500a Add Zhongping Wang <kewpie.w.zp@gmail.com> to AUTHORS
Fix compilation failure on Win x64 builder introduced by r11084

R=jkummerow@chromium.org

Review URL: https://chromiumcodereview.appspot.com/9748004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11090 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-03-20 08:12:31 +00:00
lrn@chromium.org
5468fbb19e Allow the ZWJ and ZWNJ characters in IdentifierPart as per ES5.
Patch from Mathias Bynens <mathias@qiwi.be>
BUG=1958
TEST=Try `var a\u200c\u200d;` and confirm it doesn't throw an error.

Review URL: https://chromiumcodereview.appspot.com/9433031
Patch from Mathias Bynens <mathias@qiwi.be>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10800 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-02-23 08:15:45 +00:00
yangguo@chromium.org
0f348c9208 Fix compilation with MinGW-w64.
BUG=v8:1943
TEST=

Review URL: https://chromiumcodereview.appspot.com/9428027
Patch from Jonathan Liu <net147@gmail.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10793 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-02-22 12:26:36 +00:00
rossberg@chromium.org
63debf7d0e Add Ioseb Dzmanashvili to authors.
R=vegorov@google.com,yangguo@chromium.org
BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com/9430011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10789 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-02-22 11:35:17 +00:00
vegorov@chromium.org
a297d3f9af Optionally export metadata with libv8 to enable debuggers to inspect V8 state.
Review URL: https://chromiumcodereview.appspot.com/8803024
Patch from David Pacheco <dap@joyent.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10596 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-02-02 20:18:19 +00:00
vegorov@chromium.org
a2159a6bb9 Fix GCC 4.7 warnings, which are related to char being signed in GCC
("narrowing conversion ... inside { } is ill-formed in C++11").

* src/mksnapshot.cc: Cast "char" to "unsigned char" when outputting snapshot.
* test/cctest/test-regexp.cc: Use static_cast to uc16 as the char
literal is signed.

Review URL: http://codereview.chromium.org/8825003
Patch from Tobias Burnus <burnus@net-b.de>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10241 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-12-13 13:02:08 +00:00
yangguo@chromium.org
9ca9cdfbf6 Debugger: fix stepping next with trycatch recursion
Added depth check to StepNextContinue. Do step out and queue actual StepNext if check failed.

R=yangguo@chromium.org,danno@chromium.org,vegorov@chromium.org
BUG=v8:1639
TEST=

Review URL: http://codereview.chromium.org/7780033
Patch from Fedor Indutny <fedor@indutny.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9264 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 14:38:39 +00:00
ager@chromium.org
75bebf3db8 Fixes the build for the shell on illumos and Solaris. -D__C99FEATURES__ was added to mirror how the build is done on the normal platform. The changes in the platform code are a follow up to a prior review and has the Solaris implementation be more similar to the Linux version as opposed to the FreeBSD.
Contributed by Robert Mustacchi <rm@fingolfin.org>

TEST=Note the test suite uncovered a bug in libm where pow(3M) was not doing the right thing on edge cases. The only test failures are related to this bug.

Review URL: http://codereview.chromium.org/7282034

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8502 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-01 05:50:14 +00:00
ager@chromium.org
3f6043d370 Cleanup to HEnvironment::CopyForInlining
* src/hydrogen.cc (HEnvironment::CopyForInlining): As the code for both
  the ::HYDROGEN and ::LITHIUM compilation phases is the same, just use
  one code path and remove the arg.

* src/hydrogen.h (HEnvironment): Remove now-unused CompilationPhase
  enum type and arg to CopyForInlining.

* src/arm/lithium-arm.cc (LChunkBuilder::DoEnterInlined):
* src/ia32/lithium-ia32.cc (LChunkBuilder::DoEnterInlined):
* src/x64/lithium-x64.cc (LChunkBuilder::DoEnterInlined): Adapt
  callers.

* AUTHORS: Add Igalia.

BUG=
TEST=I ran tools/test.py.

Review URL: http://codereview.chromium.org/7272002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8442 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-28 08:54:09 +00:00
vitalyr@chromium.org
b6f9db93ef AUTHORS: add Akinori MUSHA <knu@FreeBSD.org>.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7812 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-08 14:55:57 +00:00
sgjesse@chromium.org
37f33a7087 Improve modulo operation in lithium on IA32.
Implement fast paths for the special cases like PowerOfTwo divisors
and the dividend being smaller than the divisor (non-negative).

BUG=v8:1314

Review URL: http://codereview.chromium.org//6816049

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7704 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-28 14:58:45 +00:00
ager@chromium.org
d5359e338a Cleanup of FACTORY macro usage in api.cc.
BUG=
TEST=

Review URL: http://codereview.chromium.org/6725014
Patch from Peter Varga <pvarga@inf.u-szeged.hu>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7314 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-03-23 09:02:15 +00:00
vitalyr@chromium.org
7976ca2cbc Merge isolates to bleeding_edge.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7271 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-03-18 20:35:07 +00:00
vitalyr@chromium.org
76e226f832 Revert r7268: it borked the history.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7269 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-03-18 19:41:05 +00:00
vitalyr@chromium.org
6ff7fdebd3 Merge isolates to bleeding_edge.
Review URL: http://codereview.chromium.org/6685088

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7268 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-03-18 18:49:56 +00:00
vegorov@chromium.org
a2c9ca7464 Speedup decodeURI/decodeURIComponent by switching from charAt(i) to charCodeAt(i) in Decode.
Original patch by Alexander Karpinsky.

Review URL: http://codereview.chromium.org/6440001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6676 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-02-08 13:01:34 +00:00
antonm@chromium.org
aecb05354b Landing for Zaheer Ahmad.
Direct call api functions (arm implementation)

See: http://codereview.chromium.org/6170001/

Review URL: http://codereview.chromium.org/6286078

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6639 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-02-04 13:43:38 +00:00
vegorov@chromium.org
09b3041a57 GDBJIT: emit .eh_frame section on x64.
This enables proper stack unwinding on x64.

Currently this requires V8 to be compiled without snapshot and --gdbjit-full to be enabled.

Original patch by Sanjoy Das (http://codereview.chromium.org/6371011/)

Review URL: http://codereview.chromium.org/6250104

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6575 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-02-02 13:32:18 +00:00
sgjesse@chromium.org
d01a45b2b1 Prepend the tools directory to python module path
This works around possible collisions with modules installed in the system 
python directories. 

See Gentoo Linux bug report: 
http://bugs.gentoo.org/349794

Patch by Mike Gilbert <floppymaster@gmail.com>

Review URL: http://codereview.chromium.org/6253009


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6463 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-01-25 12:56:04 +00:00
sgjesse@chromium.org
fdca2c3183 nGW build
- add missing functions SignalCodeMovingGC() and MemoryBarrier() 
- avoid pointer conversion/comparison warnings 
- don't attempt to hide symbols with -fvisibility, MinGW doesn't support it 

BUG=http://code.google.com/p/v8/issues/detail?id=949

Patch by Bert Belder <bertbelder@gmail.com>

Review URL: http://codereview.chromium.org/5471001


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5913 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-12-02 15:37:45 +00:00
sgjesse@chromium.org
0c064efdb0 Make randomized allocations along 64k granularity boundaries to avoid comitting unused memory.
BUG=56036
TEST=None.

Patch by Justin Schuh <jschuh@chromium.org>

Review URL: http://codereview.chromium.org/3849004



git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5883 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-11-24 09:40:58 +00:00
erik.corry@gmail.com
8ebe8e4756 ARM: The Simulator will now handle different VFP rounding modes. RZ and RM are implemented. This is a commit of
http://codereview.chromium.org/4295003/show for Alexander Rames of ARM.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5790 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-11-09 08:26:02 +00:00
sgjesse@chromium.org
8e72ab6db9 Added USE_SIMULATOR macro that explicitly indicates that we wish to use the simulator as the execution engine. For example, this allows us to run with the ARM simulator on ARM.
Patch by Mark Lam <mark.lam@palm.com> from Hewlett-Packard Development Company, LP

Review URL: http://codereview.chromium.org/3825001


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5620 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-14 11:39:48 +00:00
erik.corry@gmail.com
62ec3292de Replace 2 ARM ldr instructions with one ldrd in the code generated
for a SubStringStub and StringCompareStub in the ARM backend.  This
is a commit of http://codereview.chromium.org/3341012 for Andreas
Anyuru.
Review URL: http://codereview.chromium.org/3387003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5457 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-09-15 10:22:55 +00:00
ricow@chromium.org
997421b755 Cosmetic change, list author names in AUTHORS alphabetically.
Review URL: http://codereview.chromium.org/3311025

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5438 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-09-10 08:12:34 +00:00
lrn@chromium.org
b6f047229c Added Michael Smith to Authors file (author of revision 5436).
Review URL: http://codereview.chromium.org/3327013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5437 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-09-10 07:08:03 +00:00
antonm@chromium.org
59645c6a19 Add v8::Value::IsRegExp method.
Patch by Vlad Burlik.

Review URL: http://codereview.chromium.org/3064051

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5227 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-08-10 09:53:56 +00:00
sgjesse@chromium.org
a1a3aa46a2 Object.seal(obj) and Object.freeze(obj) should return the input obj.
BUG=http://code.google.com/p/v8/issues/detail?id=809
TEST=Seal/freeze an object and check if Object.seal and Object.freeze returns the given object.

Burcu Dogan <burcujdogan@gmail.com>

Review URL: http://codereview.chromium.org/3056049


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5176 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-08-05 10:56:15 +00:00
erik.corry@gmail.com
d5738c0e6d Add ldrd and strd instructions to the ARM port. This is a
commit for zhangk@codeaurora.org.  See
http://codereview.chromium.org/568029 and
http://codereview.chromium.org/2019003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4618 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-05-07 20:02:57 +00:00
erik.corry@gmail.com
e2d3e3802e Update AUTHORS file to reflect previous commit
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4478 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-04-22 17:28:43 +00:00
ager@chromium.org
fc382f0ffa Revert pax change as it does not work with older versions of scons.
Review URL: http://codereview.chromium.org/661071

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3946 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-02-25 08:27:07 +00:00
ager@chromium.org
be1ea81cbf Land change to allow building on Gentoo Hardened Linux.
Codereview URL: http://codereview.chromium.org/659002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3940 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-02-24 18:50:56 +00:00
mikhail.naganov@gmail.com
4f7b9e4da3 Report code stubs to OProfile.
Patch from Dineel D Sule <dsule@codeaurora.org>.
Original issue: http://codereview.chromium.org/600019

TBR=sgjesse@chromium.org

Review URL: http://codereview.chromium.org/593038

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3831 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-02-10 17:50:16 +00:00
sgjesse@chromium.org
a6a7c75ae0 MIPS port initial commit
This is the first step in the MIPS port of V8. It adds assembler, disassembler and simulator for the MIPS32 architecture.

Contains stubbed out implementation of all the compiler/code generator infrastructure to make it all build.

Patch by Alexandre Rames from Sigma Designs Inc.

This is the landing of http://codereview.chromium.org/543161.
Review URL: http://codereview.chromium.org/561072

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3799 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-02-04 20:36:58 +00:00
ager@chromium.org
cd51fcd35f Land patch to add Solaris platform support.
Patch by Erich Ocean and Ryan Dahl.

Review URL: http://codereview.chromium.org/545125

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3688 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-25 12:37:31 +00:00
erik.corry@gmail.com
593c388b39 Fix for bug 512 from Subrato De, CodeAurora.
Review URL: http://codereview.chromium.org/464016

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3435 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-12-09 11:14:45 +00:00
erik.corry@gmail.com
0d94d7c785 Add vfp support on ARM. Patch from John Jozwiak.
Review URL: http://codereview.chromium.org/348019

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3292 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-11-12 13:04:02 +00:00
ager@chromium.org
576ae4c115 Land change by Jan de Mooij to change the toString behavior of
|function|.toString() for builtin functions.

Review URL: http://codereview.chromium.org/209014

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2913 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-09-17 11:11:01 +00:00
christian.plesner.hansen@gmail.com
6a323d3afe Const Correctness for String::Value
Patch by Patrick Gansterer <paroga@paroga.com>.
Review at http://codereview.chromium.org/199043.


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2831 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-09-07 07:54:51 +00:00
whesse@chromium.org
8ad2edb6b5 Clarify precedence of operations involving bitwise and(&) in x64/assembler.
Review URL: http://codereview.chromium.org/131099

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2223 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-06-19 09:12:20 +00:00
erik.corry@gmail.com
f04220d25a Fix compilation on FreeBSD. Thanks to Ryan Dahl for patch.
http://codereview.chromium.org/113897


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2117 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-06-08 08:51:35 +00:00
erik.corry@gmail.com
73e6d30b05 Add Joel Stanley to AUTHORS. Also sort the list so it is easier to see
whether people are already in it.
Review URL: http://codereview.chromium.org/113834

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2053 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-05-26 08:49:07 +00:00
ager@chromium.org
0582ee5da5 Land patch from Craig Schlenter to make V8 build and run when compiled
with -O3 on gcc 4.4.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2026 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-05-22 06:52:02 +00:00
sgjesse@chromium.org
6ace05ed2a Issue 63: Running tests fails of there is a dot in the checkout path
Patch by Matt Hanselman (http://codereview.chromium.org/27086). Pass in the module's filename while loading rather than the full path (so call to load_module now matches find_module).  Otherwise dots in path name get mistaken for file suffixes.

Added Matt Hanselman to AUTHORS file.

BUG=63
Review URL: http://codereview.chromium.org/28109

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1356 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-02-25 10:09:42 +00:00
ager@chromium.org
41a5c9212e Apply patch from Alexander Botero-Lowry that adds FreeBSD platform
support.
Review URL: http://codereview.chromium.org/11347

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@815 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2008-11-21 10:06:29 +00:00
kasperl@chromium.org
b75da76a2b Apply Daniel's patch for array index strings.
Review URL: http://codereview.chromium.org/7869

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@560 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2008-10-23 06:20:57 +00:00
ager@chromium.org
c1ec605496 Adding Paolo Giarrusso to AUTHORS file for his hash code patch.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@450 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2008-10-07 07:26:06 +00:00
kasperl@chromium.org
c275d66c39 Capitalize V8 in AUTHORS file.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@196 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2008-09-08 08:09:50 +00:00
kasperl@chromium.org
2f0c910731 Fix issue 35 by applying patch by Daniel James.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@195 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2008-09-08 07:58:54 +00:00
kasperl@chromium.org
57fcbc370c Add I-cache flushing to Code::Relocate. No need to call it
from Heap::CopyCode anymore.


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@161 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2008-09-05 11:23:00 +00:00
ager@chromium.org
85a8532af2 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@159 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 2008-09-05 10:20:14 +00:00
ager@chromium.org
1dba6feed0 Applied Rafal Krypa's patch to fix gcc 4.3.2 build problems.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@149 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2008-09-05 07:46:32 +00:00