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

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

Issue 2443573002: [compiler] Prepare for partially shipping Ignition. (Closed)
Patch Set: Rebased. Created 4 years, 1 month 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
« no previous file with comments | « src/log.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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 // from the calling function. When this function runs, the stack contains 74 // from the calling function. When this function runs, the stack contains
75 // a C_Entry frame and a Construct frame above the calling function's frame. 75 // a C_Entry frame and a Construct frame above the calling function's frame.
76 static void construct_call(const v8::FunctionCallbackInfo<v8::Value>& args) { 76 static void construct_call(const v8::FunctionCallbackInfo<v8::Value>& args) {
77 i::Isolate* isolate = reinterpret_cast<i::Isolate*>(args.GetIsolate()); 77 i::Isolate* isolate = reinterpret_cast<i::Isolate*>(args.GetIsolate());
78 i::StackFrameIterator frame_iterator(isolate); 78 i::StackFrameIterator frame_iterator(isolate);
79 CHECK(frame_iterator.frame()->is_exit() || 79 CHECK(frame_iterator.frame()->is_exit() ||
80 frame_iterator.frame()->is_builtin_exit()); 80 frame_iterator.frame()->is_builtin_exit());
81 frame_iterator.Advance(); 81 frame_iterator.Advance();
82 CHECK(frame_iterator.frame()->is_construct()); 82 CHECK(frame_iterator.frame()->is_construct());
83 frame_iterator.Advance(); 83 frame_iterator.Advance();
84 if (i::FLAG_ignition) { 84 if (frame_iterator.frame()->type() == i::StackFrame::STUB) {
85 // Skip over bytecode handler frame. 85 // Skip over bytecode handler frame.
86 CHECK(frame_iterator.frame()->type() == i::StackFrame::STUB);
87 frame_iterator.Advance(); 86 frame_iterator.Advance();
88 } 87 }
89 i::StackFrame* calling_frame = frame_iterator.frame(); 88 i::StackFrame* calling_frame = frame_iterator.frame();
90 CHECK(calling_frame->is_java_script()); 89 CHECK(calling_frame->is_java_script());
91 90
92 v8::Local<v8::Context> context = args.GetIsolate()->GetCurrentContext(); 91 v8::Local<v8::Context> context = args.GetIsolate()->GetCurrentContext();
93 #if defined(V8_HOST_ARCH_32_BIT) 92 #if defined(V8_HOST_ARCH_32_BIT)
94 int32_t low_bits = reinterpret_cast<int32_t>(calling_frame->fp()); 93 int32_t low_bits = reinterpret_cast<int32_t>(calling_frame->fp());
95 args.This() 94 args.This()
96 ->Set(context, v8_str("low_bits"), v8_num(low_bits >> 1)) 95 ->Set(context, v8_str("low_bits"), v8_num(low_bits >> 1))
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
289 v8::Local<v8::Context> context = CcTest::NewContext(TRACE_EXTENSION); 288 v8::Local<v8::Context> context = CcTest::NewContext(TRACE_EXTENSION);
290 v8::Context::Scope context_scope(context); 289 v8::Context::Scope context_scope(context);
291 CHECK(!i::TraceExtension::GetJsEntrySp()); 290 CHECK(!i::TraceExtension::GetJsEntrySp());
292 CompileRun("a = 1; b = a + 1;"); 291 CompileRun("a = 1; b = a + 1;");
293 CHECK(!i::TraceExtension::GetJsEntrySp()); 292 CHECK(!i::TraceExtension::GetJsEntrySp());
294 CompileRun("js_entry_sp();"); 293 CompileRun("js_entry_sp();");
295 CHECK(!i::TraceExtension::GetJsEntrySp()); 294 CHECK(!i::TraceExtension::GetJsEntrySp());
296 CompileRun("js_entry_sp_level2();"); 295 CompileRun("js_entry_sp_level2();");
297 CHECK(!i::TraceExtension::GetJsEntrySp()); 296 CHECK(!i::TraceExtension::GetJsEntrySp());
298 } 297 }
OLDNEW
« no previous file with comments | « src/log.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698