Commit Graph

57 Commits

Author SHA1 Message Date
vegorov@chromium.org
fbc230e42b Ensure that executable pages are properly guarded.
Split executable memory chunks into two pieces: header with all metadata (protection: RW) and body (protection: RWX). Separate header from metadata with a guard page and add a guard page after the page body.

R=erik.corry@gmail.com
BUG=http://crbug.com/115151

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10809 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-02-23 12:11:24 +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
fschneider@chromium.org
976d5f3797 Clean list of external references from internal objects like the hole value.
Review URL: http://codereview.chromium.org/8114032

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9511 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-04 09:07:50 +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
vitalyr@chromium.org
1dcb6e33cd Minimize malloc heap allocation on process startup.
R=vegorov@chromium.org
BUG=http://b/issue?id=5095592

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8833 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-04 15:18:18 +00:00
vegorov@chromium.org
cb99571cec Fix ContextDeserialization and PartialDeserialization tests.
Space should be reserved twice before each deserialization.

R=erik.corry@gmail.com

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8795 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-02 17:43:32 +00:00
ager@chromium.org
1bdc8031fa Introduce accessors on builtins instance and use them to avoid TLS access when getting builtins.
R=vitalyr@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7327 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-03-23 13:40:07 +00:00
ager@chromium.org
feac1ff9dd Fix COUNTERS use in test-serialize.
Review URL: http://codereview.chromium.org/6705023

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7326 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-03-23 12:07:23 +00:00
ager@chromium.org
b69591bc0f Require an isolate parameter for most external reference creation to
avoid TLS access in connection with external references.

Make the isolate accessible via the assembler.

Only for ia32 at this point. If this looks OK to you I will port it.

R=vitalyr@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7305 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-03-22 13:20:04 +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
ager@chromium.org
ec841bb97d Attempt to disambiguate RUNTIME_FUNCTION for win64 build in serialization tests.
BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6821 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-02-16 13:56:23 +00:00
erik.corry@gmail.com
302abe308f Fix some memory leaks in the serialization tests.
Review URL: http://codereview.chromium.org/4095009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5736 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-29 07:10:41 +00:00
erik.corry@gmail.com
0dcaac1939 Make Failure inherit from MaybeObject instead of Object.
Review URL: http://codereview.chromium.org/3970005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5698 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-25 15:22:03 +00:00
sgjesse@chromium.org
be5763fc4d Cleanup the way the debugger stores live registers when entering at a break
The live registers are now only stored to the expression stack with the non pointer values being stored as smis (on the 32-bit platforms these values are assumed to be 31-bit max).

This makes the CEntryStub entry/exit code much simpler, and there is no longer any need for a mode (debug or normal) on it.

Fix a missing live register when breaking at ARM keyed load.
Review URL: http://codereview.chromium.org/3141047

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5358 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-08-27 07:08:03 +00:00
sgjesse@chromium.org
685cae6021 API: Resolve linker issues with using V8 as a DLL
This changes the way the constants kJSObjectType, kFirstNonstringType and kProxyType are made available to the inlined part of the V8 API. This change to fixed constants resolves linker this linker error Windows

error LNK2001: unresolved external symbol "public: static int v8::internal::Internals::kJSObjectType" (?kJSObjectType@Internals@internal@v8@@2HA)

when linking against a V8 DLL.

This change also makes it possible to build all the C++ tests with ENABLE_DEBUGGER_SUPPORT not defined. Now C++ tests run ENABLE_DEBUGGER_SUPPORT not defined, and only the JavaScript tests which tests the debugger fails when ENABLE_DEBUGGER_SUPPORT is not defined.
Review URL: http://codereview.chromium.org/2820016

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4898 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-06-18 10:52:59 +00:00
ager@chromium.org
31cb9f7090 Add external references used for regexp execution to the serializer.
Review URL: http://codereview.chromium.org/2838001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4863 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-06-14 21:03:59 +00:00
serya@chromium.org
16d3811d50 Changing string length field type from int to SMI. It will make it be a regular field. Code generated in EmitNamedLoad could be patched for faster access to string.length.
Review URL: http://codereview.chromium.org/1706013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4581 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-05-04 14:49:50 +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
antonm@chromium.org
21af2c360a Reland 4068 which wrapped Array methods into native builtins (reverted in 4075).
Review URL: http://codereview.chromium.org/857002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4104 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-11 13:13:21 +00:00
ager@chromium.org
5fd33c7527 Revert change to always call builtins for Array functions.
It causes regressions on test shell tests.

TBR=antonm@chromium.org
Review URL: http://codereview.chromium.org/819001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4075 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-10 08:45:00 +00:00
antonm@chromium.org
52ec954dd2 Always invoke C++ ArrayPush builtin.
Now this builtin checks if it should go into fast case or resort to JS ArrayPush builtin.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4068 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-09 15:43:04 +00:00
kasperl@chromium.org
19a5126ee3 Disable two problematic tests that only test functionality
used on the partial_snapshots branch.

BUG=http://code.google.com/p/v8/issues/detail?id=632
Review URL: http://codereview.chromium.org/669062

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4023 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-04 14:45:36 +00:00
kasperl@chromium.org
81c59c5c0c Don't use strcmp to test heap object pointer equality.
Review URL: http://codereview.chromium.org/668060

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4019 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-04 12:35:39 +00:00
erik.corry@gmail.com
c2106c13fc Allow snapshots built without -DANDROID to work on Android.
Fix bug in fast code generator on ARM (can't use ip as scratch
in RecordWrite).
Activate normal-sized compilation cache on Android.
This is a port of 3938 from the partial snapshots branch.
Review URL: http://codereview.chromium.org/652227

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3992 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-02 11:54:11 +00:00
sgjesse@chromium.org
5fe8bd9919 Fix 64-bit build on Windows and Visual Studio project files
64-bit version now builds on Windows again in both release and debug mode.

The Visual Studio project files have been updated so that all three configurations work (32-bit, 64-bit and 32-bit with ARM simulator). They all convert from Visual Studio 2005 to Visual Studio 2008.

TBR=lrn@chromium.org
Review URL: http://codereview.chromium.org/549174

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3722 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-27 16:18:58 +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
sgjesse@chromium.org
30b4bff49b Fix building on 64-bit Windows
Review URL: http://codereview.chromium.org/546147

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3700 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-26 08:44:50 +00:00
mikhail.naganov@gmail.com
fdfc37c2d8 Fix test-serialize.
Sorry for a breakage...

TBR=erik.corry@gmail.com

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3638 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-18 16:56:17 +00:00
erik.corry@gmail.com
b53a609e01 Fix windows tests. In the context of fopen the opposite of 'b' for binary
is '' for ascii, not 'a' for ascii.
Review URL: http://codereview.chromium.org/542104

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3628 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-18 12:02:53 +00:00
mikhail.naganov@gmail.com
23fe22e7c8 Fix build problems.
Review URL: http://codereview.chromium.org/543087

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3622 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-15 20:15:47 +00:00
erik.corry@gmail.com
4a90166dde Implement enough of the partial snapshots that we can deserialize
a single string.
Review URL: http://codereview.chromium.org/536077

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3619 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-15 14:20:31 +00:00
vitalyr@chromium.org
bd06358b93 Optimized calling of C++ builtins (and HandleApiCall
in particular).

  * Called function is passed on the stack instead of
    using a static variable.

  * Builtins that don't need the called function don't
    get it.

  * Made is_construct statically known to HandleApiCall
    by setting custom construct stub for API functions.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3613 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-15 12:25:24 +00:00
erik.corry@gmail.com
bc334df1a8 * Improve the interface to the memory-reservation functionality.
* Add a test case that generates a serialization of a single flat string.
Review URL: http://codereview.chromium.org/542073

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3606 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-14 14:46:31 +00:00
erik.corry@gmail.com
1aeb239e60 Fix float conversion warning from some gcc versions.
Review URL: http://codereview.chromium.org/541026

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3585 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-12 15:36:43 +00:00
erik.corry@gmail.com
612d9b82f0 Add some interfaces to the GC that allow us to reserve space. This is needed
for partial snapshots.  After reserving space we can be sure that allocations
will happen linearly (no GCs and no free-list allocation).  This change also
contains the start of the partial snapshot support, which, however is not yet
completed or tested.
Review URL: http://codereview.chromium.org/545026

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3584 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-12 15:16:23 +00:00
erik.corry@gmail.com
10e183d353 Make heap serialization nondestructive.
Review URL: http://codereview.chromium.org/441017

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3360 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-11-25 12:55:33 +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
df4f52347b Allow a platform to indicate that some CPU features are always
available.  We use this to ensure that snapshots on MacOSX can
use SSE2 instructions.  Also clean up and assertify the
handling of things we can't do when we are generating a
snapshot.  Fix a bug in the new serialization tests where
they activated Snapshot::enable() too late after code had been
generated that assumed no snapshots.
Review URL: http://codereview.chromium.org/391051

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3301 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-11-13 12:32:57 +00:00
sgjesse@chromium.org
41d6cae46d Fix issue 493: Infinite loop when debug break is set when entering function.apply.
In the generated code for function.apply there was a loop checking the stack limit for interruption. This loop would call into the runtime system to handle interuption and keep running until there was no interruption. However if the interuption was debug break the runtime system would never clear the interruption as debug break is prevented in builtins are prevented and the assumption here was that returning with the debug break flag set would move execution forward.

Renamed initial_jslimit and initial_climit to real_jslimit and real_climit. Renamed a few external references related to the stack limit as well.

Exposed the real stack limit to generated code to make the stack check when entering function.apply use the real stack limit and not the stack limit which is changed to signal interruption.

Added the real stack limit to the roots array.

BUG=http://code.google.com/p/v8/issues/detail?id=493
TEST=cctest/test-debug/DebugBreakFunctionApply
Review URL: http://codereview.chromium.org/345048

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3229 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-11-05 13:59:40 +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
erik.corry@gmail.com
fb2317b63b New snapshot framework. Doesn't work on ARM yet (code targets
are different).  Is able to deserialize the whole heap and run
some stuff.  Not available as the primary snapshot system yet.
Review URL: http://codereview.chromium.org/335009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3142 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-10-27 11:54:01 +00:00
erik.corry@gmail.com
d50fbb634e Fix bug that meant that dependent tests were never reported as
failing (though they could still crash).
(Cache the result of the test in the output object, not in the
test object which is reused from the prerequisite to the dependent.)
Review URL: http://codereview.chromium.org/321001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3115 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-10-22 19:09:09 +00:00
erik.corry@gmail.com
038f9074bc Reapply ARM root array change to reduce const pool size
by using r10 to point to a list of common root objects.
This time we also disable a debugger test on ARM that
has never worked, but with this change sometimes
crashes.
Review URL: http://codereview.chromium.org/174317

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2744 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-08-24 11:57:57 +00:00
feng@chromium.org
33fb11c12f Revert commit 2701 per Erik Corry's request.
Original CL:

http://codereview.chromium.org/171041
Review URL: http://codereview.chromium.org/171089

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2702 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-08-18 00:12:26 +00:00
whesse@chromium.org
349dc04a5d Use root array to load roots in generated ARM code.
This cuts down on code size and reloc work.
Review URL: http://codereview.chromium.org/171041

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2701 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-08-17 14:31:49 +00:00
erik.corry@gmail.com
b1d09b32f9 Remove dependency on libstdc++ from test framework.
Review URL: http://codereview.chromium.org/99051

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1799 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-04-27 10:52:44 +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
olehougaard
da4fdea61a Fixing the flakiness of the serialization tests by assuring that serialization is run before every deserialization test.
Review URL: http://codereview.chromium.org/19541

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1214 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-02-03 08:35:03 +00:00