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

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

Issue 6628012: Refactor polymorphic load and inline function graph construction. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 9 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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 : chunk_(chunk), 49 : chunk_(chunk),
50 masm_(assembler), 50 masm_(assembler),
51 info_(info), 51 info_(info),
52 current_block_(-1), 52 current_block_(-1),
53 current_instruction_(-1), 53 current_instruction_(-1),
54 instructions_(chunk->instructions()), 54 instructions_(chunk->instructions()),
55 deoptimizations_(4), 55 deoptimizations_(4),
56 jump_table_(4), 56 jump_table_(4),
57 deoptimization_literals_(8), 57 deoptimization_literals_(8),
58 inlined_function_count_(0), 58 inlined_function_count_(0),
59 scope_(chunk->graph()->info()->scope()), 59 scope_(info->scope()),
60 status_(UNUSED), 60 status_(UNUSED),
61 deferred_(8), 61 deferred_(8),
62 osr_pc_offset_(-1), 62 osr_pc_offset_(-1),
63 resolver_(this) { 63 resolver_(this) {
64 PopulateDeoptimizationLiteralsWithInlinedFunctions(); 64 PopulateDeoptimizationLiteralsWithInlinedFunctions();
65 } 65 }
66 66
67 // Simple accessors. 67 // Simple accessors.
68 MacroAssembler* masm() const { return masm_; } 68 MacroAssembler* masm() const { return masm_; }
69 CompilationInfo* info() const { return info_; }
69 70
70 // Support for converting LOperands to assembler types. 71 // Support for converting LOperands to assembler types.
71 Register ToRegister(LOperand* op) const; 72 Register ToRegister(LOperand* op) const;
72 XMMRegister ToDoubleRegister(LOperand* op) const; 73 XMMRegister ToDoubleRegister(LOperand* op) const;
73 bool IsInteger32Constant(LConstantOperand* op) const; 74 bool IsInteger32Constant(LConstantOperand* op) const;
74 int ToInteger32(LConstantOperand* op) const; 75 int ToInteger32(LConstantOperand* op) const;
75 bool IsTaggedConstant(LConstantOperand* op) const; 76 bool IsTaggedConstant(LConstantOperand* op) const;
76 Handle<Object> ToHandle(LConstantOperand* op) const; 77 Handle<Object> ToHandle(LConstantOperand* op) const;
77 Operand ToOperand(LOperand* op) const; 78 Operand ToOperand(LOperand* op) const;
78 79
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 DONE, 113 DONE,
113 ABORTED 114 ABORTED
114 }; 115 };
115 116
116 bool is_unused() const { return status_ == UNUSED; } 117 bool is_unused() const { return status_ == UNUSED; }
117 bool is_generating() const { return status_ == GENERATING; } 118 bool is_generating() const { return status_ == GENERATING; }
118 bool is_done() const { return status_ == DONE; } 119 bool is_done() const { return status_ == DONE; }
119 bool is_aborted() const { return status_ == ABORTED; } 120 bool is_aborted() const { return status_ == ABORTED; }
120 121
121 int strict_mode_flag() const { 122 int strict_mode_flag() const {
122 return info_->is_strict() ? kStrictMode : kNonStrictMode; 123 return info()->is_strict() ? kStrictMode : kNonStrictMode;
123 } 124 }
124 125
125 LChunk* chunk() const { return chunk_; } 126 LChunk* chunk() const { return chunk_; }
126 Scope* scope() const { return scope_; } 127 Scope* scope() const { return scope_; }
127 HGraph* graph() const { return chunk_->graph(); } 128 HGraph* graph() const { return chunk_->graph(); }
128 129
129 int GetNextEmittedBlock(int block); 130 int GetNextEmittedBlock(int block);
130 LInstruction* GetNextInstruction(); 131 LInstruction* GetNextInstruction();
131 132
132 void EmitClassOfTest(Label* if_true, 133 void EmitClassOfTest(Label* if_true,
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 private: 297 private:
297 LCodeGen* codegen_; 298 LCodeGen* codegen_;
298 Label entry_; 299 Label entry_;
299 Label exit_; 300 Label exit_;
300 Label* external_exit_; 301 Label* external_exit_;
301 }; 302 };
302 303
303 } } // namespace v8::internal 304 } } // namespace v8::internal
304 305
305 #endif // V8_X64_LITHIUM_CODEGEN_X64_H_ 306 #endif // V8_X64_LITHIUM_CODEGEN_X64_H_
OLDNEW
« src/hydrogen.cc ('K') | « src/lithium-allocator.cc ('k') | src/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698