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

Side by Side Diff: src/code-stubs.cc

Issue 7084032: Add asserts and state tracking to ensure that we do not call (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 9 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
« no previous file with comments | « src/code-stubs.h ('k') | src/deoptimizer.cc » ('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 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 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 return true; 45 return true;
46 } 46 }
47 return false; 47 return false;
48 } 48 }
49 49
50 50
51 void CodeStub::GenerateCode(MacroAssembler* masm) { 51 void CodeStub::GenerateCode(MacroAssembler* masm) {
52 // Update the static counter each time a new code stub is generated. 52 // Update the static counter each time a new code stub is generated.
53 masm->isolate()->counters()->code_stubs()->Increment(); 53 masm->isolate()->counters()->code_stubs()->Increment();
54 54
55 // Nested stubs are not allowed for leafs. 55 // Nested stubs are not allowed for leaves.
56 AllowStubCallsScope allow_scope(masm, AllowsStubCalls()); 56 AllowStubCallsScope allow_scope(masm, false);
57 57
58 // Generate the code for the stub. 58 // Generate the code for the stub.
59 masm->set_generating_stub(true); 59 masm->set_generating_stub(true);
60 NoCurrentFrameScope scope(masm);
60 Generate(masm); 61 Generate(masm);
61 } 62 }
62 63
63 64
64 void CodeStub::RecordCodeGeneration(Code* code, MacroAssembler* masm) { 65 void CodeStub::RecordCodeGeneration(Code* code, MacroAssembler* masm) {
65 code->set_major_key(MajorKey()); 66 code->set_major_key(MajorKey());
66 67
67 Isolate* isolate = masm->isolate(); 68 Isolate* isolate = masm->isolate();
68 PROFILE(isolate, CodeCreateEvent(Logger::STUB_TAG, code, GetName())); 69 PROFILE(isolate, CodeCreateEvent(Logger::STUB_TAG, code, GetName()));
69 GDBJIT(AddCode(GDBJITInterface::STUB, GetName(), code)); 70 GDBJIT(AddCode(GDBJITInterface::STUB, GetName(), code));
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 KeyedLoadStubCompiler::GenerateLoadExternalArray(masm, array_type_); 259 KeyedLoadStubCompiler::GenerateLoadExternalArray(masm, array_type_);
259 } 260 }
260 261
261 262
262 void KeyedStoreExternalArrayStub::Generate(MacroAssembler* masm) { 263 void KeyedStoreExternalArrayStub::Generate(MacroAssembler* masm) {
263 KeyedStoreStubCompiler::GenerateStoreExternalArray(masm, array_type_); 264 KeyedStoreStubCompiler::GenerateStoreExternalArray(masm, array_type_);
264 } 265 }
265 266
266 267
267 } } // namespace v8::internal 268 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/code-stubs.h ('k') | src/deoptimizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698