Commit Graph

4670 Commits

Author SHA1 Message Date
vitalyr@chromium.org
051f156bdd Try to fix win64 build.
TBR=mikhail.naganov@gmail.com

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5664 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 16:56:44 +00:00
vitalyr@chromium.org
e6b33bd20b Support profiling based on linux kernel performance events.
Since 2.6.31 perf_events interface has been available in the
kernel. There's a nice tool called "perf" (linux-2.6/tools/perf) that
uses this interface and provides capabilities similar to oprofile. The
simplest form of its usage is just dumping the raw log (trace) of
events generated by the kernel. In this patch I'm adding a script
(tools/ll_prof.py) to build profiles based on perf trace and our code
log. All the heavy-lifting is done by perf. Compared to oprofile agent
this approach does not require recompilation and supports code moving
garbage collections.

Expected usage is documented in the ll_prof's help. Basically one
should run V8 under perf passing --ll-prof flag and then the produced
logs can be analyzed by tools/ll_prof.py.

The new --ll-prof flag enables logging of generated code object
locations and names (like --log-code), and also of their bodies, which
can be later disassembled and annotated by the script.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5663 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 16:45:11 +00:00
lrn@chromium.org
484b9df414 Limit end-anchored regexps to testing end of string where possible.
Review URL: http://codereview.chromium.org/3844006

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5661 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 14:00:01 +00:00
kmillikin@chromium.org
f2789a903b Change the StackGuard runtime function to take no arguments.
For some reason the StackGuard runtime function took a dummy argument
that it always ignored.  Change it to take no arguments.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5660 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 11:14:03 +00:00
lrn@chromium.org
00e23b719d Revert revision 5657.
TBR: erik.corry

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5658 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 10:37:54 +00:00
lrn@chromium.org
f80da64d36 Use finite-length end-anchored regexps to reduce part of regexp that is searched.
Review URL: http://codereview.chromium.org/3850005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5657 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 09:42:40 +00:00
ager@chromium.org
d4ae526526 Return false from PagedSpace::Contains if the page from an address is not valid.
This can happen on Mac where C++ code can be in the 4-8K range.  
Review URL: http://codereview.chromium.org/3781020

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5656 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 09:16:57 +00:00
sgjesse@chromium.org
02615e8b75 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@5655 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 08:23:47 +00:00
vegorov@chromium.org
82b380d3b8 Clear normalized map caches in all global contexts not just in those reachable from ThreadLocalTops.
Issue reported by Mark Lam <mark.lam@palm.com> from Hewlett-Packard Development Company, LP.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5654 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-19 08:14:41 +00:00
mikhail.naganov@gmail.com
e0ff35ddb6 Update sync profiling changes for Solaris platform.
Patch by Maciej Blizinski <blizinski@google.com>

TBR=kasperl@chromium.org
BUG=901

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5653 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 17:34:27 +00:00
vegorov@chromium.org
0028030dad Fix TestInternalWeakLists test
Releasing context handle is not enough to release context, it might be indirectly reachable through compilation cache.

TBR=sgjesse@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5652 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 17:01:30 +00:00
floitschV8@gmail.com
705a57266a Disable double strtod in ARM-simulator.
The ARM simulator is compiled for 32bits. On Linux the floating-point
operations are hence invalid for the simulator too.

Fixes build-breakage.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5651 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 16:37:19 +00:00
floitschV8@gmail.com
1193987313 Fix double-rounding in strtod.
Don't use floating-point operations on Linux,x86 to compute strtod. Since the
floating-point stack on Linux is set to 80bit double rounding may occure.

When falling back to gay_strtod append several '0's so that Gay doesn't take
the same shortcut either.

BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5650 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 15:19:39 +00:00
vegorov@chromium.org
b2b7aa6f3b Link all global contexts into a weak list.
Review URL: http://codereview.chromium.org/3764011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5649 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 14:59:03 +00:00
vitalyr@chromium.org
af95fa6081 SConstruct: make help work even if guesses failed.
Review URL: http://codereview.chromium.org/3811010

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5648 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 14:39:59 +00:00
whesse@chromium.org
e08e43691a Fix bug in comparison of two smis that differ by MIN_SMI on full compiler on all platforms.
Review URL: http://codereview.chromium.org/3767016

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5643 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 14:04:28 +00:00
antonm@chromium.org
9673ee5d59 Get rid of requested size in RetryAfterGC.
This was only used by Heap::CollectGarbage to check if after GC
available space is bigger than was requested, but nobody checked
the value returned by Heap::CollectGarbage, so requested size
was efficiently unused.

However, it may trigger spurious out of memory exceptions if requested
size is big enough.

BUG=http://code.google.com/p/chromium/issues/detail?id=54580

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5642 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 12:58:56 +00:00
kasperl@chromium.org
cabe82959f Try to simplify the semantics of the profiling code by making
sure to suspend the thread (if necessary) on mac/win32 before 
reading the VM state.

Avoid dealing with signals delivered to non-VM threads on 
linux no matter if we're profiling or not.
Review URL: http://codereview.chromium.org/3845006

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5641 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 12:37:07 +00:00
erik.corry@gmail.com
767bded993 Fix missing check for GC failure in number dictionary code.
Review URL: http://codereview.chromium.org/3781014

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5640 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 12:16:38 +00:00
vegorov@chromium.org
5598d3c671 Prepare push to trunk. Now working on version 2.5.1.
Review URL: http://codereview.chromium.org/3748013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5637 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 11:06:51 +00:00
whesse@chromium.org
056b1f3a86 Fix compilation error on ARM with gcc 4.4. Remove NULL check of pointer to member, which was dead code (never failed).
Review URL: http://codereview.chromium.org/3793011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5636 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 10:23:45 +00:00
mikhail.naganov@gmail.com
d4bc8e1585 New Heap profiler: add dumping HeapNumbers and InternalFields to snapshot.
HeapNumbers do consume memory, so it's worth dumping them. However, we
don't dump their values, as they are not as self-descriptive as values
of strings, and they will increase snapshot size. Storing heap numbers
values can be added if we will feel a sufficient demand for that.

InternalFields are used, e.g. for storing references to DOM nodes
event handlers.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5635 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-18 09:15:38 +00:00
whesse@chromium.org
a8455f0424 Do not return the constant singleton float -0.0 from UnaryOpStub, because it may be overwritten, on X64 platform.
Review URL: http://codereview.chromium.org/3748007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5631 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-15 14:50:49 +00:00
ricow@chromium.org
01d7470b9b Remove trailing spaces from js files.
This is a cosmetic change only.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5630 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-15 13:03:59 +00:00
whesse@chromium.org
9aec312468 Add stop-at flag implementation to full compiler on all platforms.
Review URL: http://codereview.chromium.org/3791009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5629 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-15 11:45:05 +00:00
erik.corry@gmail.com
759a87b520 Fix new-space-too-small test crash on 64 bit VM.
Review URL: http://codereview.chromium.org/3778009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5628 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-15 10:45:18 +00:00
erik.corry@gmail.com
d22965c49d Fix creation of an exception to avoid rare GC corner case.
Review URL: http://codereview.chromium.org/3782009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5627 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-15 07:54:20 +00:00
ager@chromium.org
740dece782 Fix the version number in the ChangeLog.
TBR=kmillikin@chromium.org
Review URL: http://codereview.chromium.org/3757004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5625 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-14 18:54:53 +00:00
floitschV8@gmail.com
43fd9a542c Work around Windows bug. Use different constants.
Windows' strtod doesn't correctly read 3e-324 a the lowest denormal, but returns 0.0 instead.
Using 4e-324 is still the same value and works.

BUG=
TEST=
Review URL: http://codereview.chromium.org/3744008

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5624 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-14 15:54:51 +00:00
floitschV8@gmail.com
2b226c598f Weed out extreme exponents in strtod.
If a decimal exponent is less than -309 return 0.0.
If a decimal exponent is greater than +324 return +infinity.

BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5623 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-14 13:47:48 +00:00
lrn@chromium.org
d5ac565882 Restructure RegExp exec cache code.
Review URL: http://codereview.chromium.org/3778004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5622 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-14 12:54:00 +00:00
sgjesse@chromium.org
e144c259c5 Remove line added by accident.
TBR=ager@chromium.org
Review URL: http://codereview.chromium.org/3761002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5621 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-14 11:46:55 +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
lrn@chromium.org
6c0cde67bc Fix bug in cache handling of lastIndex on global regexps.
Review URL: http://codereview.chromium.org/3745005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5615 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-14 08:51:20 +00:00
mikhail.naganov@gmail.com
788c5e344d Better align heap snapshots contents with debugger info.
I created a heap snapshot in Chromium, and then started comparing
it side-by-side with representations of objects provided by
the debugger, fixing discrepancies.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5612 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-13 14:57:00 +00:00
ager@chromium.org
4e259f81aa Prepare push to trunk. Now working on version 2.5.0.
Review URL: http://codereview.chromium.org/3776001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5609 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-13 08:12:58 +00:00
kmillikin@chromium.org
65edae5b62 Fix a bug in our handling of conditional expressions in test contexts.
In the FullCodeGenerator, we compile the true subexpression of a
conditional (ternary) expression in the inherited context of the
entire expression.  This is correct for effect and value contexts, but
not for test contexts where the context includes a possible
fall-through label.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5607 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-08 13:07:55 +00:00
floitschV8@gmail.com
f5ea94da69 Simplify powers-of-ten cache.
The existing cache was build to support changes to fast-dtoa. This complicated the cache. Since the cached numbers are now in a .cc file they can be shared with other parts of v8.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5606 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 13:02:36 +00:00
floitschV8@gmail.com
4cd03a4f6a Implement fast case for strtod.
Reapply r5603 with additional fix: use OS::StrNCpy instead of posix strncpy.

BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5605 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 12:53:59 +00:00
ager@chromium.org
dfacc926fc Revert strtod fast-case change (r5603) because of Windows compilation
errors.

TBR=floitschV8@gmail.com
Review URL: http://codereview.chromium.org/3582017

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5604 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 12:24:02 +00:00
floitschV8@gmail.com
ce666fc2fe Implement fast case for strtod.
If there are few non-zero digits and the 10^exponent fits into a double then
we can compute the result using 1 (or 2) double operations.

BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5603 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 12:01:25 +00:00
whesse@chromium.org
d4afed6bff Fix new strtod on Windows platform, using OS::SNPrintF instead of snprintf. Fixes error in r5600.
Review URL: http://codereview.chromium.org/3601018

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5602 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 09:40:26 +00:00
floitschV8@gmail.com
e5bb73acba Fix build-breakage. Add new line to end of strtod.h. TBR: whesse@chromium.org
BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5601 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 09:12:21 +00:00
floitschV8@gmail.com
caf6856ade Move gay_strtod outside conversions.cc.
This is the first part of removing calls to gay's strtod. Future CLs will
get rid of calls to gay_strtod entirely.

BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5600 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 08:54:10 +00:00
kasperl@chromium.org
fdde212fec Promote the current V8 benchmark suite candidate to version 6.
Review URL: http://codereview.chromium.org/3571021

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5596 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-07 07:25:22 +00:00
kmillikin@chromium.org
92a74be6f1 Fix presubmit failure.
Review URL: http://codereview.chromium.org/3605008

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5595 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-06 08:47:08 +00:00
floitschV8@gmail.com
9c00ea744b During StringToDouble negative exponents may be less than -999 with a result that is not 0.0.
Review URL: http://codereview.chromium.org/3564011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5594 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-06 08:33:52 +00:00
ager@chromium.org
55356a3627 Land for Rodolph Perfetta.
Added a missing SetCC in the ARM CompareStub.

BUG=none
TEST=none

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5593 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-06 06:09:05 +00:00
yurys@chromium.org
481c25908c Code clean-up in src/top.cc This patch addresses late review comments for http://code.google.com/p/v8/source/detail?r=5586
Review URL: http://codereview.chromium.org/3596005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5592 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-05 13:29:31 +00:00
antonm@chromium.org
7c238db829 Do not shortcut union of keys if lhs is empty.
The problem is other array may have holes, for example
when fixed array comes from JSArray (in case of named interceptor).

If that would prove to be a performance problem, we could
pass an additional argument into UnionOfKeys to hold actual length.

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5591 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-05 13:10:43 +00:00