| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_ARM64_LITHIUM_ARM64_H_ | 5 #ifndef V8_ARM64_LITHIUM_ARM64_H_ |
| 6 #define V8_ARM64_LITHIUM_ARM64_H_ | 6 #define V8_ARM64_LITHIUM_ARM64_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 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 171 V(TransitionElementsKind) \ | 171 V(TransitionElementsKind) \ |
| 172 V(TrapAllocationMemento) \ | 172 V(TrapAllocationMemento) \ |
| 173 V(TruncateDoubleToIntOrSmi) \ | 173 V(TruncateDoubleToIntOrSmi) \ |
| 174 V(Typeof) \ | 174 V(Typeof) \ |
| 175 V(TypeofIsAndBranch) \ | 175 V(TypeofIsAndBranch) \ |
| 176 V(Uint32ToDouble) \ | 176 V(Uint32ToDouble) \ |
| 177 V(UnknownOSRValue) \ | 177 V(UnknownOSRValue) \ |
| 178 V(WrapReceiver) | 178 V(WrapReceiver) |
| 179 | 179 |
| 180 | 180 |
| 181 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ | 181 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ |
| 182 virtual Opcode opcode() const FINAL OVERRIDE { \ | 182 Opcode opcode() const FINAL { return LInstruction::k##type; } \ |
| 183 return LInstruction::k##type; \ | 183 void CompileToNative(LCodeGen* generator) FINAL; \ |
| 184 } \ | 184 const char* Mnemonic() const FINAL { return mnemonic; } \ |
| 185 virtual void CompileToNative(LCodeGen* generator) FINAL OVERRIDE; \ | 185 static L##type* cast(LInstruction* instr) { \ |
| 186 virtual const char* Mnemonic() const FINAL OVERRIDE { \ | 186 DCHECK(instr->Is##type()); \ |
| 187 return mnemonic; \ | 187 return reinterpret_cast<L##type*>(instr); \ |
| 188 } \ | |
| 189 static L##type* cast(LInstruction* instr) { \ | |
| 190 DCHECK(instr->Is##type()); \ | |
| 191 return reinterpret_cast<L##type*>(instr); \ | |
| 192 } | 188 } |
| 193 | 189 |
| 194 | 190 |
| 195 #define DECLARE_HYDROGEN_ACCESSOR(type) \ | 191 #define DECLARE_HYDROGEN_ACCESSOR(type) \ |
| 196 H##type* hydrogen() const { \ | 192 H##type* hydrogen() const { \ |
| 197 return H##type::cast(this->hydrogen_value()); \ | 193 return H##type::cast(this->hydrogen_value()); \ |
| 198 } | 194 } |
| 199 | 195 |
| 200 | 196 |
| 201 class LInstruction : public ZoneObject { | 197 class LInstruction : public ZoneObject { |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 int32_t bit_field_; | 284 int32_t bit_field_; |
| 289 }; | 285 }; |
| 290 | 286 |
| 291 | 287 |
| 292 // R = number of result operands (0 or 1). | 288 // R = number of result operands (0 or 1). |
| 293 template<int R> | 289 template<int R> |
| 294 class LTemplateResultInstruction : public LInstruction { | 290 class LTemplateResultInstruction : public LInstruction { |
| 295 public: | 291 public: |
| 296 // Allow 0 or 1 output operands. | 292 // Allow 0 or 1 output operands. |
| 297 STATIC_ASSERT(R == 0 || R == 1); | 293 STATIC_ASSERT(R == 0 || R == 1); |
| 298 virtual bool HasResult() const FINAL OVERRIDE { | 294 bool HasResult() const FINAL { return (R != 0) && (result() != NULL); } |
| 299 return (R != 0) && (result() != NULL); | |
| 300 } | |
| 301 void set_result(LOperand* operand) { results_[0] = operand; } | 295 void set_result(LOperand* operand) { results_[0] = operand; } |
| 302 LOperand* result() const { return results_[0]; } | 296 LOperand* result() const OVERRIDE { return results_[0]; } |
| 303 | 297 |
| 304 protected: | 298 protected: |
| 305 EmbeddedContainer<LOperand*, R> results_; | 299 EmbeddedContainer<LOperand*, R> results_; |
| 306 }; | 300 }; |
| 307 | 301 |
| 308 | 302 |
| 309 // R = number of result operands (0 or 1). | 303 // R = number of result operands (0 or 1). |
| 310 // I = number of input operands. | 304 // I = number of input operands. |
| 311 // T = number of temporary operands. | 305 // T = number of temporary operands. |
| 312 template<int R, int I, int T> | 306 template<int R, int I, int T> |
| 313 class LTemplateInstruction : public LTemplateResultInstruction<R> { | 307 class LTemplateInstruction : public LTemplateResultInstruction<R> { |
| 314 protected: | 308 protected: |
| 315 EmbeddedContainer<LOperand*, I> inputs_; | 309 EmbeddedContainer<LOperand*, I> inputs_; |
| 316 EmbeddedContainer<LOperand*, T> temps_; | 310 EmbeddedContainer<LOperand*, T> temps_; |
| 317 | 311 |
| 318 private: | 312 private: |
| 319 // Iterator support. | 313 // Iterator support. |
| 320 virtual int InputCount() FINAL OVERRIDE { return I; } | 314 int InputCount() FINAL { return I; } |
| 321 virtual LOperand* InputAt(int i) FINAL OVERRIDE { return inputs_[i]; } | 315 LOperand* InputAt(int i) FINAL { return inputs_[i]; } |
| 322 | 316 |
| 323 virtual int TempCount() FINAL OVERRIDE { return T; } | 317 int TempCount() FINAL { return T; } |
| 324 virtual LOperand* TempAt(int i) FINAL OVERRIDE { return temps_[i]; } | 318 LOperand* TempAt(int i) FINAL { return temps_[i]; } |
| 325 }; | 319 }; |
| 326 | 320 |
| 327 | 321 |
| 328 class LTailCallThroughMegamorphicCache FINAL | 322 class LTailCallThroughMegamorphicCache FINAL |
| 329 : public LTemplateInstruction<0, 3, 0> { | 323 : public LTemplateInstruction<0, 3, 0> { |
| 330 public: | 324 public: |
| 331 explicit LTailCallThroughMegamorphicCache(LOperand* context, | 325 explicit LTailCallThroughMegamorphicCache(LOperand* context, |
| 332 LOperand* receiver, | 326 LOperand* receiver, |
| 333 LOperand* name) { | 327 LOperand* name) { |
| 334 inputs_[0] = context; | 328 inputs_[0] = context; |
| 335 inputs_[1] = receiver; | 329 inputs_[1] = receiver; |
| 336 inputs_[2] = name; | 330 inputs_[2] = name; |
| 337 } | 331 } |
| 338 | 332 |
| 339 LOperand* context() { return inputs_[0]; } | 333 LOperand* context() { return inputs_[0]; } |
| 340 LOperand* receiver() { return inputs_[1]; } | 334 LOperand* receiver() { return inputs_[1]; } |
| 341 LOperand* name() { return inputs_[2]; } | 335 LOperand* name() { return inputs_[2]; } |
| 342 | 336 |
| 343 DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache, | 337 DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache, |
| 344 "tail-call-through-megamorphic-cache") | 338 "tail-call-through-megamorphic-cache") |
| 345 DECLARE_HYDROGEN_ACCESSOR(TailCallThroughMegamorphicCache) | 339 DECLARE_HYDROGEN_ACCESSOR(TailCallThroughMegamorphicCache) |
| 346 }; | 340 }; |
| 347 | 341 |
| 348 | 342 |
| 349 class LUnknownOSRValue FINAL : public LTemplateInstruction<1, 0, 0> { | 343 class LUnknownOSRValue FINAL : public LTemplateInstruction<1, 0, 0> { |
| 350 public: | 344 public: |
| 351 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 345 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
| 352 return false; | |
| 353 } | |
| 354 DECLARE_CONCRETE_INSTRUCTION(UnknownOSRValue, "unknown-osr-value") | 346 DECLARE_CONCRETE_INSTRUCTION(UnknownOSRValue, "unknown-osr-value") |
| 355 }; | 347 }; |
| 356 | 348 |
| 357 | 349 |
| 358 template<int I, int T> | 350 template<int I, int T> |
| 359 class LControlInstruction : public LTemplateInstruction<0, I, T> { | 351 class LControlInstruction : public LTemplateInstruction<0, I, T> { |
| 360 public: | 352 public: |
| 361 LControlInstruction() : false_label_(NULL), true_label_(NULL) { } | 353 LControlInstruction() : false_label_(NULL), true_label_(NULL) { } |
| 362 | 354 |
| 363 virtual bool IsControl() const FINAL OVERRIDE { return true; } | 355 bool IsControl() const FINAL { return true; } |
| 364 | 356 |
| 365 int SuccessorCount() { return hydrogen()->SuccessorCount(); } | 357 int SuccessorCount() { return hydrogen()->SuccessorCount(); } |
| 366 HBasicBlock* SuccessorAt(int i) { return hydrogen()->SuccessorAt(i); } | 358 HBasicBlock* SuccessorAt(int i) { return hydrogen()->SuccessorAt(i); } |
| 367 | 359 |
| 368 int TrueDestination(LChunk* chunk) { | 360 int TrueDestination(LChunk* chunk) { |
| 369 return chunk->LookupDestination(true_block_id()); | 361 return chunk->LookupDestination(true_block_id()); |
| 370 } | 362 } |
| 371 | 363 |
| 372 int FalseDestination(LChunk* chunk) { | 364 int FalseDestination(LChunk* chunk) { |
| 373 return chunk->LookupDestination(false_block_id()); | 365 return chunk->LookupDestination(false_block_id()); |
| (...skipping 29 matching lines...) Expand all Loading... |
| 403 public: | 395 public: |
| 404 explicit LGap(HBasicBlock* block) | 396 explicit LGap(HBasicBlock* block) |
| 405 : block_(block) { | 397 : block_(block) { |
| 406 parallel_moves_[BEFORE] = NULL; | 398 parallel_moves_[BEFORE] = NULL; |
| 407 parallel_moves_[START] = NULL; | 399 parallel_moves_[START] = NULL; |
| 408 parallel_moves_[END] = NULL; | 400 parallel_moves_[END] = NULL; |
| 409 parallel_moves_[AFTER] = NULL; | 401 parallel_moves_[AFTER] = NULL; |
| 410 } | 402 } |
| 411 | 403 |
| 412 // Can't use the DECLARE-macro here because of sub-classes. | 404 // Can't use the DECLARE-macro here because of sub-classes. |
| 413 virtual bool IsGap() const OVERRIDE { return true; } | 405 bool IsGap() const OVERRIDE { return true; } |
| 414 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 406 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 415 static LGap* cast(LInstruction* instr) { | 407 static LGap* cast(LInstruction* instr) { |
| 416 DCHECK(instr->IsGap()); | 408 DCHECK(instr->IsGap()); |
| 417 return reinterpret_cast<LGap*>(instr); | 409 return reinterpret_cast<LGap*>(instr); |
| 418 } | 410 } |
| 419 | 411 |
| 420 bool IsRedundant() const; | 412 bool IsRedundant() const; |
| 421 | 413 |
| 422 HBasicBlock* block() const { return block_; } | 414 HBasicBlock* block() const { return block_; } |
| 423 | 415 |
| 424 enum InnerPosition { | 416 enum InnerPosition { |
| (...skipping 19 matching lines...) Expand all Loading... |
| 444 private: | 436 private: |
| 445 LParallelMove* parallel_moves_[LAST_INNER_POSITION + 1]; | 437 LParallelMove* parallel_moves_[LAST_INNER_POSITION + 1]; |
| 446 HBasicBlock* block_; | 438 HBasicBlock* block_; |
| 447 }; | 439 }; |
| 448 | 440 |
| 449 | 441 |
| 450 class LInstructionGap FINAL : public LGap { | 442 class LInstructionGap FINAL : public LGap { |
| 451 public: | 443 public: |
| 452 explicit LInstructionGap(HBasicBlock* block) : LGap(block) { } | 444 explicit LInstructionGap(HBasicBlock* block) : LGap(block) { } |
| 453 | 445 |
| 454 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 446 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { |
| 455 return !IsRedundant(); | 447 return !IsRedundant(); |
| 456 } | 448 } |
| 457 | 449 |
| 458 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap") | 450 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap") |
| 459 }; | 451 }; |
| 460 | 452 |
| 461 | 453 |
| 462 class LDrop FINAL : public LTemplateInstruction<0, 0, 0> { | 454 class LDrop FINAL : public LTemplateInstruction<0, 0, 0> { |
| 463 public: | 455 public: |
| 464 explicit LDrop(int count) : count_(count) { } | 456 explicit LDrop(int count) : count_(count) { } |
| (...skipping 20 matching lines...) Expand all Loading... |
| 485 inputs_[0] = value; | 477 inputs_[0] = value; |
| 486 } | 478 } |
| 487 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use") | 479 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use") |
| 488 }; | 480 }; |
| 489 | 481 |
| 490 | 482 |
| 491 class LGoto FINAL : public LTemplateInstruction<0, 0, 0> { | 483 class LGoto FINAL : public LTemplateInstruction<0, 0, 0> { |
| 492 public: | 484 public: |
| 493 explicit LGoto(HBasicBlock* block) : block_(block) { } | 485 explicit LGoto(HBasicBlock* block) : block_(block) { } |
| 494 | 486 |
| 495 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE; | 487 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE; |
| 496 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto") | 488 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto") |
| 497 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 489 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 498 virtual bool IsControl() const OVERRIDE { return true; } | 490 bool IsControl() const OVERRIDE { return true; } |
| 499 | 491 |
| 500 int block_id() const { return block_->block_id(); } | 492 int block_id() const { return block_->block_id(); } |
| 501 | 493 |
| 502 private: | 494 private: |
| 503 HBasicBlock* block_; | 495 HBasicBlock* block_; |
| 504 }; | 496 }; |
| 505 | 497 |
| 506 | 498 |
| 507 class LLazyBailout FINAL : public LTemplateInstruction<0, 0, 0> { | 499 class LLazyBailout FINAL : public LTemplateInstruction<0, 0, 0> { |
| 508 public: | 500 public: |
| 509 LLazyBailout() : gap_instructions_size_(0) { } | 501 LLazyBailout() : gap_instructions_size_(0) { } |
| 510 | 502 |
| 511 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout") | 503 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout") |
| 512 | 504 |
| 513 void set_gap_instructions_size(int gap_instructions_size) { | 505 void set_gap_instructions_size(int gap_instructions_size) { |
| 514 gap_instructions_size_ = gap_instructions_size; | 506 gap_instructions_size_ = gap_instructions_size; |
| 515 } | 507 } |
| 516 int gap_instructions_size() { return gap_instructions_size_; } | 508 int gap_instructions_size() { return gap_instructions_size_; } |
| 517 | 509 |
| 518 private: | 510 private: |
| 519 int gap_instructions_size_; | 511 int gap_instructions_size_; |
| 520 }; | 512 }; |
| 521 | 513 |
| 522 | 514 |
| 523 class LLabel FINAL : public LGap { | 515 class LLabel FINAL : public LGap { |
| 524 public: | 516 public: |
| 525 explicit LLabel(HBasicBlock* block) | 517 explicit LLabel(HBasicBlock* block) |
| 526 : LGap(block), replacement_(NULL) { } | 518 : LGap(block), replacement_(NULL) { } |
| 527 | 519 |
| 528 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 520 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
| 529 return false; | |
| 530 } | |
| 531 DECLARE_CONCRETE_INSTRUCTION(Label, "label") | 521 DECLARE_CONCRETE_INSTRUCTION(Label, "label") |
| 532 | 522 |
| 533 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 523 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 534 | 524 |
| 535 int block_id() const { return block()->block_id(); } | 525 int block_id() const { return block()->block_id(); } |
| 536 bool is_loop_header() const { return block()->IsLoopHeader(); } | 526 bool is_loop_header() const { return block()->IsLoopHeader(); } |
| 537 bool is_osr_entry() const { return block()->is_osr_entry(); } | 527 bool is_osr_entry() const { return block()->is_osr_entry(); } |
| 538 Label* label() { return &label_; } | 528 Label* label() { return &label_; } |
| 539 LLabel* replacement() const { return replacement_; } | 529 LLabel* replacement() const { return replacement_; } |
| 540 void set_replacement(LLabel* label) { replacement_ = label; } | 530 void set_replacement(LLabel* label) { replacement_ = label; } |
| 541 bool HasReplacement() const { return replacement_ != NULL; } | 531 bool HasReplacement() const { return replacement_ != NULL; } |
| 542 | 532 |
| 543 private: | 533 private: |
| 544 Label label_; | 534 Label label_; |
| 545 LLabel* replacement_; | 535 LLabel* replacement_; |
| 546 }; | 536 }; |
| 547 | 537 |
| 548 | 538 |
| 549 class LOsrEntry FINAL : public LTemplateInstruction<0, 0, 0> { | 539 class LOsrEntry FINAL : public LTemplateInstruction<0, 0, 0> { |
| 550 public: | 540 public: |
| 551 LOsrEntry() {} | 541 LOsrEntry() {} |
| 552 | 542 |
| 553 virtual bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { | 543 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
| 554 return false; | |
| 555 } | |
| 556 DECLARE_CONCRETE_INSTRUCTION(OsrEntry, "osr-entry") | 544 DECLARE_CONCRETE_INSTRUCTION(OsrEntry, "osr-entry") |
| 557 }; | 545 }; |
| 558 | 546 |
| 559 | 547 |
| 560 class LAccessArgumentsAt FINAL : public LTemplateInstruction<1, 3, 0> { | 548 class LAccessArgumentsAt FINAL : public LTemplateInstruction<1, 3, 0> { |
| 561 public: | 549 public: |
| 562 LAccessArgumentsAt(LOperand* arguments, | 550 LAccessArgumentsAt(LOperand* arguments, |
| 563 LOperand* length, | 551 LOperand* length, |
| 564 LOperand* index) { | 552 LOperand* index) { |
| 565 inputs_[0] = arguments; | 553 inputs_[0] = arguments; |
| 566 inputs_[1] = length; | 554 inputs_[1] = length; |
| 567 inputs_[2] = index; | 555 inputs_[2] = index; |
| 568 } | 556 } |
| 569 | 557 |
| 570 DECLARE_CONCRETE_INSTRUCTION(AccessArgumentsAt, "access-arguments-at") | 558 DECLARE_CONCRETE_INSTRUCTION(AccessArgumentsAt, "access-arguments-at") |
| 571 | 559 |
| 572 LOperand* arguments() { return inputs_[0]; } | 560 LOperand* arguments() { return inputs_[0]; } |
| 573 LOperand* length() { return inputs_[1]; } | 561 LOperand* length() { return inputs_[1]; } |
| 574 LOperand* index() { return inputs_[2]; } | 562 LOperand* index() { return inputs_[2]; } |
| 575 | 563 |
| 576 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 564 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 577 }; | 565 }; |
| 578 | 566 |
| 579 | 567 |
| 580 class LAddE FINAL : public LTemplateInstruction<1, 2, 0> { | 568 class LAddE FINAL : public LTemplateInstruction<1, 2, 0> { |
| 581 public: | 569 public: |
| 582 LAddE(LOperand* left, LOperand* right) { | 570 LAddE(LOperand* left, LOperand* right) { |
| 583 inputs_[0] = left; | 571 inputs_[0] = left; |
| 584 inputs_[1] = right; | 572 inputs_[1] = right; |
| 585 } | 573 } |
| 586 | 574 |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 714 LOperand* right) | 702 LOperand* right) |
| 715 : op_(op) { | 703 : op_(op) { |
| 716 inputs_[0] = left; | 704 inputs_[0] = left; |
| 717 inputs_[1] = right; | 705 inputs_[1] = right; |
| 718 } | 706 } |
| 719 | 707 |
| 720 Token::Value op() const { return op_; } | 708 Token::Value op() const { return op_; } |
| 721 LOperand* left() { return inputs_[0]; } | 709 LOperand* left() { return inputs_[0]; } |
| 722 LOperand* right() { return inputs_[1]; } | 710 LOperand* right() { return inputs_[1]; } |
| 723 | 711 |
| 724 virtual Opcode opcode() const OVERRIDE { | 712 Opcode opcode() const OVERRIDE { return LInstruction::kArithmeticD; } |
| 725 return LInstruction::kArithmeticD; | 713 void CompileToNative(LCodeGen* generator) OVERRIDE; |
| 726 } | 714 const char* Mnemonic() const OVERRIDE; |
| 727 virtual void CompileToNative(LCodeGen* generator) OVERRIDE; | |
| 728 virtual const char* Mnemonic() const OVERRIDE; | |
| 729 | 715 |
| 730 private: | 716 private: |
| 731 Token::Value op_; | 717 Token::Value op_; |
| 732 }; | 718 }; |
| 733 | 719 |
| 734 | 720 |
| 735 class LArithmeticT FINAL : public LTemplateInstruction<1, 3, 0> { | 721 class LArithmeticT FINAL : public LTemplateInstruction<1, 3, 0> { |
| 736 public: | 722 public: |
| 737 LArithmeticT(Token::Value op, | 723 LArithmeticT(Token::Value op, |
| 738 LOperand* context, | 724 LOperand* context, |
| 739 LOperand* left, | 725 LOperand* left, |
| 740 LOperand* right) | 726 LOperand* right) |
| 741 : op_(op) { | 727 : op_(op) { |
| 742 inputs_[0] = context; | 728 inputs_[0] = context; |
| 743 inputs_[1] = left; | 729 inputs_[1] = left; |
| 744 inputs_[2] = right; | 730 inputs_[2] = right; |
| 745 } | 731 } |
| 746 | 732 |
| 747 LOperand* context() { return inputs_[0]; } | 733 LOperand* context() { return inputs_[0]; } |
| 748 LOperand* left() { return inputs_[1]; } | 734 LOperand* left() { return inputs_[1]; } |
| 749 LOperand* right() { return inputs_[2]; } | 735 LOperand* right() { return inputs_[2]; } |
| 750 Token::Value op() const { return op_; } | 736 Token::Value op() const { return op_; } |
| 751 | 737 |
| 752 virtual Opcode opcode() const OVERRIDE { | 738 Opcode opcode() const OVERRIDE { return LInstruction::kArithmeticT; } |
| 753 return LInstruction::kArithmeticT; | 739 void CompileToNative(LCodeGen* generator) OVERRIDE; |
| 754 } | 740 const char* Mnemonic() const OVERRIDE; |
| 755 virtual void CompileToNative(LCodeGen* generator) OVERRIDE; | |
| 756 virtual const char* Mnemonic() const OVERRIDE; | |
| 757 | 741 |
| 758 private: | 742 private: |
| 759 Token::Value op_; | 743 Token::Value op_; |
| 760 }; | 744 }; |
| 761 | 745 |
| 762 | 746 |
| 763 class LBoundsCheck FINAL : public LTemplateInstruction<0, 2, 0> { | 747 class LBoundsCheck FINAL : public LTemplateInstruction<0, 2, 0> { |
| 764 public: | 748 public: |
| 765 explicit LBoundsCheck(LOperand* index, LOperand* length) { | 749 explicit LBoundsCheck(LOperand* index, LOperand* length) { |
| 766 inputs_[0] = index; | 750 inputs_[0] = index; |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 831 temps_[1] = temp2; | 815 temps_[1] = temp2; |
| 832 } | 816 } |
| 833 | 817 |
| 834 LOperand* value() { return inputs_[0]; } | 818 LOperand* value() { return inputs_[0]; } |
| 835 LOperand* temp1() { return temps_[0]; } | 819 LOperand* temp1() { return temps_[0]; } |
| 836 LOperand* temp2() { return temps_[1]; } | 820 LOperand* temp2() { return temps_[1]; } |
| 837 | 821 |
| 838 DECLARE_CONCRETE_INSTRUCTION(Branch, "branch") | 822 DECLARE_CONCRETE_INSTRUCTION(Branch, "branch") |
| 839 DECLARE_HYDROGEN_ACCESSOR(Branch) | 823 DECLARE_HYDROGEN_ACCESSOR(Branch) |
| 840 | 824 |
| 841 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 825 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 842 }; | 826 }; |
| 843 | 827 |
| 844 | 828 |
| 845 class LCallJSFunction FINAL : public LTemplateInstruction<1, 1, 0> { | 829 class LCallJSFunction FINAL : public LTemplateInstruction<1, 1, 0> { |
| 846 public: | 830 public: |
| 847 explicit LCallJSFunction(LOperand* function) { | 831 explicit LCallJSFunction(LOperand* function) { |
| 848 inputs_[0] = function; | 832 inputs_[0] = function; |
| 849 } | 833 } |
| 850 | 834 |
| 851 LOperand* function() { return inputs_[0]; } | 835 LOperand* function() { return inputs_[0]; } |
| 852 | 836 |
| 853 DECLARE_CONCRETE_INSTRUCTION(CallJSFunction, "call-js-function") | 837 DECLARE_CONCRETE_INSTRUCTION(CallJSFunction, "call-js-function") |
| 854 DECLARE_HYDROGEN_ACCESSOR(CallJSFunction) | 838 DECLARE_HYDROGEN_ACCESSOR(CallJSFunction) |
| 855 | 839 |
| 856 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 840 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 857 | 841 |
| 858 int arity() const { return hydrogen()->argument_count() - 1; } | 842 int arity() const { return hydrogen()->argument_count() - 1; } |
| 859 }; | 843 }; |
| 860 | 844 |
| 861 | 845 |
| 862 class LCallFunction FINAL : public LTemplateInstruction<1, 2, 0> { | 846 class LCallFunction FINAL : public LTemplateInstruction<1, 2, 0> { |
| 863 public: | 847 public: |
| 864 LCallFunction(LOperand* context, LOperand* function) { | 848 LCallFunction(LOperand* context, LOperand* function) { |
| 865 inputs_[0] = context; | 849 inputs_[0] = context; |
| 866 inputs_[1] = function; | 850 inputs_[1] = function; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 882 inputs_[0] = context; | 866 inputs_[0] = context; |
| 883 inputs_[1] = constructor; | 867 inputs_[1] = constructor; |
| 884 } | 868 } |
| 885 | 869 |
| 886 LOperand* context() { return inputs_[0]; } | 870 LOperand* context() { return inputs_[0]; } |
| 887 LOperand* constructor() { return inputs_[1]; } | 871 LOperand* constructor() { return inputs_[1]; } |
| 888 | 872 |
| 889 DECLARE_CONCRETE_INSTRUCTION(CallNew, "call-new") | 873 DECLARE_CONCRETE_INSTRUCTION(CallNew, "call-new") |
| 890 DECLARE_HYDROGEN_ACCESSOR(CallNew) | 874 DECLARE_HYDROGEN_ACCESSOR(CallNew) |
| 891 | 875 |
| 892 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 876 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 893 | 877 |
| 894 int arity() const { return hydrogen()->argument_count() - 1; } | 878 int arity() const { return hydrogen()->argument_count() - 1; } |
| 895 }; | 879 }; |
| 896 | 880 |
| 897 | 881 |
| 898 class LCallNewArray FINAL : public LTemplateInstruction<1, 2, 0> { | 882 class LCallNewArray FINAL : public LTemplateInstruction<1, 2, 0> { |
| 899 public: | 883 public: |
| 900 LCallNewArray(LOperand* context, LOperand* constructor) { | 884 LCallNewArray(LOperand* context, LOperand* constructor) { |
| 901 inputs_[0] = context; | 885 inputs_[0] = context; |
| 902 inputs_[1] = constructor; | 886 inputs_[1] = constructor; |
| 903 } | 887 } |
| 904 | 888 |
| 905 LOperand* context() { return inputs_[0]; } | 889 LOperand* context() { return inputs_[0]; } |
| 906 LOperand* constructor() { return inputs_[1]; } | 890 LOperand* constructor() { return inputs_[1]; } |
| 907 | 891 |
| 908 DECLARE_CONCRETE_INSTRUCTION(CallNewArray, "call-new-array") | 892 DECLARE_CONCRETE_INSTRUCTION(CallNewArray, "call-new-array") |
| 909 DECLARE_HYDROGEN_ACCESSOR(CallNewArray) | 893 DECLARE_HYDROGEN_ACCESSOR(CallNewArray) |
| 910 | 894 |
| 911 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 895 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 912 | 896 |
| 913 int arity() const { return hydrogen()->argument_count() - 1; } | 897 int arity() const { return hydrogen()->argument_count() - 1; } |
| 914 }; | 898 }; |
| 915 | 899 |
| 916 | 900 |
| 917 class LCallRuntime FINAL : public LTemplateInstruction<1, 1, 0> { | 901 class LCallRuntime FINAL : public LTemplateInstruction<1, 1, 0> { |
| 918 public: | 902 public: |
| 919 explicit LCallRuntime(LOperand* context) { | 903 explicit LCallRuntime(LOperand* context) { |
| 920 inputs_[0] = context; | 904 inputs_[0] = context; |
| 921 } | 905 } |
| 922 | 906 |
| 923 LOperand* context() { return inputs_[0]; } | 907 LOperand* context() { return inputs_[0]; } |
| 924 | 908 |
| 925 DECLARE_CONCRETE_INSTRUCTION(CallRuntime, "call-runtime") | 909 DECLARE_CONCRETE_INSTRUCTION(CallRuntime, "call-runtime") |
| 926 DECLARE_HYDROGEN_ACCESSOR(CallRuntime) | 910 DECLARE_HYDROGEN_ACCESSOR(CallRuntime) |
| 927 | 911 |
| 928 virtual bool ClobbersDoubleRegisters(Isolate* isolate) const OVERRIDE { | 912 bool ClobbersDoubleRegisters(Isolate* isolate) const OVERRIDE { |
| 929 return save_doubles() == kDontSaveFPRegs; | 913 return save_doubles() == kDontSaveFPRegs; |
| 930 } | 914 } |
| 931 | 915 |
| 932 const Runtime::Function* function() const { return hydrogen()->function(); } | 916 const Runtime::Function* function() const { return hydrogen()->function(); } |
| 933 int arity() const { return hydrogen()->argument_count(); } | 917 int arity() const { return hydrogen()->argument_count(); } |
| 934 SaveFPRegsMode save_doubles() const { return hydrogen()->save_doubles(); } | 918 SaveFPRegsMode save_doubles() const { return hydrogen()->save_doubles(); } |
| 935 }; | 919 }; |
| 936 | 920 |
| 937 | 921 |
| 938 class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> { | 922 class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> { |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1090 } | 1074 } |
| 1091 | 1075 |
| 1092 LOperand* value() { return inputs_[0]; } | 1076 LOperand* value() { return inputs_[0]; } |
| 1093 LOperand* temp1() { return temps_[0]; } | 1077 LOperand* temp1() { return temps_[0]; } |
| 1094 LOperand* temp2() { return temps_[1]; } | 1078 LOperand* temp2() { return temps_[1]; } |
| 1095 | 1079 |
| 1096 DECLARE_CONCRETE_INSTRUCTION(ClassOfTestAndBranch, | 1080 DECLARE_CONCRETE_INSTRUCTION(ClassOfTestAndBranch, |
| 1097 "class-of-test-and-branch") | 1081 "class-of-test-and-branch") |
| 1098 DECLARE_HYDROGEN_ACCESSOR(ClassOfTestAndBranch) | 1082 DECLARE_HYDROGEN_ACCESSOR(ClassOfTestAndBranch) |
| 1099 | 1083 |
| 1100 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1084 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1101 }; | 1085 }; |
| 1102 | 1086 |
| 1103 | 1087 |
| 1104 class LCmpHoleAndBranchD FINAL : public LControlInstruction<1, 1> { | 1088 class LCmpHoleAndBranchD FINAL : public LControlInstruction<1, 1> { |
| 1105 public: | 1089 public: |
| 1106 explicit LCmpHoleAndBranchD(LOperand* object, LOperand* temp) { | 1090 explicit LCmpHoleAndBranchD(LOperand* object, LOperand* temp) { |
| 1107 inputs_[0] = object; | 1091 inputs_[0] = object; |
| 1108 temps_[0] = temp; | 1092 temps_[0] = temp; |
| 1109 } | 1093 } |
| 1110 | 1094 |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1208 | 1192 |
| 1209 DECLARE_CONCRETE_INSTRUCTION(CompareNumericAndBranch, | 1193 DECLARE_CONCRETE_INSTRUCTION(CompareNumericAndBranch, |
| 1210 "compare-numeric-and-branch") | 1194 "compare-numeric-and-branch") |
| 1211 DECLARE_HYDROGEN_ACCESSOR(CompareNumericAndBranch) | 1195 DECLARE_HYDROGEN_ACCESSOR(CompareNumericAndBranch) |
| 1212 | 1196 |
| 1213 Token::Value op() const { return hydrogen()->token(); } | 1197 Token::Value op() const { return hydrogen()->token(); } |
| 1214 bool is_double() const { | 1198 bool is_double() const { |
| 1215 return hydrogen()->representation().IsDouble(); | 1199 return hydrogen()->representation().IsDouble(); |
| 1216 } | 1200 } |
| 1217 | 1201 |
| 1218 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1202 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1219 }; | 1203 }; |
| 1220 | 1204 |
| 1221 | 1205 |
| 1222 class LConstantD FINAL : public LTemplateInstruction<1, 0, 0> { | 1206 class LConstantD FINAL : public LTemplateInstruction<1, 0, 0> { |
| 1223 public: | 1207 public: |
| 1224 DECLARE_CONCRETE_INSTRUCTION(ConstantD, "constant-d") | 1208 DECLARE_CONCRETE_INSTRUCTION(ConstantD, "constant-d") |
| 1225 DECLARE_HYDROGEN_ACCESSOR(Constant) | 1209 DECLARE_HYDROGEN_ACCESSOR(Constant) |
| 1226 | 1210 |
| 1227 double value() const { return hydrogen()->DoubleValue(); } | 1211 double value() const { return hydrogen()->DoubleValue(); } |
| 1228 }; | 1212 }; |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1306 | 1290 |
| 1307 LOperand* context() { return inputs_[0]; } | 1291 LOperand* context() { return inputs_[0]; } |
| 1308 | 1292 |
| 1309 DECLARE_CONCRETE_INSTRUCTION(DeclareGlobals, "declare-globals") | 1293 DECLARE_CONCRETE_INSTRUCTION(DeclareGlobals, "declare-globals") |
| 1310 DECLARE_HYDROGEN_ACCESSOR(DeclareGlobals) | 1294 DECLARE_HYDROGEN_ACCESSOR(DeclareGlobals) |
| 1311 }; | 1295 }; |
| 1312 | 1296 |
| 1313 | 1297 |
| 1314 class LDeoptimize FINAL : public LTemplateInstruction<0, 0, 0> { | 1298 class LDeoptimize FINAL : public LTemplateInstruction<0, 0, 0> { |
| 1315 public: | 1299 public: |
| 1316 virtual bool IsControl() const OVERRIDE { return true; } | 1300 bool IsControl() const OVERRIDE { return true; } |
| 1317 DECLARE_CONCRETE_INSTRUCTION(Deoptimize, "deoptimize") | 1301 DECLARE_CONCRETE_INSTRUCTION(Deoptimize, "deoptimize") |
| 1318 DECLARE_HYDROGEN_ACCESSOR(Deoptimize) | 1302 DECLARE_HYDROGEN_ACCESSOR(Deoptimize) |
| 1319 }; | 1303 }; |
| 1320 | 1304 |
| 1321 | 1305 |
| 1322 class LDivByPowerOf2I FINAL : public LTemplateInstruction<1, 1, 0> { | 1306 class LDivByPowerOf2I FINAL : public LTemplateInstruction<1, 1, 0> { |
| 1323 public: | 1307 public: |
| 1324 LDivByPowerOf2I(LOperand* dividend, int32_t divisor) { | 1308 LDivByPowerOf2I(LOperand* dividend, int32_t divisor) { |
| 1325 inputs_[0] = dividend; | 1309 inputs_[0] = dividend; |
| 1326 divisor_ = divisor; | 1310 divisor_ = divisor; |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1440 temps_[0] = temp; | 1424 temps_[0] = temp; |
| 1441 } | 1425 } |
| 1442 | 1426 |
| 1443 LOperand* value() { return inputs_[0]; } | 1427 LOperand* value() { return inputs_[0]; } |
| 1444 LOperand* temp() { return temps_[0]; } | 1428 LOperand* temp() { return temps_[0]; } |
| 1445 | 1429 |
| 1446 DECLARE_CONCRETE_INSTRUCTION(HasCachedArrayIndexAndBranch, | 1430 DECLARE_CONCRETE_INSTRUCTION(HasCachedArrayIndexAndBranch, |
| 1447 "has-cached-array-index-and-branch") | 1431 "has-cached-array-index-and-branch") |
| 1448 DECLARE_HYDROGEN_ACCESSOR(HasCachedArrayIndexAndBranch) | 1432 DECLARE_HYDROGEN_ACCESSOR(HasCachedArrayIndexAndBranch) |
| 1449 | 1433 |
| 1450 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1434 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1451 }; | 1435 }; |
| 1452 | 1436 |
| 1453 | 1437 |
| 1454 class LHasInstanceTypeAndBranch FINAL : public LControlInstruction<1, 1> { | 1438 class LHasInstanceTypeAndBranch FINAL : public LControlInstruction<1, 1> { |
| 1455 public: | 1439 public: |
| 1456 LHasInstanceTypeAndBranch(LOperand* value, LOperand* temp) { | 1440 LHasInstanceTypeAndBranch(LOperand* value, LOperand* temp) { |
| 1457 inputs_[0] = value; | 1441 inputs_[0] = value; |
| 1458 temps_[0] = temp; | 1442 temps_[0] = temp; |
| 1459 } | 1443 } |
| 1460 | 1444 |
| 1461 LOperand* value() { return inputs_[0]; } | 1445 LOperand* value() { return inputs_[0]; } |
| 1462 LOperand* temp() { return temps_[0]; } | 1446 LOperand* temp() { return temps_[0]; } |
| 1463 | 1447 |
| 1464 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch, | 1448 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch, |
| 1465 "has-instance-type-and-branch") | 1449 "has-instance-type-and-branch") |
| 1466 DECLARE_HYDROGEN_ACCESSOR(HasInstanceTypeAndBranch) | 1450 DECLARE_HYDROGEN_ACCESSOR(HasInstanceTypeAndBranch) |
| 1467 | 1451 |
| 1468 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1452 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1469 }; | 1453 }; |
| 1470 | 1454 |
| 1471 | 1455 |
| 1472 class LInnerAllocatedObject FINAL : public LTemplateInstruction<1, 2, 0> { | 1456 class LInnerAllocatedObject FINAL : public LTemplateInstruction<1, 2, 0> { |
| 1473 public: | 1457 public: |
| 1474 LInnerAllocatedObject(LOperand* base_object, LOperand* offset) { | 1458 LInnerAllocatedObject(LOperand* base_object, LOperand* offset) { |
| 1475 inputs_[0] = base_object; | 1459 inputs_[0] = base_object; |
| 1476 inputs_[1] = offset; | 1460 inputs_[1] = offset; |
| 1477 } | 1461 } |
| 1478 | 1462 |
| 1479 LOperand* base_object() const { return inputs_[0]; } | 1463 LOperand* base_object() const { return inputs_[0]; } |
| 1480 LOperand* offset() const { return inputs_[1]; } | 1464 LOperand* offset() const { return inputs_[1]; } |
| 1481 | 1465 |
| 1482 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1466 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1483 | 1467 |
| 1484 DECLARE_CONCRETE_INSTRUCTION(InnerAllocatedObject, "inner-allocated-object") | 1468 DECLARE_CONCRETE_INSTRUCTION(InnerAllocatedObject, "inner-allocated-object") |
| 1485 }; | 1469 }; |
| 1486 | 1470 |
| 1487 | 1471 |
| 1488 class LInstanceOf FINAL : public LTemplateInstruction<1, 3, 0> { | 1472 class LInstanceOf FINAL : public LTemplateInstruction<1, 3, 0> { |
| 1489 public: | 1473 public: |
| 1490 LInstanceOf(LOperand* context, LOperand* left, LOperand* right) { | 1474 LInstanceOf(LOperand* context, LOperand* left, LOperand* right) { |
| 1491 inputs_[0] = context; | 1475 inputs_[0] = context; |
| 1492 inputs_[1] = left; | 1476 inputs_[1] = left; |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1552 } | 1536 } |
| 1553 | 1537 |
| 1554 LOperand* target() const { return inputs_[0]; } | 1538 LOperand* target() const { return inputs_[0]; } |
| 1555 | 1539 |
| 1556 CallInterfaceDescriptor descriptor() { return descriptor_; } | 1540 CallInterfaceDescriptor descriptor() { return descriptor_; } |
| 1557 | 1541 |
| 1558 private: | 1542 private: |
| 1559 DECLARE_CONCRETE_INSTRUCTION(CallWithDescriptor, "call-with-descriptor") | 1543 DECLARE_CONCRETE_INSTRUCTION(CallWithDescriptor, "call-with-descriptor") |
| 1560 DECLARE_HYDROGEN_ACCESSOR(CallWithDescriptor) | 1544 DECLARE_HYDROGEN_ACCESSOR(CallWithDescriptor) |
| 1561 | 1545 |
| 1562 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1546 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1563 | 1547 |
| 1564 int arity() const { return hydrogen()->argument_count() - 1; } | 1548 int arity() const { return hydrogen()->argument_count() - 1; } |
| 1565 | 1549 |
| 1566 CallInterfaceDescriptor descriptor_; | 1550 CallInterfaceDescriptor descriptor_; |
| 1567 ZoneList<LOperand*> inputs_; | 1551 ZoneList<LOperand*> inputs_; |
| 1568 | 1552 |
| 1569 // Iterator support. | 1553 // Iterator support. |
| 1570 virtual int InputCount() FINAL OVERRIDE { return inputs_.length(); } | 1554 int InputCount() FINAL { return inputs_.length(); } |
| 1571 virtual LOperand* InputAt(int i) FINAL OVERRIDE { return inputs_[i]; } | 1555 LOperand* InputAt(int i) FINAL { return inputs_[i]; } |
| 1572 | 1556 |
| 1573 virtual int TempCount() FINAL OVERRIDE { return 0; } | 1557 int TempCount() FINAL { return 0; } |
| 1574 virtual LOperand* TempAt(int i) FINAL OVERRIDE { return NULL; } | 1558 LOperand* TempAt(int i) FINAL { return NULL; } |
| 1575 }; | 1559 }; |
| 1576 | 1560 |
| 1577 | 1561 |
| 1578 class LInvokeFunction FINAL : public LTemplateInstruction<1, 2, 0> { | 1562 class LInvokeFunction FINAL : public LTemplateInstruction<1, 2, 0> { |
| 1579 public: | 1563 public: |
| 1580 LInvokeFunction(LOperand* context, LOperand* function) { | 1564 LInvokeFunction(LOperand* context, LOperand* function) { |
| 1581 inputs_[0] = context; | 1565 inputs_[0] = context; |
| 1582 inputs_[1] = function; | 1566 inputs_[1] = function; |
| 1583 } | 1567 } |
| 1584 | 1568 |
| 1585 LOperand* context() { return inputs_[0]; } | 1569 LOperand* context() { return inputs_[0]; } |
| 1586 LOperand* function() { return inputs_[1]; } | 1570 LOperand* function() { return inputs_[1]; } |
| 1587 | 1571 |
| 1588 DECLARE_CONCRETE_INSTRUCTION(InvokeFunction, "invoke-function") | 1572 DECLARE_CONCRETE_INSTRUCTION(InvokeFunction, "invoke-function") |
| 1589 DECLARE_HYDROGEN_ACCESSOR(InvokeFunction) | 1573 DECLARE_HYDROGEN_ACCESSOR(InvokeFunction) |
| 1590 | 1574 |
| 1591 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1575 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1592 | 1576 |
| 1593 int arity() const { return hydrogen()->argument_count() - 1; } | 1577 int arity() const { return hydrogen()->argument_count() - 1; } |
| 1594 }; | 1578 }; |
| 1595 | 1579 |
| 1596 | 1580 |
| 1597 class LIsConstructCallAndBranch FINAL : public LControlInstruction<0, 2> { | 1581 class LIsConstructCallAndBranch FINAL : public LControlInstruction<0, 2> { |
| 1598 public: | 1582 public: |
| 1599 LIsConstructCallAndBranch(LOperand* temp1, LOperand* temp2) { | 1583 LIsConstructCallAndBranch(LOperand* temp1, LOperand* temp2) { |
| 1600 temps_[0] = temp1; | 1584 temps_[0] = temp1; |
| 1601 temps_[1] = temp2; | 1585 temps_[1] = temp2; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 1617 temps_[1] = temp2; | 1601 temps_[1] = temp2; |
| 1618 } | 1602 } |
| 1619 | 1603 |
| 1620 LOperand* value() { return inputs_[0]; } | 1604 LOperand* value() { return inputs_[0]; } |
| 1621 LOperand* temp1() { return temps_[0]; } | 1605 LOperand* temp1() { return temps_[0]; } |
| 1622 LOperand* temp2() { return temps_[1]; } | 1606 LOperand* temp2() { return temps_[1]; } |
| 1623 | 1607 |
| 1624 DECLARE_CONCRETE_INSTRUCTION(IsObjectAndBranch, "is-object-and-branch") | 1608 DECLARE_CONCRETE_INSTRUCTION(IsObjectAndBranch, "is-object-and-branch") |
| 1625 DECLARE_HYDROGEN_ACCESSOR(IsObjectAndBranch) | 1609 DECLARE_HYDROGEN_ACCESSOR(IsObjectAndBranch) |
| 1626 | 1610 |
| 1627 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1611 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1628 }; | 1612 }; |
| 1629 | 1613 |
| 1630 | 1614 |
| 1631 class LIsStringAndBranch FINAL : public LControlInstruction<1, 1> { | 1615 class LIsStringAndBranch FINAL : public LControlInstruction<1, 1> { |
| 1632 public: | 1616 public: |
| 1633 LIsStringAndBranch(LOperand* value, LOperand* temp) { | 1617 LIsStringAndBranch(LOperand* value, LOperand* temp) { |
| 1634 inputs_[0] = value; | 1618 inputs_[0] = value; |
| 1635 temps_[0] = temp; | 1619 temps_[0] = temp; |
| 1636 } | 1620 } |
| 1637 | 1621 |
| 1638 LOperand* value() { return inputs_[0]; } | 1622 LOperand* value() { return inputs_[0]; } |
| 1639 LOperand* temp() { return temps_[0]; } | 1623 LOperand* temp() { return temps_[0]; } |
| 1640 | 1624 |
| 1641 DECLARE_CONCRETE_INSTRUCTION(IsStringAndBranch, "is-string-and-branch") | 1625 DECLARE_CONCRETE_INSTRUCTION(IsStringAndBranch, "is-string-and-branch") |
| 1642 DECLARE_HYDROGEN_ACCESSOR(IsStringAndBranch) | 1626 DECLARE_HYDROGEN_ACCESSOR(IsStringAndBranch) |
| 1643 | 1627 |
| 1644 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1628 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1645 }; | 1629 }; |
| 1646 | 1630 |
| 1647 | 1631 |
| 1648 class LIsSmiAndBranch FINAL : public LControlInstruction<1, 0> { | 1632 class LIsSmiAndBranch FINAL : public LControlInstruction<1, 0> { |
| 1649 public: | 1633 public: |
| 1650 explicit LIsSmiAndBranch(LOperand* value) { | 1634 explicit LIsSmiAndBranch(LOperand* value) { |
| 1651 inputs_[0] = value; | 1635 inputs_[0] = value; |
| 1652 } | 1636 } |
| 1653 | 1637 |
| 1654 LOperand* value() { return inputs_[0]; } | 1638 LOperand* value() { return inputs_[0]; } |
| 1655 | 1639 |
| 1656 DECLARE_CONCRETE_INSTRUCTION(IsSmiAndBranch, "is-smi-and-branch") | 1640 DECLARE_CONCRETE_INSTRUCTION(IsSmiAndBranch, "is-smi-and-branch") |
| 1657 DECLARE_HYDROGEN_ACCESSOR(IsSmiAndBranch) | 1641 DECLARE_HYDROGEN_ACCESSOR(IsSmiAndBranch) |
| 1658 | 1642 |
| 1659 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1643 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1660 }; | 1644 }; |
| 1661 | 1645 |
| 1662 | 1646 |
| 1663 class LIsUndetectableAndBranch FINAL : public LControlInstruction<1, 1> { | 1647 class LIsUndetectableAndBranch FINAL : public LControlInstruction<1, 1> { |
| 1664 public: | 1648 public: |
| 1665 explicit LIsUndetectableAndBranch(LOperand* value, LOperand* temp) { | 1649 explicit LIsUndetectableAndBranch(LOperand* value, LOperand* temp) { |
| 1666 inputs_[0] = value; | 1650 inputs_[0] = value; |
| 1667 temps_[0] = temp; | 1651 temps_[0] = temp; |
| 1668 } | 1652 } |
| 1669 | 1653 |
| 1670 LOperand* value() { return inputs_[0]; } | 1654 LOperand* value() { return inputs_[0]; } |
| 1671 LOperand* temp() { return temps_[0]; } | 1655 LOperand* temp() { return temps_[0]; } |
| 1672 | 1656 |
| 1673 DECLARE_CONCRETE_INSTRUCTION(IsUndetectableAndBranch, | 1657 DECLARE_CONCRETE_INSTRUCTION(IsUndetectableAndBranch, |
| 1674 "is-undetectable-and-branch") | 1658 "is-undetectable-and-branch") |
| 1675 DECLARE_HYDROGEN_ACCESSOR(IsUndetectableAndBranch) | 1659 DECLARE_HYDROGEN_ACCESSOR(IsUndetectableAndBranch) |
| 1676 | 1660 |
| 1677 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1661 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1678 }; | 1662 }; |
| 1679 | 1663 |
| 1680 | 1664 |
| 1681 class LLoadContextSlot FINAL : public LTemplateInstruction<1, 1, 0> { | 1665 class LLoadContextSlot FINAL : public LTemplateInstruction<1, 1, 0> { |
| 1682 public: | 1666 public: |
| 1683 explicit LLoadContextSlot(LOperand* context) { | 1667 explicit LLoadContextSlot(LOperand* context) { |
| 1684 inputs_[0] = context; | 1668 inputs_[0] = context; |
| 1685 } | 1669 } |
| 1686 | 1670 |
| 1687 LOperand* context() { return inputs_[0]; } | 1671 LOperand* context() { return inputs_[0]; } |
| 1688 | 1672 |
| 1689 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot") | 1673 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot") |
| 1690 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot) | 1674 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot) |
| 1691 | 1675 |
| 1692 int slot_index() const { return hydrogen()->slot_index(); } | 1676 int slot_index() const { return hydrogen()->slot_index(); } |
| 1693 | 1677 |
| 1694 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 1678 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 1695 }; | 1679 }; |
| 1696 | 1680 |
| 1697 | 1681 |
| 1698 class LLoadNamedField FINAL : public LTemplateInstruction<1, 1, 0> { | 1682 class LLoadNamedField FINAL : public LTemplateInstruction<1, 1, 0> { |
| 1699 public: | 1683 public: |
| 1700 explicit LLoadNamedField(LOperand* object) { | 1684 explicit LLoadNamedField(LOperand* object) { |
| 1701 inputs_[0] = object; | 1685 inputs_[0] = object; |
| 1702 } | 1686 } |
| 1703 | 1687 |
| 1704 LOperand* object() { return inputs_[0]; } | 1688 LOperand* object() { return inputs_[0]; } |
| (...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2265 | 2249 |
| 2266 LOperand* temp() { return temps_[0]; } | 2250 LOperand* temp() { return temps_[0]; } |
| 2267 | 2251 |
| 2268 DECLARE_CONCRETE_INSTRUCTION(NumberUntagD, "double-untag") | 2252 DECLARE_CONCRETE_INSTRUCTION(NumberUntagD, "double-untag") |
| 2269 DECLARE_HYDROGEN_ACCESSOR(Change) | 2253 DECLARE_HYDROGEN_ACCESSOR(Change) |
| 2270 }; | 2254 }; |
| 2271 | 2255 |
| 2272 | 2256 |
| 2273 class LParameter FINAL : public LTemplateInstruction<1, 0, 0> { | 2257 class LParameter FINAL : public LTemplateInstruction<1, 0, 0> { |
| 2274 public: | 2258 public: |
| 2275 virtual bool HasInterestingComment(LCodeGen* gen) const { return false; } | 2259 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } |
| 2276 DECLARE_CONCRETE_INSTRUCTION(Parameter, "parameter") | 2260 DECLARE_CONCRETE_INSTRUCTION(Parameter, "parameter") |
| 2277 }; | 2261 }; |
| 2278 | 2262 |
| 2279 | 2263 |
| 2280 class LPower FINAL : public LTemplateInstruction<1, 2, 0> { | 2264 class LPower FINAL : public LTemplateInstruction<1, 2, 0> { |
| 2281 public: | 2265 public: |
| 2282 LPower(LOperand* left, LOperand* right) { | 2266 LPower(LOperand* left, LOperand* right) { |
| 2283 inputs_[0] = left; | 2267 inputs_[0] = left; |
| 2284 inputs_[1] = right; | 2268 inputs_[1] = right; |
| 2285 } | 2269 } |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2324 bool ShouldSplitPush() const { | 2308 bool ShouldSplitPush() const { |
| 2325 return inputs_.length() >= kRecommendedMaxPushedArgs; | 2309 return inputs_.length() >= kRecommendedMaxPushedArgs; |
| 2326 } | 2310 } |
| 2327 | 2311 |
| 2328 protected: | 2312 protected: |
| 2329 Zone* zone_; | 2313 Zone* zone_; |
| 2330 ZoneList<LOperand*> inputs_; | 2314 ZoneList<LOperand*> inputs_; |
| 2331 | 2315 |
| 2332 private: | 2316 private: |
| 2333 // Iterator support. | 2317 // Iterator support. |
| 2334 virtual int InputCount() FINAL OVERRIDE { return inputs_.length(); } | 2318 int InputCount() FINAL { return inputs_.length(); } |
| 2335 virtual LOperand* InputAt(int i) FINAL OVERRIDE { return inputs_[i]; } | 2319 LOperand* InputAt(int i) FINAL { return inputs_[i]; } |
| 2336 | 2320 |
| 2337 virtual int TempCount() FINAL OVERRIDE { return 0; } | 2321 int TempCount() FINAL { return 0; } |
| 2338 virtual LOperand* TempAt(int i) FINAL OVERRIDE { return NULL; } | 2322 LOperand* TempAt(int i) FINAL { return NULL; } |
| 2339 }; | 2323 }; |
| 2340 | 2324 |
| 2341 | 2325 |
| 2342 class LRegExpLiteral FINAL : public LTemplateInstruction<1, 1, 0> { | 2326 class LRegExpLiteral FINAL : public LTemplateInstruction<1, 1, 0> { |
| 2343 public: | 2327 public: |
| 2344 explicit LRegExpLiteral(LOperand* context) { | 2328 explicit LRegExpLiteral(LOperand* context) { |
| 2345 inputs_[0] = context; | 2329 inputs_[0] = context; |
| 2346 } | 2330 } |
| 2347 | 2331 |
| 2348 LOperand* context() { return inputs_[0]; } | 2332 LOperand* context() { return inputs_[0]; } |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2578 } | 2562 } |
| 2579 | 2563 |
| 2580 LOperand* context() { return inputs_[0]; } | 2564 LOperand* context() { return inputs_[0]; } |
| 2581 LOperand* object() { return inputs_[1]; } | 2565 LOperand* object() { return inputs_[1]; } |
| 2582 LOperand* key() { return inputs_[2]; } | 2566 LOperand* key() { return inputs_[2]; } |
| 2583 LOperand* value() { return inputs_[3]; } | 2567 LOperand* value() { return inputs_[3]; } |
| 2584 | 2568 |
| 2585 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic") | 2569 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic") |
| 2586 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric) | 2570 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric) |
| 2587 | 2571 |
| 2588 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2572 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2589 | 2573 |
| 2590 StrictMode strict_mode() { return hydrogen()->strict_mode(); } | 2574 StrictMode strict_mode() { return hydrogen()->strict_mode(); } |
| 2591 }; | 2575 }; |
| 2592 | 2576 |
| 2593 | 2577 |
| 2594 class LStoreNamedField FINAL : public LTemplateInstruction<0, 2, 2> { | 2578 class LStoreNamedField FINAL : public LTemplateInstruction<0, 2, 2> { |
| 2595 public: | 2579 public: |
| 2596 LStoreNamedField(LOperand* object, LOperand* value, | 2580 LStoreNamedField(LOperand* object, LOperand* value, |
| 2597 LOperand* temp0, LOperand* temp1) { | 2581 LOperand* temp0, LOperand* temp1) { |
| 2598 inputs_[0] = object; | 2582 inputs_[0] = object; |
| 2599 inputs_[1] = value; | 2583 inputs_[1] = value; |
| 2600 temps_[0] = temp0; | 2584 temps_[0] = temp0; |
| 2601 temps_[1] = temp1; | 2585 temps_[1] = temp1; |
| 2602 } | 2586 } |
| 2603 | 2587 |
| 2604 LOperand* object() { return inputs_[0]; } | 2588 LOperand* object() { return inputs_[0]; } |
| 2605 LOperand* value() { return inputs_[1]; } | 2589 LOperand* value() { return inputs_[1]; } |
| 2606 LOperand* temp0() { return temps_[0]; } | 2590 LOperand* temp0() { return temps_[0]; } |
| 2607 LOperand* temp1() { return temps_[1]; } | 2591 LOperand* temp1() { return temps_[1]; } |
| 2608 | 2592 |
| 2609 DECLARE_CONCRETE_INSTRUCTION(StoreNamedField, "store-named-field") | 2593 DECLARE_CONCRETE_INSTRUCTION(StoreNamedField, "store-named-field") |
| 2610 DECLARE_HYDROGEN_ACCESSOR(StoreNamedField) | 2594 DECLARE_HYDROGEN_ACCESSOR(StoreNamedField) |
| 2611 | 2595 |
| 2612 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2596 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2613 | 2597 |
| 2614 Representation representation() const { | 2598 Representation representation() const { |
| 2615 return hydrogen()->field_representation(); | 2599 return hydrogen()->field_representation(); |
| 2616 } | 2600 } |
| 2617 }; | 2601 }; |
| 2618 | 2602 |
| 2619 | 2603 |
| 2620 class LStoreNamedGeneric FINAL: public LTemplateInstruction<0, 3, 0> { | 2604 class LStoreNamedGeneric FINAL: public LTemplateInstruction<0, 3, 0> { |
| 2621 public: | 2605 public: |
| 2622 LStoreNamedGeneric(LOperand* context, LOperand* object, LOperand* value) { | 2606 LStoreNamedGeneric(LOperand* context, LOperand* object, LOperand* value) { |
| 2623 inputs_[0] = context; | 2607 inputs_[0] = context; |
| 2624 inputs_[1] = object; | 2608 inputs_[1] = object; |
| 2625 inputs_[2] = value; | 2609 inputs_[2] = value; |
| 2626 } | 2610 } |
| 2627 | 2611 |
| 2628 LOperand* context() { return inputs_[0]; } | 2612 LOperand* context() { return inputs_[0]; } |
| 2629 LOperand* object() { return inputs_[1]; } | 2613 LOperand* object() { return inputs_[1]; } |
| 2630 LOperand* value() { return inputs_[2]; } | 2614 LOperand* value() { return inputs_[2]; } |
| 2631 | 2615 |
| 2632 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic") | 2616 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic") |
| 2633 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric) | 2617 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric) |
| 2634 | 2618 |
| 2635 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2619 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2636 | 2620 |
| 2637 Handle<Object> name() const { return hydrogen()->name(); } | 2621 Handle<Object> name() const { return hydrogen()->name(); } |
| 2638 StrictMode strict_mode() { return hydrogen()->strict_mode(); } | 2622 StrictMode strict_mode() { return hydrogen()->strict_mode(); } |
| 2639 }; | 2623 }; |
| 2640 | 2624 |
| 2641 | 2625 |
| 2642 class LStringAdd FINAL : public LTemplateInstruction<1, 3, 0> { | 2626 class LStringAdd FINAL : public LTemplateInstruction<1, 3, 0> { |
| 2643 public: | 2627 public: |
| 2644 LStringAdd(LOperand* context, LOperand* left, LOperand* right) { | 2628 LStringAdd(LOperand* context, LOperand* left, LOperand* right) { |
| 2645 inputs_[0] = context; | 2629 inputs_[0] = context; |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2700 LOperand* context() { return inputs_[0]; } | 2684 LOperand* context() { return inputs_[0]; } |
| 2701 LOperand* left() { return inputs_[1]; } | 2685 LOperand* left() { return inputs_[1]; } |
| 2702 LOperand* right() { return inputs_[2]; } | 2686 LOperand* right() { return inputs_[2]; } |
| 2703 | 2687 |
| 2704 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch, | 2688 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch, |
| 2705 "string-compare-and-branch") | 2689 "string-compare-and-branch") |
| 2706 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch) | 2690 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch) |
| 2707 | 2691 |
| 2708 Token::Value op() const { return hydrogen()->token(); } | 2692 Token::Value op() const { return hydrogen()->token(); } |
| 2709 | 2693 |
| 2710 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2694 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2711 }; | 2695 }; |
| 2712 | 2696 |
| 2713 | 2697 |
| 2714 // Truncating conversion from a tagged value to an int32. | 2698 // Truncating conversion from a tagged value to an int32. |
| 2715 class LTaggedToI FINAL : public LTemplateInstruction<1, 1, 2> { | 2699 class LTaggedToI FINAL : public LTemplateInstruction<1, 1, 2> { |
| 2716 public: | 2700 public: |
| 2717 explicit LTaggedToI(LOperand* value, LOperand* temp1, LOperand* temp2) { | 2701 explicit LTaggedToI(LOperand* value, LOperand* temp1, LOperand* temp2) { |
| 2718 inputs_[0] = value; | 2702 inputs_[0] = value; |
| 2719 temps_[0] = temp1; | 2703 temps_[0] = temp1; |
| 2720 temps_[1] = temp2; | 2704 temps_[1] = temp2; |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2779 LOperand* temp) { | 2763 LOperand* temp) { |
| 2780 inputs_[0] = function; | 2764 inputs_[0] = function; |
| 2781 inputs_[1] = code_object; | 2765 inputs_[1] = code_object; |
| 2782 temps_[0] = temp; | 2766 temps_[0] = temp; |
| 2783 } | 2767 } |
| 2784 | 2768 |
| 2785 LOperand* function() { return inputs_[0]; } | 2769 LOperand* function() { return inputs_[0]; } |
| 2786 LOperand* code_object() { return inputs_[1]; } | 2770 LOperand* code_object() { return inputs_[1]; } |
| 2787 LOperand* temp() { return temps_[0]; } | 2771 LOperand* temp() { return temps_[0]; } |
| 2788 | 2772 |
| 2789 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2773 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2790 | 2774 |
| 2791 DECLARE_CONCRETE_INSTRUCTION(StoreCodeEntry, "store-code-entry") | 2775 DECLARE_CONCRETE_INSTRUCTION(StoreCodeEntry, "store-code-entry") |
| 2792 DECLARE_HYDROGEN_ACCESSOR(StoreCodeEntry) | 2776 DECLARE_HYDROGEN_ACCESSOR(StoreCodeEntry) |
| 2793 }; | 2777 }; |
| 2794 | 2778 |
| 2795 | 2779 |
| 2796 class LStoreContextSlot FINAL : public LTemplateInstruction<0, 2, 1> { | 2780 class LStoreContextSlot FINAL : public LTemplateInstruction<0, 2, 1> { |
| 2797 public: | 2781 public: |
| 2798 LStoreContextSlot(LOperand* context, LOperand* value, LOperand* temp) { | 2782 LStoreContextSlot(LOperand* context, LOperand* value, LOperand* temp) { |
| 2799 inputs_[0] = context; | 2783 inputs_[0] = context; |
| 2800 inputs_[1] = value; | 2784 inputs_[1] = value; |
| 2801 temps_[0] = temp; | 2785 temps_[0] = temp; |
| 2802 } | 2786 } |
| 2803 | 2787 |
| 2804 LOperand* context() { return inputs_[0]; } | 2788 LOperand* context() { return inputs_[0]; } |
| 2805 LOperand* value() { return inputs_[1]; } | 2789 LOperand* value() { return inputs_[1]; } |
| 2806 LOperand* temp() { return temps_[0]; } | 2790 LOperand* temp() { return temps_[0]; } |
| 2807 | 2791 |
| 2808 DECLARE_CONCRETE_INSTRUCTION(StoreContextSlot, "store-context-slot") | 2792 DECLARE_CONCRETE_INSTRUCTION(StoreContextSlot, "store-context-slot") |
| 2809 DECLARE_HYDROGEN_ACCESSOR(StoreContextSlot) | 2793 DECLARE_HYDROGEN_ACCESSOR(StoreContextSlot) |
| 2810 | 2794 |
| 2811 int slot_index() { return hydrogen()->slot_index(); } | 2795 int slot_index() { return hydrogen()->slot_index(); } |
| 2812 | 2796 |
| 2813 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2797 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2814 }; | 2798 }; |
| 2815 | 2799 |
| 2816 | 2800 |
| 2817 class LStoreGlobalCell FINAL : public LTemplateInstruction<0, 1, 2> { | 2801 class LStoreGlobalCell FINAL : public LTemplateInstruction<0, 1, 2> { |
| 2818 public: | 2802 public: |
| 2819 LStoreGlobalCell(LOperand* value, LOperand* temp1, LOperand* temp2) { | 2803 LStoreGlobalCell(LOperand* value, LOperand* temp1, LOperand* temp2) { |
| 2820 inputs_[0] = value; | 2804 inputs_[0] = value; |
| 2821 temps_[0] = temp1; | 2805 temps_[0] = temp1; |
| 2822 temps_[1] = temp2; | 2806 temps_[1] = temp2; |
| 2823 } | 2807 } |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2909 | 2893 |
| 2910 LOperand* object() { return inputs_[0]; } | 2894 LOperand* object() { return inputs_[0]; } |
| 2911 LOperand* context() { return inputs_[1]; } | 2895 LOperand* context() { return inputs_[1]; } |
| 2912 LOperand* temp1() { return temps_[0]; } | 2896 LOperand* temp1() { return temps_[0]; } |
| 2913 LOperand* temp2() { return temps_[1]; } | 2897 LOperand* temp2() { return temps_[1]; } |
| 2914 | 2898 |
| 2915 DECLARE_CONCRETE_INSTRUCTION(TransitionElementsKind, | 2899 DECLARE_CONCRETE_INSTRUCTION(TransitionElementsKind, |
| 2916 "transition-elements-kind") | 2900 "transition-elements-kind") |
| 2917 DECLARE_HYDROGEN_ACCESSOR(TransitionElementsKind) | 2901 DECLARE_HYDROGEN_ACCESSOR(TransitionElementsKind) |
| 2918 | 2902 |
| 2919 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2903 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2920 | 2904 |
| 2921 Handle<Map> original_map() { return hydrogen()->original_map().handle(); } | 2905 Handle<Map> original_map() { return hydrogen()->original_map().handle(); } |
| 2922 Handle<Map> transitioned_map() { | 2906 Handle<Map> transitioned_map() { |
| 2923 return hydrogen()->transitioned_map().handle(); | 2907 return hydrogen()->transitioned_map().handle(); |
| 2924 } | 2908 } |
| 2925 ElementsKind from_kind() const { return hydrogen()->from_kind(); } | 2909 ElementsKind from_kind() const { return hydrogen()->from_kind(); } |
| 2926 ElementsKind to_kind() const { return hydrogen()->to_kind(); } | 2910 ElementsKind to_kind() const { return hydrogen()->to_kind(); } |
| 2927 }; | 2911 }; |
| 2928 | 2912 |
| 2929 | 2913 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2984 | 2968 |
| 2985 LOperand* value() { return inputs_[0]; } | 2969 LOperand* value() { return inputs_[0]; } |
| 2986 LOperand* temp1() { return temps_[0]; } | 2970 LOperand* temp1() { return temps_[0]; } |
| 2987 LOperand* temp2() { return temps_[1]; } | 2971 LOperand* temp2() { return temps_[1]; } |
| 2988 | 2972 |
| 2989 DECLARE_CONCRETE_INSTRUCTION(TypeofIsAndBranch, "typeof-is-and-branch") | 2973 DECLARE_CONCRETE_INSTRUCTION(TypeofIsAndBranch, "typeof-is-and-branch") |
| 2990 DECLARE_HYDROGEN_ACCESSOR(TypeofIsAndBranch) | 2974 DECLARE_HYDROGEN_ACCESSOR(TypeofIsAndBranch) |
| 2991 | 2975 |
| 2992 Handle<String> type_literal() const { return hydrogen()->type_literal(); } | 2976 Handle<String> type_literal() const { return hydrogen()->type_literal(); } |
| 2993 | 2977 |
| 2994 virtual void PrintDataTo(StringStream* stream) OVERRIDE; | 2978 void PrintDataTo(StringStream* stream) OVERRIDE; |
| 2995 }; | 2979 }; |
| 2996 | 2980 |
| 2997 | 2981 |
| 2998 class LUint32ToDouble FINAL : public LTemplateInstruction<1, 1, 0> { | 2982 class LUint32ToDouble FINAL : public LTemplateInstruction<1, 1, 0> { |
| 2999 public: | 2983 public: |
| 3000 explicit LUint32ToDouble(LOperand* value) { | 2984 explicit LUint32ToDouble(LOperand* value) { |
| 3001 inputs_[0] = value; | 2985 inputs_[0] = value; |
| 3002 } | 2986 } |
| 3003 | 2987 |
| 3004 LOperand* value() { return inputs_[0]; } | 2988 LOperand* value() { return inputs_[0]; } |
| (...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3250 | 3234 |
| 3251 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 3235 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
| 3252 }; | 3236 }; |
| 3253 | 3237 |
| 3254 #undef DECLARE_HYDROGEN_ACCESSOR | 3238 #undef DECLARE_HYDROGEN_ACCESSOR |
| 3255 #undef DECLARE_CONCRETE_INSTRUCTION | 3239 #undef DECLARE_CONCRETE_INSTRUCTION |
| 3256 | 3240 |
| 3257 } } // namespace v8::internal | 3241 } } // namespace v8::internal |
| 3258 | 3242 |
| 3259 #endif // V8_ARM64_LITHIUM_ARM64_H_ | 3243 #endif // V8_ARM64_LITHIUM_ARM64_H_ |
| OLD | NEW |