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

Side by Side Diff: src/x64/deoptimizer-x64.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
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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 int Deoptimizer::patch_size() { 44 int Deoptimizer::patch_size() {
45 return Assembler::kCallInstructionLength; 45 return Assembler::kCallInstructionLength;
46 } 46 }
47 47
48 48
49 void Deoptimizer::DeoptimizeFunctionWithPreparedFunctionList( 49 void Deoptimizer::DeoptimizeFunctionWithPreparedFunctionList(
50 JSFunction* function) { 50 JSFunction* function) {
51 Isolate* isolate = function->GetIsolate(); 51 Isolate* isolate = function->GetIsolate();
52 HandleScope scope(isolate); 52 HandleScope scope(isolate);
53 AssertNoAllocation no_allocation; 53 DisallowHeapAllocation nha;
54 54
55 ASSERT(function->IsOptimized()); 55 ASSERT(function->IsOptimized());
56 ASSERT(function->FunctionsInFunctionListShareSameCode()); 56 ASSERT(function->FunctionsInFunctionListShareSameCode());
57 57
58 // Get the optimized code. 58 // Get the optimized code.
59 Code* code = function->code(); 59 Code* code = function->code();
60 60
61 // The optimized code is going to be patched, so we cannot use it any more. 61 // The optimized code is going to be patched, so we cannot use it any more.
62 function->shared()->EvictFromOptimizedCodeMap(code, "deoptimized function"); 62 function->shared()->EvictFromOptimizedCodeMap(code, "deoptimized function");
63 63
(...skipping 554 matching lines...) Expand 10 before | Expand all | Expand 10 after
618 } 618 }
619 __ bind(&done); 619 __ bind(&done);
620 } 620 }
621 621
622 #undef __ 622 #undef __
623 623
624 624
625 } } // namespace v8::internal 625 } } // namespace v8::internal
626 626
627 #endif // V8_TARGET_ARCH_X64 627 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/api.cc ('K') | « src/x64/assembler-x64.cc ('k') | src/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698