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

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

Issue 10534139: One Zone per CompilationInfo. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rename CompilationInfoZone to ZoneWithCompilationInfo 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/x64/full-codegen-x64.cc ('k') | src/zone.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 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 27 matching lines...) Expand all
38 38
39 namespace v8 { 39 namespace v8 {
40 namespace internal { 40 namespace internal {
41 41
42 // Forward declarations. 42 // Forward declarations.
43 class LDeferredCode; 43 class LDeferredCode;
44 class SafepointGenerator; 44 class SafepointGenerator;
45 45
46 class LCodeGen BASE_EMBEDDED { 46 class LCodeGen BASE_EMBEDDED {
47 public: 47 public:
48 LCodeGen(LChunk* chunk, MacroAssembler* assembler, CompilationInfo* info, 48 LCodeGen(LChunk* chunk, MacroAssembler* assembler, CompilationInfo* info)
49 Zone* zone) 49 : zone_(info->zone()),
50 : chunk_(chunk), 50 chunk_(chunk),
51 masm_(assembler), 51 masm_(assembler),
52 info_(info), 52 info_(info),
53 current_block_(-1), 53 current_block_(-1),
54 current_instruction_(-1), 54 current_instruction_(-1),
55 instructions_(chunk->instructions()), 55 instructions_(chunk->instructions()),
56 deoptimizations_(4, zone), 56 deoptimizations_(4, info->zone()),
57 jump_table_(4, zone), 57 jump_table_(4, info->zone()),
58 deoptimization_literals_(8, zone), 58 deoptimization_literals_(8, info->zone()),
59 inlined_function_count_(0), 59 inlined_function_count_(0),
60 scope_(info->scope()), 60 scope_(info->scope()),
61 status_(UNUSED), 61 status_(UNUSED),
62 translations_(zone), 62 translations_(info->zone()),
63 deferred_(8, zone), 63 deferred_(8, info->zone()),
64 osr_pc_offset_(-1), 64 osr_pc_offset_(-1),
65 last_lazy_deopt_pc_(0), 65 last_lazy_deopt_pc_(0),
66 safepoints_(zone), 66 safepoints_(info->zone()),
67 zone_(zone),
68 resolver_(this), 67 resolver_(this),
69 expected_safepoint_kind_(Safepoint::kSimple) { 68 expected_safepoint_kind_(Safepoint::kSimple) {
70 PopulateDeoptimizationLiteralsWithInlinedFunctions(); 69 PopulateDeoptimizationLiteralsWithInlinedFunctions();
71 } 70 }
72 71
73 // Simple accessors. 72 // Simple accessors.
74 MacroAssembler* masm() const { return masm_; } 73 MacroAssembler* masm() const { return masm_; }
75 CompilationInfo* info() const { return info_; } 74 CompilationInfo* info() const { return info_; }
76 Isolate* isolate() const { return info_->isolate(); } 75 Isolate* isolate() const { return info_->isolate(); }
77 Factory* factory() const { return isolate()->factory(); } 76 Factory* factory() const { return isolate()->factory(); }
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 struct JumpTableEntry { 317 struct JumpTableEntry {
319 explicit inline JumpTableEntry(Address entry) 318 explicit inline JumpTableEntry(Address entry)
320 : label(), 319 : label(),
321 address(entry) { } 320 address(entry) { }
322 Label label; 321 Label label;
323 Address address; 322 Address address;
324 }; 323 };
325 324
326 void EnsureSpaceForLazyDeopt(int space_needed); 325 void EnsureSpaceForLazyDeopt(int space_needed);
327 326
327 Zone* zone_;
328 LChunk* const chunk_; 328 LChunk* const chunk_;
329 MacroAssembler* const masm_; 329 MacroAssembler* const masm_;
330 CompilationInfo* const info_; 330 CompilationInfo* const info_;
331 331
332 int current_block_; 332 int current_block_;
333 int current_instruction_; 333 int current_instruction_;
334 const ZoneList<LInstruction*>* instructions_; 334 const ZoneList<LInstruction*>* instructions_;
335 ZoneList<LEnvironment*> deoptimizations_; 335 ZoneList<LEnvironment*> deoptimizations_;
336 ZoneList<JumpTableEntry> jump_table_; 336 ZoneList<JumpTableEntry> jump_table_;
337 ZoneList<Handle<Object> > deoptimization_literals_; 337 ZoneList<Handle<Object> > deoptimization_literals_;
338 int inlined_function_count_; 338 int inlined_function_count_;
339 Scope* const scope_; 339 Scope* const scope_;
340 Status status_; 340 Status status_;
341 TranslationBuffer translations_; 341 TranslationBuffer translations_;
342 ZoneList<LDeferredCode*> deferred_; 342 ZoneList<LDeferredCode*> deferred_;
343 int osr_pc_offset_; 343 int osr_pc_offset_;
344 int last_lazy_deopt_pc_; 344 int last_lazy_deopt_pc_;
345 345
346 // Builder that keeps track of safepoints in the code. The table 346 // Builder that keeps track of safepoints in the code. The table
347 // itself is emitted at the end of the generated code. 347 // itself is emitted at the end of the generated code.
348 SafepointTableBuilder safepoints_; 348 SafepointTableBuilder safepoints_;
349 349
350 Zone* zone_;
351
352 // Compiler from a set of parallel moves to a sequential list of moves. 350 // Compiler from a set of parallel moves to a sequential list of moves.
353 LGapResolver resolver_; 351 LGapResolver resolver_;
354 352
355 Safepoint::Kind expected_safepoint_kind_; 353 Safepoint::Kind expected_safepoint_kind_;
356 354
357 class PushSafepointRegistersScope BASE_EMBEDDED { 355 class PushSafepointRegistersScope BASE_EMBEDDED {
358 public: 356 public:
359 explicit PushSafepointRegistersScope(LCodeGen* codegen) 357 explicit PushSafepointRegistersScope(LCodeGen* codegen)
360 : codegen_(codegen) { 358 : codegen_(codegen) {
361 ASSERT(codegen_->expected_safepoint_kind_ == Safepoint::kSimple); 359 ASSERT(codegen_->expected_safepoint_kind_ == Safepoint::kSimple);
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
406 LCodeGen* codegen_; 404 LCodeGen* codegen_;
407 Label entry_; 405 Label entry_;
408 Label exit_; 406 Label exit_;
409 Label* external_exit_; 407 Label* external_exit_;
410 int instruction_index_; 408 int instruction_index_;
411 }; 409 };
412 410
413 } } // namespace v8::internal 411 } } // namespace v8::internal
414 412
415 #endif // V8_X64_LITHIUM_CODEGEN_X64_H_ 413 #endif // V8_X64_LITHIUM_CODEGEN_X64_H_
OLDNEW
« no previous file with comments | « src/x64/full-codegen-x64.cc ('k') | src/zone.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698