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

Side by Side Diff: src/frames.cc

Issue 15691017: Make assertion scopes thread safe. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 6 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
« src/api.cc ('K') | « src/factory.cc ('k') | src/handles.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 759 matching lines...) Expand 10 before | Expand all | Expand 10 after
770 functions->Add(summary); 770 functions->Add(summary);
771 } 771 }
772 772
773 773
774 void JavaScriptFrame::PrintTop(Isolate* isolate, 774 void JavaScriptFrame::PrintTop(Isolate* isolate,
775 FILE* file, 775 FILE* file,
776 bool print_args, 776 bool print_args,
777 bool print_line_number) { 777 bool print_line_number) {
778 // constructor calls 778 // constructor calls
779 HandleScope scope(isolate); 779 HandleScope scope(isolate);
780 AssertNoAllocation no_allocation; 780 DisallowHeapAllocation no_allocation;
781 JavaScriptFrameIterator it(isolate); 781 JavaScriptFrameIterator it(isolate);
782 while (!it.done()) { 782 while (!it.done()) {
783 if (it.frame()->is_java_script()) { 783 if (it.frame()->is_java_script()) {
784 JavaScriptFrame* frame = it.frame(); 784 JavaScriptFrame* frame = it.frame();
785 if (frame->IsConstructor()) PrintF(file, "new "); 785 if (frame->IsConstructor()) PrintF(file, "new ");
786 // function name 786 // function name
787 Object* maybe_fun = frame->function(); 787 Object* maybe_fun = frame->function();
788 if (maybe_fun->IsJSFunction()) { 788 if (maybe_fun->IsJSFunction()) {
789 JSFunction* fun = JSFunction::cast(maybe_fun); 789 JSFunction* fun = JSFunction::cast(maybe_fun);
790 fun->PrintName(); 790 fun->PrintName();
(...skipping 823 matching lines...) Expand 10 before | Expand all | Expand 10 after
1614 ZoneList<StackFrame*> list(10, zone); 1614 ZoneList<StackFrame*> list(10, zone);
1615 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) { 1615 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) {
1616 StackFrame* frame = AllocateFrameCopy(it.frame(), zone); 1616 StackFrame* frame = AllocateFrameCopy(it.frame(), zone);
1617 list.Add(frame, zone); 1617 list.Add(frame, zone);
1618 } 1618 }
1619 return list.ToVector(); 1619 return list.ToVector();
1620 } 1620 }
1621 1621
1622 1622
1623 } } // namespace v8::internal 1623 } } // namespace v8::internal
OLDNEW
« src/api.cc ('K') | « src/factory.cc ('k') | src/handles.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698