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

Side by Side Diff: src/deoptimizer.cc

Issue 6066010: Merge 6095:6198 from bleeding_edge to experimental/gc. (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/gc/
Patch Set: Created 9 years, 11 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/deoptimizer.h ('k') | src/factory.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 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 MemoryAllocator::Free(eager_deoptimization_entry_code_); 302 MemoryAllocator::Free(eager_deoptimization_entry_code_);
303 eager_deoptimization_entry_code_ = NULL; 303 eager_deoptimization_entry_code_ = NULL;
304 } 304 }
305 if (lazy_deoptimization_entry_code_ != NULL) { 305 if (lazy_deoptimization_entry_code_ != NULL) {
306 MemoryAllocator::Free(lazy_deoptimization_entry_code_); 306 MemoryAllocator::Free(lazy_deoptimization_entry_code_);
307 lazy_deoptimization_entry_code_ = NULL; 307 lazy_deoptimization_entry_code_ = NULL;
308 } 308 }
309 } 309 }
310 310
311 311
312 unsigned Deoptimizer::GetOutputInfo(DeoptimizationOutputData* data, 312 int Deoptimizer::GetOutputInfo(DeoptimizationOutputData* data,
313 unsigned id, 313 unsigned id,
314 SharedFunctionInfo* shared) { 314 SharedFunctionInfo* shared) {
315 // TODO(kasperl): For now, we do a simple linear search for the PC 315 // TODO(kasperl): For now, we do a simple linear search for the PC
316 // offset associated with the given node id. This should probably be 316 // offset associated with the given node id. This should probably be
317 // changed to a binary search. 317 // changed to a binary search.
318 int length = data->DeoptPoints(); 318 int length = data->DeoptPoints();
319 Smi* smi_id = Smi::FromInt(id); 319 Smi* smi_id = Smi::FromInt(id);
320 for (int i = 0; i < length; i++) { 320 for (int i = 0; i < length; i++) {
321 if (data->AstId(i) == smi_id) { 321 if (data->AstId(i) == smi_id) {
322 return data->PcAndState(i)->value(); 322 return data->PcAndState(i)->value();
323 } 323 }
324 } 324 }
(...skipping 814 matching lines...) Expand 10 before | Expand all | Expand 10 after
1139 Deoptimizer::HandleWeakDeoptimizedCode); 1139 Deoptimizer::HandleWeakDeoptimizedCode);
1140 } 1140 }
1141 1141
1142 1142
1143 DeoptimizingCodeListNode::~DeoptimizingCodeListNode() { 1143 DeoptimizingCodeListNode::~DeoptimizingCodeListNode() {
1144 GlobalHandles::Destroy(reinterpret_cast<Object**>(code_.location())); 1144 GlobalHandles::Destroy(reinterpret_cast<Object**>(code_.location()));
1145 } 1145 }
1146 1146
1147 1147
1148 } } // namespace v8::internal 1148 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/deoptimizer.h ('k') | src/factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698