OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_MIPS_LITHIUM_MIPS_H_ | 5 #ifndef V8_MIPS_LITHIUM_MIPS_H_ |
6 #define V8_MIPS_LITHIUM_MIPS_H_ | 6 #define V8_MIPS_LITHIUM_MIPS_H_ |
7 | 7 |
8 #include "src/hydrogen.h" | 8 #include "src/hydrogen.h" |
9 #include "src/lithium.h" | 9 #include "src/lithium.h" |
10 #include "src/lithium-allocator.h" | 10 #include "src/lithium-allocator.h" |
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 V(ThisFunction) \ | 155 V(ThisFunction) \ |
156 V(ToFastProperties) \ | 156 V(ToFastProperties) \ |
157 V(TransitionElementsKind) \ | 157 V(TransitionElementsKind) \ |
158 V(TrapAllocationMemento) \ | 158 V(TrapAllocationMemento) \ |
159 V(Typeof) \ | 159 V(Typeof) \ |
160 V(TypeofIsAndBranch) \ | 160 V(TypeofIsAndBranch) \ |
161 V(Uint32ToDouble) \ | 161 V(Uint32ToDouble) \ |
162 V(UnknownOSRValue) \ | 162 V(UnknownOSRValue) \ |
163 V(WrapReceiver) | 163 V(WrapReceiver) |
164 | 164 |
165 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ | 165 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ |
166 virtual Opcode opcode() const FINAL OVERRIDE { \ | 166 Opcode opcode() const FINAL { return LInstruction::k##type; } \ |
167 return LInstruction::k##type; \ | 167 void CompileToNative(LCodeGen* generator) FINAL; \ |
168 } \ | 168 const char* Mnemonic() const FINAL { return mnemonic; } \ |
169 virtual void CompileToNative(LCodeGen* generator) FINAL OVERRIDE; \ | 169 static L##type* cast(LInstruction* instr) { \ |
170 virtual const char* Mnemonic() const FINAL OVERRIDE { \ | 170 DCHECK(instr->Is##type()); \ |
171 return mnemonic; \ | 171 return reinterpret_cast<L##type*>(instr); \ |
172 } \ | |
173 static L##type* cast(LInstruction* instr) { \ | |
174 DCHECK(instr->Is##type()); \ | |
175 return reinterpret_cast<L##type*>(instr); \ | |
176 } | 172 } |
177 | 173 |
178 | 174 |
179 #define DECLARE_HYDROGEN_ACCESSOR(type) \ | 175 #define DECLARE_HYDROGEN_ACCESSOR(type) \ |
180 H##type* hydrogen() const { \ | 176 H##type* hydrogen() const { \ |
181 return H##type::cast(hydrogen_value()); \ | 177 return H##type::cast(hydrogen_value()); \ |
182 } | 178 } |
183 | 179 |
184 | 180 |
185 class LInstruction : public ZoneObject { | 181 class LInstruction : public ZoneObject { |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
280 int bit_field_; | 276 int bit_field_; |
281 }; | 277 }; |
282 | 278 |
283 | 279 |
284 // R = number of result operands (0 or 1). | 280 // R = number of result operands (0 or 1). |
285 template<int R> | 281 template<int R> |
286 class LTemplateResultInstruction : public LInstruction { | 282 class LTemplateResultInstruction : public LInstruction { |
287 public: | 283 public: |
288 // Allow 0 or 1 output operands. | 284 // Allow 0 or 1 output operands. |
289 STATIC_ASSERT(R == 0 || R == 1); | 285 STATIC_ASSERT(R == 0 || R == 1); |
290 virtual bool HasResult() const FINAL OVERRIDE { | 286 bool HasResult() const FINAL { return R != 0 && result() != NULL; } |
291 return R != 0 && result() != NULL; | |
292 } | |
293 void set_result(LOperand* operand) { results_[0] = operand; } | 287 void set_result(LOperand* operand) { results_[0] = operand; } |
294 LOperand* result() const { return results_[0]; } | 288 LOperand* result() const OVERRIDE { return results_[0]; } |
295 | 289 |
296 protected: | 290 protected: |
297 EmbeddedContainer<LOperand*, R> results_; | 291 EmbeddedContainer<LOperand*, R> results_; |
298 }; | 292 }; |
299 | 293 |
300 | 294 |
301 // R = number of result operands (0 or 1). | 295 // R = number of result operands (0 or 1). |
302 // I = number of input operands. | 296 // I = number of input operands. |
303 // T = number of temporary operands. | 297 // T = number of temporary operands. |
304 template<int R, int I, int T> | 298 template<int R, int I, int T> |
305 class LTemplateInstruction : public LTemplateResultInstruction<R> { | 299 class LTemplateInstruction : public LTemplateResultInstruction<R> { |
306 protected: | 300 protected: |
307 EmbeddedContainer<LOperand*, I> inputs_; | 301 EmbeddedContainer<LOperand*, I> inputs_; |
308 EmbeddedContainer<LOperand*, T> temps_; | 302 EmbeddedContainer<LOperand*, T> temps_; |
309 | 303 |
310 private: | 304 private: |
311 // Iterator support. | 305 // Iterator support. |
312 virtual int InputCount() FINAL OVERRIDE { return I; } | 306 int InputCount() FINAL { return I; } |
313 virtual LOperand* InputAt(int i) FINAL OVERRIDE { return inputs_[i]; } | 307 LOperand* InputAt(int i) FINAL { return inputs_[i]; } |
314 | 308 |
315 virtual int TempCount() FINAL OVERRIDE { return T; } | 309 int TempCount() FINAL { return T; } |
316 virtual LOperand* TempAt(int i) FINAL OVERRIDE { return temps_[i]; } | 310 LOperand* TempAt(int i) FINAL { return temps_[i]; } |
317 }; | 311 }; |
318 | 312 |
319 | 313 |
320 class LGap : public LTemplateInstruction<0, 0, 0> { | 314 class LGap : public LTemplateInstruction<0, 0, 0> { |
321 public: | 315 public: |
322 explicit LGap(HBasicBlock* block) | 316 explicit LGap(HBasicBlock* block) |
323 : block_(block) { | 317 : block_(block) { |
324 parallel_moves_[BEFORE] = NULL; | 318 parallel_moves_[BEFORE] = NULL; |
325 parallel_moves_[START] = NULL; | 319 parallel_moves_[START] = NULL; |
326 parallel_moves_[END] = NULL; | 320 parallel_moves_[END] = NULL; |
327 parallel_moves_[AFTER] = NULL; | 321 parallel_moves_[AFTER] = NULL; |
328 } | 322 } |
329 | 323 |
330 // Can't use the DECLARE-macro here because of sub-classes. | 324 // Can't use the DECLARE-macro here because of sub-classes. |
331 virtual bool IsGap() const FINAL OVERRIDE { return true; } | 325 bool IsGap() const FINAL { return true; } |
332 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 326 void PrintDataTo(StringStream* stream) OVERRIDE; |
333 static LGap* cast(LInstruction* instr) { | 327 static LGap* cast(LInstruction* instr) { |
334 DCHECK(instr->IsGap()); | 328 DCHECK(instr->IsGap()); |
335 return reinterpret_cast<LGap*>(instr); | 329 return reinterpret_cast<LGap*>(instr); |
336 } | 330 } |
337 | 331 |
338 bool IsRedundant() const; | 332 bool IsRedundant() const; |
339 | 333 |
340 HBasicBlock* block() const { return block_; } | 334 HBasicBlock* block() const { return block_; } |
341 | 335 |
342 enum InnerPosition { | 336 enum InnerPosition { |
(...skipping 19 matching lines...) Expand all Loading... |
362 private: | 356 private: |
363 LParallelMove* parallel_moves_[LAST_INNER_POSITION + 1]; | 357 LParallelMove* parallel_moves_[LAST_INNER_POSITION + 1]; |
364 HBasicBlock* block_; | 358 HBasicBlock* block_; |
365 }; | 359 }; |
366 | 360 |
367 | 361 |
368 class LInstructionGap FINAL : public LGap { | 362 class LInstructionGap FINAL : public LGap { |
369 public: | 363 public: |
370 explicit LInstructionGap(HBasicBlock* block) : LGap(block) { } | 364 explicit LInstructionGap(HBasicBlock* block) : LGap(block) { } |
371 | 365 |
372 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 366 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { |
373 return !IsRedundant(); | 367 return !IsRedundant(); |
374 } | 368 } |
375 | 369 |
376 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap") | 370 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap") |
377 }; | 371 }; |
378 | 372 |
379 | 373 |
380 class LGoto FINAL : public LTemplateInstruction<0, 0, 0> { | 374 class LGoto FINAL : public LTemplateInstruction<0, 0, 0> { |
381 public: | 375 public: |
382 explicit LGoto(HBasicBlock* block) : block_(block) { } | 376 explicit LGoto(HBasicBlock* block) : block_(block) { } |
383 | 377 |
384 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE; | 378 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE; |
385 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto") | 379 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto") |
386 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 380 void PrintDataTo(StringStream* stream) OVERRIDE; |
387 virtual bool IsControl() const OVERRIDE { return true; } | 381 bool IsControl() const OVERRIDE { return true; } |
388 | 382 |
389 int block_id() const { return block_->block_id(); } | 383 int block_id() const { return block_->block_id(); } |
390 | 384 |
391 private: | 385 private: |
392 HBasicBlock* block_; | 386 HBasicBlock* block_; |
393 }; | 387 }; |
394 | 388 |
395 | 389 |
396 class LLazyBailout FINAL : public LTemplateInstruction<0, 0, 0> { | 390 class LLazyBailout FINAL : public LTemplateInstruction<0, 0, 0> { |
397 public: | 391 public: |
(...skipping 22 matching lines...) Expand all Loading... |
420 public: | 414 public: |
421 explicit LDummyUse(LOperand* value) { | 415 explicit LDummyUse(LOperand* value) { |
422 inputs_[0] = value; | 416 inputs_[0] = value; |
423 } | 417 } |
424 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use") | 418 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use") |
425 }; | 419 }; |
426 | 420 |
427 | 421 |
428 class LDeoptimize FINAL : public LTemplateInstruction<0, 0, 0> { | 422 class LDeoptimize FINAL : public LTemplateInstruction<0, 0, 0> { |
429 public: | 423 public: |
430 virtual bool IsControl() const OVERRIDE { return true; } | 424 bool IsControl() const OVERRIDE { return true; } |
431 DECLARE_CONCRETE_INSTRUCTION(Deoptimize, "deoptimize") | 425 DECLARE_CONCRETE_INSTRUCTION(Deoptimize, "deoptimize") |
432 DECLARE_HYDROGEN_ACCESSOR(Deoptimize) | 426 DECLARE_HYDROGEN_ACCESSOR(Deoptimize) |
433 }; | 427 }; |
434 | 428 |
435 | 429 |
436 class LLabel FINAL : public LGap { | 430 class LLabel FINAL : public LGap { |
437 public: | 431 public: |
438 explicit LLabel(HBasicBlock* block) | 432 explicit LLabel(HBasicBlock* block) |
439 : LGap(block), replacement_(NULL) { } | 433 : LGap(block), replacement_(NULL) { } |
440 | 434 |
441 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 435 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
442 return false; | |
443 } | |
444 DECLARE_CONCRETE_INSTRUCTION(Label, "label") | 436 DECLARE_CONCRETE_INSTRUCTION(Label, "label") |
445 | 437 |
446 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 438 void PrintDataTo(StringStream* stream) OVERRIDE; |
447 | 439 |
448 int block_id() const { return block()->block_id(); } | 440 int block_id() const { return block()->block_id(); } |
449 bool is_loop_header() const { return block()->IsLoopHeader(); } | 441 bool is_loop_header() const { return block()->IsLoopHeader(); } |
450 bool is_osr_entry() const { return block()->is_osr_entry(); } | 442 bool is_osr_entry() const { return block()->is_osr_entry(); } |
451 Label* label() { return &label_; } | 443 Label* label() { return &label_; } |
452 LLabel* replacement() const { return replacement_; } | 444 LLabel* replacement() const { return replacement_; } |
453 void set_replacement(LLabel* label) { replacement_ = label; } | 445 void set_replacement(LLabel* label) { replacement_ = label; } |
454 bool HasReplacement() const { return replacement_ != NULL; } | 446 bool HasReplacement() const { return replacement_ != NULL; } |
455 | 447 |
456 private: | 448 private: |
457 Label label_; | 449 Label label_; |
458 LLabel* replacement_; | 450 LLabel* replacement_; |
459 }; | 451 }; |
460 | 452 |
461 | 453 |
462 class LParameter FINAL : public LTemplateInstruction<1, 0, 0> { | 454 class LParameter FINAL : public LTemplateInstruction<1, 0, 0> { |
463 public: | 455 public: |
464 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 456 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
465 return false; | |
466 } | |
467 DECLARE_CONCRETE_INSTRUCTION(Parameter, "parameter") | 457 DECLARE_CONCRETE_INSTRUCTION(Parameter, "parameter") |
468 }; | 458 }; |
469 | 459 |
470 | 460 |
471 class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> { | 461 class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> { |
472 public: | 462 public: |
473 explicit LCallStub(LOperand* context) { | 463 explicit LCallStub(LOperand* context) { |
474 inputs_[0] = context; | 464 inputs_[0] = context; |
475 } | 465 } |
476 | 466 |
(...skipping 20 matching lines...) Expand all Loading... |
497 LOperand* name() { return inputs_[2]; } | 487 LOperand* name() { return inputs_[2]; } |
498 | 488 |
499 DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache, | 489 DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache, |
500 "tail-call-through-megamorphic-cache") | 490 "tail-call-through-megamorphic-cache") |
501 DECLARE_HYDROGEN_ACCESSOR(TailCallThroughMegamorphicCache) | 491 DECLARE_HYDROGEN_ACCESSOR(TailCallThroughMegamorphicCache) |
502 }; | 492 }; |
503 | 493 |
504 | 494 |
505 class LUnknownOSRValue FINAL : public LTemplateInstruction<1, 0, 0> { | 495 class LUnknownOSRValue FINAL : public LTemplateInstruction<1, 0, 0> { |
506 public: | 496 public: |
507 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 497 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
508 return false; | |
509 } | |
510 DECLARE_CONCRETE_INSTRUCTION(UnknownOSRValue, "unknown-osr-value") | 498 DECLARE_CONCRETE_INSTRUCTION(UnknownOSRValue, "unknown-osr-value") |
511 }; | 499 }; |
512 | 500 |
513 | 501 |
514 template<int I, int T> | 502 template<int I, int T> |
515 class LControlInstruction : public LTemplateInstruction<0, I, T> { | 503 class LControlInstruction : public LTemplateInstruction<0, I, T> { |
516 public: | 504 public: |
517 LControlInstruction() : false_label_(NULL), true_label_(NULL) { } | 505 LControlInstruction() : false_label_(NULL), true_label_(NULL) { } |
518 | 506 |
519 virtual bool IsControl() const FINAL OVERRIDE { return true; } | 507 bool IsControl() const FINAL { return true; } |
520 | 508 |
521 int SuccessorCount() { return hydrogen()->SuccessorCount(); } | 509 int SuccessorCount() { return hydrogen()->SuccessorCount(); } |
522 HBasicBlock* SuccessorAt(int i) { return hydrogen()->SuccessorAt(i); } | 510 HBasicBlock* SuccessorAt(int i) { return hydrogen()->SuccessorAt(i); } |
523 | 511 |
524 int TrueDestination(LChunk* chunk) { | 512 int TrueDestination(LChunk* chunk) { |
525 return chunk->LookupDestination(true_block_id()); | 513 return chunk->LookupDestination(true_block_id()); |
526 } | 514 } |
527 int FalseDestination(LChunk* chunk) { | 515 int FalseDestination(LChunk* chunk) { |
528 return chunk->LookupDestination(false_block_id()); | 516 return chunk->LookupDestination(false_block_id()); |
529 } | 517 } |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
598 inputs_[1] = length; | 586 inputs_[1] = length; |
599 inputs_[2] = index; | 587 inputs_[2] = index; |
600 } | 588 } |
601 | 589 |
602 DECLARE_CONCRETE_INSTRUCTION(AccessArgumentsAt, "access-arguments-at") | 590 DECLARE_CONCRETE_INSTRUCTION(AccessArgumentsAt, "access-arguments-at") |
603 | 591 |
604 LOperand* arguments() { return inputs_[0]; } | 592 LOperand* arguments() { return inputs_[0]; } |
605 LOperand* length() { return inputs_[1]; } | 593 LOperand* length() { return inputs_[1]; } |
606 LOperand* index() { return inputs_[2]; } | 594 LOperand* index() { return inputs_[2]; } |
607 | 595 |
608 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 596 void PrintDataTo(StringStream* stream) OVERRIDE; |
609 }; | 597 }; |
610 | 598 |
611 | 599 |
612 class LArgumentsLength FINAL : public LTemplateInstruction<1, 1, 0> { | 600 class LArgumentsLength FINAL : public LTemplateInstruction<1, 1, 0> { |
613 public: | 601 public: |
614 explicit LArgumentsLength(LOperand* elements) { | 602 explicit LArgumentsLength(LOperand* elements) { |
615 inputs_[0] = elements; | 603 inputs_[0] = elements; |
616 } | 604 } |
617 | 605 |
618 LOperand* elements() { return inputs_[0]; } | 606 LOperand* elements() { return inputs_[0]; } |
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
838 | 826 |
839 DECLARE_CONCRETE_INSTRUCTION(CompareNumericAndBranch, | 827 DECLARE_CONCRETE_INSTRUCTION(CompareNumericAndBranch, |
840 "compare-numeric-and-branch") | 828 "compare-numeric-and-branch") |
841 DECLARE_HYDROGEN_ACCESSOR(CompareNumericAndBranch) | 829 DECLARE_HYDROGEN_ACCESSOR(CompareNumericAndBranch) |
842 | 830 |
843 Token::Value op() const { return hydrogen()->token(); } | 831 Token::Value op() const { return hydrogen()->token(); } |
844 bool is_double() const { | 832 bool is_double() const { |
845 return hydrogen()->representation().IsDouble(); | 833 return hydrogen()->representation().IsDouble(); |
846 } | 834 } |
847 | 835 |
848 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 836 void PrintDataTo(StringStream* stream) OVERRIDE; |
849 }; | 837 }; |
850 | 838 |
851 | 839 |
852 class LMathFloor FINAL : public LTemplateInstruction<1, 1, 1> { | 840 class LMathFloor FINAL : public LTemplateInstruction<1, 1, 1> { |
853 public: | 841 public: |
854 LMathFloor(LOperand* value, LOperand* temp) { | 842 LMathFloor(LOperand* value, LOperand* temp) { |
855 inputs_[0] = value; | 843 inputs_[0] = value; |
856 temps_[0] = temp; | 844 temps_[0] = temp; |
857 } | 845 } |
858 | 846 |
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1026 inputs_[0] = value; | 1014 inputs_[0] = value; |
1027 temps_[0] = temp; | 1015 temps_[0] = temp; |
1028 } | 1016 } |
1029 | 1017 |
1030 LOperand* value() { return inputs_[0]; } | 1018 LOperand* value() { return inputs_[0]; } |
1031 LOperand* temp() { return temps_[0]; } | 1019 LOperand* temp() { return temps_[0]; } |
1032 | 1020 |
1033 DECLARE_CONCRETE_INSTRUCTION(IsObjectAndBranch, "is-object-and-branch") | 1021 DECLARE_CONCRETE_INSTRUCTION(IsObjectAndBranch, "is-object-and-branch") |
1034 DECLARE_HYDROGEN_ACCESSOR(IsObjectAndBranch) | 1022 DECLARE_HYDROGEN_ACCESSOR(IsObjectAndBranch) |
1035 | 1023 |
1036 virtual void PrintDataTo(StringStream* stream); | 1024 void PrintDataTo(StringStream* stream) OVERRIDE; |
1037 }; | 1025 }; |
1038 | 1026 |
1039 | 1027 |
1040 class LIsStringAndBranch FINAL : public LControlInstruction<1, 1> { | 1028 class LIsStringAndBranch FINAL : public LControlInstruction<1, 1> { |
1041 public: | 1029 public: |
1042 LIsStringAndBranch(LOperand* value, LOperand* temp) { | 1030 LIsStringAndBranch(LOperand* value, LOperand* temp) { |
1043 inputs_[0] = value; | 1031 inputs_[0] = value; |
1044 temps_[0] = temp; | 1032 temps_[0] = temp; |
1045 } | 1033 } |
1046 | 1034 |
1047 LOperand* value() { return inputs_[0]; } | 1035 LOperand* value() { return inputs_[0]; } |
1048 LOperand* temp() { return temps_[0]; } | 1036 LOperand* temp() { return temps_[0]; } |
1049 | 1037 |
1050 DECLARE_CONCRETE_INSTRUCTION(IsStringAndBranch, "is-string-and-branch") | 1038 DECLARE_CONCRETE_INSTRUCTION(IsStringAndBranch, "is-string-and-branch") |
1051 DECLARE_HYDROGEN_ACCESSOR(IsStringAndBranch) | 1039 DECLARE_HYDROGEN_ACCESSOR(IsStringAndBranch) |
1052 | 1040 |
1053 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1041 void PrintDataTo(StringStream* stream) OVERRIDE; |
1054 }; | 1042 }; |
1055 | 1043 |
1056 | 1044 |
1057 class LIsSmiAndBranch FINAL : public LControlInstruction<1, 0> { | 1045 class LIsSmiAndBranch FINAL : public LControlInstruction<1, 0> { |
1058 public: | 1046 public: |
1059 explicit LIsSmiAndBranch(LOperand* value) { | 1047 explicit LIsSmiAndBranch(LOperand* value) { |
1060 inputs_[0] = value; | 1048 inputs_[0] = value; |
1061 } | 1049 } |
1062 | 1050 |
1063 LOperand* value() { return inputs_[0]; } | 1051 LOperand* value() { return inputs_[0]; } |
1064 | 1052 |
1065 DECLARE_CONCRETE_INSTRUCTION(IsSmiAndBranch, "is-smi-and-branch") | 1053 DECLARE_CONCRETE_INSTRUCTION(IsSmiAndBranch, "is-smi-and-branch") |
1066 DECLARE_HYDROGEN_ACCESSOR(IsSmiAndBranch) | 1054 DECLARE_HYDROGEN_ACCESSOR(IsSmiAndBranch) |
1067 | 1055 |
1068 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1056 void PrintDataTo(StringStream* stream) OVERRIDE; |
1069 }; | 1057 }; |
1070 | 1058 |
1071 | 1059 |
1072 class LIsUndetectableAndBranch FINAL : public LControlInstruction<1, 1> { | 1060 class LIsUndetectableAndBranch FINAL : public LControlInstruction<1, 1> { |
1073 public: | 1061 public: |
1074 explicit LIsUndetectableAndBranch(LOperand* value, LOperand* temp) { | 1062 explicit LIsUndetectableAndBranch(LOperand* value, LOperand* temp) { |
1075 inputs_[0] = value; | 1063 inputs_[0] = value; |
1076 temps_[0] = temp; | 1064 temps_[0] = temp; |
1077 } | 1065 } |
1078 | 1066 |
1079 LOperand* value() { return inputs_[0]; } | 1067 LOperand* value() { return inputs_[0]; } |
1080 LOperand* temp() { return temps_[0]; } | 1068 LOperand* temp() { return temps_[0]; } |
1081 | 1069 |
1082 DECLARE_CONCRETE_INSTRUCTION(IsUndetectableAndBranch, | 1070 DECLARE_CONCRETE_INSTRUCTION(IsUndetectableAndBranch, |
1083 "is-undetectable-and-branch") | 1071 "is-undetectable-and-branch") |
1084 DECLARE_HYDROGEN_ACCESSOR(IsUndetectableAndBranch) | 1072 DECLARE_HYDROGEN_ACCESSOR(IsUndetectableAndBranch) |
1085 | 1073 |
1086 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1074 void PrintDataTo(StringStream* stream) OVERRIDE; |
1087 }; | 1075 }; |
1088 | 1076 |
1089 | 1077 |
1090 class LStringCompareAndBranch FINAL : public LControlInstruction<3, 0> { | 1078 class LStringCompareAndBranch FINAL : public LControlInstruction<3, 0> { |
1091 public: | 1079 public: |
1092 LStringCompareAndBranch(LOperand* context, LOperand* left, LOperand* right) { | 1080 LStringCompareAndBranch(LOperand* context, LOperand* left, LOperand* right) { |
1093 inputs_[0] = context; | 1081 inputs_[0] = context; |
1094 inputs_[1] = left; | 1082 inputs_[1] = left; |
1095 inputs_[2] = right; | 1083 inputs_[2] = right; |
1096 } | 1084 } |
1097 | 1085 |
1098 LOperand* context() { return inputs_[0]; } | 1086 LOperand* context() { return inputs_[0]; } |
1099 LOperand* left() { return inputs_[1]; } | 1087 LOperand* left() { return inputs_[1]; } |
1100 LOperand* right() { return inputs_[2]; } | 1088 LOperand* right() { return inputs_[2]; } |
1101 | 1089 |
1102 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch, | 1090 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch, |
1103 "string-compare-and-branch") | 1091 "string-compare-and-branch") |
1104 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch) | 1092 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch) |
1105 | 1093 |
1106 Token::Value op() const { return hydrogen()->token(); } | 1094 Token::Value op() const { return hydrogen()->token(); } |
1107 | 1095 |
1108 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1096 void PrintDataTo(StringStream* stream) OVERRIDE; |
1109 }; | 1097 }; |
1110 | 1098 |
1111 | 1099 |
1112 class LHasInstanceTypeAndBranch FINAL : public LControlInstruction<1, 0> { | 1100 class LHasInstanceTypeAndBranch FINAL : public LControlInstruction<1, 0> { |
1113 public: | 1101 public: |
1114 explicit LHasInstanceTypeAndBranch(LOperand* value) { | 1102 explicit LHasInstanceTypeAndBranch(LOperand* value) { |
1115 inputs_[0] = value; | 1103 inputs_[0] = value; |
1116 } | 1104 } |
1117 | 1105 |
1118 LOperand* value() { return inputs_[0]; } | 1106 LOperand* value() { return inputs_[0]; } |
1119 | 1107 |
1120 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch, | 1108 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch, |
1121 "has-instance-type-and-branch") | 1109 "has-instance-type-and-branch") |
1122 DECLARE_HYDROGEN_ACCESSOR(HasInstanceTypeAndBranch) | 1110 DECLARE_HYDROGEN_ACCESSOR(HasInstanceTypeAndBranch) |
1123 | 1111 |
1124 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1112 void PrintDataTo(StringStream* stream) OVERRIDE; |
1125 }; | 1113 }; |
1126 | 1114 |
1127 | 1115 |
1128 class LGetCachedArrayIndex FINAL : public LTemplateInstruction<1, 1, 0> { | 1116 class LGetCachedArrayIndex FINAL : public LTemplateInstruction<1, 1, 0> { |
1129 public: | 1117 public: |
1130 explicit LGetCachedArrayIndex(LOperand* value) { | 1118 explicit LGetCachedArrayIndex(LOperand* value) { |
1131 inputs_[0] = value; | 1119 inputs_[0] = value; |
1132 } | 1120 } |
1133 | 1121 |
1134 LOperand* value() { return inputs_[0]; } | 1122 LOperand* value() { return inputs_[0]; } |
1135 | 1123 |
1136 DECLARE_CONCRETE_INSTRUCTION(GetCachedArrayIndex, "get-cached-array-index") | 1124 DECLARE_CONCRETE_INSTRUCTION(GetCachedArrayIndex, "get-cached-array-index") |
1137 DECLARE_HYDROGEN_ACCESSOR(GetCachedArrayIndex) | 1125 DECLARE_HYDROGEN_ACCESSOR(GetCachedArrayIndex) |
1138 }; | 1126 }; |
1139 | 1127 |
1140 | 1128 |
1141 class LHasCachedArrayIndexAndBranch FINAL | 1129 class LHasCachedArrayIndexAndBranch FINAL |
1142 : public LControlInstruction<1, 0> { | 1130 : public LControlInstruction<1, 0> { |
1143 public: | 1131 public: |
1144 explicit LHasCachedArrayIndexAndBranch(LOperand* value) { | 1132 explicit LHasCachedArrayIndexAndBranch(LOperand* value) { |
1145 inputs_[0] = value; | 1133 inputs_[0] = value; |
1146 } | 1134 } |
1147 | 1135 |
1148 LOperand* value() { return inputs_[0]; } | 1136 LOperand* value() { return inputs_[0]; } |
1149 | 1137 |
1150 DECLARE_CONCRETE_INSTRUCTION(HasCachedArrayIndexAndBranch, | 1138 DECLARE_CONCRETE_INSTRUCTION(HasCachedArrayIndexAndBranch, |
1151 "has-cached-array-index-and-branch") | 1139 "has-cached-array-index-and-branch") |
1152 DECLARE_HYDROGEN_ACCESSOR(HasCachedArrayIndexAndBranch) | 1140 DECLARE_HYDROGEN_ACCESSOR(HasCachedArrayIndexAndBranch) |
1153 | 1141 |
1154 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1142 void PrintDataTo(StringStream* stream) OVERRIDE; |
1155 }; | 1143 }; |
1156 | 1144 |
1157 | 1145 |
1158 class LClassOfTestAndBranch FINAL : public LControlInstruction<1, 1> { | 1146 class LClassOfTestAndBranch FINAL : public LControlInstruction<1, 1> { |
1159 public: | 1147 public: |
1160 LClassOfTestAndBranch(LOperand* value, LOperand* temp) { | 1148 LClassOfTestAndBranch(LOperand* value, LOperand* temp) { |
1161 inputs_[0] = value; | 1149 inputs_[0] = value; |
1162 temps_[0] = temp; | 1150 temps_[0] = temp; |
1163 } | 1151 } |
1164 | 1152 |
1165 LOperand* value() { return inputs_[0]; } | 1153 LOperand* value() { return inputs_[0]; } |
1166 LOperand* temp() { return temps_[0]; } | 1154 LOperand* temp() { return temps_[0]; } |
1167 | 1155 |
1168 DECLARE_CONCRETE_INSTRUCTION(ClassOfTestAndBranch, | 1156 DECLARE_CONCRETE_INSTRUCTION(ClassOfTestAndBranch, |
1169 "class-of-test-and-branch") | 1157 "class-of-test-and-branch") |
1170 DECLARE_HYDROGEN_ACCESSOR(ClassOfTestAndBranch) | 1158 DECLARE_HYDROGEN_ACCESSOR(ClassOfTestAndBranch) |
1171 | 1159 |
1172 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1160 void PrintDataTo(StringStream* stream) OVERRIDE; |
1173 }; | 1161 }; |
1174 | 1162 |
1175 | 1163 |
1176 class LCmpT FINAL : public LTemplateInstruction<1, 3, 0> { | 1164 class LCmpT FINAL : public LTemplateInstruction<1, 3, 0> { |
1177 public: | 1165 public: |
1178 LCmpT(LOperand* context, LOperand* left, LOperand* right) { | 1166 LCmpT(LOperand* context, LOperand* left, LOperand* right) { |
1179 inputs_[0] = context; | 1167 inputs_[0] = context; |
1180 inputs_[1] = left; | 1168 inputs_[1] = left; |
1181 inputs_[2] = right; | 1169 inputs_[2] = right; |
1182 } | 1170 } |
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1359 public: | 1347 public: |
1360 explicit LBranch(LOperand* value) { | 1348 explicit LBranch(LOperand* value) { |
1361 inputs_[0] = value; | 1349 inputs_[0] = value; |
1362 } | 1350 } |
1363 | 1351 |
1364 LOperand* value() { return inputs_[0]; } | 1352 LOperand* value() { return inputs_[0]; } |
1365 | 1353 |
1366 DECLARE_CONCRETE_INSTRUCTION(Branch, "branch") | 1354 DECLARE_CONCRETE_INSTRUCTION(Branch, "branch") |
1367 DECLARE_HYDROGEN_ACCESSOR(Branch) | 1355 DECLARE_HYDROGEN_ACCESSOR(Branch) |
1368 | 1356 |
1369 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1357 void PrintDataTo(StringStream* stream) OVERRIDE; |
1370 }; | 1358 }; |
1371 | 1359 |
1372 | 1360 |
1373 class LCmpMapAndBranch FINAL : public LControlInstruction<1, 1> { | 1361 class LCmpMapAndBranch FINAL : public LControlInstruction<1, 1> { |
1374 public: | 1362 public: |
1375 LCmpMapAndBranch(LOperand* value, LOperand* temp) { | 1363 LCmpMapAndBranch(LOperand* value, LOperand* temp) { |
1376 inputs_[0] = value; | 1364 inputs_[0] = value; |
1377 temps_[0] = temp; | 1365 temps_[0] = temp; |
1378 } | 1366 } |
1379 | 1367 |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1504 LArithmeticD(Token::Value op, LOperand* left, LOperand* right) | 1492 LArithmeticD(Token::Value op, LOperand* left, LOperand* right) |
1505 : op_(op) { | 1493 : op_(op) { |
1506 inputs_[0] = left; | 1494 inputs_[0] = left; |
1507 inputs_[1] = right; | 1495 inputs_[1] = right; |
1508 } | 1496 } |
1509 | 1497 |
1510 Token::Value op() const { return op_; } | 1498 Token::Value op() const { return op_; } |
1511 LOperand* left() { return inputs_[0]; } | 1499 LOperand* left() { return inputs_[0]; } |
1512 LOperand* right() { return inputs_[1]; } | 1500 LOperand* right() { return inputs_[1]; } |
1513 | 1501 |
1514 virtual Opcode opcode() const OVERRIDE { | 1502 Opcode opcode() const OVERRIDE { return LInstruction::kArithmeticD; } |
1515 return LInstruction::kArithmeticD; | 1503 void CompileToNative(LCodeGen* generator) OVERRIDE; |
1516 } | 1504 const char* Mnemonic() const OVERRIDE; |
1517 virtual void CompileToNative(LCodeGen* generator) OVERRIDE; | |
1518 virtual const char* Mnemonic() const OVERRIDE; | |
1519 | 1505 |
1520 private: | 1506 private: |
1521 Token::Value op_; | 1507 Token::Value op_; |
1522 }; | 1508 }; |
1523 | 1509 |
1524 | 1510 |
1525 class LArithmeticT FINAL : public LTemplateInstruction<1, 3, 0> { | 1511 class LArithmeticT FINAL : public LTemplateInstruction<1, 3, 0> { |
1526 public: | 1512 public: |
1527 LArithmeticT(Token::Value op, | 1513 LArithmeticT(Token::Value op, |
1528 LOperand* context, | 1514 LOperand* context, |
1529 LOperand* left, | 1515 LOperand* left, |
1530 LOperand* right) | 1516 LOperand* right) |
1531 : op_(op) { | 1517 : op_(op) { |
1532 inputs_[0] = context; | 1518 inputs_[0] = context; |
1533 inputs_[1] = left; | 1519 inputs_[1] = left; |
1534 inputs_[2] = right; | 1520 inputs_[2] = right; |
1535 } | 1521 } |
1536 | 1522 |
1537 LOperand* context() { return inputs_[0]; } | 1523 LOperand* context() { return inputs_[0]; } |
1538 LOperand* left() { return inputs_[1]; } | 1524 LOperand* left() { return inputs_[1]; } |
1539 LOperand* right() { return inputs_[2]; } | 1525 LOperand* right() { return inputs_[2]; } |
1540 Token::Value op() const { return op_; } | 1526 Token::Value op() const { return op_; } |
1541 | 1527 |
1542 virtual Opcode opcode() const FINAL { return LInstruction::kArithmeticT; } | 1528 Opcode opcode() const FINAL { return LInstruction::kArithmeticT; } |
1543 virtual void CompileToNative(LCodeGen* generator) OVERRIDE; | 1529 void CompileToNative(LCodeGen* generator) OVERRIDE; |
1544 virtual const char* Mnemonic() const OVERRIDE; | 1530 const char* Mnemonic() const OVERRIDE; |
1545 | 1531 |
1546 private: | 1532 private: |
1547 Token::Value op_; | 1533 Token::Value op_; |
1548 }; | 1534 }; |
1549 | 1535 |
1550 | 1536 |
1551 class LReturn FINAL : public LTemplateInstruction<0, 3, 0> { | 1537 class LReturn FINAL : public LTemplateInstruction<0, 3, 0> { |
1552 public: | 1538 public: |
1553 LReturn(LOperand* value, LOperand* context, LOperand* parameter_count) { | 1539 LReturn(LOperand* value, LOperand* context, LOperand* parameter_count) { |
1554 inputs_[0] = value; | 1540 inputs_[0] = value; |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1643 bool is_fixed_typed_array() const { | 1629 bool is_fixed_typed_array() const { |
1644 return hydrogen()->is_fixed_typed_array(); | 1630 return hydrogen()->is_fixed_typed_array(); |
1645 } | 1631 } |
1646 bool is_typed_elements() const { | 1632 bool is_typed_elements() const { |
1647 return is_external() || is_fixed_typed_array(); | 1633 return is_external() || is_fixed_typed_array(); |
1648 } | 1634 } |
1649 | 1635 |
1650 DECLARE_CONCRETE_INSTRUCTION(LoadKeyed, "load-keyed") | 1636 DECLARE_CONCRETE_INSTRUCTION(LoadKeyed, "load-keyed") |
1651 DECLARE_HYDROGEN_ACCESSOR(LoadKeyed) | 1637 DECLARE_HYDROGEN_ACCESSOR(LoadKeyed) |
1652 | 1638 |
1653 virtual void PrintDataTo(StringStream* stream); | 1639 void PrintDataTo(StringStream* stream) OVERRIDE; |
1654 uint32_t base_offset() const { return hydrogen()->base_offset(); } | 1640 uint32_t base_offset() const { return hydrogen()->base_offset(); } |
1655 }; | 1641 }; |
1656 | 1642 |
1657 | 1643 |
1658 class LLoadKeyedGeneric FINAL : public LTemplateInstruction<1, 3, 1> { | 1644 class LLoadKeyedGeneric FINAL : public LTemplateInstruction<1, 3, 1> { |
1659 public: | 1645 public: |
1660 LLoadKeyedGeneric(LOperand* context, LOperand* object, LOperand* key, | 1646 LLoadKeyedGeneric(LOperand* context, LOperand* object, LOperand* key, |
1661 LOperand* vector) { | 1647 LOperand* vector) { |
1662 inputs_[0] = context; | 1648 inputs_[0] = context; |
1663 inputs_[1] = object; | 1649 inputs_[1] = object; |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1724 inputs_[0] = context; | 1710 inputs_[0] = context; |
1725 } | 1711 } |
1726 | 1712 |
1727 LOperand* context() { return inputs_[0]; } | 1713 LOperand* context() { return inputs_[0]; } |
1728 | 1714 |
1729 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot") | 1715 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot") |
1730 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot) | 1716 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot) |
1731 | 1717 |
1732 int slot_index() { return hydrogen()->slot_index(); } | 1718 int slot_index() { return hydrogen()->slot_index(); } |
1733 | 1719 |
1734 virtual void PrintDataTo(StringStream* stream); | 1720 void PrintDataTo(StringStream* stream) OVERRIDE; |
1735 }; | 1721 }; |
1736 | 1722 |
1737 | 1723 |
1738 class LStoreContextSlot FINAL : public LTemplateInstruction<0, 2, 0> { | 1724 class LStoreContextSlot FINAL : public LTemplateInstruction<0, 2, 0> { |
1739 public: | 1725 public: |
1740 LStoreContextSlot(LOperand* context, LOperand* value) { | 1726 LStoreContextSlot(LOperand* context, LOperand* value) { |
1741 inputs_[0] = context; | 1727 inputs_[0] = context; |
1742 inputs_[1] = value; | 1728 inputs_[1] = value; |
1743 } | 1729 } |
1744 | 1730 |
1745 LOperand* context() { return inputs_[0]; } | 1731 LOperand* context() { return inputs_[0]; } |
1746 LOperand* value() { return inputs_[1]; } | 1732 LOperand* value() { return inputs_[1]; } |
1747 | 1733 |
1748 DECLARE_CONCRETE_INSTRUCTION(StoreContextSlot, "store-context-slot") | 1734 DECLARE_CONCRETE_INSTRUCTION(StoreContextSlot, "store-context-slot") |
1749 DECLARE_HYDROGEN_ACCESSOR(StoreContextSlot) | 1735 DECLARE_HYDROGEN_ACCESSOR(StoreContextSlot) |
1750 | 1736 |
1751 int slot_index() { return hydrogen()->slot_index(); } | 1737 int slot_index() { return hydrogen()->slot_index(); } |
1752 | 1738 |
1753 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1739 void PrintDataTo(StringStream* stream) OVERRIDE; |
1754 }; | 1740 }; |
1755 | 1741 |
1756 | 1742 |
1757 class LPushArgument FINAL : public LTemplateInstruction<0, 1, 0> { | 1743 class LPushArgument FINAL : public LTemplateInstruction<0, 1, 0> { |
1758 public: | 1744 public: |
1759 explicit LPushArgument(LOperand* value) { | 1745 explicit LPushArgument(LOperand* value) { |
1760 inputs_[0] = value; | 1746 inputs_[0] = value; |
1761 } | 1747 } |
1762 | 1748 |
1763 LOperand* value() { return inputs_[0]; } | 1749 LOperand* value() { return inputs_[0]; } |
(...skipping 18 matching lines...) Expand all Loading... |
1782 class LStoreCodeEntry FINAL: public LTemplateInstruction<0, 2, 0> { | 1768 class LStoreCodeEntry FINAL: public LTemplateInstruction<0, 2, 0> { |
1783 public: | 1769 public: |
1784 LStoreCodeEntry(LOperand* function, LOperand* code_object) { | 1770 LStoreCodeEntry(LOperand* function, LOperand* code_object) { |
1785 inputs_[0] = function; | 1771 inputs_[0] = function; |
1786 inputs_[1] = code_object; | 1772 inputs_[1] = code_object; |
1787 } | 1773 } |
1788 | 1774 |
1789 LOperand* function() { return inputs_[0]; } | 1775 LOperand* function() { return inputs_[0]; } |
1790 LOperand* code_object() { return inputs_[1]; } | 1776 LOperand* code_object() { return inputs_[1]; } |
1791 | 1777 |
1792 virtual void PrintDataTo(StringStream* stream); | 1778 void PrintDataTo(StringStream* stream) OVERRIDE; |
1793 | 1779 |
1794 DECLARE_CONCRETE_INSTRUCTION(StoreCodeEntry, "store-code-entry") | 1780 DECLARE_CONCRETE_INSTRUCTION(StoreCodeEntry, "store-code-entry") |
1795 DECLARE_HYDROGEN_ACCESSOR(StoreCodeEntry) | 1781 DECLARE_HYDROGEN_ACCESSOR(StoreCodeEntry) |
1796 }; | 1782 }; |
1797 | 1783 |
1798 | 1784 |
1799 class LInnerAllocatedObject FINAL: public LTemplateInstruction<1, 2, 0> { | 1785 class LInnerAllocatedObject FINAL: public LTemplateInstruction<1, 2, 0> { |
1800 public: | 1786 public: |
1801 LInnerAllocatedObject(LOperand* base_object, LOperand* offset) { | 1787 LInnerAllocatedObject(LOperand* base_object, LOperand* offset) { |
1802 inputs_[0] = base_object; | 1788 inputs_[0] = base_object; |
1803 inputs_[1] = offset; | 1789 inputs_[1] = offset; |
1804 } | 1790 } |
1805 | 1791 |
1806 LOperand* base_object() const { return inputs_[0]; } | 1792 LOperand* base_object() const { return inputs_[0]; } |
1807 LOperand* offset() const { return inputs_[1]; } | 1793 LOperand* offset() const { return inputs_[1]; } |
1808 | 1794 |
1809 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1795 void PrintDataTo(StringStream* stream) OVERRIDE; |
1810 | 1796 |
1811 DECLARE_CONCRETE_INSTRUCTION(InnerAllocatedObject, "inner-allocated-object") | 1797 DECLARE_CONCRETE_INSTRUCTION(InnerAllocatedObject, "inner-allocated-object") |
1812 }; | 1798 }; |
1813 | 1799 |
1814 | 1800 |
1815 class LThisFunction FINAL : public LTemplateInstruction<1, 0, 0> { | 1801 class LThisFunction FINAL : public LTemplateInstruction<1, 0, 0> { |
1816 public: | 1802 public: |
1817 DECLARE_CONCRETE_INSTRUCTION(ThisFunction, "this-function") | 1803 DECLARE_CONCRETE_INSTRUCTION(ThisFunction, "this-function") |
1818 DECLARE_HYDROGEN_ACCESSOR(ThisFunction) | 1804 DECLARE_HYDROGEN_ACCESSOR(ThisFunction) |
1819 }; | 1805 }; |
(...skipping 23 matching lines...) Expand all Loading... |
1843 public: | 1829 public: |
1844 explicit LCallJSFunction(LOperand* function) { | 1830 explicit LCallJSFunction(LOperand* function) { |
1845 inputs_[0] = function; | 1831 inputs_[0] = function; |
1846 } | 1832 } |
1847 | 1833 |
1848 LOperand* function() { return inputs_[0]; } | 1834 LOperand* function() { return inputs_[0]; } |
1849 | 1835 |
1850 DECLARE_CONCRETE_INSTRUCTION(CallJSFunction, "call-js-function") | 1836 DECLARE_CONCRETE_INSTRUCTION(CallJSFunction, "call-js-function") |
1851 DECLARE_HYDROGEN_ACCESSOR(CallJSFunction) | 1837 DECLARE_HYDROGEN_ACCESSOR(CallJSFunction) |
1852 | 1838 |
1853 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1839 void PrintDataTo(StringStream* stream) OVERRIDE; |
1854 | 1840 |
1855 int arity() const { return hydrogen()->argument_count() - 1; } | 1841 int arity() const { return hydrogen()->argument_count() - 1; } |
1856 }; | 1842 }; |
1857 | 1843 |
1858 | 1844 |
1859 class LCallWithDescriptor FINAL : public LTemplateResultInstruction<1> { | 1845 class LCallWithDescriptor FINAL : public LTemplateResultInstruction<1> { |
1860 public: | 1846 public: |
1861 LCallWithDescriptor(CallInterfaceDescriptor descriptor, | 1847 LCallWithDescriptor(CallInterfaceDescriptor descriptor, |
1862 const ZoneList<LOperand*>& operands, Zone* zone) | 1848 const ZoneList<LOperand*>& operands, Zone* zone) |
1863 : descriptor_(descriptor), | 1849 : descriptor_(descriptor), |
1864 inputs_(descriptor.GetRegisterParameterCount() + 1, zone) { | 1850 inputs_(descriptor.GetRegisterParameterCount() + 1, zone) { |
1865 DCHECK(descriptor.GetRegisterParameterCount() + 1 == operands.length()); | 1851 DCHECK(descriptor.GetRegisterParameterCount() + 1 == operands.length()); |
1866 inputs_.AddAll(operands, zone); | 1852 inputs_.AddAll(operands, zone); |
1867 } | 1853 } |
1868 | 1854 |
1869 LOperand* target() const { return inputs_[0]; } | 1855 LOperand* target() const { return inputs_[0]; } |
1870 | 1856 |
1871 const CallInterfaceDescriptor descriptor() { return descriptor_; } | 1857 const CallInterfaceDescriptor descriptor() { return descriptor_; } |
1872 | 1858 |
1873 private: | 1859 private: |
1874 DECLARE_CONCRETE_INSTRUCTION(CallWithDescriptor, "call-with-descriptor") | 1860 DECLARE_CONCRETE_INSTRUCTION(CallWithDescriptor, "call-with-descriptor") |
1875 DECLARE_HYDROGEN_ACCESSOR(CallWithDescriptor) | 1861 DECLARE_HYDROGEN_ACCESSOR(CallWithDescriptor) |
1876 | 1862 |
1877 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1863 void PrintDataTo(StringStream* stream) OVERRIDE; |
1878 | 1864 |
1879 int arity() const { return hydrogen()->argument_count() - 1; } | 1865 int arity() const { return hydrogen()->argument_count() - 1; } |
1880 | 1866 |
1881 CallInterfaceDescriptor descriptor_; | 1867 CallInterfaceDescriptor descriptor_; |
1882 ZoneList<LOperand*> inputs_; | 1868 ZoneList<LOperand*> inputs_; |
1883 | 1869 |
1884 // Iterator support. | 1870 // Iterator support. |
1885 virtual int InputCount() FINAL OVERRIDE { return inputs_.length(); } | 1871 int InputCount() FINAL { return inputs_.length(); } |
1886 virtual LOperand* InputAt(int i) FINAL OVERRIDE { return inputs_[i]; } | 1872 LOperand* InputAt(int i) FINAL { return inputs_[i]; } |
1887 | 1873 |
1888 virtual int TempCount() FINAL OVERRIDE { return 0; } | 1874 int TempCount() FINAL { return 0; } |
1889 virtual LOperand* TempAt(int i) FINAL OVERRIDE { return NULL; } | 1875 LOperand* TempAt(int i) FINAL { return NULL; } |
1890 }; | 1876 }; |
1891 | 1877 |
1892 | 1878 |
1893 | 1879 |
1894 class LInvokeFunction FINAL : public LTemplateInstruction<1, 2, 0> { | 1880 class LInvokeFunction FINAL : public LTemplateInstruction<1, 2, 0> { |
1895 public: | 1881 public: |
1896 LInvokeFunction(LOperand* context, LOperand* function) { | 1882 LInvokeFunction(LOperand* context, LOperand* function) { |
1897 inputs_[0] = context; | 1883 inputs_[0] = context; |
1898 inputs_[1] = function; | 1884 inputs_[1] = function; |
1899 } | 1885 } |
1900 | 1886 |
1901 LOperand* context() { return inputs_[0]; } | 1887 LOperand* context() { return inputs_[0]; } |
1902 LOperand* function() { return inputs_[1]; } | 1888 LOperand* function() { return inputs_[1]; } |
1903 | 1889 |
1904 DECLARE_CONCRETE_INSTRUCTION(InvokeFunction, "invoke-function") | 1890 DECLARE_CONCRETE_INSTRUCTION(InvokeFunction, "invoke-function") |
1905 DECLARE_HYDROGEN_ACCESSOR(InvokeFunction) | 1891 DECLARE_HYDROGEN_ACCESSOR(InvokeFunction) |
1906 | 1892 |
1907 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1893 void PrintDataTo(StringStream* stream) OVERRIDE; |
1908 | 1894 |
1909 int arity() const { return hydrogen()->argument_count() - 1; } | 1895 int arity() const { return hydrogen()->argument_count() - 1; } |
1910 }; | 1896 }; |
1911 | 1897 |
1912 | 1898 |
1913 class LCallFunction FINAL : public LTemplateInstruction<1, 2, 0> { | 1899 class LCallFunction FINAL : public LTemplateInstruction<1, 2, 0> { |
1914 public: | 1900 public: |
1915 LCallFunction(LOperand* context, LOperand* function) { | 1901 LCallFunction(LOperand* context, LOperand* function) { |
1916 inputs_[0] = context; | 1902 inputs_[0] = context; |
1917 inputs_[1] = function; | 1903 inputs_[1] = function; |
(...skipping 15 matching lines...) Expand all Loading... |
1933 inputs_[0] = context; | 1919 inputs_[0] = context; |
1934 inputs_[1] = constructor; | 1920 inputs_[1] = constructor; |
1935 } | 1921 } |
1936 | 1922 |
1937 LOperand* context() { return inputs_[0]; } | 1923 LOperand* context() { return inputs_[0]; } |
1938 LOperand* constructor() { return inputs_[1]; } | 1924 LOperand* constructor() { return inputs_[1]; } |
1939 | 1925 |
1940 DECLARE_CONCRETE_INSTRUCTION(CallNew, "call-new") | 1926 DECLARE_CONCRETE_INSTRUCTION(CallNew, "call-new") |
1941 DECLARE_HYDROGEN_ACCESSOR(CallNew) | 1927 DECLARE_HYDROGEN_ACCESSOR(CallNew) |
1942 | 1928 |
1943 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1929 void PrintDataTo(StringStream* stream) OVERRIDE; |
1944 | 1930 |
1945 int arity() const { return hydrogen()->argument_count() - 1; } | 1931 int arity() const { return hydrogen()->argument_count() - 1; } |
1946 }; | 1932 }; |
1947 | 1933 |
1948 | 1934 |
1949 class LCallNewArray FINAL : public LTemplateInstruction<1, 2, 0> { | 1935 class LCallNewArray FINAL : public LTemplateInstruction<1, 2, 0> { |
1950 public: | 1936 public: |
1951 LCallNewArray(LOperand* context, LOperand* constructor) { | 1937 LCallNewArray(LOperand* context, LOperand* constructor) { |
1952 inputs_[0] = context; | 1938 inputs_[0] = context; |
1953 inputs_[1] = constructor; | 1939 inputs_[1] = constructor; |
1954 } | 1940 } |
1955 | 1941 |
1956 LOperand* context() { return inputs_[0]; } | 1942 LOperand* context() { return inputs_[0]; } |
1957 LOperand* constructor() { return inputs_[1]; } | 1943 LOperand* constructor() { return inputs_[1]; } |
1958 | 1944 |
1959 DECLARE_CONCRETE_INSTRUCTION(CallNewArray, "call-new-array") | 1945 DECLARE_CONCRETE_INSTRUCTION(CallNewArray, "call-new-array") |
1960 DECLARE_HYDROGEN_ACCESSOR(CallNewArray) | 1946 DECLARE_HYDROGEN_ACCESSOR(CallNewArray) |
1961 | 1947 |
1962 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1948 void PrintDataTo(StringStream* stream) OVERRIDE; |
1963 | 1949 |
1964 int arity() const { return hydrogen()->argument_count() - 1; } | 1950 int arity() const { return hydrogen()->argument_count() - 1; } |
1965 }; | 1951 }; |
1966 | 1952 |
1967 | 1953 |
1968 class LCallRuntime FINAL : public LTemplateInstruction<1, 1, 0> { | 1954 class LCallRuntime FINAL : public LTemplateInstruction<1, 1, 0> { |
1969 public: | 1955 public: |
1970 explicit LCallRuntime(LOperand* context) { | 1956 explicit LCallRuntime(LOperand* context) { |
1971 inputs_[0] = context; | 1957 inputs_[0] = context; |
1972 } | 1958 } |
1973 | 1959 |
1974 LOperand* context() { return inputs_[0]; } | 1960 LOperand* context() { return inputs_[0]; } |
1975 | 1961 |
1976 DECLARE_CONCRETE_INSTRUCTION(CallRuntime, "call-runtime") | 1962 DECLARE_CONCRETE_INSTRUCTION(CallRuntime, "call-runtime") |
1977 DECLARE_HYDROGEN_ACCESSOR(CallRuntime) | 1963 DECLARE_HYDROGEN_ACCESSOR(CallRuntime) |
1978 | 1964 |
1979 virtual bool ClobbersDoubleRegisters(Isolate* isolate) const OVERRIDE { | 1965 bool ClobbersDoubleRegisters(Isolate* isolate) const OVERRIDE { |
1980 return save_doubles() == kDontSaveFPRegs; | 1966 return save_doubles() == kDontSaveFPRegs; |
1981 } | 1967 } |
1982 | 1968 |
1983 const Runtime::Function* function() const { return hydrogen()->function(); } | 1969 const Runtime::Function* function() const { return hydrogen()->function(); } |
1984 int arity() const { return hydrogen()->argument_count(); } | 1970 int arity() const { return hydrogen()->argument_count(); } |
1985 SaveFPRegsMode save_doubles() const { return hydrogen()->save_doubles(); } | 1971 SaveFPRegsMode save_doubles() const { return hydrogen()->save_doubles(); } |
1986 }; | 1972 }; |
1987 | 1973 |
1988 | 1974 |
1989 class LInteger32ToDouble FINAL : public LTemplateInstruction<1, 1, 0> { | 1975 class LInteger32ToDouble FINAL : public LTemplateInstruction<1, 1, 0> { |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2147 temps_[0] = temp; | 2133 temps_[0] = temp; |
2148 } | 2134 } |
2149 | 2135 |
2150 LOperand* object() { return inputs_[0]; } | 2136 LOperand* object() { return inputs_[0]; } |
2151 LOperand* value() { return inputs_[1]; } | 2137 LOperand* value() { return inputs_[1]; } |
2152 LOperand* temp() { return temps_[0]; } | 2138 LOperand* temp() { return temps_[0]; } |
2153 | 2139 |
2154 DECLARE_CONCRETE_INSTRUCTION(StoreNamedField, "store-named-field") | 2140 DECLARE_CONCRETE_INSTRUCTION(StoreNamedField, "store-named-field") |
2155 DECLARE_HYDROGEN_ACCESSOR(StoreNamedField) | 2141 DECLARE_HYDROGEN_ACCESSOR(StoreNamedField) |
2156 | 2142 |
2157 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2143 void PrintDataTo(StringStream* stream) OVERRIDE; |
2158 | 2144 |
2159 Representation representation() const { | 2145 Representation representation() const { |
2160 return hydrogen()->field_representation(); | 2146 return hydrogen()->field_representation(); |
2161 } | 2147 } |
2162 }; | 2148 }; |
2163 | 2149 |
2164 | 2150 |
2165 class LStoreNamedGeneric FINAL : public LTemplateInstruction<0, 3, 0> { | 2151 class LStoreNamedGeneric FINAL : public LTemplateInstruction<0, 3, 0> { |
2166 public: | 2152 public: |
2167 LStoreNamedGeneric(LOperand* context, LOperand* object, LOperand* value) { | 2153 LStoreNamedGeneric(LOperand* context, LOperand* object, LOperand* value) { |
2168 inputs_[0] = context; | 2154 inputs_[0] = context; |
2169 inputs_[1] = object; | 2155 inputs_[1] = object; |
2170 inputs_[2] = value; | 2156 inputs_[2] = value; |
2171 } | 2157 } |
2172 | 2158 |
2173 LOperand* context() { return inputs_[0]; } | 2159 LOperand* context() { return inputs_[0]; } |
2174 LOperand* object() { return inputs_[1]; } | 2160 LOperand* object() { return inputs_[1]; } |
2175 LOperand* value() { return inputs_[2]; } | 2161 LOperand* value() { return inputs_[2]; } |
2176 | 2162 |
2177 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic") | 2163 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic") |
2178 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric) | 2164 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric) |
2179 | 2165 |
2180 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2166 void PrintDataTo(StringStream* stream) OVERRIDE; |
2181 | 2167 |
2182 Handle<Object> name() const { return hydrogen()->name(); } | 2168 Handle<Object> name() const { return hydrogen()->name(); } |
2183 StrictMode strict_mode() { return hydrogen()->strict_mode(); } | 2169 StrictMode strict_mode() { return hydrogen()->strict_mode(); } |
2184 }; | 2170 }; |
2185 | 2171 |
2186 | 2172 |
2187 class LStoreKeyed FINAL : public LTemplateInstruction<0, 3, 0> { | 2173 class LStoreKeyed FINAL : public LTemplateInstruction<0, 3, 0> { |
2188 public: | 2174 public: |
2189 LStoreKeyed(LOperand* object, LOperand* key, LOperand* value) { | 2175 LStoreKeyed(LOperand* object, LOperand* key, LOperand* value) { |
2190 inputs_[0] = object; | 2176 inputs_[0] = object; |
(...skipping 11 matching lines...) Expand all Loading... |
2202 LOperand* elements() { return inputs_[0]; } | 2188 LOperand* elements() { return inputs_[0]; } |
2203 LOperand* key() { return inputs_[1]; } | 2189 LOperand* key() { return inputs_[1]; } |
2204 LOperand* value() { return inputs_[2]; } | 2190 LOperand* value() { return inputs_[2]; } |
2205 ElementsKind elements_kind() const { | 2191 ElementsKind elements_kind() const { |
2206 return hydrogen()->elements_kind(); | 2192 return hydrogen()->elements_kind(); |
2207 } | 2193 } |
2208 | 2194 |
2209 DECLARE_CONCRETE_INSTRUCTION(StoreKeyed, "store-keyed") | 2195 DECLARE_CONCRETE_INSTRUCTION(StoreKeyed, "store-keyed") |
2210 DECLARE_HYDROGEN_ACCESSOR(StoreKeyed) | 2196 DECLARE_HYDROGEN_ACCESSOR(StoreKeyed) |
2211 | 2197 |
2212 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2198 void PrintDataTo(StringStream* stream) OVERRIDE; |
2213 bool NeedsCanonicalization() { return hydrogen()->NeedsCanonicalization(); } | 2199 bool NeedsCanonicalization() { return hydrogen()->NeedsCanonicalization(); } |
2214 uint32_t base_offset() const { return hydrogen()->base_offset(); } | 2200 uint32_t base_offset() const { return hydrogen()->base_offset(); } |
2215 }; | 2201 }; |
2216 | 2202 |
2217 | 2203 |
2218 class LStoreKeyedGeneric FINAL : public LTemplateInstruction<0, 4, 0> { | 2204 class LStoreKeyedGeneric FINAL : public LTemplateInstruction<0, 4, 0> { |
2219 public: | 2205 public: |
2220 LStoreKeyedGeneric(LOperand* context, | 2206 LStoreKeyedGeneric(LOperand* context, |
2221 LOperand* obj, | 2207 LOperand* obj, |
2222 LOperand* key, | 2208 LOperand* key, |
2223 LOperand* value) { | 2209 LOperand* value) { |
2224 inputs_[0] = context; | 2210 inputs_[0] = context; |
2225 inputs_[1] = obj; | 2211 inputs_[1] = obj; |
2226 inputs_[2] = key; | 2212 inputs_[2] = key; |
2227 inputs_[3] = value; | 2213 inputs_[3] = value; |
2228 } | 2214 } |
2229 | 2215 |
2230 LOperand* context() { return inputs_[0]; } | 2216 LOperand* context() { return inputs_[0]; } |
2231 LOperand* object() { return inputs_[1]; } | 2217 LOperand* object() { return inputs_[1]; } |
2232 LOperand* key() { return inputs_[2]; } | 2218 LOperand* key() { return inputs_[2]; } |
2233 LOperand* value() { return inputs_[3]; } | 2219 LOperand* value() { return inputs_[3]; } |
2234 | 2220 |
2235 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic") | 2221 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic") |
2236 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric) | 2222 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric) |
2237 | 2223 |
2238 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2224 void PrintDataTo(StringStream* stream) OVERRIDE; |
2239 | 2225 |
2240 StrictMode strict_mode() { return hydrogen()->strict_mode(); } | 2226 StrictMode strict_mode() { return hydrogen()->strict_mode(); } |
2241 }; | 2227 }; |
2242 | 2228 |
2243 | 2229 |
2244 class LTransitionElementsKind FINAL : public LTemplateInstruction<0, 2, 1> { | 2230 class LTransitionElementsKind FINAL : public LTemplateInstruction<0, 2, 1> { |
2245 public: | 2231 public: |
2246 LTransitionElementsKind(LOperand* object, | 2232 LTransitionElementsKind(LOperand* object, |
2247 LOperand* context, | 2233 LOperand* context, |
2248 LOperand* new_map_temp) { | 2234 LOperand* new_map_temp) { |
2249 inputs_[0] = object; | 2235 inputs_[0] = object; |
2250 inputs_[1] = context; | 2236 inputs_[1] = context; |
2251 temps_[0] = new_map_temp; | 2237 temps_[0] = new_map_temp; |
2252 } | 2238 } |
2253 | 2239 |
2254 LOperand* context() { return inputs_[1]; } | 2240 LOperand* context() { return inputs_[1]; } |
2255 LOperand* object() { return inputs_[0]; } | 2241 LOperand* object() { return inputs_[0]; } |
2256 LOperand* new_map_temp() { return temps_[0]; } | 2242 LOperand* new_map_temp() { return temps_[0]; } |
2257 | 2243 |
2258 DECLARE_CONCRETE_INSTRUCTION(TransitionElementsKind, | 2244 DECLARE_CONCRETE_INSTRUCTION(TransitionElementsKind, |
2259 "transition-elements-kind") | 2245 "transition-elements-kind") |
2260 DECLARE_HYDROGEN_ACCESSOR(TransitionElementsKind) | 2246 DECLARE_HYDROGEN_ACCESSOR(TransitionElementsKind) |
2261 | 2247 |
2262 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2248 void PrintDataTo(StringStream* stream) OVERRIDE; |
2263 | 2249 |
2264 Handle<Map> original_map() { return hydrogen()->original_map().handle(); } | 2250 Handle<Map> original_map() { return hydrogen()->original_map().handle(); } |
2265 Handle<Map> transitioned_map() { | 2251 Handle<Map> transitioned_map() { |
2266 return hydrogen()->transitioned_map().handle(); | 2252 return hydrogen()->transitioned_map().handle(); |
2267 } | 2253 } |
2268 ElementsKind from_kind() { return hydrogen()->from_kind(); } | 2254 ElementsKind from_kind() { return hydrogen()->from_kind(); } |
2269 ElementsKind to_kind() { return hydrogen()->to_kind(); } | 2255 ElementsKind to_kind() { return hydrogen()->to_kind(); } |
2270 }; | 2256 }; |
2271 | 2257 |
2272 | 2258 |
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2548 inputs_[0] = value; | 2534 inputs_[0] = value; |
2549 } | 2535 } |
2550 | 2536 |
2551 LOperand* value() { return inputs_[0]; } | 2537 LOperand* value() { return inputs_[0]; } |
2552 | 2538 |
2553 DECLARE_CONCRETE_INSTRUCTION(TypeofIsAndBranch, "typeof-is-and-branch") | 2539 DECLARE_CONCRETE_INSTRUCTION(TypeofIsAndBranch, "typeof-is-and-branch") |
2554 DECLARE_HYDROGEN_ACCESSOR(TypeofIsAndBranch) | 2540 DECLARE_HYDROGEN_ACCESSOR(TypeofIsAndBranch) |
2555 | 2541 |
2556 Handle<String> type_literal() { return hydrogen()->type_literal(); } | 2542 Handle<String> type_literal() { return hydrogen()->type_literal(); } |
2557 | 2543 |
2558 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2544 void PrintDataTo(StringStream* stream) OVERRIDE; |
2559 }; | 2545 }; |
2560 | 2546 |
2561 | 2547 |
2562 class LIsConstructCallAndBranch FINAL : public LControlInstruction<0, 1> { | 2548 class LIsConstructCallAndBranch FINAL : public LControlInstruction<0, 1> { |
2563 public: | 2549 public: |
2564 explicit LIsConstructCallAndBranch(LOperand* temp) { | 2550 explicit LIsConstructCallAndBranch(LOperand* temp) { |
2565 temps_[0] = temp; | 2551 temps_[0] = temp; |
2566 } | 2552 } |
2567 | 2553 |
2568 LOperand* temp() { return temps_[0]; } | 2554 LOperand* temp() { return temps_[0]; } |
2569 | 2555 |
2570 DECLARE_CONCRETE_INSTRUCTION(IsConstructCallAndBranch, | 2556 DECLARE_CONCRETE_INSTRUCTION(IsConstructCallAndBranch, |
2571 "is-construct-call-and-branch") | 2557 "is-construct-call-and-branch") |
2572 }; | 2558 }; |
2573 | 2559 |
2574 | 2560 |
2575 class LOsrEntry FINAL : public LTemplateInstruction<0, 0, 0> { | 2561 class LOsrEntry FINAL : public LTemplateInstruction<0, 0, 0> { |
2576 public: | 2562 public: |
2577 LOsrEntry() {} | 2563 LOsrEntry() {} |
2578 | 2564 |
2579 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 2565 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
2580 return false; | |
2581 } | |
2582 DECLARE_CONCRETE_INSTRUCTION(OsrEntry, "osr-entry") | 2566 DECLARE_CONCRETE_INSTRUCTION(OsrEntry, "osr-entry") |
2583 }; | 2567 }; |
2584 | 2568 |
2585 | 2569 |
2586 class LStackCheck FINAL : public LTemplateInstruction<0, 1, 0> { | 2570 class LStackCheck FINAL : public LTemplateInstruction<0, 1, 0> { |
2587 public: | 2571 public: |
2588 explicit LStackCheck(LOperand* context) { | 2572 explicit LStackCheck(LOperand* context) { |
2589 inputs_[0] = context; | 2573 inputs_[0] = context; |
2590 } | 2574 } |
2591 | 2575 |
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2774 | 2758 |
2775 // An input operand in a register or a constant operand. | 2759 // An input operand in a register or a constant operand. |
2776 MUST_USE_RESULT LOperand* UseRegisterOrConstant(HValue* value); | 2760 MUST_USE_RESULT LOperand* UseRegisterOrConstant(HValue* value); |
2777 MUST_USE_RESULT LOperand* UseRegisterOrConstantAtStart(HValue* value); | 2761 MUST_USE_RESULT LOperand* UseRegisterOrConstantAtStart(HValue* value); |
2778 | 2762 |
2779 // An input operand in a constant operand. | 2763 // An input operand in a constant operand. |
2780 MUST_USE_RESULT LOperand* UseConstant(HValue* value); | 2764 MUST_USE_RESULT LOperand* UseConstant(HValue* value); |
2781 | 2765 |
2782 // An input operand in register, stack slot or a constant operand. | 2766 // An input operand in register, stack slot or a constant operand. |
2783 // Will not be moved to a register even if one is freely available. | 2767 // Will not be moved to a register even if one is freely available. |
2784 virtual MUST_USE_RESULT LOperand* UseAny(HValue* value) OVERRIDE; | 2768 MUST_USE_RESULT LOperand* UseAny(HValue* value) OVERRIDE; |
2785 | 2769 |
2786 // Temporary operand that must be in a register. | 2770 // Temporary operand that must be in a register. |
2787 MUST_USE_RESULT LUnallocated* TempRegister(); | 2771 MUST_USE_RESULT LUnallocated* TempRegister(); |
2788 MUST_USE_RESULT LUnallocated* TempDoubleRegister(); | 2772 MUST_USE_RESULT LUnallocated* TempDoubleRegister(); |
2789 MUST_USE_RESULT LOperand* FixedTemp(Register reg); | 2773 MUST_USE_RESULT LOperand* FixedTemp(Register reg); |
2790 MUST_USE_RESULT LOperand* FixedTemp(DoubleRegister reg); | 2774 MUST_USE_RESULT LOperand* FixedTemp(DoubleRegister reg); |
2791 | 2775 |
2792 // Methods for setting up define-use relationships. | 2776 // Methods for setting up define-use relationships. |
2793 // Return the same instruction that they are passed. | 2777 // Return the same instruction that they are passed. |
2794 LInstruction* Define(LTemplateResultInstruction<1>* instr, | 2778 LInstruction* Define(LTemplateResultInstruction<1>* instr, |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2832 | 2816 |
2833 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2817 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
2834 }; | 2818 }; |
2835 | 2819 |
2836 #undef DECLARE_HYDROGEN_ACCESSOR | 2820 #undef DECLARE_HYDROGEN_ACCESSOR |
2837 #undef DECLARE_CONCRETE_INSTRUCTION | 2821 #undef DECLARE_CONCRETE_INSTRUCTION |
2838 | 2822 |
2839 } } // namespace v8::internal | 2823 } } // namespace v8::internal |
2840 | 2824 |
2841 #endif // V8_MIPS_LITHIUM_MIPS_H_ | 2825 #endif // V8_MIPS_LITHIUM_MIPS_H_ |
OLD | NEW |