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

Side by Side Diff: runtime/vm/flow_graph_compiler.cc

Issue 15563007: Remove an unnecessary setter. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 7 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 (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_XXX. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_XXX.
6 6
7 #include "vm/flow_graph_compiler.h" 7 #include "vm/flow_graph_compiler.h"
8 8
9 #include "vm/cha.h" 9 #include "vm/cha.h"
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 ASSERT(Code::kSCallTableFunctionEntry == 1); 331 ASSERT(Code::kSCallTableFunctionEntry == 1);
332 static_calls_target_table_.Add(func); 332 static_calls_target_table_.Add(func);
333 ASSERT(Code::kSCallTableCodeEntry == 2); 333 ASSERT(Code::kSCallTableCodeEntry == 2);
334 static_calls_target_table_.Add(Code::Handle()); 334 static_calls_target_table_.Add(Code::Handle());
335 } 335 }
336 336
337 337
338 void FlowGraphCompiler::AddDeoptIndexAtCall(intptr_t deopt_id, 338 void FlowGraphCompiler::AddDeoptIndexAtCall(intptr_t deopt_id,
339 intptr_t token_pos) { 339 intptr_t token_pos) {
340 ASSERT(is_optimizing()); 340 ASSERT(is_optimizing());
341 CompilerDeoptInfo* info = new CompilerDeoptInfo(deopt_id, kDeoptAtCall); 341 CompilerDeoptInfo* info =
342 ASSERT(pending_deoptimization_env_ != NULL); 342 new CompilerDeoptInfo(deopt_id,
343 info->set_deoptimization_env(pending_deoptimization_env_); 343 kDeoptAtCall,
344 pending_deoptimization_env_);
344 info->set_pc_offset(assembler()->CodeSize()); 345 info->set_pc_offset(assembler()->CodeSize());
345 deopt_infos_.Add(info); 346 deopt_infos_.Add(info);
346 } 347 }
347 348
348 349
349 void FlowGraphCompiler::RecordSafepoint(LocationSummary* locs) { 350 void FlowGraphCompiler::RecordSafepoint(LocationSummary* locs) {
350 if (is_optimizing()) { 351 if (is_optimizing()) {
351 BitmapBuilder* bitmap = locs->stack_bitmap(); 352 BitmapBuilder* bitmap = locs->stack_bitmap();
352 ASSERT(bitmap != NULL); 353 ASSERT(bitmap != NULL);
353 ASSERT(bitmap->Length() <= StackSize()); 354 ASSERT(bitmap->Length() <= StackSize());
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 intptr_t register_bit_count = bitmap->Length() - StackSize(); 393 intptr_t register_bit_count = bitmap->Length() - StackSize();
393 stackmap_table_builder_->AddEntry(assembler()->CodeSize(), 394 stackmap_table_builder_->AddEntry(assembler()->CodeSize(),
394 bitmap, 395 bitmap,
395 register_bit_count); 396 register_bit_count);
396 } 397 }
397 } 398 }
398 399
399 400
400 Label* FlowGraphCompiler::AddDeoptStub(intptr_t deopt_id, 401 Label* FlowGraphCompiler::AddDeoptStub(intptr_t deopt_id,
401 DeoptReasonId reason) { 402 DeoptReasonId reason) {
403 ASSERT(is_optimizing_);
402 CompilerDeoptInfoWithStub* stub = 404 CompilerDeoptInfoWithStub* stub =
403 new CompilerDeoptInfoWithStub(deopt_id, reason); 405 new CompilerDeoptInfoWithStub(deopt_id,
404 ASSERT(is_optimizing_); 406 reason,
405 ASSERT(pending_deoptimization_env_ != NULL); 407 pending_deoptimization_env_);
406 stub->set_deoptimization_env(pending_deoptimization_env_);
407 deopt_infos_.Add(stub); 408 deopt_infos_.Add(stub);
408 return stub->entry_label(); 409 return stub->entry_label();
409 } 410 }
410 411
411 412
412 void FlowGraphCompiler::FinalizeExceptionHandlers(const Code& code) { 413 void FlowGraphCompiler::FinalizeExceptionHandlers(const Code& code) {
413 ASSERT(exception_handlers_list_ != NULL); 414 ASSERT(exception_handlers_list_ != NULL);
414 const ExceptionHandlers& handlers = ExceptionHandlers::Handle( 415 const ExceptionHandlers& handlers = ExceptionHandlers::Handle(
415 exception_handlers_list_->FinalizeExceptionHandlers(code.EntryPoint())); 416 exception_handlers_list_->FinalizeExceptionHandlers(code.EntryPoint()));
416 code.set_exception_handlers(handlers); 417 code.set_exception_handlers(handlers);
(...skipping 663 matching lines...) Expand 10 before | Expand all | Expand 10 after
1080 1081
1081 for (int i = 0; i < len; i++) { 1082 for (int i = 0; i < len; i++) {
1082 sorted->Add(CidTarget(ic_data.GetReceiverClassIdAt(i), 1083 sorted->Add(CidTarget(ic_data.GetReceiverClassIdAt(i),
1083 &Function::ZoneHandle(ic_data.GetTargetAt(i)), 1084 &Function::ZoneHandle(ic_data.GetTargetAt(i)),
1084 ic_data.GetCountAt(i))); 1085 ic_data.GetCountAt(i)));
1085 } 1086 }
1086 sorted->Sort(HighestCountFirst); 1087 sorted->Sort(HighestCountFirst);
1087 } 1088 }
1088 1089
1089 } // namespace dart 1090 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698