Commit Graph

65 Commits

Author SHA1 Message Date
jochen@chromium.org
a294defe9b Remove usage of deprecated APIs from v8 itself
Also turn on depreaction warnings

BUG=v8:3023
R=svenpanne@chromium.org, dcarney@chromium.org
LOG=n

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18008 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-11-22 12:28:58 +00:00
svenpanne@chromium.org
22b9adce49 Have mercy and don't kill the Context::Scope immediately after birth.
BUG=v8::2994
R=dcarney@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17627 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-11-12 07:03:59 +00:00
svenpanne@chromium.org
847f4ce616 Removed dead code from mksnapshot.
R=mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17262 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-10-18 09:06:58 +00:00
dcarney@chromium.org
44afd2a5f9 don't use default isolate in mksnapshot
R=svenpanne@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16869 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-09-20 13:19:40 +00:00
jochen@chromium.org
c5b3ce0671 Snapshot i18n Javascript code
The previous attempt used Boolean instead of $Boolean.

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

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16687 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-09-12 13:50:38 +00:00
dcarney@chromium.org
cc2257b92a move HEAP to /test
R=svenpanne@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16631 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-09-11 07:14:41 +00:00
dcarney@chromium.org
bb01557abf remove Isolate::Current from most files starting with 's' through 'v'
R=svenpanne@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16507 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-09-03 11:54:08 +00:00
svenpanne@chromium.org
625874a48c Deprecate Persistent functions which were marked to be deprecated.
BUG=
R=svenpanne@chromium.org

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

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16493 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-09-03 07:34:34 +00:00
jkummerow@chromium.org
caba24c813 Revert "Snapshot i18n Javascript code" and "Fix mjsunit/debug-script after r16298".
This reverts r16298 and r16303 due to ChromeOS browser_tests failures ("Uncaught ReferenceError: Boolean is not defined" in --gtest_filter="FileDisplay/FileManagerBrowserTest.Test/0" and others)

R=mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16336 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-08-26 17:00:58 +00:00
jochen@chromium.org
064c91be57 Snapshot i18n Javascript code
BUG=v8:2745
R=mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16298 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-08-23 13:24:48 +00:00
jochen@chromium.org
97409c2363 Move InitializeICU() to the V8 API and use it.
I can't get rid of the enable_i18n flag yet, as we need to be able to
turn off all extensions for creating the snapshot.

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

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15618 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-07-11 09:58:54 +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
dcarney@chromium.org
8b2c26d736 remove most uses of raw handle constructors
R=svenpanne@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15107 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-06-13 09:27:09 +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
fec64cd698 remove most remaining V8_ALLOW_ACCESS_TO* defines
R=svenpanne@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14870 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-05-29 08:39:37 +00:00
dcarney@chromium.org
d4fd9db342 fix nosnapshot test failure in 14793004, do not deprecate function
BUG=
TBR=svenpanne@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14585 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-05-08 07:45:16 +00:00
mstarzinger@chromium.org
04a5b3d6b6 Revert "deprecate Context::New which returns Persistent"
This reverts r14573 because of test failures in no-snapshot mode in the
cctest/test-debug/ScriptCollectedEventContext test case.

TBR=dcarney@chromium.org,svenpanne@chromium.org
TEST=cctest/test-debug/ScriptCollectedEventContext

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14578 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-05-07 16:28:51 +00:00
dcarney@chromium.org
386de8010b deprecate Context::New which returns Persistent
BUG=
TBR=marja@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14573 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-05-07 13:29:24 +00:00
dcarney@chromium.org
cf5ff5a14c first step to remove unsafe handles
R=svenpanne@chromium.org
BUG=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14530 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-05-02 20:18:42 +00:00
svenpanne@chromium.org
0c63e8d698 Also print the exception when mksnapshot failed to compile extra code.
Before, it would only print the exception when it failed to run the code

R=svenpanne@chromium.org

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

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14478 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-04-29 11:49:24 +00:00
svenpanne@chromium.org
53310ac152 Added a version of the v8::HandleScope constructor with an Isolate and use that consistently.
I tried to limit the use of v8::Isolate::GetCurrent() and v8::internal::Isolate::Current() as much as possible, but sometimes this would have involved restructuring tests quite a bit, which is better left for a separate CL.

BUG=v8:2487

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13953 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-03-15 12:06:53 +00:00
svenpanne@chromium.org
52d10a68cb Add Isolate parameter to Persistent class.
BUG=v8:2487

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13501 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-01-25 08:31:46 +00:00
erik.corry@gmail.com
5a8d1764bc Refactoring of snapshots. This simplifies and improves
the speed of deserializing code.  The current startup
time improvement for V8 is around 6%, but code deserialization
is speeded up disproportionately, and we will soon have more
code in the snapshot.
* Removed support for deserializing into large object space.
  The regular pages are 1Mbyte now and that is plenty.  This
  is a big simplification.
* Instead of reserving space for the snapshot we actually
  allocate it now.  This removes some special casing from
  the memory management and simplifies deserialization since
  we are just bumping a pointer rather than calling the
  normal allocation routines during deserialization.
* Record in the snapshot how much we need to boot up and
  allocate it instead of just assuming that allocations in
  a new VM will always be linear.
* In the snapshot we always address an object as a negative
  offset from the current allocation point.  We used to
  sometimes address from the start of the deserialized data,
  but this is less useful now that we have good support for
  roots and repetitions in the deserialization data.
* Code objects were previously deserialized (like other
  objects) by alternating raw data (deserialized with memcpy)
  and pointers (to external references, other objects, etc.).
  Now we deserialize code objects with a single memcpy,
  followed by a series of skips and pointers that partially
  overwrite the code we memcopied out of the snapshot.
  The skips are sometimes merged into the following
  instruction in the deserialization data to reduce dispatch
  time.
* Integers in the snapshot were stored in a variable length
  format that gives a compact representation for small positive
  integers.  This is still the case, but the new encoding can
  be decoded without branches or conditional instructions,
  which is faster on a modern CPU.
Review URL: https://chromiumcodereview.appspot.com/10918067

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12505 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-09-14 11:16:56 +00:00
erik.corry@gmail.com
000519013f Remove unused variable in mksnapshot.cc.
Review URL: https://chromiumcodereview.appspot.com/10559078

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11874 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-06-20 08:14:31 +00:00
erikcorry
458e87fd05 Snapshots: Add --extra-code flag to mksnapshot which lets you specify a file
with more JS code that is loaded into the VM before writing the snapshot.  Get
rid of the hard coded limit on the partial snapshot cache size.  This change
disables most of the serializer tests for the snapshot build of the VM: It's
getting too complicated to support both booting from a snapshot and then
creating a new snapshot from the same VM or loading more code with another
snapshot in the same VM.
Review URL: http://codereview.chromium.org/10574013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11871 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-06-19 18:38:03 +00:00
erikcorry
634ffc9600 Report syntax errors in natives when building with mksnapshot.
Review URL: http://codereview.chromium.org/10443085

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11687 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-05-31 12:26:36 +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
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
erik.corry@gmail.com
8f9721bbbf Shave 39% from snapshot size.
Review URL: http://codereview.chromium.org/8344079

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9722 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-20 12:27:10 +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
29bb1f8d62 Remove STL dependencies from mksnapshot.cc
Remove unused code and consequently the stl includes of map and string.

R=mnaganov@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9125 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-05 08:06:29 +00:00
mikhail.naganov@gmail.com
58824435d1 Pick the namespace alias 'i' from v8.h.
These files already include v8.h so they don't need to define the
namespace alias again.

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

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8919 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-12 09:49:55 +00:00
sgjesse@chromium.org
8a6108de95 Remove the ability to compile without logging and profiling
The preprocessor defines ENABLE_LOGGING_AND_PROFILING and ENABLE_VMSTATE_TRACKING has been removed as these where required to be turned on for Crankshaft to work. To re-enable reducing the binary size by leaving out heap and CPU profiler a new set of defines needs to be created.

R=ager@chromium.org

BUG=v8:1271
TEST=all

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8622 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-13 09:09:04 +00:00
mikhail.naganov@gmail.com
f1309b0417 Compress sources of JS libraries in addition to the snapshot.
This saves ~170K on current sources.

R=sgjesse@chromium.org
BUG=none
TEST=none

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8189 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-06 20:47:30 +00:00
mikhail.naganov@gmail.com
9a2cb3009c Fix whitespace error after r7726
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7727 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-29 12:47:34 +00:00
mikhail.naganov@gmail.com
7a8996b626 Fix Linux builds after r7724
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7726 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-29 12:43:24 +00:00
mikhail.naganov@gmail.com
ec58c05f4e Add support for startup data (snapshot) compression.
This is for mobile platforms where application footprint size is
important. To avoid including compression libraries into V8, we assume
that the host machine have them (true for Linux), and rely on embedder
to provide decompressed data.

Currently, only snapshot data can be comressed. It is also possible to
compress libraries sources, but it is more involved and will be
addressed in another CL.

BUG=none
TEST=none

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7724 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-04-29 12:08:33 +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
kasperl@chromium.org
7d6a3b433f Merge the partial_snapshots branch back into bleeding_edge. For
now, the custom call generator stuff is disabled.
Review URL: http://codereview.chromium.org/1094014

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4217 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-23 11:40:38 +00:00
erik.corry@gmail.com
90045ddd5e Another step on the way to context snapshots. We can now refer to
objects in the startup heap from a partial snapshot.  This happens
through the partial snapshot cache.  A startup snapshot and a
partial snapshot are created together so that the startup snapshot
contains the partial snapshot cache entries needed.
Review URL: http://codereview.chromium.org/548149

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3713 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-27 08:25:48 +00:00
mikhail.naganov@gmail.com
37d3972429 Fix issue 571: display descriptive names for code objects from snapshot.
As this is only needed for internal profiling (not for DevTools),
the following approach had been chosen:

 - during snapshot creation, positions of serialized objects inside
   a snapshot are logged;

 - then during V8 initialization, positions of deserealized objects
   are logged;

 - those positions are used for retrieving code objects names from
   snapshot creation log, which needs to be supplied to tick processor
   script.

Positions logging is controlled with the new flag: --log_snapshot_positions.
This flag is turned off by default, and this adds no startup penalty.

To plug this fix to Golem, the following actions are needed:

 - logs created using 'mksnapshot' need to be stored along with VM images;

 - tick processor script needs to be run with '--snapshot-log=...' cmdline
   argument.

BUG=571

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3635 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-18 16:04:25 +00:00
ager@chromium.org
c1cafb7cf1 Port FastNewClosureStub introduced for ia32 in r3477 to x64 and arm.
BUG=552
Review URL: http://codereview.chromium.org/543010

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3578 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-12 07:16:49 +00:00
erik.corry@gmail.com
64941f1cf9 * Remove old snapshot implementation
Review URL: http://codereview.chromium.org/394007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3307 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-11-16 12:08:40 +00:00
erik.corry@gmail.com
b9d37517d2 * Do a GC in mksnapshot to get rid of some extraneous junk.
* Make snapshot more compact by coding the tag and the space
in one byte.  Contract some common sequences to one byte.
* Use back references only within one page.  Index from the
start of the space otherwise.
* Serialize Smis as raw data rather than int-encoding them.
This takes a little more space but is faster.
Review URL: http://codereview.chromium.org/341079

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3208 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-11-03 21:00:43 +00:00
erik.corry@gmail.com
dbd7f20d2d Introduce a switch for the new snapshot code and switch
it on by default.  Includes bug fixes for new snapshots.
Review URL: http://codereview.chromium.org/342054

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3184 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-10-30 10:23:12 +00:00
mike@belshe.com
6f3c50460a Update the Idle collector to do a full GC
after being idle for some time.

Remove the default argument from CollectAllGarbage.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2748 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-08-25 02:54:39 +00:00
sgjesse@chromium.org
be7f110adf Remove definition of _HAS_EXCEPTIONS from source files.
The define _HAS_EXCEPTIONS=0 is only required on Windows and is already set in the SCons build file and Visual Studio project files.
Review URL: http://codereview.chromium.org/67116

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1707 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-04-14 14:58:23 +00:00
kasperl@chromium.org
1e42e70021 Use SSE3 instructions - if available - for faster To(U)Int32
conversion in bit operation stubs. Disable serialization
support by default to allow us to use SSE3 instructions and
faster write barrier code when running without snapshot.
Review URL: http://codereview.chromium.org/27046

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1364 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-02-25 14:57:46 +00:00