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

Side by Side Diff: src/arm/lithium-codegen-arm.h

Issue 10443114: Progress towards making Zones independent of Isolates and Threads. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fix nits and rebase on current bleeding_edge Created 8 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/arm/lithium-arm.cc ('k') | src/arm/lithium-codegen-arm.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 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 25 matching lines...) Expand all
36 36
37 namespace v8 { 37 namespace v8 {
38 namespace internal { 38 namespace internal {
39 39
40 // Forward declarations. 40 // Forward declarations.
41 class LDeferredCode; 41 class LDeferredCode;
42 class SafepointGenerator; 42 class SafepointGenerator;
43 43
44 class LCodeGen BASE_EMBEDDED { 44 class LCodeGen BASE_EMBEDDED {
45 public: 45 public:
46 LCodeGen(LChunk* chunk, MacroAssembler* assembler, CompilationInfo* info) 46 LCodeGen(LChunk* chunk, MacroAssembler* assembler, CompilationInfo* info,
47 Zone* zone)
47 : chunk_(chunk), 48 : chunk_(chunk),
48 masm_(assembler), 49 masm_(assembler),
49 info_(info), 50 info_(info),
50 current_block_(-1), 51 current_block_(-1),
51 current_instruction_(-1), 52 current_instruction_(-1),
52 instructions_(chunk->instructions()), 53 instructions_(chunk->instructions()),
53 deoptimizations_(4), 54 deoptimizations_(4),
54 deopt_jump_table_(4), 55 deopt_jump_table_(4),
55 deoptimization_literals_(8), 56 deoptimization_literals_(8),
56 inlined_function_count_(0), 57 inlined_function_count_(0),
57 scope_(info->scope()), 58 scope_(info->scope()),
58 status_(UNUSED), 59 status_(UNUSED),
60 translations_(zone),
59 deferred_(8), 61 deferred_(8),
60 osr_pc_offset_(-1), 62 osr_pc_offset_(-1),
61 last_lazy_deopt_pc_(0), 63 last_lazy_deopt_pc_(0),
64 safepoints_(zone),
62 resolver_(this), 65 resolver_(this),
63 expected_safepoint_kind_(Safepoint::kSimple) { 66 expected_safepoint_kind_(Safepoint::kSimple),
67 zone_(zone) {
64 PopulateDeoptimizationLiteralsWithInlinedFunctions(); 68 PopulateDeoptimizationLiteralsWithInlinedFunctions();
65 } 69 }
66 70
67 71
68 // Simple accessors. 72 // Simple accessors.
69 MacroAssembler* masm() const { return masm_; } 73 MacroAssembler* masm() const { return masm_; }
70 CompilationInfo* info() const { return info_; } 74 CompilationInfo* info() const { return info_; }
71 Isolate* isolate() const { return info_->isolate(); } 75 Isolate* isolate() const { return info_->isolate(); }
72 Factory* factory() const { return isolate()->factory(); } 76 Factory* factory() const { return isolate()->factory(); }
73 Heap* heap() const { return isolate()->heap(); } 77 Heap* heap() const { return isolate()->heap(); }
78 Zone* zone() const { return zone_; }
74 79
75 // Support for converting LOperands to assembler types. 80 // Support for converting LOperands to assembler types.
76 // LOperand must be a register. 81 // LOperand must be a register.
77 Register ToRegister(LOperand* op) const; 82 Register ToRegister(LOperand* op) const;
78 83
79 // LOperand is loaded into scratch, unless already a register. 84 // LOperand is loaded into scratch, unless already a register.
80 Register EmitLoadRegister(LOperand* op, Register scratch); 85 Register EmitLoadRegister(LOperand* op, Register scratch);
81 86
82 // LOperand must be a double register. 87 // LOperand must be a double register.
83 DoubleRegister ToDoubleRegister(LOperand* op) const; 88 DoubleRegister ToDoubleRegister(LOperand* op) const;
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 369
365 // Builder that keeps track of safepoints in the code. The table 370 // Builder that keeps track of safepoints in the code. The table
366 // itself is emitted at the end of the generated code. 371 // itself is emitted at the end of the generated code.
367 SafepointTableBuilder safepoints_; 372 SafepointTableBuilder safepoints_;
368 373
369 // Compiler from a set of parallel moves to a sequential list of moves. 374 // Compiler from a set of parallel moves to a sequential list of moves.
370 LGapResolver resolver_; 375 LGapResolver resolver_;
371 376
372 Safepoint::Kind expected_safepoint_kind_; 377 Safepoint::Kind expected_safepoint_kind_;
373 378
379 Zone* zone_;
380
374 class PushSafepointRegistersScope BASE_EMBEDDED { 381 class PushSafepointRegistersScope BASE_EMBEDDED {
375 public: 382 public:
376 PushSafepointRegistersScope(LCodeGen* codegen, 383 PushSafepointRegistersScope(LCodeGen* codegen,
377 Safepoint::Kind kind) 384 Safepoint::Kind kind)
378 : codegen_(codegen) { 385 : codegen_(codegen) {
379 ASSERT(codegen_->expected_safepoint_kind_ == Safepoint::kSimple); 386 ASSERT(codegen_->expected_safepoint_kind_ == Safepoint::kSimple);
380 codegen_->expected_safepoint_kind_ = kind; 387 codegen_->expected_safepoint_kind_ = kind;
381 388
382 switch (codegen_->expected_safepoint_kind_) { 389 switch (codegen_->expected_safepoint_kind_) {
383 case Safepoint::kWithRegisters: 390 case Safepoint::kWithRegisters:
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 LCodeGen* codegen_; 451 LCodeGen* codegen_;
445 Label entry_; 452 Label entry_;
446 Label exit_; 453 Label exit_;
447 Label* external_exit_; 454 Label* external_exit_;
448 int instruction_index_; 455 int instruction_index_;
449 }; 456 };
450 457
451 } } // namespace v8::internal 458 } } // namespace v8::internal
452 459
453 #endif // V8_ARM_LITHIUM_CODEGEN_ARM_H_ 460 #endif // V8_ARM_LITHIUM_CODEGEN_ARM_H_
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698