Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(586)

Side by Side Diff: test/cctest/test-log-stack-tracer.cc

Issue 2137008: Reapply r4686: Complete version of full codegen for x64.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/x64/macro-assembler-x64.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2009 the V8 project authors. All rights reserved. 1 // Copyright 2006-2009 the V8 project authors. All rights reserved.
2 // 2 //
3 // Tests of profiler-related functions from log.h 3 // Tests of profiler-related functions from log.h
4 4
5 #ifdef ENABLE_LOGGING_AND_PROFILING 5 #ifdef ENABLE_LOGGING_AND_PROFILING
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 8
9 #include "v8.h" 9 #include "v8.h"
10 10
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after
266 SetGlobalProperty(func_name, v8::ToApi<Value>(func)); 266 SetGlobalProperty(func_name, v8::ToApi<Value>(func));
267 CHECK_EQ(*func, *GetGlobalJSFunction(func_name)); 267 CHECK_EQ(*func, *GetGlobalJSFunction(func_name));
268 } 268 }
269 269
270 270
271 // This test verifies that stack tracing works when called during 271 // This test verifies that stack tracing works when called during
272 // execution of a native function called from JS code. In this case, 272 // execution of a native function called from JS code. In this case,
273 // StackTracer uses Top::c_entry_fp as a starting point for stack 273 // StackTracer uses Top::c_entry_fp as a starting point for stack
274 // walking. 274 // walking.
275 TEST(CFromJSStackTrace) { 275 TEST(CFromJSStackTrace) {
276 #ifdef V8_HOST_ARCH_IA32 276 #if defined(V8_HOST_ARCH_IA32) || defined(V8_HOST_ARCH_X64)
277 // TODO(711) The hack of replacing the inline runtime function 277 // TODO(711) The hack of replacing the inline runtime function
278 // RandomHeapNumber with GetFrameNumber does not work with the way the full 278 // RandomHeapNumber with GetFrameNumber does not work with the way the full
279 // compiler generates inline runtime calls. 279 // compiler generates inline runtime calls.
280 i::FLAG_force_full_compiler = false; 280 i::FLAG_force_full_compiler = false;
281 #endif 281 #endif
282 282
283 TickSample sample; 283 TickSample sample;
284 InitTraceEnv(&sample); 284 InitTraceEnv(&sample);
285 285
286 InitializeVM(); 286 InitializeVM();
(...skipping 21 matching lines...) Expand all
308 CheckObjectIsJSFunction("JSTrace", sample.stack[1]); 308 CheckObjectIsJSFunction("JSTrace", sample.stack[1]);
309 } 309 }
310 310
311 311
312 // This test verifies that stack tracing works when called during 312 // This test verifies that stack tracing works when called during
313 // execution of JS code. However, as calling StackTracer requires 313 // execution of JS code. However, as calling StackTracer requires
314 // entering native code, we can only emulate pure JS by erasing 314 // entering native code, we can only emulate pure JS by erasing
315 // Top::c_entry_fp value. In this case, StackTracer uses passed frame 315 // Top::c_entry_fp value. In this case, StackTracer uses passed frame
316 // pointer value as a starting point for stack walking. 316 // pointer value as a starting point for stack walking.
317 TEST(PureJSStackTrace) { 317 TEST(PureJSStackTrace) {
318 #ifdef V8_HOST_ARCH_IA32 318 #if defined(V8_HOST_ARCH_IA32) || defined(V8_HOST_ARCH_X64)
319 // TODO(711) The hack of replacing the inline runtime function 319 // TODO(711) The hack of replacing the inline runtime function
320 // RandomHeapNumber with GetFrameNumber does not work with the way the full 320 // RandomHeapNumber with GetFrameNumber does not work with the way the full
321 // compiler generates inline runtime calls. 321 // compiler generates inline runtime calls.
322 i::FLAG_force_full_compiler = false; 322 i::FLAG_force_full_compiler = false;
323 #endif 323 #endif
324 324
325 TickSample sample; 325 TickSample sample;
326 InitTraceEnv(&sample); 326 InitTraceEnv(&sample);
327 327
328 InitializeVM(); 328 InitializeVM();
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
402 CHECK_EQ(0, GetJsEntrySp()); 402 CHECK_EQ(0, GetJsEntrySp());
403 CompileRun("a = 1; b = a + 1;"); 403 CompileRun("a = 1; b = a + 1;");
404 CHECK_EQ(0, GetJsEntrySp()); 404 CHECK_EQ(0, GetJsEntrySp());
405 CompileRun("js_entry_sp();"); 405 CompileRun("js_entry_sp();");
406 CHECK_EQ(0, GetJsEntrySp()); 406 CHECK_EQ(0, GetJsEntrySp());
407 CompileRun("js_entry_sp_level2();"); 407 CompileRun("js_entry_sp_level2();");
408 CHECK_EQ(0, GetJsEntrySp()); 408 CHECK_EQ(0, GetJsEntrySp());
409 } 409 }
410 410
411 #endif // ENABLE_LOGGING_AND_PROFILING 411 #endif // ENABLE_LOGGING_AND_PROFILING
OLDNEW
« no previous file with comments | « src/x64/macro-assembler-x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698