v8/test/cctest
yurys@chromium.org 44dfaa2a1e Fix test-cpu-profiler/FunctionCallSample flakiness under GC stress testing
The test flakes on "V8 GC Stress" bots and the sample looks like this:
[Top down]:
   90     0   (root) [-1] #0 1
    1     1    (program) [-1] #0 2
   89    89    (garbage collector) [-1] #0 3
which means that almost all samples are inside GC and we have no |start| node in the collected profile.

Running the test with different combinations of --gc-interval=500 and --stress-compaction flags gives the results quoted below. They don't give a ground to require |start| node presense in the profile when doing GC stress testing. So this change makes the |start| node optional in the collected profile if GC stress testing is on.

$ ./out/ia32.debug/cctest --gc-interval=500 --stress-compaction --trace-gc  test-cpu-profiler/FunctionCallSample
[10291]       76 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 49.5 ms (+ 0.2 ms in 1 steps since start of marking, biggest step 0.2 ms) [StackGuard GC request] [GC in old space requested].
[10291]      110 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 25.3 ms [Logger::LogCompiledFunctions] [GC in old space requested].
[10291]      135 ms: Mark-sweep 0.4 (17.8) -> 0.4 (17.8) MB, 22.8 ms [Logger::LogAccessorCallbacks] [GC in old space requested].
[10291]      179 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 39.9 ms (+ 0.1 ms in 1 steps since start of marking, biggest step 0.1 ms) [Runtime::PerformGC] [GC in old space forced by flags].
[10291]      209 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 29.1 ms (+ 0.1 ms in 1 steps since start of marking, biggest step 0.1 ms) [Runtime::PerformGC] [GC in old space forced by flags].
[10291]      240 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 29.1 ms (+ 0.1 ms in 1 steps since start of marking, biggest step 0.1 ms) [Runtime::PerformGC] [GC in old space forced by flags].
[Top down]:
   99     0   (root) [-1] #0 1
    4     4    start [-1] #16 3
   93    93    (garbage collector) [-1] #0 4
    2     2    (program) [-1] #0 2

$ ./out/ia32.debug/cctest --gc-interval=500  --trace-gc  test-cpu-profiler/FunctionCallSample
[10328]       46 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 14.9 ms [Logger::LogCompiledFunctions] [GC in old space requested].
[10328]       61 ms: Mark-sweep 0.4 (17.8) -> 0.4 (17.8) MB, 12.9 ms [Logger::LogAccessorCallbacks] [GC in old space requested].
[10328]       65 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.3 ms [Runtime::PerformGC].
[10328]       67 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.3 ms [Runtime::PerformGC].
[10328]       69 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       70 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       72 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       73 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       75 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       77 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       78 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       80 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       81 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       83 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       85 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       86 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       88 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       89 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       91 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       93 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       94 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.3 ms [Runtime::PerformGC].
[10328]       96 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       97 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]       99 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      101 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      102 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      104 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      105 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      107 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      109 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      110 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      112 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      113 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.3 ms [Runtime::PerformGC].
[10328]      115 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      117 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      118 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      120 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      121 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      123 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      125 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      126 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      128 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      129 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      131 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      133 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      134 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      136 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      137 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      139 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      141 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      142 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      144 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.3 ms [Runtime::PerformGC].
[10328]      145 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      147 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      149 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      150 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      152 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      153 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.3 ms [Runtime::PerformGC].
[10328]      155 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      157 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      158 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      160 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      162 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[10328]      163 ms: Scavenge 0.5 (17.8) -> 0.4 (17.8) MB, 1.2 ms [Runtime::PerformGC].
[Top down]:
   95     0   (root) [-1] #0 1
   12    11    start [-1] #16 3
    1     1      bar [-1] #16 4
   81    81    (garbage collector) [-1] #0 5
    2     2    (program) [-1] #0 2

$ ./out/ia32.debug/cctest --stress-compaction --trace-gc  test-cpu-profiler/FunctionCallSample
[10355]       76 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 49.9 ms (+ 0.1 ms in 1 steps since start of marking, biggest step 0.1 ms) [StackGuard GC request] [GC in old space requested].
[10355]      110 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 25.5 ms [Logger::LogCompiledFunctions] [GC in old space requested].
[10355]      135 ms: Mark-sweep 0.4 (17.8) -> 0.4 (17.8) MB, 22.9 ms [Logger::LogAccessorCallbacks] [GC in old space requested].
[10355]      189 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 49.8 ms (+ 0.2 ms in 1 steps since start of marking, biggest step 0.2 ms) [StackGuard GC request] [GC in old space requested].
[10355]      234 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 42.5 ms (+ 0.1 ms in 1 steps since start of marking, biggest step 0.1 ms) [StackGuard GC request] [GC in old space requested].
[10355]      278 ms: Mark-sweep 0.5 (17.8) -> 0.4 (17.8) MB, 42.5 ms (+ 0.1 ms in 1 steps since start of marking, biggest step 0.1 ms) [StackGuard GC request] [GC in old space requested].
[Top down]:
  135     0   (root) [-1] #0 1
    6     6    start [-1] #16 3
  127   127    (garbage collector) [-1] #0 4
    2     2    (program) [-1] #0 2

BUG=None
R=jkummerow@chromium.org, loislo@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15471 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-07-03 14:26:38 +00:00
..
cctest.cc Change ArrayBuffer API and implementation to use embedder-provided allocator. 2013-06-11 10:41:14 +00:00
cctest.gyp Introduce a notion of "v8_code" in gyp config files. 2013-06-28 15:22:46 +00:00
cctest.h remove most uses of raw handle constructors 2013-06-13 09:27:09 +00:00
cctest.status MIPS: Fix test-cpu-profiler/SampleWhenFrameIsNotSetup flakiness on MIPS simulator. 2013-06-19 17:20:25 +00:00
gay-fixed.cc Dtoa for fixed notation. 2010-05-05 13:51:27 +00:00
gay-fixed.h Dtoa for fixed notation. 2010-05-05 13:51:27 +00:00
gay-precision.cc Added precision mode to fast-dtoa. 2010-09-20 09:18:00 +00:00
gay-precision.h Added precision mode to fast-dtoa. 2010-09-20 09:18:00 +00:00
gay-shortest.cc Dtoa for fixed notation. 2010-05-05 13:51:27 +00:00
gay-shortest.h Dtoa for fixed notation. 2010-05-05 13:51:27 +00:00
log-eq-of-logging-and-traversal.js Eliminate the need for code delete events in CPU profiler. 2011-09-14 11:47:03 +00:00
test-accessors.cc remove all old style callbacks - patch 1 of many 2013-06-20 08:12:59 +00:00
test-alloc.cc Deprecate FACTORY helper macro. 2013-06-04 10:30:05 +00:00
test-api.cc Restore message when rethrowing in TryCatch. 2013-07-01 10:54:39 +00:00
test-assembler-arm.cc Deprecate FACTORY helper macro. 2013-06-04 10:30:05 +00:00
test-assembler-ia32.cc Deprecate FACTORY helper macro. 2013-06-04 10:30:05 +00:00
test-assembler-mips.cc MIPS: Fix cctest/test-assembler-mips on MIPS32R1 architecture. 2013-06-19 17:15:21 +00:00
test-assembler-x64.cc remove most V8_ALLOW_ACCESS_TO_* defines from test classes 2013-05-28 11:54:52 +00:00
test-ast.cc Get rid of ZoneScope completely. 2013-06-26 13:36:16 +00:00
test-bignum-dtoa.cc Fix X64 compilation on Windows. 2011-02-03 11:13:04 +00:00
test-bignum.cc Bignum implementation of Strtod. 2010-11-08 11:49:47 +00:00
test-circular-queue.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-compare-nil-ic-stub.cc Migrate Compare ICs to new type rep 2013-06-12 17:20:37 +00:00
test-compiler.cc Fixed more gc stress builder tests. 2013-06-25 11:16:13 +00:00
test-conversions.cc Fix build failure on Linux since r14681. 2013-05-15 13:14:24 +00:00
test-cpu-profiler.cc Fix test-cpu-profiler/FunctionCallSample flakiness under GC stress testing 2013-07-03 14:26:38 +00:00
test-dataflow.cc Get rid of ZoneScope completely. 2013-06-26 13:36:16 +00:00
test-date.cc Added a version of the v8::HandleScope constructor with an Isolate and use that consistently. 2013-03-15 12:06:53 +00:00
test-debug.cc Debug: support breakpoints set in the middle of statement (try #2 after rollback) 2013-07-01 13:44:10 +00:00
test-declarative-accessors.cc remove most uses of raw handle constructors 2013-06-13 09:27:09 +00:00
test-decls.cc remove all old style callbacks - patch 3 2013-06-20 12:28:27 +00:00
test-deoptimization.cc stop using AsciiValue 2013-05-13 14:18:05 +00:00
test-dictionary.cc Disable stress_compaction flag in several GC tests to meet test 2013-06-19 08:58:09 +00:00
test-disasm-arm.cc remove most V8_ALLOW_ACCESS_TO_* defines from test classes 2013-05-28 11:54:52 +00:00
test-disasm-ia32.cc Deprecate FACTORY helper macro. 2013-06-04 10:30:05 +00:00
test-disasm-mips.cc Unify the way cctest initalizes the VM for each test case. 2013-04-10 08:29:39 +00:00
test-disasm-x64.cc Unify the way cctest initalizes the VM for each test case. 2013-04-10 08:29:39 +00:00
test-diy-fp.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-double.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-dtoa.cc Fix compilation on 64-bit Windows, update Visual Studio projects. 2011-02-03 13:29:10 +00:00
test-fast-dtoa.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-fixed-dtoa.cc Dtoa for fixed notation. 2010-05-05 13:51:27 +00:00
test-flags.cc Ensure removing processed command line arguments. 2012-06-13 15:02:05 +00:00
test-func-name-inference.cc Deprecate FACTORY helper macro. 2013-06-04 10:30:05 +00:00
test-global-handles.cc New GC APIs, try 2. 2013-04-24 15:59:23 +00:00
test-global-object.cc remove most uses of raw handle constructors 2013-06-13 09:27:09 +00:00
test-hashing.cc Clean up the usage of V8_TARGET_ARCH_${arch} and V8_HOST_ARCH_${arch} 2013-06-28 15:34:48 +00:00
test-hashmap.cc Make the hash map test run faster by doing less work. 2009-05-15 13:49:00 +00:00
test-heap-profiler.cc Heap snapshot: Update user roots definition. 2013-06-28 12:53:52 +00:00
test-heap.cc Handlify JSObject::SetPrototype method. 2013-07-02 15:32:46 +00:00
test-list.cc Progress towards making Zones independent of Isolates and Threads. 2012-06-04 14:42:58 +00:00
test-liveedit.cc Get rid of ZoneScope completely. 2013-06-26 13:36:16 +00:00
test-lock.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-lockers.cc Clean up the usage of V8_TARGET_ARCH_${arch} and V8_HOST_ARCH_${arch} 2013-06-28 15:34:48 +00:00
test-log-stack-tracer.cc remove all old style callbacks - patch 3 2013-06-20 12:28:27 +00:00
test-log.cc CPUProfiler: fix for test. 2013-06-24 13:03:19 +00:00
test-macro-assembler-x64.cc Clean up the usage of V8_TARGET_ARCH_${arch} and V8_HOST_ARCH_${arch} 2013-06-28 15:34:48 +00:00
test-mark-compact.cc Relax test constraints from r15439 (Join threads after stopping). 2013-07-02 09:59:08 +00:00
test-object-observe.cc remove most uses of raw handle constructors 2013-06-13 09:27:09 +00:00
test-parsing.cc Add initial parser support for harmony iteration 2013-06-06 14:38:26 +00:00
test-platform-linux.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-platform-macos.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-platform-nullos.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-platform-tls.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-platform-win32.cc Make gyp work with MingW32 2013-04-15 08:33:31 +00:00
test-platform.cc Determine number of available cores on all platforms. 2013-02-15 12:38:59 +00:00
test-profile-generator.cc CPUProfiler: propagate scriptId to the front-end 2013-07-02 06:14:01 +00:00
test-random.cc Deprecate FACTORY helper macro. 2013-06-04 10:30:05 +00:00
test-regexp.cc Clean up the usage of V8_TARGET_ARCH_${arch} and V8_HOST_ARCH_${arch} 2013-06-28 15:34:48 +00:00
test-reloc-info.cc Merge experimental/gc branch to the bleeding_edge. 2011-09-19 18:36:47 +00:00
test-serialize.cc Remove unused counters 2013-06-19 16:50:38 +00:00
test-sockets.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-spaces.cc Use MemoryChunk-based allocation for deoptimization entry code 2013-01-29 09:09:55 +00:00
test-strings.cc Get rid of ZoneScope completely. 2013-06-26 13:36:16 +00:00
test-strtod.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-symbols.cc remove most V8_ALLOW_ACCESS_TO_* defines from test classes 2013-05-28 11:54:52 +00:00
test-thread-termination.cc remove all old style callbacks - patch 3 2013-06-20 12:28:27 +00:00
test-threads.cc remove most V8_ALLOW_ACCESS_TO_* defines from test classes 2013-05-28 11:54:52 +00:00
test-types.cc Introduce Unsigned32 and RegExp types 2013-06-26 09:51:57 +00:00
test-unbound-queue.cc Add missing license headers. 2013-03-07 11:12:26 +00:00
test-utils.cc Replace OS::MemCopy with OS::MemMove (just as fast but more flexible). 2013-04-16 12:30:51 +00:00
test-version.cc Update V8 to version 3.0 (re-land r5920). 2010-12-07 11:31:57 +00:00
test-weakmaps.cc remove old MakeWeak 2013-06-03 08:17:04 +00:00
test-weaktypedarrays.cc API for DataView. 2013-06-24 11:23:50 +00:00
testcfg.py Remove SCons related files 2013-04-18 11:01:14 +00:00