Commit Graph

67 Commits

Author SHA1 Message Date
jochen@chromium.org
ae2709f800 Fix an implicit cast from int64 to double in the i18n extension
On MSVS, this throws an error

BUG=v8:2745
R=jkummerow@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15557 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-07-08 15:22:12 +00:00
yangguo@chromium.org
02674ee414 Keep two empty lines between declarations for cpp files
R=yangguo@chromium.org

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

Patch from Haitao Feng <haitao.feng@intel.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15510 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-07-05 09:52:11 +00:00
jkummerow@chromium.org
84833a59ba Mark i18n functions as native and set proper names
BUG=v8:2745
R=jkummerow@chromium.org

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

Patch from Jochen Eisinger <jochen@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15478 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-07-03 15:30:27 +00:00
jkummerow@chromium.org
56ab3e3404 Import the v8-i18n extension into v8
This adds the gyp flag v8_enable_i18n_support (off by default), and the
v8 flag FLAG_enable_i18n (on by default, but without effect if
v8_enable_i18n_support is off).

BUG=v8:2745
R=cira@chromium.org, danno@chromium.org, jkummerow@chromium.org

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

Patch from Jochen Eisinger <jochen@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15464 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-07-03 11:22:29 +00:00
danno@chromium.org
1b89cbf817 Separate Cell and PropertyCell spaces
This makes it possible to store additional information on property cells, for example Type and optimized Code dependencies.

R=mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15089 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-06-12 15:03:44 +00:00
dcarney@chromium.org
33dabf08f9 Cutover v8 to use new style callbacks internally
R=svenpanne@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14952 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-06-05 12:36:33 +00:00
dcarney@chromium.org
b774c3edfe stop using AsciiValue
TBR=svenpanne@chomium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14645 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-05-13 14:18:05 +00:00
mstarzinger@chromium.org
3d84765fc2 Expose the GC under a name that is less collision prone than window.gc.
This also keeps backwards compatibility (window.gc() still works).

BUG=2641

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

Patch from Marja Hölttä <marja@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14397 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-04-23 16:30:51 +00:00
rossberg@chromium.org
55f93b5532 Renamed "symbols" to "internalized strings" throughout the code base,
in preparation of the introduction of ES6 'symbols' (aka private/unique names).

The SymbolTable became the StringTable. I also made sure to adapt all comments. The only remaining use of the term "symbol" (other than unrelated uses in the parser and such) is now 'NewSymbol' in the API and the 'V8.KeyedLoadGenericSymbol' counter, changing which might break embedders.

The one functional change in this CL is that I removed the former 'empty_string' constant, since it is redundant given the 'empty_symbol' constant that we also had (and both were used inconsistently).

R=yangguo@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13781 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-02-28 17:03:34 +00:00
yangguo@chromium.org
e41c17084f Continues Latin-1 support. All tests pass with ENABLE_LATIN_1 flag.
R=yangguo@chromium.org
BUG=

Review URL: https://chromiumcodereview.appspot.com/11818025
Patch from Dan Carney <dcarney@google.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13344 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-01-09 15:47:53 +00:00
mstarzinger@chromium.org
ff5e63761e Revert "Allow incremental marking when expose_gc is turned on."
This reverts r13072 from bleeding edge.

R=hpayer@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13099 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-11-30 09:42:20 +00:00
hpayer@chromium.org
c772d649cf Allow incremental marking when expose_gc is turned on.
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13072 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-11-28 08:43:10 +00:00
yangguo@chromium.org
36f5b6d41f Rename IsAsciiRepresentation
This is a straight rename:

IsAsciiRepresentation -> IsOneByteRepresentation
IsAsciiRepresentationUnderneath -> IsOneByteRepresentationUnderneath
AllocateRawAsciiString -> AllocateRawOneByteString
AllocateStringFromAscii -> AllocateStringFromOneByte

R=yangguo@chromium.org,
BUG=

Review URL: https://chromiumcodereview.appspot.com/11308066
Patch from Dan Carney <dcarney@google.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13023 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-11-21 10:01:05 +00:00
mstarzinger@chromium.org
ebb44f0d30 Expose gc(true) to JavaScript, which triggers a scavenger GC.
With the --expose_gc option, gc() is exposed to JavaScript. Currently gc() triggers a full GC.

To enable JavaScript to test the behavior of a scavenger GC, this patch exposes gc(true). If the first argument is true, gc(...) triggers a scavenger GC. Otherwise, gc(...) triggers a full GC.

BUG=
Test=Manually confirmed that gc() and gc(false) trigger a full GC and that gc(true) triggers a scavenger GC.

Review URL: https://codereview.chromium.org/11232065
Patch from Kentaro Hara <haraken@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12815 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-10-25 12:23:03 +00:00
ulan@chromium.org
92fd1eb347 Fix Win64 compile error caused by r12272.
R=mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12276 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-08-08 09:46:45 +00:00
ulan@chromium.org
a270eeef2d Add heap space sizes and external memory counter to V8 statistics extension.
R=yangguo@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12272 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-08-08 07:37:07 +00:00
yangguo@chromium.org
0a0b4f4f2f Fix crash bug when calling getV8Statistics().
BUG=v8:2270

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12255 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-08-03 14:03:30 +00:00
danno@chromium.org
0fb5189a32 Refine object stats for FixedArrays.
R=yangguo@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12165 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-07-20 14:06:24 +00:00
yangguo@chromium.org
ca2b0e366b Expose counters in javascript.
R=rossberg
BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12124 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-07-18 12:27:29 +00:00
svenpanne@chromium.org
7c7c2801f5 Valgrind cleanliness, part 5: Delete extensions on exit.
This fixes 4 leaks, returning 196 bytes of lost memory.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11184 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-03-29 09:45:46 +00:00
vegorov@chromium.org
a7b0481b6d Tweak compaction candidate selection to avoid keeping page with low occupancy around.
Increase slots buffer chain length to 15 to make compaction more aggressive and usefull.

Pass gc and collector selection reasons to GCTracer to allow more meaningull --gc-trace.

Print fragmentation of spaces that we do not compact.

R=erik.corry@gmail.com

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10601 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-02-03 14:16:40 +00:00
yangguo@chromium.org
504fff1118 Cleaning up after r10471.
Review URL: https://chromiumcodereview.appspot.com/9193007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10472 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-01-23 08:39:49 +00:00
yangguo@chromium.org
bc091f31c8 Removing experimental i18n code from v8 repository. Internationalization support is hosted under code.google.com/p/v8-i18n for couple months now.
TEST=Chromium/WebKit builds should pass.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10471 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-01-23 08:09:22 +00:00
yangguo@chromium.org
5c23e4e57a Avoid explicitly using built-in new operator where possible to appease Windows build.
Review URL: http://codereview.chromium.org/8561011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10028 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-11-18 11:08:46 +00:00
yangguo@chromium.org
6551e8d47d Removing exit time destructors by leaking static members.
Note that some cctests and d8 still contain statical members with exit time destructors.

BUG=v8:1828

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10025 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-11-18 08:59:33 +00:00
yangguo@chromium.org
d7f3985e33 Rolling back r9662.
Review URL: http://codereview.chromium.org/8321001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9665 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-17 13:39:56 +00:00
yangguo@chromium.org
d2434953e2 Changes around ascii-check for strings wrt external strings.
Review URL: http://codereview.chromium.org/8312015

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9662 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-17 12:49:34 +00:00
vegorov@chromium.org
ac36cb4504 Merge experimental/gc branch to the bleeding_edge.
Review URL: http://codereview.chromium.org/7945009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9328 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-19 18:36:47 +00:00
mikhail.naganov@gmail.com
5105a20dd7 Make a static non-POD object a static raw pointer instead.
Change it to a plain static pointer and initialize lazy.

BUG=83856
TEST=None

R=ager@chromium.org,mnaganov@chromium.org

Signed-off-by: Thiago Farina <tfarina@chromium.org>

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9120 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-02 16:46:35 +00:00
cira@chromium.org
24e6d48d9b Return error not null for date time format.
BUG=v8:1602
TEST=new (new v8Locale().createDateTimeFormat()).getWeekdays should return Error not a Null.
Review URL: http://codereview.chromium.org/7647027

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8935 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-15 22:29:03 +00:00
cira@chromium.org
d0ee5982a8 ICU 4.6 NumberFormat::EStyle enum is gone in ICU 4.8. Adding #if #else to make it work across versions.
There was an ICU cleanup (removing all C++ style enums and replacing them with plain C enums). NumberFormat::EStyle had a draft status (from ICU 4.2) and it was cut. Confusion came up because DateFormat::EStyle is stable and won't be removed.

TEST=Compile Chromium with ICU 4.6 and ICU 4.8
BUG=1561
Review URL: http://codereview.chromium.org/7421003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8701 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-20 17:46:56 +00:00
cira@chromium.org
ab2c0d4503 Change timeType and dateType in i18n date format API into timeStyle and dateStyle to match the proposal.
I've kept old keys too, until ChromeOS user switches to time/dateStyle.

Fixed regex for matching styles in date and number format.

TEST=i18n.kaziprst.org/datetimeformat.html should show proper results for both timeType and timeStyle.
Review URL: http://codereview.chromium.org/7244008

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8423 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-24 16:58:28 +00:00
cira@chromium.org
2b77b78446 Adding support for number formating to the JS i18n API.
This is the last part of the API that belongs in public spec.

Methods supported:
- format
- derive

Options supported:
- style (decimal, scientific, currency and percent)
- pattern
- skeleton

TEST= Visit i18n.kaziprst.org/numberformat.html
Review URL: http://codereview.chromium.org/7129051

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8379 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-22 18:55:06 +00:00
whesse@chromium.org
61510da25a Restore accidentally deleted src/extensions/experimental/i18n.js
Review URL: http://codereview.chromium.org/7205030

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8335 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-20 14:14:33 +00:00
karlklose@chromium.org
f4e4bc43a8 Merge arguments branch to bleeding edge (second try).
Review URL: http://codereview.chromium.org/7187007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8315 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-16 14:12:58 +00:00
karlklose@chromium.org
cc19d1e278 Revert "Merge arguments branch to bleeding merge."
This reverts commit ceb31498b9d69edca3260820fb4047045891ce6d.

TBR=kmillikin@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8308 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-16 06:37:49 +00:00
karlklose@chromium.org
6cfeb2d400 Merge arguments branch to bleeding merge.
Review URL: http://codereview.chromium.org/7167006

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8300 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-15 15:09:28 +00:00
cira@chromium.org
a60085b28a Re-landing http://codereview.chromium.org/7014019.
Adding DateTimeFormat class to i18n API with following methods:

- format
- getWeekdays
- getMonths
- get Eras
- getAmPm

Difference from the reverted revision:

Removed all references to v8/src, like ASSERT_EQ.

All #includes have full path to include/v8.h or extension headers.

TEST=Visit i18n.kaziprst.org/datetimeformat.html
Review URL: http://codereview.chromium.org/7105002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8151 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-01 21:10:56 +00:00
cira@chromium.org
ab00b00a87 Removed all references to v8/src from i18n extension code.
Removed I18N enum from v8/src/natives.h

Removed use of Vector and natives.h from i18n-extension.cc. Added new
python script that generates i18n-js.cc from i18n.js.

Made all paths absolute pointing to either v8/include or
v8/src/extensions/experimental.

Exported -Iv8 for embedders (-Iv8/include was there already).
Review URL: http://codereview.chromium.org/7077012

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8127 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-31 17:21:28 +00:00
cira@chromium.org
46c7ddd9a8 Landing http://codereview.chromium.org/7033038 for jshin.
Make 'ignoreCase' work in collator. 

BUG=28604
TEST=http://www.i18nl10n.com/chrome/coll.html
Review URL: http://codereview.chromium.org/7008023

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8066 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-25 22:18:41 +00:00
ager@chromium.org
5765e8a9c0 Experimental i18n extension breaks shared library build. Revert recent
changes to unblock V8 release.

Revert "Adding DateTimeFormat class to i18n API with following methods:"

Revert "Some internal methods are requested when v8 is built as DLL (V8_SHARED), and"

R=sgjesse@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7981 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-23 08:35:46 +00:00
ager@chromium.org
fe6bdabc07 Some internal methods are requested when v8 is built as DLL (V8_SHARED), and
they are not available.
Make them no-op (or better yet part of public API).

TEST = Build Chromium with V8_SHARED

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7973 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-23 06:14:32 +00:00
cira@chromium.org
11cc4dcfc6 Adding DateTimeFormat class to i18n API with following methods:
- format
- getWeekdays
- getMonths
- get Eras
- getAmPm

TEST=Visit i18n.kaziprst.org/datetimeformat.html
Review URL: http://codereview.chromium.org/7014019

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7967 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-19 21:12:47 +00:00
cira@chromium.org
9695ce9f37 Trying to re-land http://codereview.chromium.org/6901141.
Changes from previus revision:
- Made my own strncpy in I18NUtils class (we can't use OS::SNPrintF nor snprintf).
- Fixed a crashing bug related to ICU call in LanguageMatcher::BCP47ToICUFormat.

TEST=Visit i18n.kaziprst.org/locale.html
Review URL: http://codereview.chromium.org/6928017

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7796 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-05 17:18:22 +00:00
sgjesse@chromium.org
dfed2ce8a3 Revert r7768
This broke the Chromium Windows shared build.

BUG=none
TEST=Windows shared build works when pushed to Chromium
Review URL: http://codereview.chromium.org/6932007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7777 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-04 11:12:06 +00:00
cira@chromium.org
5a9fa7a8c6 Change v8Locale to match proposal - constructor is different (takes settings object, not a plain string) and I've added derive method to it.
Added comments to i18n.js methods and properties, and util functions to check settings and locale validity.

Added LanguageMatcher class until ICU gets C implementation (in progress, but late for our current deadline). I added TODO to remove LanguageMatcher code. 

TEST=Visit http://i18n.kaziprst.org/locale.html.
Review URL: http://codereview.chromium.org/6901141

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7768 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-03 20:43:51 +00:00
ricow@chromium.org
06932d0e6b Revert 7634, Fix experimental.gyp to include i18n-empty-js.cc so that js2c.py get correct parameters.
This caused all chromium based builds to fail (e.g., DumpRenderTree)
Review URL: http://codereview.chromium.org/6882003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7643 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-18 08:01:50 +00:00
cira@chromium.org
d637c32e63 Fix experimental.gyp to include i18n-empty-js.cc so that js2c.py get correct parameters.
Bug occured somewhere in the merge process.
Review URL: http://codereview.chromium.org/6875013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7634 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-15 20:31:30 +00:00
ager@chromium.org
5fd4fa2a9e Introduce experimental natives that are enabled by a runtime flag.
Clean up the use of js2c. We generated two identical files.

R=sgjesse@chromium.org,rossberg@chromium.org
BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7630 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-15 12:31:03 +00:00
cira@chromium.org
8aaa0c6b18 Add v8Locale.Collator
This is a partial implementation of Collator per what's agreed upon at the last
ECMAScript meeting + mailing list. Only the following three options are implemented: ignoreAccent, ignoreCase, numeric. 

ChromeOS and Chrome need this feature for M12. This could be added as chrome extension API. Giiven that we have a rough agreement on the collation part of ECMAScript API, we thought it'd save us some duplicated work adding this to v8 (experimental i18n api) now rather than implementing it in Chrome now and moving it later. 


BUG=28604
TEST=http://i18nl10n.com/chrome/coll2.html
Review URL: http://codereview.chromium.org/6673011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7620 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-14 19:10:51 +00:00