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

Side by Side Diff: src/ppc/lithium-ppc.h

Issue 1088993003: Replace OVERRIDE->override and FINAL->final since we now require C++11. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/ppc/lithium-gap-resolver-ppc.h ('k') | src/preparser.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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_PPC_LITHIUM_PPC_H_ 5 #ifndef V8_PPC_LITHIUM_PPC_H_
6 #define V8_PPC_LITHIUM_PPC_H_ 6 #define V8_PPC_LITHIUM_PPC_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 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 V(TransitionElementsKind) \ 158 V(TransitionElementsKind) \
159 V(TrapAllocationMemento) \ 159 V(TrapAllocationMemento) \
160 V(Typeof) \ 160 V(Typeof) \
161 V(TypeofIsAndBranch) \ 161 V(TypeofIsAndBranch) \
162 V(Uint32ToDouble) \ 162 V(Uint32ToDouble) \
163 V(UnknownOSRValue) \ 163 V(UnknownOSRValue) \
164 V(WrapReceiver) 164 V(WrapReceiver)
165 165
166 166
167 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ 167 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \
168 Opcode opcode() const FINAL { return LInstruction::k##type; } \ 168 Opcode opcode() const final { return LInstruction::k##type; } \
169 void CompileToNative(LCodeGen* generator) FINAL; \ 169 void CompileToNative(LCodeGen* generator) final; \
170 const char* Mnemonic() const FINAL { return mnemonic; } \ 170 const char* Mnemonic() const final { return mnemonic; } \
171 static L##type* cast(LInstruction* instr) { \ 171 static L##type* cast(LInstruction* instr) { \
172 DCHECK(instr->Is##type()); \ 172 DCHECK(instr->Is##type()); \
173 return reinterpret_cast<L##type*>(instr); \ 173 return reinterpret_cast<L##type*>(instr); \
174 } 174 }
175 175
176 176
177 #define DECLARE_HYDROGEN_ACCESSOR(type) \ 177 #define DECLARE_HYDROGEN_ACCESSOR(type) \
178 H##type* hydrogen() const { return H##type::cast(hydrogen_value()); } 178 H##type* hydrogen() const { return H##type::cast(hydrogen_value()); }
179 179
180 180
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 int bit_field_; 274 int bit_field_;
275 }; 275 };
276 276
277 277
278 // R = number of result operands (0 or 1). 278 // R = number of result operands (0 or 1).
279 template <int R> 279 template <int R>
280 class LTemplateResultInstruction : public LInstruction { 280 class LTemplateResultInstruction : public LInstruction {
281 public: 281 public:
282 // Allow 0 or 1 output operands. 282 // Allow 0 or 1 output operands.
283 STATIC_ASSERT(R == 0 || R == 1); 283 STATIC_ASSERT(R == 0 || R == 1);
284 bool HasResult() const FINAL { return R != 0 && result() != NULL; } 284 bool HasResult() const final { return R != 0 && result() != NULL; }
285 void set_result(LOperand* operand) { results_[0] = operand; } 285 void set_result(LOperand* operand) { results_[0] = operand; }
286 LOperand* result() const OVERRIDE { return results_[0]; } 286 LOperand* result() const override { return results_[0]; }
287 287
288 protected: 288 protected:
289 EmbeddedContainer<LOperand*, R> results_; 289 EmbeddedContainer<LOperand*, R> results_;
290 }; 290 };
291 291
292 292
293 // R = number of result operands (0 or 1). 293 // R = number of result operands (0 or 1).
294 // I = number of input operands. 294 // I = number of input operands.
295 // T = number of temporary operands. 295 // T = number of temporary operands.
296 template <int R, int I, int T> 296 template <int R, int I, int T>
297 class LTemplateInstruction : public LTemplateResultInstruction<R> { 297 class LTemplateInstruction : public LTemplateResultInstruction<R> {
298 protected: 298 protected:
299 EmbeddedContainer<LOperand*, I> inputs_; 299 EmbeddedContainer<LOperand*, I> inputs_;
300 EmbeddedContainer<LOperand*, T> temps_; 300 EmbeddedContainer<LOperand*, T> temps_;
301 301
302 private: 302 private:
303 // Iterator support. 303 // Iterator support.
304 int InputCount() FINAL { return I; } 304 int InputCount() final { return I; }
305 LOperand* InputAt(int i) FINAL { return inputs_[i]; } 305 LOperand* InputAt(int i) final { return inputs_[i]; }
306 306
307 int TempCount() FINAL { return T; } 307 int TempCount() final { return T; }
308 LOperand* TempAt(int i) FINAL { return temps_[i]; } 308 LOperand* TempAt(int i) final { return temps_[i]; }
309 }; 309 };
310 310
311 311
312 class LGap : public LTemplateInstruction<0, 0, 0> { 312 class LGap : public LTemplateInstruction<0, 0, 0> {
313 public: 313 public:
314 explicit LGap(HBasicBlock* block) : block_(block) { 314 explicit LGap(HBasicBlock* block) : block_(block) {
315 parallel_moves_[BEFORE] = NULL; 315 parallel_moves_[BEFORE] = NULL;
316 parallel_moves_[START] = NULL; 316 parallel_moves_[START] = NULL;
317 parallel_moves_[END] = NULL; 317 parallel_moves_[END] = NULL;
318 parallel_moves_[AFTER] = NULL; 318 parallel_moves_[AFTER] = NULL;
319 } 319 }
320 320
321 // Can't use the DECLARE-macro here because of sub-classes. 321 // Can't use the DECLARE-macro here because of sub-classes.
322 bool IsGap() const OVERRIDE { return true; } 322 bool IsGap() const override { return true; }
323 void PrintDataTo(StringStream* stream) OVERRIDE; 323 void PrintDataTo(StringStream* stream) override;
324 static LGap* cast(LInstruction* instr) { 324 static LGap* cast(LInstruction* instr) {
325 DCHECK(instr->IsGap()); 325 DCHECK(instr->IsGap());
326 return reinterpret_cast<LGap*>(instr); 326 return reinterpret_cast<LGap*>(instr);
327 } 327 }
328 328
329 bool IsRedundant() const; 329 bool IsRedundant() const;
330 330
331 HBasicBlock* block() const { return block_; } 331 HBasicBlock* block() const { return block_; }
332 332
333 enum InnerPosition { 333 enum InnerPosition {
(...skipping 15 matching lines...) Expand all
349 LParallelMove* GetParallelMove(InnerPosition pos) { 349 LParallelMove* GetParallelMove(InnerPosition pos) {
350 return parallel_moves_[pos]; 350 return parallel_moves_[pos];
351 } 351 }
352 352
353 private: 353 private:
354 LParallelMove* parallel_moves_[LAST_INNER_POSITION + 1]; 354 LParallelMove* parallel_moves_[LAST_INNER_POSITION + 1];
355 HBasicBlock* block_; 355 HBasicBlock* block_;
356 }; 356 };
357 357
358 358
359 class LInstructionGap FINAL : public LGap { 359 class LInstructionGap final : public LGap {
360 public: 360 public:
361 explicit LInstructionGap(HBasicBlock* block) : LGap(block) {} 361 explicit LInstructionGap(HBasicBlock* block) : LGap(block) {}
362 362
363 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { 363 bool HasInterestingComment(LCodeGen* gen) const override {
364 return !IsRedundant(); 364 return !IsRedundant();
365 } 365 }
366 366
367 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap") 367 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap")
368 }; 368 };
369 369
370 370
371 class LGoto FINAL : public LTemplateInstruction<0, 0, 0> { 371 class LGoto final : public LTemplateInstruction<0, 0, 0> {
372 public: 372 public:
373 explicit LGoto(HBasicBlock* block) : block_(block) {} 373 explicit LGoto(HBasicBlock* block) : block_(block) {}
374 374
375 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE; 375 bool HasInterestingComment(LCodeGen* gen) const override;
376 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto") 376 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto")
377 void PrintDataTo(StringStream* stream) OVERRIDE; 377 void PrintDataTo(StringStream* stream) override;
378 bool IsControl() const OVERRIDE { return true; } 378 bool IsControl() const override { return true; }
379 379
380 int block_id() const { return block_->block_id(); } 380 int block_id() const { return block_->block_id(); }
381 381
382 private: 382 private:
383 HBasicBlock* block_; 383 HBasicBlock* block_;
384 }; 384 };
385 385
386 386
387 class LLazyBailout FINAL : public LTemplateInstruction<0, 0, 0> { 387 class LLazyBailout final : public LTemplateInstruction<0, 0, 0> {
388 public: 388 public:
389 LLazyBailout() : gap_instructions_size_(0) {} 389 LLazyBailout() : gap_instructions_size_(0) {}
390 390
391 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout") 391 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout")
392 392
393 void set_gap_instructions_size(int gap_instructions_size) { 393 void set_gap_instructions_size(int gap_instructions_size) {
394 gap_instructions_size_ = gap_instructions_size; 394 gap_instructions_size_ = gap_instructions_size;
395 } 395 }
396 int gap_instructions_size() { return gap_instructions_size_; } 396 int gap_instructions_size() { return gap_instructions_size_; }
397 397
398 private: 398 private:
399 int gap_instructions_size_; 399 int gap_instructions_size_;
400 }; 400 };
401 401
402 402
403 class LDummy FINAL : public LTemplateInstruction<1, 0, 0> { 403 class LDummy final : public LTemplateInstruction<1, 0, 0> {
404 public: 404 public:
405 LDummy() {} 405 LDummy() {}
406 DECLARE_CONCRETE_INSTRUCTION(Dummy, "dummy") 406 DECLARE_CONCRETE_INSTRUCTION(Dummy, "dummy")
407 }; 407 };
408 408
409 409
410 class LDummyUse FINAL : public LTemplateInstruction<1, 1, 0> { 410 class LDummyUse final : public LTemplateInstruction<1, 1, 0> {
411 public: 411 public:
412 explicit LDummyUse(LOperand* value) { inputs_[0] = value; } 412 explicit LDummyUse(LOperand* value) { inputs_[0] = value; }
413 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use") 413 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use")
414 }; 414 };
415 415
416 416
417 class LDeoptimize FINAL : public LTemplateInstruction<0, 0, 0> { 417 class LDeoptimize final : public LTemplateInstruction<0, 0, 0> {
418 public: 418 public:
419 bool IsControl() const OVERRIDE { return true; } 419 bool IsControl() const override { return true; }
420 DECLARE_CONCRETE_INSTRUCTION(Deoptimize, "deoptimize") 420 DECLARE_CONCRETE_INSTRUCTION(Deoptimize, "deoptimize")
421 DECLARE_HYDROGEN_ACCESSOR(Deoptimize) 421 DECLARE_HYDROGEN_ACCESSOR(Deoptimize)
422 }; 422 };
423 423
424 424
425 class LLabel FINAL : public LGap { 425 class LLabel final : public LGap {
426 public: 426 public:
427 explicit LLabel(HBasicBlock* block) : LGap(block), replacement_(NULL) {} 427 explicit LLabel(HBasicBlock* block) : LGap(block), replacement_(NULL) {}
428 428
429 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } 429 bool HasInterestingComment(LCodeGen* gen) const override { return false; }
430 DECLARE_CONCRETE_INSTRUCTION(Label, "label") 430 DECLARE_CONCRETE_INSTRUCTION(Label, "label")
431 431
432 void PrintDataTo(StringStream* stream) OVERRIDE; 432 void PrintDataTo(StringStream* stream) override;
433 433
434 int block_id() const { return block()->block_id(); } 434 int block_id() const { return block()->block_id(); }
435 bool is_loop_header() const { return block()->IsLoopHeader(); } 435 bool is_loop_header() const { return block()->IsLoopHeader(); }
436 bool is_osr_entry() const { return block()->is_osr_entry(); } 436 bool is_osr_entry() const { return block()->is_osr_entry(); }
437 Label* label() { return &label_; } 437 Label* label() { return &label_; }
438 LLabel* replacement() const { return replacement_; } 438 LLabel* replacement() const { return replacement_; }
439 void set_replacement(LLabel* label) { replacement_ = label; } 439 void set_replacement(LLabel* label) { replacement_ = label; }
440 bool HasReplacement() const { return replacement_ != NULL; } 440 bool HasReplacement() const { return replacement_ != NULL; }
441 441
442 private: 442 private:
443 Label label_; 443 Label label_;
444 LLabel* replacement_; 444 LLabel* replacement_;
445 }; 445 };
446 446
447 447
448 class LParameter FINAL : public LTemplateInstruction<1, 0, 0> { 448 class LParameter final : public LTemplateInstruction<1, 0, 0> {
449 public: 449 public:
450 virtual bool HasInterestingComment(LCodeGen* gen) const { return false; } 450 virtual bool HasInterestingComment(LCodeGen* gen) const { return false; }
451 DECLARE_CONCRETE_INSTRUCTION(Parameter, "parameter") 451 DECLARE_CONCRETE_INSTRUCTION(Parameter, "parameter")
452 }; 452 };
453 453
454 454
455 class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> { 455 class LCallStub final : public LTemplateInstruction<1, 1, 0> {
456 public: 456 public:
457 explicit LCallStub(LOperand* context) { inputs_[0] = context; } 457 explicit LCallStub(LOperand* context) { inputs_[0] = context; }
458 458
459 LOperand* context() { return inputs_[0]; } 459 LOperand* context() { return inputs_[0]; }
460 460
461 DECLARE_CONCRETE_INSTRUCTION(CallStub, "call-stub") 461 DECLARE_CONCRETE_INSTRUCTION(CallStub, "call-stub")
462 DECLARE_HYDROGEN_ACCESSOR(CallStub) 462 DECLARE_HYDROGEN_ACCESSOR(CallStub)
463 }; 463 };
464 464
465 465
466 class LTailCallThroughMegamorphicCache FINAL 466 class LTailCallThroughMegamorphicCache final
467 : public LTemplateInstruction<0, 3, 0> { 467 : public LTemplateInstruction<0, 3, 0> {
468 public: 468 public:
469 LTailCallThroughMegamorphicCache(LOperand* context, LOperand* receiver, 469 LTailCallThroughMegamorphicCache(LOperand* context, LOperand* receiver,
470 LOperand* name) { 470 LOperand* name) {
471 inputs_[0] = context; 471 inputs_[0] = context;
472 inputs_[1] = receiver; 472 inputs_[1] = receiver;
473 inputs_[2] = name; 473 inputs_[2] = name;
474 } 474 }
475 475
476 LOperand* context() { return inputs_[0]; } 476 LOperand* context() { return inputs_[0]; }
477 LOperand* receiver() { return inputs_[1]; } 477 LOperand* receiver() { return inputs_[1]; }
478 LOperand* name() { return inputs_[2]; } 478 LOperand* name() { return inputs_[2]; }
479 479
480 DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache, 480 DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache,
481 "tail-call-through-megamorphic-cache") 481 "tail-call-through-megamorphic-cache")
482 DECLARE_HYDROGEN_ACCESSOR(TailCallThroughMegamorphicCache) 482 DECLARE_HYDROGEN_ACCESSOR(TailCallThroughMegamorphicCache)
483 }; 483 };
484 484
485 485
486 class LUnknownOSRValue FINAL : public LTemplateInstruction<1, 0, 0> { 486 class LUnknownOSRValue final : public LTemplateInstruction<1, 0, 0> {
487 public: 487 public:
488 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } 488 bool HasInterestingComment(LCodeGen* gen) const override { return false; }
489 DECLARE_CONCRETE_INSTRUCTION(UnknownOSRValue, "unknown-osr-value") 489 DECLARE_CONCRETE_INSTRUCTION(UnknownOSRValue, "unknown-osr-value")
490 }; 490 };
491 491
492 492
493 template <int I, int T> 493 template <int I, int T>
494 class LControlInstruction : public LTemplateInstruction<0, I, T> { 494 class LControlInstruction : public LTemplateInstruction<0, I, T> {
495 public: 495 public:
496 LControlInstruction() : false_label_(NULL), true_label_(NULL) {} 496 LControlInstruction() : false_label_(NULL), true_label_(NULL) {}
497 497
498 bool IsControl() const FINAL { return true; } 498 bool IsControl() const final { return true; }
499 499
500 int SuccessorCount() { return hydrogen()->SuccessorCount(); } 500 int SuccessorCount() { return hydrogen()->SuccessorCount(); }
501 HBasicBlock* SuccessorAt(int i) { return hydrogen()->SuccessorAt(i); } 501 HBasicBlock* SuccessorAt(int i) { return hydrogen()->SuccessorAt(i); }
502 502
503 int TrueDestination(LChunk* chunk) { 503 int TrueDestination(LChunk* chunk) {
504 return chunk->LookupDestination(true_block_id()); 504 return chunk->LookupDestination(true_block_id());
505 } 505 }
506 int FalseDestination(LChunk* chunk) { 506 int FalseDestination(LChunk* chunk) {
507 return chunk->LookupDestination(false_block_id()); 507 return chunk->LookupDestination(false_block_id());
508 } 508 }
(...skipping 18 matching lines...) Expand all
527 private: 527 private:
528 HControlInstruction* hydrogen() { 528 HControlInstruction* hydrogen() {
529 return HControlInstruction::cast(this->hydrogen_value()); 529 return HControlInstruction::cast(this->hydrogen_value());
530 } 530 }
531 531
532 Label* false_label_; 532 Label* false_label_;
533 Label* true_label_; 533 Label* true_label_;
534 }; 534 };
535 535
536 536
537 class LWrapReceiver FINAL : public LTemplateInstruction<1, 2, 0> { 537 class LWrapReceiver final : public LTemplateInstruction<1, 2, 0> {
538 public: 538 public:
539 LWrapReceiver(LOperand* receiver, LOperand* function) { 539 LWrapReceiver(LOperand* receiver, LOperand* function) {
540 inputs_[0] = receiver; 540 inputs_[0] = receiver;
541 inputs_[1] = function; 541 inputs_[1] = function;
542 } 542 }
543 543
544 DECLARE_CONCRETE_INSTRUCTION(WrapReceiver, "wrap-receiver") 544 DECLARE_CONCRETE_INSTRUCTION(WrapReceiver, "wrap-receiver")
545 DECLARE_HYDROGEN_ACCESSOR(WrapReceiver) 545 DECLARE_HYDROGEN_ACCESSOR(WrapReceiver)
546 546
547 LOperand* receiver() { return inputs_[0]; } 547 LOperand* receiver() { return inputs_[0]; }
548 LOperand* function() { return inputs_[1]; } 548 LOperand* function() { return inputs_[1]; }
549 }; 549 };
550 550
551 551
552 class LApplyArguments FINAL : public LTemplateInstruction<1, 4, 0> { 552 class LApplyArguments final : public LTemplateInstruction<1, 4, 0> {
553 public: 553 public:
554 LApplyArguments(LOperand* function, LOperand* receiver, LOperand* length, 554 LApplyArguments(LOperand* function, LOperand* receiver, LOperand* length,
555 LOperand* elements) { 555 LOperand* elements) {
556 inputs_[0] = function; 556 inputs_[0] = function;
557 inputs_[1] = receiver; 557 inputs_[1] = receiver;
558 inputs_[2] = length; 558 inputs_[2] = length;
559 inputs_[3] = elements; 559 inputs_[3] = elements;
560 } 560 }
561 561
562 DECLARE_CONCRETE_INSTRUCTION(ApplyArguments, "apply-arguments") 562 DECLARE_CONCRETE_INSTRUCTION(ApplyArguments, "apply-arguments")
563 563
564 LOperand* function() { return inputs_[0]; } 564 LOperand* function() { return inputs_[0]; }
565 LOperand* receiver() { return inputs_[1]; } 565 LOperand* receiver() { return inputs_[1]; }
566 LOperand* length() { return inputs_[2]; } 566 LOperand* length() { return inputs_[2]; }
567 LOperand* elements() { return inputs_[3]; } 567 LOperand* elements() { return inputs_[3]; }
568 }; 568 };
569 569
570 570
571 class LAccessArgumentsAt FINAL : public LTemplateInstruction<1, 3, 0> { 571 class LAccessArgumentsAt final : public LTemplateInstruction<1, 3, 0> {
572 public: 572 public:
573 LAccessArgumentsAt(LOperand* arguments, LOperand* length, LOperand* index) { 573 LAccessArgumentsAt(LOperand* arguments, LOperand* length, LOperand* index) {
574 inputs_[0] = arguments; 574 inputs_[0] = arguments;
575 inputs_[1] = length; 575 inputs_[1] = length;
576 inputs_[2] = index; 576 inputs_[2] = index;
577 } 577 }
578 578
579 DECLARE_CONCRETE_INSTRUCTION(AccessArgumentsAt, "access-arguments-at") 579 DECLARE_CONCRETE_INSTRUCTION(AccessArgumentsAt, "access-arguments-at")
580 580
581 LOperand* arguments() { return inputs_[0]; } 581 LOperand* arguments() { return inputs_[0]; }
582 LOperand* length() { return inputs_[1]; } 582 LOperand* length() { return inputs_[1]; }
583 LOperand* index() { return inputs_[2]; } 583 LOperand* index() { return inputs_[2]; }
584 584
585 void PrintDataTo(StringStream* stream) OVERRIDE; 585 void PrintDataTo(StringStream* stream) override;
586 }; 586 };
587 587
588 588
589 class LArgumentsLength FINAL : public LTemplateInstruction<1, 1, 0> { 589 class LArgumentsLength final : public LTemplateInstruction<1, 1, 0> {
590 public: 590 public:
591 explicit LArgumentsLength(LOperand* elements) { inputs_[0] = elements; } 591 explicit LArgumentsLength(LOperand* elements) { inputs_[0] = elements; }
592 592
593 LOperand* elements() { return inputs_[0]; } 593 LOperand* elements() { return inputs_[0]; }
594 594
595 DECLARE_CONCRETE_INSTRUCTION(ArgumentsLength, "arguments-length") 595 DECLARE_CONCRETE_INSTRUCTION(ArgumentsLength, "arguments-length")
596 }; 596 };
597 597
598 598
599 class LArgumentsElements FINAL : public LTemplateInstruction<1, 0, 0> { 599 class LArgumentsElements final : public LTemplateInstruction<1, 0, 0> {
600 public: 600 public:
601 DECLARE_CONCRETE_INSTRUCTION(ArgumentsElements, "arguments-elements") 601 DECLARE_CONCRETE_INSTRUCTION(ArgumentsElements, "arguments-elements")
602 DECLARE_HYDROGEN_ACCESSOR(ArgumentsElements) 602 DECLARE_HYDROGEN_ACCESSOR(ArgumentsElements)
603 }; 603 };
604 604
605 605
606 class LModByPowerOf2I FINAL : public LTemplateInstruction<1, 1, 0> { 606 class LModByPowerOf2I final : public LTemplateInstruction<1, 1, 0> {
607 public: 607 public:
608 LModByPowerOf2I(LOperand* dividend, int32_t divisor) { 608 LModByPowerOf2I(LOperand* dividend, int32_t divisor) {
609 inputs_[0] = dividend; 609 inputs_[0] = dividend;
610 divisor_ = divisor; 610 divisor_ = divisor;
611 } 611 }
612 612
613 LOperand* dividend() { return inputs_[0]; } 613 LOperand* dividend() { return inputs_[0]; }
614 int32_t divisor() const { return divisor_; } 614 int32_t divisor() const { return divisor_; }
615 615
616 DECLARE_CONCRETE_INSTRUCTION(ModByPowerOf2I, "mod-by-power-of-2-i") 616 DECLARE_CONCRETE_INSTRUCTION(ModByPowerOf2I, "mod-by-power-of-2-i")
617 DECLARE_HYDROGEN_ACCESSOR(Mod) 617 DECLARE_HYDROGEN_ACCESSOR(Mod)
618 618
619 private: 619 private:
620 int32_t divisor_; 620 int32_t divisor_;
621 }; 621 };
622 622
623 623
624 class LModByConstI FINAL : public LTemplateInstruction<1, 1, 0> { 624 class LModByConstI final : public LTemplateInstruction<1, 1, 0> {
625 public: 625 public:
626 LModByConstI(LOperand* dividend, int32_t divisor) { 626 LModByConstI(LOperand* dividend, int32_t divisor) {
627 inputs_[0] = dividend; 627 inputs_[0] = dividend;
628 divisor_ = divisor; 628 divisor_ = divisor;
629 } 629 }
630 630
631 LOperand* dividend() { return inputs_[0]; } 631 LOperand* dividend() { return inputs_[0]; }
632 int32_t divisor() const { return divisor_; } 632 int32_t divisor() const { return divisor_; }
633 633
634 DECLARE_CONCRETE_INSTRUCTION(ModByConstI, "mod-by-const-i") 634 DECLARE_CONCRETE_INSTRUCTION(ModByConstI, "mod-by-const-i")
635 DECLARE_HYDROGEN_ACCESSOR(Mod) 635 DECLARE_HYDROGEN_ACCESSOR(Mod)
636 636
637 private: 637 private:
638 int32_t divisor_; 638 int32_t divisor_;
639 }; 639 };
640 640
641 641
642 class LModI FINAL : public LTemplateInstruction<1, 2, 0> { 642 class LModI final : public LTemplateInstruction<1, 2, 0> {
643 public: 643 public:
644 LModI(LOperand* left, LOperand* right) { 644 LModI(LOperand* left, LOperand* right) {
645 inputs_[0] = left; 645 inputs_[0] = left;
646 inputs_[1] = right; 646 inputs_[1] = right;
647 } 647 }
648 648
649 LOperand* left() { return inputs_[0]; } 649 LOperand* left() { return inputs_[0]; }
650 LOperand* right() { return inputs_[1]; } 650 LOperand* right() { return inputs_[1]; }
651 651
652 DECLARE_CONCRETE_INSTRUCTION(ModI, "mod-i") 652 DECLARE_CONCRETE_INSTRUCTION(ModI, "mod-i")
653 DECLARE_HYDROGEN_ACCESSOR(Mod) 653 DECLARE_HYDROGEN_ACCESSOR(Mod)
654 }; 654 };
655 655
656 656
657 class LDivByPowerOf2I FINAL : public LTemplateInstruction<1, 1, 0> { 657 class LDivByPowerOf2I final : public LTemplateInstruction<1, 1, 0> {
658 public: 658 public:
659 LDivByPowerOf2I(LOperand* dividend, int32_t divisor) { 659 LDivByPowerOf2I(LOperand* dividend, int32_t divisor) {
660 inputs_[0] = dividend; 660 inputs_[0] = dividend;
661 divisor_ = divisor; 661 divisor_ = divisor;
662 } 662 }
663 663
664 LOperand* dividend() { return inputs_[0]; } 664 LOperand* dividend() { return inputs_[0]; }
665 int32_t divisor() const { return divisor_; } 665 int32_t divisor() const { return divisor_; }
666 666
667 DECLARE_CONCRETE_INSTRUCTION(DivByPowerOf2I, "div-by-power-of-2-i") 667 DECLARE_CONCRETE_INSTRUCTION(DivByPowerOf2I, "div-by-power-of-2-i")
668 DECLARE_HYDROGEN_ACCESSOR(Div) 668 DECLARE_HYDROGEN_ACCESSOR(Div)
669 669
670 private: 670 private:
671 int32_t divisor_; 671 int32_t divisor_;
672 }; 672 };
673 673
674 674
675 class LDivByConstI FINAL : public LTemplateInstruction<1, 1, 0> { 675 class LDivByConstI final : public LTemplateInstruction<1, 1, 0> {
676 public: 676 public:
677 LDivByConstI(LOperand* dividend, int32_t divisor) { 677 LDivByConstI(LOperand* dividend, int32_t divisor) {
678 inputs_[0] = dividend; 678 inputs_[0] = dividend;
679 divisor_ = divisor; 679 divisor_ = divisor;
680 } 680 }
681 681
682 LOperand* dividend() { return inputs_[0]; } 682 LOperand* dividend() { return inputs_[0]; }
683 int32_t divisor() const { return divisor_; } 683 int32_t divisor() const { return divisor_; }
684 684
685 DECLARE_CONCRETE_INSTRUCTION(DivByConstI, "div-by-const-i") 685 DECLARE_CONCRETE_INSTRUCTION(DivByConstI, "div-by-const-i")
686 DECLARE_HYDROGEN_ACCESSOR(Div) 686 DECLARE_HYDROGEN_ACCESSOR(Div)
687 687
688 private: 688 private:
689 int32_t divisor_; 689 int32_t divisor_;
690 }; 690 };
691 691
692 692
693 class LDivI FINAL : public LTemplateInstruction<1, 2, 0> { 693 class LDivI final : public LTemplateInstruction<1, 2, 0> {
694 public: 694 public:
695 LDivI(LOperand* dividend, LOperand* divisor) { 695 LDivI(LOperand* dividend, LOperand* divisor) {
696 inputs_[0] = dividend; 696 inputs_[0] = dividend;
697 inputs_[1] = divisor; 697 inputs_[1] = divisor;
698 } 698 }
699 699
700 LOperand* dividend() { return inputs_[0]; } 700 LOperand* dividend() { return inputs_[0]; }
701 LOperand* divisor() { return inputs_[1]; } 701 LOperand* divisor() { return inputs_[1]; }
702 702
703 DECLARE_CONCRETE_INSTRUCTION(DivI, "div-i") 703 DECLARE_CONCRETE_INSTRUCTION(DivI, "div-i")
704 DECLARE_HYDROGEN_ACCESSOR(BinaryOperation) 704 DECLARE_HYDROGEN_ACCESSOR(BinaryOperation)
705 }; 705 };
706 706
707 707
708 class LFlooringDivByPowerOf2I FINAL : public LTemplateInstruction<1, 1, 0> { 708 class LFlooringDivByPowerOf2I final : public LTemplateInstruction<1, 1, 0> {
709 public: 709 public:
710 LFlooringDivByPowerOf2I(LOperand* dividend, int32_t divisor) { 710 LFlooringDivByPowerOf2I(LOperand* dividend, int32_t divisor) {
711 inputs_[0] = dividend; 711 inputs_[0] = dividend;
712 divisor_ = divisor; 712 divisor_ = divisor;
713 } 713 }
714 714
715 LOperand* dividend() { return inputs_[0]; } 715 LOperand* dividend() { return inputs_[0]; }
716 int32_t divisor() { return divisor_; } 716 int32_t divisor() { return divisor_; }
717 717
718 DECLARE_CONCRETE_INSTRUCTION(FlooringDivByPowerOf2I, 718 DECLARE_CONCRETE_INSTRUCTION(FlooringDivByPowerOf2I,
719 "flooring-div-by-power-of-2-i") 719 "flooring-div-by-power-of-2-i")
720 DECLARE_HYDROGEN_ACCESSOR(MathFloorOfDiv) 720 DECLARE_HYDROGEN_ACCESSOR(MathFloorOfDiv)
721 721
722 private: 722 private:
723 int32_t divisor_; 723 int32_t divisor_;
724 }; 724 };
725 725
726 726
727 class LFlooringDivByConstI FINAL : public LTemplateInstruction<1, 1, 1> { 727 class LFlooringDivByConstI final : public LTemplateInstruction<1, 1, 1> {
728 public: 728 public:
729 LFlooringDivByConstI(LOperand* dividend, int32_t divisor, LOperand* temp) { 729 LFlooringDivByConstI(LOperand* dividend, int32_t divisor, LOperand* temp) {
730 inputs_[0] = dividend; 730 inputs_[0] = dividend;
731 divisor_ = divisor; 731 divisor_ = divisor;
732 temps_[0] = temp; 732 temps_[0] = temp;
733 } 733 }
734 734
735 LOperand* dividend() { return inputs_[0]; } 735 LOperand* dividend() { return inputs_[0]; }
736 int32_t divisor() const { return divisor_; } 736 int32_t divisor() const { return divisor_; }
737 LOperand* temp() { return temps_[0]; } 737 LOperand* temp() { return temps_[0]; }
738 738
739 DECLARE_CONCRETE_INSTRUCTION(FlooringDivByConstI, "flooring-div-by-const-i") 739 DECLARE_CONCRETE_INSTRUCTION(FlooringDivByConstI, "flooring-div-by-const-i")
740 DECLARE_HYDROGEN_ACCESSOR(MathFloorOfDiv) 740 DECLARE_HYDROGEN_ACCESSOR(MathFloorOfDiv)
741 741
742 private: 742 private:
743 int32_t divisor_; 743 int32_t divisor_;
744 }; 744 };
745 745
746 746
747 class LFlooringDivI FINAL : public LTemplateInstruction<1, 2, 0> { 747 class LFlooringDivI final : public LTemplateInstruction<1, 2, 0> {
748 public: 748 public:
749 LFlooringDivI(LOperand* dividend, LOperand* divisor) { 749 LFlooringDivI(LOperand* dividend, LOperand* divisor) {
750 inputs_[0] = dividend; 750 inputs_[0] = dividend;
751 inputs_[1] = divisor; 751 inputs_[1] = divisor;
752 } 752 }
753 753
754 LOperand* dividend() { return inputs_[0]; } 754 LOperand* dividend() { return inputs_[0]; }
755 LOperand* divisor() { return inputs_[1]; } 755 LOperand* divisor() { return inputs_[1]; }
756 756
757 DECLARE_CONCRETE_INSTRUCTION(FlooringDivI, "flooring-div-i") 757 DECLARE_CONCRETE_INSTRUCTION(FlooringDivI, "flooring-div-i")
758 DECLARE_HYDROGEN_ACCESSOR(MathFloorOfDiv) 758 DECLARE_HYDROGEN_ACCESSOR(MathFloorOfDiv)
759 }; 759 };
760 760
761 761
762 class LMulI FINAL : public LTemplateInstruction<1, 2, 0> { 762 class LMulI final : public LTemplateInstruction<1, 2, 0> {
763 public: 763 public:
764 LMulI(LOperand* left, LOperand* right) { 764 LMulI(LOperand* left, LOperand* right) {
765 inputs_[0] = left; 765 inputs_[0] = left;
766 inputs_[1] = right; 766 inputs_[1] = right;
767 } 767 }
768 768
769 LOperand* left() { return inputs_[0]; } 769 LOperand* left() { return inputs_[0]; }
770 LOperand* right() { return inputs_[1]; } 770 LOperand* right() { return inputs_[1]; }
771 771
772 DECLARE_CONCRETE_INSTRUCTION(MulI, "mul-i") 772 DECLARE_CONCRETE_INSTRUCTION(MulI, "mul-i")
773 DECLARE_HYDROGEN_ACCESSOR(Mul) 773 DECLARE_HYDROGEN_ACCESSOR(Mul)
774 }; 774 };
775 775
776 776
777 // Instruction for computing multiplier * multiplicand + addend. 777 // Instruction for computing multiplier * multiplicand + addend.
778 class LMultiplyAddD FINAL : public LTemplateInstruction<1, 3, 0> { 778 class LMultiplyAddD final : public LTemplateInstruction<1, 3, 0> {
779 public: 779 public:
780 LMultiplyAddD(LOperand* addend, LOperand* multiplier, 780 LMultiplyAddD(LOperand* addend, LOperand* multiplier,
781 LOperand* multiplicand) { 781 LOperand* multiplicand) {
782 inputs_[0] = addend; 782 inputs_[0] = addend;
783 inputs_[1] = multiplier; 783 inputs_[1] = multiplier;
784 inputs_[2] = multiplicand; 784 inputs_[2] = multiplicand;
785 } 785 }
786 786
787 LOperand* addend() { return inputs_[0]; } 787 LOperand* addend() { return inputs_[0]; }
788 LOperand* multiplier() { return inputs_[1]; } 788 LOperand* multiplier() { return inputs_[1]; }
789 LOperand* multiplicand() { return inputs_[2]; } 789 LOperand* multiplicand() { return inputs_[2]; }
790 790
791 DECLARE_CONCRETE_INSTRUCTION(MultiplyAddD, "multiply-add-d") 791 DECLARE_CONCRETE_INSTRUCTION(MultiplyAddD, "multiply-add-d")
792 }; 792 };
793 793
794 794
795 // Instruction for computing minuend - multiplier * multiplicand. 795 // Instruction for computing minuend - multiplier * multiplicand.
796 class LMultiplySubD FINAL : public LTemplateInstruction<1, 3, 0> { 796 class LMultiplySubD final : public LTemplateInstruction<1, 3, 0> {
797 public: 797 public:
798 LMultiplySubD(LOperand* minuend, LOperand* multiplier, 798 LMultiplySubD(LOperand* minuend, LOperand* multiplier,
799 LOperand* multiplicand) { 799 LOperand* multiplicand) {
800 inputs_[0] = minuend; 800 inputs_[0] = minuend;
801 inputs_[1] = multiplier; 801 inputs_[1] = multiplier;
802 inputs_[2] = multiplicand; 802 inputs_[2] = multiplicand;
803 } 803 }
804 804
805 LOperand* minuend() { return inputs_[0]; } 805 LOperand* minuend() { return inputs_[0]; }
806 LOperand* multiplier() { return inputs_[1]; } 806 LOperand* multiplier() { return inputs_[1]; }
807 LOperand* multiplicand() { return inputs_[2]; } 807 LOperand* multiplicand() { return inputs_[2]; }
808 808
809 DECLARE_CONCRETE_INSTRUCTION(MultiplySubD, "multiply-sub-d") 809 DECLARE_CONCRETE_INSTRUCTION(MultiplySubD, "multiply-sub-d")
810 }; 810 };
811 811
812 812
813 class LDebugBreak FINAL : public LTemplateInstruction<0, 0, 0> { 813 class LDebugBreak final : public LTemplateInstruction<0, 0, 0> {
814 public: 814 public:
815 DECLARE_CONCRETE_INSTRUCTION(DebugBreak, "break") 815 DECLARE_CONCRETE_INSTRUCTION(DebugBreak, "break")
816 }; 816 };
817 817
818 818
819 class LCompareNumericAndBranch FINAL : public LControlInstruction<2, 0> { 819 class LCompareNumericAndBranch final : public LControlInstruction<2, 0> {
820 public: 820 public:
821 LCompareNumericAndBranch(LOperand* left, LOperand* right) { 821 LCompareNumericAndBranch(LOperand* left, LOperand* right) {
822 inputs_[0] = left; 822 inputs_[0] = left;
823 inputs_[1] = right; 823 inputs_[1] = right;
824 } 824 }
825 825
826 LOperand* left() { return inputs_[0]; } 826 LOperand* left() { return inputs_[0]; }
827 LOperand* right() { return inputs_[1]; } 827 LOperand* right() { return inputs_[1]; }
828 828
829 DECLARE_CONCRETE_INSTRUCTION(CompareNumericAndBranch, 829 DECLARE_CONCRETE_INSTRUCTION(CompareNumericAndBranch,
830 "compare-numeric-and-branch") 830 "compare-numeric-and-branch")
831 DECLARE_HYDROGEN_ACCESSOR(CompareNumericAndBranch) 831 DECLARE_HYDROGEN_ACCESSOR(CompareNumericAndBranch)
832 832
833 Token::Value op() const { return hydrogen()->token(); } 833 Token::Value op() const { return hydrogen()->token(); }
834 bool is_double() const { return hydrogen()->representation().IsDouble(); } 834 bool is_double() const { return hydrogen()->representation().IsDouble(); }
835 835
836 void PrintDataTo(StringStream* stream) OVERRIDE; 836 void PrintDataTo(StringStream* stream) override;
837 }; 837 };
838 838
839 839
840 class LMathFloor FINAL : public LTemplateInstruction<1, 1, 0> { 840 class LMathFloor final : public LTemplateInstruction<1, 1, 0> {
841 public: 841 public:
842 explicit LMathFloor(LOperand* value) { inputs_[0] = value; } 842 explicit LMathFloor(LOperand* value) { inputs_[0] = value; }
843 843
844 LOperand* value() { return inputs_[0]; } 844 LOperand* value() { return inputs_[0]; }
845 845
846 DECLARE_CONCRETE_INSTRUCTION(MathFloor, "math-floor") 846 DECLARE_CONCRETE_INSTRUCTION(MathFloor, "math-floor")
847 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) 847 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation)
848 }; 848 };
849 849
850 850
851 class LMathRound FINAL : public LTemplateInstruction<1, 1, 1> { 851 class LMathRound final : public LTemplateInstruction<1, 1, 1> {
852 public: 852 public:
853 LMathRound(LOperand* value, LOperand* temp) { 853 LMathRound(LOperand* value, LOperand* temp) {
854 inputs_[0] = value; 854 inputs_[0] = value;
855 temps_[0] = temp; 855 temps_[0] = temp;
856 } 856 }
857 857
858 LOperand* value() { return inputs_[0]; } 858 LOperand* value() { return inputs_[0]; }
859 LOperand* temp() { return temps_[0]; } 859 LOperand* temp() { return temps_[0]; }
860 860
861 DECLARE_CONCRETE_INSTRUCTION(MathRound, "math-round") 861 DECLARE_CONCRETE_INSTRUCTION(MathRound, "math-round")
862 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) 862 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation)
863 }; 863 };
864 864
865 865
866 class LMathFround FINAL : public LTemplateInstruction<1, 1, 0> { 866 class LMathFround final : public LTemplateInstruction<1, 1, 0> {
867 public: 867 public:
868 explicit LMathFround(LOperand* value) { inputs_[0] = value; } 868 explicit LMathFround(LOperand* value) { inputs_[0] = value; }
869 869
870 LOperand* value() { return inputs_[0]; } 870 LOperand* value() { return inputs_[0]; }
871 871
872 DECLARE_CONCRETE_INSTRUCTION(MathFround, "math-fround") 872 DECLARE_CONCRETE_INSTRUCTION(MathFround, "math-fround")
873 }; 873 };
874 874
875 875
876 class LMathAbs FINAL : public LTemplateInstruction<1, 2, 0> { 876 class LMathAbs final : public LTemplateInstruction<1, 2, 0> {
877 public: 877 public:
878 LMathAbs(LOperand* context, LOperand* value) { 878 LMathAbs(LOperand* context, LOperand* value) {
879 inputs_[1] = context; 879 inputs_[1] = context;
880 inputs_[0] = value; 880 inputs_[0] = value;
881 } 881 }
882 882
883 LOperand* context() { return inputs_[1]; } 883 LOperand* context() { return inputs_[1]; }
884 LOperand* value() { return inputs_[0]; } 884 LOperand* value() { return inputs_[0]; }
885 885
886 DECLARE_CONCRETE_INSTRUCTION(MathAbs, "math-abs") 886 DECLARE_CONCRETE_INSTRUCTION(MathAbs, "math-abs")
887 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) 887 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation)
888 }; 888 };
889 889
890 890
891 class LMathLog FINAL : public LTemplateInstruction<1, 1, 0> { 891 class LMathLog final : public LTemplateInstruction<1, 1, 0> {
892 public: 892 public:
893 explicit LMathLog(LOperand* value) { inputs_[0] = value; } 893 explicit LMathLog(LOperand* value) { inputs_[0] = value; }
894 894
895 LOperand* value() { return inputs_[0]; } 895 LOperand* value() { return inputs_[0]; }
896 896
897 DECLARE_CONCRETE_INSTRUCTION(MathLog, "math-log") 897 DECLARE_CONCRETE_INSTRUCTION(MathLog, "math-log")
898 }; 898 };
899 899
900 900
901 class LMathClz32 FINAL : public LTemplateInstruction<1, 1, 0> { 901 class LMathClz32 final : public LTemplateInstruction<1, 1, 0> {
902 public: 902 public:
903 explicit LMathClz32(LOperand* value) { inputs_[0] = value; } 903 explicit LMathClz32(LOperand* value) { inputs_[0] = value; }
904 904
905 LOperand* value() { return inputs_[0]; } 905 LOperand* value() { return inputs_[0]; }
906 906
907 DECLARE_CONCRETE_INSTRUCTION(MathClz32, "math-clz32") 907 DECLARE_CONCRETE_INSTRUCTION(MathClz32, "math-clz32")
908 }; 908 };
909 909
910 910
911 class LMathExp FINAL : public LTemplateInstruction<1, 1, 3> { 911 class LMathExp final : public LTemplateInstruction<1, 1, 3> {
912 public: 912 public:
913 LMathExp(LOperand* value, LOperand* double_temp, LOperand* temp1, 913 LMathExp(LOperand* value, LOperand* double_temp, LOperand* temp1,
914 LOperand* temp2) { 914 LOperand* temp2) {
915 inputs_[0] = value; 915 inputs_[0] = value;
916 temps_[0] = temp1; 916 temps_[0] = temp1;
917 temps_[1] = temp2; 917 temps_[1] = temp2;
918 temps_[2] = double_temp; 918 temps_[2] = double_temp;
919 ExternalReference::InitializeMathExpData(); 919 ExternalReference::InitializeMathExpData();
920 } 920 }
921 921
922 LOperand* value() { return inputs_[0]; } 922 LOperand* value() { return inputs_[0]; }
923 LOperand* temp1() { return temps_[0]; } 923 LOperand* temp1() { return temps_[0]; }
924 LOperand* temp2() { return temps_[1]; } 924 LOperand* temp2() { return temps_[1]; }
925 LOperand* double_temp() { return temps_[2]; } 925 LOperand* double_temp() { return temps_[2]; }
926 926
927 DECLARE_CONCRETE_INSTRUCTION(MathExp, "math-exp") 927 DECLARE_CONCRETE_INSTRUCTION(MathExp, "math-exp")
928 }; 928 };
929 929
930 930
931 class LMathSqrt FINAL : public LTemplateInstruction<1, 1, 0> { 931 class LMathSqrt final : public LTemplateInstruction<1, 1, 0> {
932 public: 932 public:
933 explicit LMathSqrt(LOperand* value) { inputs_[0] = value; } 933 explicit LMathSqrt(LOperand* value) { inputs_[0] = value; }
934 934
935 LOperand* value() { return inputs_[0]; } 935 LOperand* value() { return inputs_[0]; }
936 936
937 DECLARE_CONCRETE_INSTRUCTION(MathSqrt, "math-sqrt") 937 DECLARE_CONCRETE_INSTRUCTION(MathSqrt, "math-sqrt")
938 }; 938 };
939 939
940 940
941 class LMathPowHalf FINAL : public LTemplateInstruction<1, 1, 0> { 941 class LMathPowHalf final : public LTemplateInstruction<1, 1, 0> {
942 public: 942 public:
943 explicit LMathPowHalf(LOperand* value) { inputs_[0] = value; } 943 explicit LMathPowHalf(LOperand* value) { inputs_[0] = value; }
944 944
945 LOperand* value() { return inputs_[0]; } 945 LOperand* value() { return inputs_[0]; }
946 946
947 DECLARE_CONCRETE_INSTRUCTION(MathPowHalf, "math-pow-half") 947 DECLARE_CONCRETE_INSTRUCTION(MathPowHalf, "math-pow-half")
948 }; 948 };
949 949
950 950
951 class LCmpObjectEqAndBranch FINAL : public LControlInstruction<2, 0> { 951 class LCmpObjectEqAndBranch final : public LControlInstruction<2, 0> {
952 public: 952 public:
953 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) { 953 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) {
954 inputs_[0] = left; 954 inputs_[0] = left;
955 inputs_[1] = right; 955 inputs_[1] = right;
956 } 956 }
957 957
958 LOperand* left() { return inputs_[0]; } 958 LOperand* left() { return inputs_[0]; }
959 LOperand* right() { return inputs_[1]; } 959 LOperand* right() { return inputs_[1]; }
960 960
961 DECLARE_CONCRETE_INSTRUCTION(CmpObjectEqAndBranch, "cmp-object-eq-and-branch") 961 DECLARE_CONCRETE_INSTRUCTION(CmpObjectEqAndBranch, "cmp-object-eq-and-branch")
962 DECLARE_HYDROGEN_ACCESSOR(CompareObjectEqAndBranch) 962 DECLARE_HYDROGEN_ACCESSOR(CompareObjectEqAndBranch)
963 }; 963 };
964 964
965 965
966 class LCmpHoleAndBranch FINAL : public LControlInstruction<1, 0> { 966 class LCmpHoleAndBranch final : public LControlInstruction<1, 0> {
967 public: 967 public:
968 explicit LCmpHoleAndBranch(LOperand* object) { inputs_[0] = object; } 968 explicit LCmpHoleAndBranch(LOperand* object) { inputs_[0] = object; }
969 969
970 LOperand* object() { return inputs_[0]; } 970 LOperand* object() { return inputs_[0]; }
971 971
972 DECLARE_CONCRETE_INSTRUCTION(CmpHoleAndBranch, "cmp-hole-and-branch") 972 DECLARE_CONCRETE_INSTRUCTION(CmpHoleAndBranch, "cmp-hole-and-branch")
973 DECLARE_HYDROGEN_ACCESSOR(CompareHoleAndBranch) 973 DECLARE_HYDROGEN_ACCESSOR(CompareHoleAndBranch)
974 }; 974 };
975 975
976 976
977 class LCompareMinusZeroAndBranch FINAL : public LControlInstruction<1, 1> { 977 class LCompareMinusZeroAndBranch final : public LControlInstruction<1, 1> {
978 public: 978 public:
979 LCompareMinusZeroAndBranch(LOperand* value, LOperand* temp) { 979 LCompareMinusZeroAndBranch(LOperand* value, LOperand* temp) {
980 inputs_[0] = value; 980 inputs_[0] = value;
981 temps_[0] = temp; 981 temps_[0] = temp;
982 } 982 }
983 983
984 LOperand* value() { return inputs_[0]; } 984 LOperand* value() { return inputs_[0]; }
985 LOperand* temp() { return temps_[0]; } 985 LOperand* temp() { return temps_[0]; }
986 986
987 DECLARE_CONCRETE_INSTRUCTION(CompareMinusZeroAndBranch, 987 DECLARE_CONCRETE_INSTRUCTION(CompareMinusZeroAndBranch,
988 "cmp-minus-zero-and-branch") 988 "cmp-minus-zero-and-branch")
989 DECLARE_HYDROGEN_ACCESSOR(CompareMinusZeroAndBranch) 989 DECLARE_HYDROGEN_ACCESSOR(CompareMinusZeroAndBranch)
990 }; 990 };
991 991
992 992
993 class LIsObjectAndBranch FINAL : public LControlInstruction<1, 1> { 993 class LIsObjectAndBranch final : public LControlInstruction<1, 1> {
994 public: 994 public:
995 LIsObjectAndBranch(LOperand* value, LOperand* temp) { 995 LIsObjectAndBranch(LOperand* value, LOperand* temp) {
996 inputs_[0] = value; 996 inputs_[0] = value;
997 temps_[0] = temp; 997 temps_[0] = temp;
998 } 998 }
999 999
1000 LOperand* value() { return inputs_[0]; } 1000 LOperand* value() { return inputs_[0]; }
1001 LOperand* temp() { return temps_[0]; } 1001 LOperand* temp() { return temps_[0]; }
1002 1002
1003 DECLARE_CONCRETE_INSTRUCTION(IsObjectAndBranch, "is-object-and-branch") 1003 DECLARE_CONCRETE_INSTRUCTION(IsObjectAndBranch, "is-object-and-branch")
1004 DECLARE_HYDROGEN_ACCESSOR(IsObjectAndBranch) 1004 DECLARE_HYDROGEN_ACCESSOR(IsObjectAndBranch)
1005 1005
1006 void PrintDataTo(StringStream* stream) OVERRIDE; 1006 void PrintDataTo(StringStream* stream) override;
1007 }; 1007 };
1008 1008
1009 1009
1010 class LIsStringAndBranch FINAL : public LControlInstruction<1, 1> { 1010 class LIsStringAndBranch final : public LControlInstruction<1, 1> {
1011 public: 1011 public:
1012 LIsStringAndBranch(LOperand* value, LOperand* temp) { 1012 LIsStringAndBranch(LOperand* value, LOperand* temp) {
1013 inputs_[0] = value; 1013 inputs_[0] = value;
1014 temps_[0] = temp; 1014 temps_[0] = temp;
1015 } 1015 }
1016 1016
1017 LOperand* value() { return inputs_[0]; } 1017 LOperand* value() { return inputs_[0]; }
1018 LOperand* temp() { return temps_[0]; } 1018 LOperand* temp() { return temps_[0]; }
1019 1019
1020 DECLARE_CONCRETE_INSTRUCTION(IsStringAndBranch, "is-string-and-branch") 1020 DECLARE_CONCRETE_INSTRUCTION(IsStringAndBranch, "is-string-and-branch")
1021 DECLARE_HYDROGEN_ACCESSOR(IsStringAndBranch) 1021 DECLARE_HYDROGEN_ACCESSOR(IsStringAndBranch)
1022 1022
1023 void PrintDataTo(StringStream* stream) OVERRIDE; 1023 void PrintDataTo(StringStream* stream) override;
1024 }; 1024 };
1025 1025
1026 1026
1027 class LIsSmiAndBranch FINAL : public LControlInstruction<1, 0> { 1027 class LIsSmiAndBranch final : public LControlInstruction<1, 0> {
1028 public: 1028 public:
1029 explicit LIsSmiAndBranch(LOperand* value) { inputs_[0] = value; } 1029 explicit LIsSmiAndBranch(LOperand* value) { inputs_[0] = value; }
1030 1030
1031 LOperand* value() { return inputs_[0]; } 1031 LOperand* value() { return inputs_[0]; }
1032 1032
1033 DECLARE_CONCRETE_INSTRUCTION(IsSmiAndBranch, "is-smi-and-branch") 1033 DECLARE_CONCRETE_INSTRUCTION(IsSmiAndBranch, "is-smi-and-branch")
1034 DECLARE_HYDROGEN_ACCESSOR(IsSmiAndBranch) 1034 DECLARE_HYDROGEN_ACCESSOR(IsSmiAndBranch)
1035 1035
1036 void PrintDataTo(StringStream* stream) OVERRIDE; 1036 void PrintDataTo(StringStream* stream) override;
1037 }; 1037 };
1038 1038
1039 1039
1040 class LIsUndetectableAndBranch FINAL : public LControlInstruction<1, 1> { 1040 class LIsUndetectableAndBranch final : public LControlInstruction<1, 1> {
1041 public: 1041 public:
1042 explicit LIsUndetectableAndBranch(LOperand* value, LOperand* temp) { 1042 explicit LIsUndetectableAndBranch(LOperand* value, LOperand* temp) {
1043 inputs_[0] = value; 1043 inputs_[0] = value;
1044 temps_[0] = temp; 1044 temps_[0] = temp;
1045 } 1045 }
1046 1046
1047 LOperand* value() { return inputs_[0]; } 1047 LOperand* value() { return inputs_[0]; }
1048 LOperand* temp() { return temps_[0]; } 1048 LOperand* temp() { return temps_[0]; }
1049 1049
1050 DECLARE_CONCRETE_INSTRUCTION(IsUndetectableAndBranch, 1050 DECLARE_CONCRETE_INSTRUCTION(IsUndetectableAndBranch,
1051 "is-undetectable-and-branch") 1051 "is-undetectable-and-branch")
1052 DECLARE_HYDROGEN_ACCESSOR(IsUndetectableAndBranch) 1052 DECLARE_HYDROGEN_ACCESSOR(IsUndetectableAndBranch)
1053 1053
1054 void PrintDataTo(StringStream* stream) OVERRIDE; 1054 void PrintDataTo(StringStream* stream) override;
1055 }; 1055 };
1056 1056
1057 1057
1058 class LStringCompareAndBranch FINAL : public LControlInstruction<3, 0> { 1058 class LStringCompareAndBranch final : public LControlInstruction<3, 0> {
1059 public: 1059 public:
1060 LStringCompareAndBranch(LOperand* context, LOperand* left, LOperand* right) { 1060 LStringCompareAndBranch(LOperand* context, LOperand* left, LOperand* right) {
1061 inputs_[0] = context; 1061 inputs_[0] = context;
1062 inputs_[1] = left; 1062 inputs_[1] = left;
1063 inputs_[2] = right; 1063 inputs_[2] = right;
1064 } 1064 }
1065 1065
1066 LOperand* context() { return inputs_[0]; } 1066 LOperand* context() { return inputs_[0]; }
1067 LOperand* left() { return inputs_[1]; } 1067 LOperand* left() { return inputs_[1]; }
1068 LOperand* right() { return inputs_[2]; } 1068 LOperand* right() { return inputs_[2]; }
1069 1069
1070 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch, 1070 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch,
1071 "string-compare-and-branch") 1071 "string-compare-and-branch")
1072 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch) 1072 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch)
1073 1073
1074 Token::Value op() const { return hydrogen()->token(); } 1074 Token::Value op() const { return hydrogen()->token(); }
1075 1075
1076 void PrintDataTo(StringStream* stream) OVERRIDE; 1076 void PrintDataTo(StringStream* stream) override;
1077 }; 1077 };
1078 1078
1079 1079
1080 class LHasInstanceTypeAndBranch FINAL : public LControlInstruction<1, 0> { 1080 class LHasInstanceTypeAndBranch final : public LControlInstruction<1, 0> {
1081 public: 1081 public:
1082 explicit LHasInstanceTypeAndBranch(LOperand* value) { inputs_[0] = value; } 1082 explicit LHasInstanceTypeAndBranch(LOperand* value) { inputs_[0] = value; }
1083 1083
1084 LOperand* value() { return inputs_[0]; } 1084 LOperand* value() { return inputs_[0]; }
1085 1085
1086 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch, 1086 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch,
1087 "has-instance-type-and-branch") 1087 "has-instance-type-and-branch")
1088 DECLARE_HYDROGEN_ACCESSOR(HasInstanceTypeAndBranch) 1088 DECLARE_HYDROGEN_ACCESSOR(HasInstanceTypeAndBranch)
1089 1089
1090 void PrintDataTo(StringStream* stream) OVERRIDE; 1090 void PrintDataTo(StringStream* stream) override;
1091 }; 1091 };
1092 1092
1093 1093
1094 class LGetCachedArrayIndex FINAL : public LTemplateInstruction<1, 1, 0> { 1094 class LGetCachedArrayIndex final : public LTemplateInstruction<1, 1, 0> {
1095 public: 1095 public:
1096 explicit LGetCachedArrayIndex(LOperand* value) { inputs_[0] = value; } 1096 explicit LGetCachedArrayIndex(LOperand* value) { inputs_[0] = value; }
1097 1097
1098 LOperand* value() { return inputs_[0]; } 1098 LOperand* value() { return inputs_[0]; }
1099 1099
1100 DECLARE_CONCRETE_INSTRUCTION(GetCachedArrayIndex, "get-cached-array-index") 1100 DECLARE_CONCRETE_INSTRUCTION(GetCachedArrayIndex, "get-cached-array-index")
1101 DECLARE_HYDROGEN_ACCESSOR(GetCachedArrayIndex) 1101 DECLARE_HYDROGEN_ACCESSOR(GetCachedArrayIndex)
1102 }; 1102 };
1103 1103
1104 1104
1105 class LHasCachedArrayIndexAndBranch FINAL : public LControlInstruction<1, 0> { 1105 class LHasCachedArrayIndexAndBranch final : public LControlInstruction<1, 0> {
1106 public: 1106 public:
1107 explicit LHasCachedArrayIndexAndBranch(LOperand* value) { 1107 explicit LHasCachedArrayIndexAndBranch(LOperand* value) {
1108 inputs_[0] = value; 1108 inputs_[0] = value;
1109 } 1109 }
1110 1110
1111 LOperand* value() { return inputs_[0]; } 1111 LOperand* value() { return inputs_[0]; }
1112 1112
1113 DECLARE_CONCRETE_INSTRUCTION(HasCachedArrayIndexAndBranch, 1113 DECLARE_CONCRETE_INSTRUCTION(HasCachedArrayIndexAndBranch,
1114 "has-cached-array-index-and-branch") 1114 "has-cached-array-index-and-branch")
1115 DECLARE_HYDROGEN_ACCESSOR(HasCachedArrayIndexAndBranch) 1115 DECLARE_HYDROGEN_ACCESSOR(HasCachedArrayIndexAndBranch)
1116 1116
1117 void PrintDataTo(StringStream* stream) OVERRIDE; 1117 void PrintDataTo(StringStream* stream) override;
1118 }; 1118 };
1119 1119
1120 1120
1121 class LClassOfTestAndBranch FINAL : public LControlInstruction<1, 1> { 1121 class LClassOfTestAndBranch final : public LControlInstruction<1, 1> {
1122 public: 1122 public:
1123 LClassOfTestAndBranch(LOperand* value, LOperand* temp) { 1123 LClassOfTestAndBranch(LOperand* value, LOperand* temp) {
1124 inputs_[0] = value; 1124 inputs_[0] = value;
1125 temps_[0] = temp; 1125 temps_[0] = temp;
1126 } 1126 }
1127 1127
1128 LOperand* value() { return inputs_[0]; } 1128 LOperand* value() { return inputs_[0]; }
1129 LOperand* temp() { return temps_[0]; } 1129 LOperand* temp() { return temps_[0]; }
1130 1130
1131 DECLARE_CONCRETE_INSTRUCTION(ClassOfTestAndBranch, "class-of-test-and-branch") 1131 DECLARE_CONCRETE_INSTRUCTION(ClassOfTestAndBranch, "class-of-test-and-branch")
1132 DECLARE_HYDROGEN_ACCESSOR(ClassOfTestAndBranch) 1132 DECLARE_HYDROGEN_ACCESSOR(ClassOfTestAndBranch)
1133 1133
1134 void PrintDataTo(StringStream* stream) OVERRIDE; 1134 void PrintDataTo(StringStream* stream) override;
1135 }; 1135 };
1136 1136
1137 1137
1138 class LCmpT FINAL : public LTemplateInstruction<1, 3, 0> { 1138 class LCmpT final : public LTemplateInstruction<1, 3, 0> {
1139 public: 1139 public:
1140 LCmpT(LOperand* context, LOperand* left, LOperand* right) { 1140 LCmpT(LOperand* context, LOperand* left, LOperand* right) {
1141 inputs_[0] = context; 1141 inputs_[0] = context;
1142 inputs_[1] = left; 1142 inputs_[1] = left;
1143 inputs_[2] = right; 1143 inputs_[2] = right;
1144 } 1144 }
1145 1145
1146 LOperand* context() { return inputs_[0]; } 1146 LOperand* context() { return inputs_[0]; }
1147 LOperand* left() { return inputs_[1]; } 1147 LOperand* left() { return inputs_[1]; }
1148 LOperand* right() { return inputs_[2]; } 1148 LOperand* right() { return inputs_[2]; }
1149 1149
1150 DECLARE_CONCRETE_INSTRUCTION(CmpT, "cmp-t") 1150 DECLARE_CONCRETE_INSTRUCTION(CmpT, "cmp-t")
1151 DECLARE_HYDROGEN_ACCESSOR(CompareGeneric) 1151 DECLARE_HYDROGEN_ACCESSOR(CompareGeneric)
1152 1152
1153 Token::Value op() const { return hydrogen()->token(); } 1153 Token::Value op() const { return hydrogen()->token(); }
1154 }; 1154 };
1155 1155
1156 1156
1157 class LInstanceOf FINAL : public LTemplateInstruction<1, 3, 0> { 1157 class LInstanceOf final : public LTemplateInstruction<1, 3, 0> {
1158 public: 1158 public:
1159 LInstanceOf(LOperand* context, LOperand* left, LOperand* right) { 1159 LInstanceOf(LOperand* context, LOperand* left, LOperand* right) {
1160 inputs_[0] = context; 1160 inputs_[0] = context;
1161 inputs_[1] = left; 1161 inputs_[1] = left;
1162 inputs_[2] = right; 1162 inputs_[2] = right;
1163 } 1163 }
1164 1164
1165 LOperand* context() { return inputs_[0]; } 1165 LOperand* context() { return inputs_[0]; }
1166 LOperand* left() { return inputs_[1]; } 1166 LOperand* left() { return inputs_[1]; }
1167 LOperand* right() { return inputs_[2]; } 1167 LOperand* right() { return inputs_[2]; }
1168 1168
1169 DECLARE_CONCRETE_INSTRUCTION(InstanceOf, "instance-of") 1169 DECLARE_CONCRETE_INSTRUCTION(InstanceOf, "instance-of")
1170 }; 1170 };
1171 1171
1172 1172
1173 class LInstanceOfKnownGlobal FINAL : public LTemplateInstruction<1, 2, 1> { 1173 class LInstanceOfKnownGlobal final : public LTemplateInstruction<1, 2, 1> {
1174 public: 1174 public:
1175 LInstanceOfKnownGlobal(LOperand* context, LOperand* value, LOperand* temp) { 1175 LInstanceOfKnownGlobal(LOperand* context, LOperand* value, LOperand* temp) {
1176 inputs_[0] = context; 1176 inputs_[0] = context;
1177 inputs_[1] = value; 1177 inputs_[1] = value;
1178 temps_[0] = temp; 1178 temps_[0] = temp;
1179 } 1179 }
1180 1180
1181 LOperand* context() { return inputs_[0]; } 1181 LOperand* context() { return inputs_[0]; }
1182 LOperand* value() { return inputs_[1]; } 1182 LOperand* value() { return inputs_[1]; }
1183 LOperand* temp() { return temps_[0]; } 1183 LOperand* temp() { return temps_[0]; }
1184 1184
1185 DECLARE_CONCRETE_INSTRUCTION(InstanceOfKnownGlobal, 1185 DECLARE_CONCRETE_INSTRUCTION(InstanceOfKnownGlobal,
1186 "instance-of-known-global") 1186 "instance-of-known-global")
1187 DECLARE_HYDROGEN_ACCESSOR(InstanceOfKnownGlobal) 1187 DECLARE_HYDROGEN_ACCESSOR(InstanceOfKnownGlobal)
1188 1188
1189 Handle<JSFunction> function() const { return hydrogen()->function(); } 1189 Handle<JSFunction> function() const { return hydrogen()->function(); }
1190 LEnvironment* GetDeferredLazyDeoptimizationEnvironment() { 1190 LEnvironment* GetDeferredLazyDeoptimizationEnvironment() {
1191 return lazy_deopt_env_; 1191 return lazy_deopt_env_;
1192 } 1192 }
1193 virtual void SetDeferredLazyDeoptimizationEnvironment( 1193 virtual void SetDeferredLazyDeoptimizationEnvironment(
1194 LEnvironment* env) OVERRIDE { 1194 LEnvironment* env) override {
1195 lazy_deopt_env_ = env; 1195 lazy_deopt_env_ = env;
1196 } 1196 }
1197 1197
1198 private: 1198 private:
1199 LEnvironment* lazy_deopt_env_; 1199 LEnvironment* lazy_deopt_env_;
1200 }; 1200 };
1201 1201
1202 1202
1203 class LBoundsCheck FINAL : public LTemplateInstruction<0, 2, 0> { 1203 class LBoundsCheck final : public LTemplateInstruction<0, 2, 0> {
1204 public: 1204 public:
1205 LBoundsCheck(LOperand* index, LOperand* length) { 1205 LBoundsCheck(LOperand* index, LOperand* length) {
1206 inputs_[0] = index; 1206 inputs_[0] = index;
1207 inputs_[1] = length; 1207 inputs_[1] = length;
1208 } 1208 }
1209 1209
1210 LOperand* index() { return inputs_[0]; } 1210 LOperand* index() { return inputs_[0]; }
1211 LOperand* length() { return inputs_[1]; } 1211 LOperand* length() { return inputs_[1]; }
1212 1212
1213 DECLARE_CONCRETE_INSTRUCTION(BoundsCheck, "bounds-check") 1213 DECLARE_CONCRETE_INSTRUCTION(BoundsCheck, "bounds-check")
1214 DECLARE_HYDROGEN_ACCESSOR(BoundsCheck) 1214 DECLARE_HYDROGEN_ACCESSOR(BoundsCheck)
1215 }; 1215 };
1216 1216
1217 1217
1218 class LBitI FINAL : public LTemplateInstruction<1, 2, 0> { 1218 class LBitI final : public LTemplateInstruction<1, 2, 0> {
1219 public: 1219 public:
1220 LBitI(LOperand* left, LOperand* right) { 1220 LBitI(LOperand* left, LOperand* right) {
1221 inputs_[0] = left; 1221 inputs_[0] = left;
1222 inputs_[1] = right; 1222 inputs_[1] = right;
1223 } 1223 }
1224 1224
1225 LOperand* left() { return inputs_[0]; } 1225 LOperand* left() { return inputs_[0]; }
1226 LOperand* right() { return inputs_[1]; } 1226 LOperand* right() { return inputs_[1]; }
1227 1227
1228 Token::Value op() const { return hydrogen()->op(); } 1228 Token::Value op() const { return hydrogen()->op(); }
1229 1229
1230 DECLARE_CONCRETE_INSTRUCTION(BitI, "bit-i") 1230 DECLARE_CONCRETE_INSTRUCTION(BitI, "bit-i")
1231 DECLARE_HYDROGEN_ACCESSOR(Bitwise) 1231 DECLARE_HYDROGEN_ACCESSOR(Bitwise)
1232 }; 1232 };
1233 1233
1234 1234
1235 class LShiftI FINAL : public LTemplateInstruction<1, 2, 0> { 1235 class LShiftI final : public LTemplateInstruction<1, 2, 0> {
1236 public: 1236 public:
1237 LShiftI(Token::Value op, LOperand* left, LOperand* right, bool can_deopt) 1237 LShiftI(Token::Value op, LOperand* left, LOperand* right, bool can_deopt)
1238 : op_(op), can_deopt_(can_deopt) { 1238 : op_(op), can_deopt_(can_deopt) {
1239 inputs_[0] = left; 1239 inputs_[0] = left;
1240 inputs_[1] = right; 1240 inputs_[1] = right;
1241 } 1241 }
1242 1242
1243 Token::Value op() const { return op_; } 1243 Token::Value op() const { return op_; }
1244 LOperand* left() { return inputs_[0]; } 1244 LOperand* left() { return inputs_[0]; }
1245 LOperand* right() { return inputs_[1]; } 1245 LOperand* right() { return inputs_[1]; }
1246 bool can_deopt() const { return can_deopt_; } 1246 bool can_deopt() const { return can_deopt_; }
1247 1247
1248 DECLARE_CONCRETE_INSTRUCTION(ShiftI, "shift-i") 1248 DECLARE_CONCRETE_INSTRUCTION(ShiftI, "shift-i")
1249 1249
1250 private: 1250 private:
1251 Token::Value op_; 1251 Token::Value op_;
1252 bool can_deopt_; 1252 bool can_deopt_;
1253 }; 1253 };
1254 1254
1255 1255
1256 class LSubI FINAL : public LTemplateInstruction<1, 2, 0> { 1256 class LSubI final : public LTemplateInstruction<1, 2, 0> {
1257 public: 1257 public:
1258 LSubI(LOperand* left, LOperand* right) { 1258 LSubI(LOperand* left, LOperand* right) {
1259 inputs_[0] = left; 1259 inputs_[0] = left;
1260 inputs_[1] = right; 1260 inputs_[1] = right;
1261 } 1261 }
1262 1262
1263 LOperand* left() { return inputs_[0]; } 1263 LOperand* left() { return inputs_[0]; }
1264 LOperand* right() { return inputs_[1]; } 1264 LOperand* right() { return inputs_[1]; }
1265 1265
1266 DECLARE_CONCRETE_INSTRUCTION(SubI, "sub-i") 1266 DECLARE_CONCRETE_INSTRUCTION(SubI, "sub-i")
1267 DECLARE_HYDROGEN_ACCESSOR(Sub) 1267 DECLARE_HYDROGEN_ACCESSOR(Sub)
1268 }; 1268 };
1269 1269
1270 1270
1271 class LRSubI FINAL : public LTemplateInstruction<1, 2, 0> { 1271 class LRSubI final : public LTemplateInstruction<1, 2, 0> {
1272 public: 1272 public:
1273 LRSubI(LOperand* left, LOperand* right) { 1273 LRSubI(LOperand* left, LOperand* right) {
1274 inputs_[0] = left; 1274 inputs_[0] = left;
1275 inputs_[1] = right; 1275 inputs_[1] = right;
1276 } 1276 }
1277 1277
1278 LOperand* left() { return inputs_[0]; } 1278 LOperand* left() { return inputs_[0]; }
1279 LOperand* right() { return inputs_[1]; } 1279 LOperand* right() { return inputs_[1]; }
1280 1280
1281 DECLARE_CONCRETE_INSTRUCTION(RSubI, "rsub-i") 1281 DECLARE_CONCRETE_INSTRUCTION(RSubI, "rsub-i")
1282 DECLARE_HYDROGEN_ACCESSOR(Sub) 1282 DECLARE_HYDROGEN_ACCESSOR(Sub)
1283 }; 1283 };
1284 1284
1285 1285
1286 class LConstantI FINAL : public LTemplateInstruction<1, 0, 0> { 1286 class LConstantI final : public LTemplateInstruction<1, 0, 0> {
1287 public: 1287 public:
1288 DECLARE_CONCRETE_INSTRUCTION(ConstantI, "constant-i") 1288 DECLARE_CONCRETE_INSTRUCTION(ConstantI, "constant-i")
1289 DECLARE_HYDROGEN_ACCESSOR(Constant) 1289 DECLARE_HYDROGEN_ACCESSOR(Constant)
1290 1290
1291 int32_t value() const { return hydrogen()->Integer32Value(); } 1291 int32_t value() const { return hydrogen()->Integer32Value(); }
1292 }; 1292 };
1293 1293
1294 1294
1295 class LConstantS FINAL : public LTemplateInstruction<1, 0, 0> { 1295 class LConstantS final : public LTemplateInstruction<1, 0, 0> {
1296 public: 1296 public:
1297 DECLARE_CONCRETE_INSTRUCTION(ConstantS, "constant-s") 1297 DECLARE_CONCRETE_INSTRUCTION(ConstantS, "constant-s")
1298 DECLARE_HYDROGEN_ACCESSOR(Constant) 1298 DECLARE_HYDROGEN_ACCESSOR(Constant)
1299 1299
1300 Smi* value() const { return Smi::FromInt(hydrogen()->Integer32Value()); } 1300 Smi* value() const { return Smi::FromInt(hydrogen()->Integer32Value()); }
1301 }; 1301 };
1302 1302
1303 1303
1304 class LConstantD FINAL : public LTemplateInstruction<1, 0, 0> { 1304 class LConstantD final : public LTemplateInstruction<1, 0, 0> {
1305 public: 1305 public:
1306 DECLARE_CONCRETE_INSTRUCTION(ConstantD, "constant-d") 1306 DECLARE_CONCRETE_INSTRUCTION(ConstantD, "constant-d")
1307 DECLARE_HYDROGEN_ACCESSOR(Constant) 1307 DECLARE_HYDROGEN_ACCESSOR(Constant)
1308 1308
1309 double value() const { return hydrogen()->DoubleValue(); } 1309 double value() const { return hydrogen()->DoubleValue(); }
1310 uint64_t bits() const { return hydrogen()->DoubleValueAsBits(); } 1310 uint64_t bits() const { return hydrogen()->DoubleValueAsBits(); }
1311 }; 1311 };
1312 1312
1313 1313
1314 class LConstantE FINAL : public LTemplateInstruction<1, 0, 0> { 1314 class LConstantE final : public LTemplateInstruction<1, 0, 0> {
1315 public: 1315 public:
1316 DECLARE_CONCRETE_INSTRUCTION(ConstantE, "constant-e") 1316 DECLARE_CONCRETE_INSTRUCTION(ConstantE, "constant-e")
1317 DECLARE_HYDROGEN_ACCESSOR(Constant) 1317 DECLARE_HYDROGEN_ACCESSOR(Constant)
1318 1318
1319 ExternalReference value() const { 1319 ExternalReference value() const {
1320 return hydrogen()->ExternalReferenceValue(); 1320 return hydrogen()->ExternalReferenceValue();
1321 } 1321 }
1322 }; 1322 };
1323 1323
1324 1324
1325 class LConstantT FINAL : public LTemplateInstruction<1, 0, 0> { 1325 class LConstantT final : public LTemplateInstruction<1, 0, 0> {
1326 public: 1326 public:
1327 DECLARE_CONCRETE_INSTRUCTION(ConstantT, "constant-t") 1327 DECLARE_CONCRETE_INSTRUCTION(ConstantT, "constant-t")
1328 DECLARE_HYDROGEN_ACCESSOR(Constant) 1328 DECLARE_HYDROGEN_ACCESSOR(Constant)
1329 1329
1330 Handle<Object> value(Isolate* isolate) const { 1330 Handle<Object> value(Isolate* isolate) const {
1331 return hydrogen()->handle(isolate); 1331 return hydrogen()->handle(isolate);
1332 } 1332 }
1333 }; 1333 };
1334 1334
1335 1335
1336 class LBranch FINAL : public LControlInstruction<1, 0> { 1336 class LBranch final : public LControlInstruction<1, 0> {
1337 public: 1337 public:
1338 explicit LBranch(LOperand* value) { inputs_[0] = value; } 1338 explicit LBranch(LOperand* value) { inputs_[0] = value; }
1339 1339
1340 LOperand* value() { return inputs_[0]; } 1340 LOperand* value() { return inputs_[0]; }
1341 1341
1342 DECLARE_CONCRETE_INSTRUCTION(Branch, "branch") 1342 DECLARE_CONCRETE_INSTRUCTION(Branch, "branch")
1343 DECLARE_HYDROGEN_ACCESSOR(Branch) 1343 DECLARE_HYDROGEN_ACCESSOR(Branch)
1344 1344
1345 void PrintDataTo(StringStream* stream) OVERRIDE; 1345 void PrintDataTo(StringStream* stream) override;
1346 }; 1346 };
1347 1347
1348 1348
1349 class LCmpMapAndBranch FINAL : public LControlInstruction<1, 1> { 1349 class LCmpMapAndBranch final : public LControlInstruction<1, 1> {
1350 public: 1350 public:
1351 LCmpMapAndBranch(LOperand* value, LOperand* temp) { 1351 LCmpMapAndBranch(LOperand* value, LOperand* temp) {
1352 inputs_[0] = value; 1352 inputs_[0] = value;
1353 temps_[0] = temp; 1353 temps_[0] = temp;
1354 } 1354 }
1355 1355
1356 LOperand* value() { return inputs_[0]; } 1356 LOperand* value() { return inputs_[0]; }
1357 LOperand* temp() { return temps_[0]; } 1357 LOperand* temp() { return temps_[0]; }
1358 1358
1359 DECLARE_CONCRETE_INSTRUCTION(CmpMapAndBranch, "cmp-map-and-branch") 1359 DECLARE_CONCRETE_INSTRUCTION(CmpMapAndBranch, "cmp-map-and-branch")
1360 DECLARE_HYDROGEN_ACCESSOR(CompareMap) 1360 DECLARE_HYDROGEN_ACCESSOR(CompareMap)
1361 1361
1362 Handle<Map> map() const { return hydrogen()->map().handle(); } 1362 Handle<Map> map() const { return hydrogen()->map().handle(); }
1363 }; 1363 };
1364 1364
1365 1365
1366 class LMapEnumLength FINAL : public LTemplateInstruction<1, 1, 0> { 1366 class LMapEnumLength final : public LTemplateInstruction<1, 1, 0> {
1367 public: 1367 public:
1368 explicit LMapEnumLength(LOperand* value) { inputs_[0] = value; } 1368 explicit LMapEnumLength(LOperand* value) { inputs_[0] = value; }
1369 1369
1370 LOperand* value() { return inputs_[0]; } 1370 LOperand* value() { return inputs_[0]; }
1371 1371
1372 DECLARE_CONCRETE_INSTRUCTION(MapEnumLength, "map-enum-length") 1372 DECLARE_CONCRETE_INSTRUCTION(MapEnumLength, "map-enum-length")
1373 }; 1373 };
1374 1374
1375 1375
1376 class LDateField FINAL : public LTemplateInstruction<1, 1, 1> { 1376 class LDateField final : public LTemplateInstruction<1, 1, 1> {
1377 public: 1377 public:
1378 LDateField(LOperand* date, LOperand* temp, Smi* index) : index_(index) { 1378 LDateField(LOperand* date, LOperand* temp, Smi* index) : index_(index) {
1379 inputs_[0] = date; 1379 inputs_[0] = date;
1380 temps_[0] = temp; 1380 temps_[0] = temp;
1381 } 1381 }
1382 1382
1383 LOperand* date() { return inputs_[0]; } 1383 LOperand* date() { return inputs_[0]; }
1384 LOperand* temp() { return temps_[0]; } 1384 LOperand* temp() { return temps_[0]; }
1385 Smi* index() const { return index_; } 1385 Smi* index() const { return index_; }
1386 1386
1387 DECLARE_CONCRETE_INSTRUCTION(DateField, "date-field") 1387 DECLARE_CONCRETE_INSTRUCTION(DateField, "date-field")
1388 DECLARE_HYDROGEN_ACCESSOR(DateField) 1388 DECLARE_HYDROGEN_ACCESSOR(DateField)
1389 1389
1390 private: 1390 private:
1391 Smi* index_; 1391 Smi* index_;
1392 }; 1392 };
1393 1393
1394 1394
1395 class LSeqStringGetChar FINAL : public LTemplateInstruction<1, 2, 0> { 1395 class LSeqStringGetChar final : public LTemplateInstruction<1, 2, 0> {
1396 public: 1396 public:
1397 LSeqStringGetChar(LOperand* string, LOperand* index) { 1397 LSeqStringGetChar(LOperand* string, LOperand* index) {
1398 inputs_[0] = string; 1398 inputs_[0] = string;
1399 inputs_[1] = index; 1399 inputs_[1] = index;
1400 } 1400 }
1401 1401
1402 LOperand* string() const { return inputs_[0]; } 1402 LOperand* string() const { return inputs_[0]; }
1403 LOperand* index() const { return inputs_[1]; } 1403 LOperand* index() const { return inputs_[1]; }
1404 1404
1405 DECLARE_CONCRETE_INSTRUCTION(SeqStringGetChar, "seq-string-get-char") 1405 DECLARE_CONCRETE_INSTRUCTION(SeqStringGetChar, "seq-string-get-char")
1406 DECLARE_HYDROGEN_ACCESSOR(SeqStringGetChar) 1406 DECLARE_HYDROGEN_ACCESSOR(SeqStringGetChar)
1407 }; 1407 };
1408 1408
1409 1409
1410 class LSeqStringSetChar FINAL : public LTemplateInstruction<1, 4, 0> { 1410 class LSeqStringSetChar final : public LTemplateInstruction<1, 4, 0> {
1411 public: 1411 public:
1412 LSeqStringSetChar(LOperand* context, LOperand* string, LOperand* index, 1412 LSeqStringSetChar(LOperand* context, LOperand* string, LOperand* index,
1413 LOperand* value) { 1413 LOperand* value) {
1414 inputs_[0] = context; 1414 inputs_[0] = context;
1415 inputs_[1] = string; 1415 inputs_[1] = string;
1416 inputs_[2] = index; 1416 inputs_[2] = index;
1417 inputs_[3] = value; 1417 inputs_[3] = value;
1418 } 1418 }
1419 1419
1420 LOperand* string() { return inputs_[1]; } 1420 LOperand* string() { return inputs_[1]; }
1421 LOperand* index() { return inputs_[2]; } 1421 LOperand* index() { return inputs_[2]; }
1422 LOperand* value() { return inputs_[3]; } 1422 LOperand* value() { return inputs_[3]; }
1423 1423
1424 DECLARE_CONCRETE_INSTRUCTION(SeqStringSetChar, "seq-string-set-char") 1424 DECLARE_CONCRETE_INSTRUCTION(SeqStringSetChar, "seq-string-set-char")
1425 DECLARE_HYDROGEN_ACCESSOR(SeqStringSetChar) 1425 DECLARE_HYDROGEN_ACCESSOR(SeqStringSetChar)
1426 }; 1426 };
1427 1427
1428 1428
1429 class LAddI FINAL : public LTemplateInstruction<1, 2, 0> { 1429 class LAddI final : public LTemplateInstruction<1, 2, 0> {
1430 public: 1430 public:
1431 LAddI(LOperand* left, LOperand* right) { 1431 LAddI(LOperand* left, LOperand* right) {
1432 inputs_[0] = left; 1432 inputs_[0] = left;
1433 inputs_[1] = right; 1433 inputs_[1] = right;
1434 } 1434 }
1435 1435
1436 LOperand* left() { return inputs_[0]; } 1436 LOperand* left() { return inputs_[0]; }
1437 LOperand* right() { return inputs_[1]; } 1437 LOperand* right() { return inputs_[1]; }
1438 1438
1439 DECLARE_CONCRETE_INSTRUCTION(AddI, "add-i") 1439 DECLARE_CONCRETE_INSTRUCTION(AddI, "add-i")
1440 DECLARE_HYDROGEN_ACCESSOR(Add) 1440 DECLARE_HYDROGEN_ACCESSOR(Add)
1441 }; 1441 };
1442 1442
1443 1443
1444 class LMathMinMax FINAL : public LTemplateInstruction<1, 2, 0> { 1444 class LMathMinMax final : public LTemplateInstruction<1, 2, 0> {
1445 public: 1445 public:
1446 LMathMinMax(LOperand* left, LOperand* right) { 1446 LMathMinMax(LOperand* left, LOperand* right) {
1447 inputs_[0] = left; 1447 inputs_[0] = left;
1448 inputs_[1] = right; 1448 inputs_[1] = right;
1449 } 1449 }
1450 1450
1451 LOperand* left() { return inputs_[0]; } 1451 LOperand* left() { return inputs_[0]; }
1452 LOperand* right() { return inputs_[1]; } 1452 LOperand* right() { return inputs_[1]; }
1453 1453
1454 DECLARE_CONCRETE_INSTRUCTION(MathMinMax, "math-min-max") 1454 DECLARE_CONCRETE_INSTRUCTION(MathMinMax, "math-min-max")
1455 DECLARE_HYDROGEN_ACCESSOR(MathMinMax) 1455 DECLARE_HYDROGEN_ACCESSOR(MathMinMax)
1456 }; 1456 };
1457 1457
1458 1458
1459 class LPower FINAL : public LTemplateInstruction<1, 2, 0> { 1459 class LPower final : public LTemplateInstruction<1, 2, 0> {
1460 public: 1460 public:
1461 LPower(LOperand* left, LOperand* right) { 1461 LPower(LOperand* left, LOperand* right) {
1462 inputs_[0] = left; 1462 inputs_[0] = left;
1463 inputs_[1] = right; 1463 inputs_[1] = right;
1464 } 1464 }
1465 1465
1466 LOperand* left() { return inputs_[0]; } 1466 LOperand* left() { return inputs_[0]; }
1467 LOperand* right() { return inputs_[1]; } 1467 LOperand* right() { return inputs_[1]; }
1468 1468
1469 DECLARE_CONCRETE_INSTRUCTION(Power, "power") 1469 DECLARE_CONCRETE_INSTRUCTION(Power, "power")
1470 DECLARE_HYDROGEN_ACCESSOR(Power) 1470 DECLARE_HYDROGEN_ACCESSOR(Power)
1471 }; 1471 };
1472 1472
1473 1473
1474 class LArithmeticD FINAL : public LTemplateInstruction<1, 2, 0> { 1474 class LArithmeticD final : public LTemplateInstruction<1, 2, 0> {
1475 public: 1475 public:
1476 LArithmeticD(Token::Value op, LOperand* left, LOperand* right) : op_(op) { 1476 LArithmeticD(Token::Value op, LOperand* left, LOperand* right) : op_(op) {
1477 inputs_[0] = left; 1477 inputs_[0] = left;
1478 inputs_[1] = right; 1478 inputs_[1] = right;
1479 } 1479 }
1480 1480
1481 Token::Value op() const { return op_; } 1481 Token::Value op() const { return op_; }
1482 LOperand* left() { return inputs_[0]; } 1482 LOperand* left() { return inputs_[0]; }
1483 LOperand* right() { return inputs_[1]; } 1483 LOperand* right() { return inputs_[1]; }
1484 1484
1485 Opcode opcode() const OVERRIDE { return LInstruction::kArithmeticD; } 1485 Opcode opcode() const override { return LInstruction::kArithmeticD; }
1486 void CompileToNative(LCodeGen* generator) OVERRIDE; 1486 void CompileToNative(LCodeGen* generator) override;
1487 const char* Mnemonic() const OVERRIDE; 1487 const char* Mnemonic() const override;
1488 1488
1489 private: 1489 private:
1490 Token::Value op_; 1490 Token::Value op_;
1491 }; 1491 };
1492 1492
1493 1493
1494 class LArithmeticT FINAL : public LTemplateInstruction<1, 3, 0> { 1494 class LArithmeticT final : public LTemplateInstruction<1, 3, 0> {
1495 public: 1495 public:
1496 LArithmeticT(Token::Value op, LOperand* context, LOperand* left, 1496 LArithmeticT(Token::Value op, LOperand* context, LOperand* left,
1497 LOperand* right) 1497 LOperand* right)
1498 : op_(op) { 1498 : op_(op) {
1499 inputs_[0] = context; 1499 inputs_[0] = context;
1500 inputs_[1] = left; 1500 inputs_[1] = left;
1501 inputs_[2] = right; 1501 inputs_[2] = right;
1502 } 1502 }
1503 1503
1504 LOperand* context() { return inputs_[0]; } 1504 LOperand* context() { return inputs_[0]; }
1505 LOperand* left() { return inputs_[1]; } 1505 LOperand* left() { return inputs_[1]; }
1506 LOperand* right() { return inputs_[2]; } 1506 LOperand* right() { return inputs_[2]; }
1507 Token::Value op() const { return op_; } 1507 Token::Value op() const { return op_; }
1508 1508
1509 Opcode opcode() const OVERRIDE { return LInstruction::kArithmeticT; } 1509 Opcode opcode() const override { return LInstruction::kArithmeticT; }
1510 void CompileToNative(LCodeGen* generator) OVERRIDE; 1510 void CompileToNative(LCodeGen* generator) override;
1511 const char* Mnemonic() const OVERRIDE; 1511 const char* Mnemonic() const override;
1512 1512
1513 private: 1513 private:
1514 Token::Value op_; 1514 Token::Value op_;
1515 }; 1515 };
1516 1516
1517 1517
1518 class LReturn FINAL : public LTemplateInstruction<0, 3, 0> { 1518 class LReturn final : public LTemplateInstruction<0, 3, 0> {
1519 public: 1519 public:
1520 LReturn(LOperand* value, LOperand* context, LOperand* parameter_count) { 1520 LReturn(LOperand* value, LOperand* context, LOperand* parameter_count) {
1521 inputs_[0] = value; 1521 inputs_[0] = value;
1522 inputs_[1] = context; 1522 inputs_[1] = context;
1523 inputs_[2] = parameter_count; 1523 inputs_[2] = parameter_count;
1524 } 1524 }
1525 1525
1526 LOperand* value() { return inputs_[0]; } 1526 LOperand* value() { return inputs_[0]; }
1527 1527
1528 bool has_constant_parameter_count() { 1528 bool has_constant_parameter_count() {
1529 return parameter_count()->IsConstantOperand(); 1529 return parameter_count()->IsConstantOperand();
1530 } 1530 }
1531 LConstantOperand* constant_parameter_count() { 1531 LConstantOperand* constant_parameter_count() {
1532 DCHECK(has_constant_parameter_count()); 1532 DCHECK(has_constant_parameter_count());
1533 return LConstantOperand::cast(parameter_count()); 1533 return LConstantOperand::cast(parameter_count());
1534 } 1534 }
1535 LOperand* parameter_count() { return inputs_[2]; } 1535 LOperand* parameter_count() { return inputs_[2]; }
1536 1536
1537 DECLARE_CONCRETE_INSTRUCTION(Return, "return") 1537 DECLARE_CONCRETE_INSTRUCTION(Return, "return")
1538 }; 1538 };
1539 1539
1540 1540
1541 class LLoadNamedField FINAL : public LTemplateInstruction<1, 1, 0> { 1541 class LLoadNamedField final : public LTemplateInstruction<1, 1, 0> {
1542 public: 1542 public:
1543 explicit LLoadNamedField(LOperand* object) { inputs_[0] = object; } 1543 explicit LLoadNamedField(LOperand* object) { inputs_[0] = object; }
1544 1544
1545 LOperand* object() { return inputs_[0]; } 1545 LOperand* object() { return inputs_[0]; }
1546 1546
1547 DECLARE_CONCRETE_INSTRUCTION(LoadNamedField, "load-named-field") 1547 DECLARE_CONCRETE_INSTRUCTION(LoadNamedField, "load-named-field")
1548 DECLARE_HYDROGEN_ACCESSOR(LoadNamedField) 1548 DECLARE_HYDROGEN_ACCESSOR(LoadNamedField)
1549 }; 1549 };
1550 1550
1551 1551
1552 class LLoadNamedGeneric FINAL : public LTemplateInstruction<1, 2, 1> { 1552 class LLoadNamedGeneric final : public LTemplateInstruction<1, 2, 1> {
1553 public: 1553 public:
1554 LLoadNamedGeneric(LOperand* context, LOperand* object, LOperand* vector) { 1554 LLoadNamedGeneric(LOperand* context, LOperand* object, LOperand* vector) {
1555 inputs_[0] = context; 1555 inputs_[0] = context;
1556 inputs_[1] = object; 1556 inputs_[1] = object;
1557 temps_[0] = vector; 1557 temps_[0] = vector;
1558 } 1558 }
1559 1559
1560 LOperand* context() { return inputs_[0]; } 1560 LOperand* context() { return inputs_[0]; }
1561 LOperand* object() { return inputs_[1]; } 1561 LOperand* object() { return inputs_[1]; }
1562 LOperand* temp_vector() { return temps_[0]; } 1562 LOperand* temp_vector() { return temps_[0]; }
1563 1563
1564 DECLARE_CONCRETE_INSTRUCTION(LoadNamedGeneric, "load-named-generic") 1564 DECLARE_CONCRETE_INSTRUCTION(LoadNamedGeneric, "load-named-generic")
1565 DECLARE_HYDROGEN_ACCESSOR(LoadNamedGeneric) 1565 DECLARE_HYDROGEN_ACCESSOR(LoadNamedGeneric)
1566 1566
1567 Handle<Object> name() const { return hydrogen()->name(); } 1567 Handle<Object> name() const { return hydrogen()->name(); }
1568 }; 1568 };
1569 1569
1570 1570
1571 class LLoadFunctionPrototype FINAL : public LTemplateInstruction<1, 1, 0> { 1571 class LLoadFunctionPrototype final : public LTemplateInstruction<1, 1, 0> {
1572 public: 1572 public:
1573 explicit LLoadFunctionPrototype(LOperand* function) { inputs_[0] = function; } 1573 explicit LLoadFunctionPrototype(LOperand* function) { inputs_[0] = function; }
1574 1574
1575 LOperand* function() { return inputs_[0]; } 1575 LOperand* function() { return inputs_[0]; }
1576 1576
1577 DECLARE_CONCRETE_INSTRUCTION(LoadFunctionPrototype, "load-function-prototype") 1577 DECLARE_CONCRETE_INSTRUCTION(LoadFunctionPrototype, "load-function-prototype")
1578 DECLARE_HYDROGEN_ACCESSOR(LoadFunctionPrototype) 1578 DECLARE_HYDROGEN_ACCESSOR(LoadFunctionPrototype)
1579 }; 1579 };
1580 1580
1581 1581
1582 class LLoadRoot FINAL : public LTemplateInstruction<1, 0, 0> { 1582 class LLoadRoot final : public LTemplateInstruction<1, 0, 0> {
1583 public: 1583 public:
1584 DECLARE_CONCRETE_INSTRUCTION(LoadRoot, "load-root") 1584 DECLARE_CONCRETE_INSTRUCTION(LoadRoot, "load-root")
1585 DECLARE_HYDROGEN_ACCESSOR(LoadRoot) 1585 DECLARE_HYDROGEN_ACCESSOR(LoadRoot)
1586 1586
1587 Heap::RootListIndex index() const { return hydrogen()->index(); } 1587 Heap::RootListIndex index() const { return hydrogen()->index(); }
1588 }; 1588 };
1589 1589
1590 1590
1591 class LLoadKeyed FINAL : public LTemplateInstruction<1, 2, 0> { 1591 class LLoadKeyed final : public LTemplateInstruction<1, 2, 0> {
1592 public: 1592 public:
1593 LLoadKeyed(LOperand* elements, LOperand* key) { 1593 LLoadKeyed(LOperand* elements, LOperand* key) {
1594 inputs_[0] = elements; 1594 inputs_[0] = elements;
1595 inputs_[1] = key; 1595 inputs_[1] = key;
1596 } 1596 }
1597 1597
1598 LOperand* elements() { return inputs_[0]; } 1598 LOperand* elements() { return inputs_[0]; }
1599 LOperand* key() { return inputs_[1]; } 1599 LOperand* key() { return inputs_[1]; }
1600 ElementsKind elements_kind() const { return hydrogen()->elements_kind(); } 1600 ElementsKind elements_kind() const { return hydrogen()->elements_kind(); }
1601 bool is_external() const { return hydrogen()->is_external(); } 1601 bool is_external() const { return hydrogen()->is_external(); }
1602 bool is_fixed_typed_array() const { 1602 bool is_fixed_typed_array() const {
1603 return hydrogen()->is_fixed_typed_array(); 1603 return hydrogen()->is_fixed_typed_array();
1604 } 1604 }
1605 bool is_typed_elements() const { 1605 bool is_typed_elements() const {
1606 return is_external() || is_fixed_typed_array(); 1606 return is_external() || is_fixed_typed_array();
1607 } 1607 }
1608 1608
1609 DECLARE_CONCRETE_INSTRUCTION(LoadKeyed, "load-keyed") 1609 DECLARE_CONCRETE_INSTRUCTION(LoadKeyed, "load-keyed")
1610 DECLARE_HYDROGEN_ACCESSOR(LoadKeyed) 1610 DECLARE_HYDROGEN_ACCESSOR(LoadKeyed)
1611 1611
1612 void PrintDataTo(StringStream* stream) OVERRIDE; 1612 void PrintDataTo(StringStream* stream) override;
1613 uint32_t base_offset() const { return hydrogen()->base_offset(); } 1613 uint32_t base_offset() const { return hydrogen()->base_offset(); }
1614 }; 1614 };
1615 1615
1616 1616
1617 class LLoadKeyedGeneric FINAL : public LTemplateInstruction<1, 3, 1> { 1617 class LLoadKeyedGeneric final : public LTemplateInstruction<1, 3, 1> {
1618 public: 1618 public:
1619 LLoadKeyedGeneric(LOperand* context, LOperand* object, LOperand* key, 1619 LLoadKeyedGeneric(LOperand* context, LOperand* object, LOperand* key,
1620 LOperand* vector) { 1620 LOperand* vector) {
1621 inputs_[0] = context; 1621 inputs_[0] = context;
1622 inputs_[1] = object; 1622 inputs_[1] = object;
1623 inputs_[2] = key; 1623 inputs_[2] = key;
1624 temps_[0] = vector; 1624 temps_[0] = vector;
1625 } 1625 }
1626 1626
1627 LOperand* context() { return inputs_[0]; } 1627 LOperand* context() { return inputs_[0]; }
1628 LOperand* object() { return inputs_[1]; } 1628 LOperand* object() { return inputs_[1]; }
1629 LOperand* key() { return inputs_[2]; } 1629 LOperand* key() { return inputs_[2]; }
1630 LOperand* temp_vector() { return temps_[0]; } 1630 LOperand* temp_vector() { return temps_[0]; }
1631 1631
1632 DECLARE_CONCRETE_INSTRUCTION(LoadKeyedGeneric, "load-keyed-generic") 1632 DECLARE_CONCRETE_INSTRUCTION(LoadKeyedGeneric, "load-keyed-generic")
1633 DECLARE_HYDROGEN_ACCESSOR(LoadKeyedGeneric) 1633 DECLARE_HYDROGEN_ACCESSOR(LoadKeyedGeneric)
1634 }; 1634 };
1635 1635
1636 1636
1637 class LLoadGlobalGeneric FINAL : public LTemplateInstruction<1, 2, 1> { 1637 class LLoadGlobalGeneric final : public LTemplateInstruction<1, 2, 1> {
1638 public: 1638 public:
1639 LLoadGlobalGeneric(LOperand* context, LOperand* global_object, 1639 LLoadGlobalGeneric(LOperand* context, LOperand* global_object,
1640 LOperand* vector) { 1640 LOperand* vector) {
1641 inputs_[0] = context; 1641 inputs_[0] = context;
1642 inputs_[1] = global_object; 1642 inputs_[1] = global_object;
1643 temps_[0] = vector; 1643 temps_[0] = vector;
1644 } 1644 }
1645 1645
1646 LOperand* context() { return inputs_[0]; } 1646 LOperand* context() { return inputs_[0]; }
1647 LOperand* global_object() { return inputs_[1]; } 1647 LOperand* global_object() { return inputs_[1]; }
1648 LOperand* temp_vector() { return temps_[0]; } 1648 LOperand* temp_vector() { return temps_[0]; }
1649 1649
1650 DECLARE_CONCRETE_INSTRUCTION(LoadGlobalGeneric, "load-global-generic") 1650 DECLARE_CONCRETE_INSTRUCTION(LoadGlobalGeneric, "load-global-generic")
1651 DECLARE_HYDROGEN_ACCESSOR(LoadGlobalGeneric) 1651 DECLARE_HYDROGEN_ACCESSOR(LoadGlobalGeneric)
1652 1652
1653 Handle<Object> name() const { return hydrogen()->name(); } 1653 Handle<Object> name() const { return hydrogen()->name(); }
1654 bool for_typeof() const { return hydrogen()->for_typeof(); } 1654 bool for_typeof() const { return hydrogen()->for_typeof(); }
1655 }; 1655 };
1656 1656
1657 1657
1658 class LLoadContextSlot FINAL : public LTemplateInstruction<1, 1, 0> { 1658 class LLoadContextSlot final : public LTemplateInstruction<1, 1, 0> {
1659 public: 1659 public:
1660 explicit LLoadContextSlot(LOperand* context) { inputs_[0] = context; } 1660 explicit LLoadContextSlot(LOperand* context) { inputs_[0] = context; }
1661 1661
1662 LOperand* context() { return inputs_[0]; } 1662 LOperand* context() { return inputs_[0]; }
1663 1663
1664 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot") 1664 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot")
1665 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot) 1665 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot)
1666 1666
1667 int slot_index() { return hydrogen()->slot_index(); } 1667 int slot_index() { return hydrogen()->slot_index(); }
1668 1668
1669 void PrintDataTo(StringStream* stream) OVERRIDE; 1669 void PrintDataTo(StringStream* stream) override;
1670 }; 1670 };
1671 1671
1672 1672
1673 class LStoreContextSlot FINAL : public LTemplateInstruction<0, 2, 0> { 1673 class LStoreContextSlot final : public LTemplateInstruction<0, 2, 0> {
1674 public: 1674 public:
1675 LStoreContextSlot(LOperand* context, LOperand* value) { 1675 LStoreContextSlot(LOperand* context, LOperand* value) {
1676 inputs_[0] = context; 1676 inputs_[0] = context;
1677 inputs_[1] = value; 1677 inputs_[1] = value;
1678 } 1678 }
1679 1679
1680 LOperand* context() { return inputs_[0]; } 1680 LOperand* context() { return inputs_[0]; }
1681 LOperand* value() { return inputs_[1]; } 1681 LOperand* value() { return inputs_[1]; }
1682 1682
1683 DECLARE_CONCRETE_INSTRUCTION(StoreContextSlot, "store-context-slot") 1683 DECLARE_CONCRETE_INSTRUCTION(StoreContextSlot, "store-context-slot")
1684 DECLARE_HYDROGEN_ACCESSOR(StoreContextSlot) 1684 DECLARE_HYDROGEN_ACCESSOR(StoreContextSlot)
1685 1685
1686 int slot_index() { return hydrogen()->slot_index(); } 1686 int slot_index() { return hydrogen()->slot_index(); }
1687 1687
1688 void PrintDataTo(StringStream* stream) OVERRIDE; 1688 void PrintDataTo(StringStream* stream) override;
1689 }; 1689 };
1690 1690
1691 1691
1692 class LPushArgument FINAL : public LTemplateInstruction<0, 1, 0> { 1692 class LPushArgument final : public LTemplateInstruction<0, 1, 0> {
1693 public: 1693 public:
1694 explicit LPushArgument(LOperand* value) { inputs_[0] = value; } 1694 explicit LPushArgument(LOperand* value) { inputs_[0] = value; }
1695 1695
1696 LOperand* value() { return inputs_[0]; } 1696 LOperand* value() { return inputs_[0]; }
1697 1697
1698 DECLARE_CONCRETE_INSTRUCTION(PushArgument, "push-argument") 1698 DECLARE_CONCRETE_INSTRUCTION(PushArgument, "push-argument")
1699 }; 1699 };
1700 1700
1701 1701
1702 class LDrop FINAL : public LTemplateInstruction<0, 0, 0> { 1702 class LDrop final : public LTemplateInstruction<0, 0, 0> {
1703 public: 1703 public:
1704 explicit LDrop(int count) : count_(count) {} 1704 explicit LDrop(int count) : count_(count) {}
1705 1705
1706 int count() const { return count_; } 1706 int count() const { return count_; }
1707 1707
1708 DECLARE_CONCRETE_INSTRUCTION(Drop, "drop") 1708 DECLARE_CONCRETE_INSTRUCTION(Drop, "drop")
1709 1709
1710 private: 1710 private:
1711 int count_; 1711 int count_;
1712 }; 1712 };
1713 1713
1714 1714
1715 class LStoreCodeEntry FINAL : public LTemplateInstruction<0, 2, 0> { 1715 class LStoreCodeEntry final : public LTemplateInstruction<0, 2, 0> {
1716 public: 1716 public:
1717 LStoreCodeEntry(LOperand* function, LOperand* code_object) { 1717 LStoreCodeEntry(LOperand* function, LOperand* code_object) {
1718 inputs_[0] = function; 1718 inputs_[0] = function;
1719 inputs_[1] = code_object; 1719 inputs_[1] = code_object;
1720 } 1720 }
1721 1721
1722 LOperand* function() { return inputs_[0]; } 1722 LOperand* function() { return inputs_[0]; }
1723 LOperand* code_object() { return inputs_[1]; } 1723 LOperand* code_object() { return inputs_[1]; }
1724 1724
1725 void PrintDataTo(StringStream* stream) OVERRIDE; 1725 void PrintDataTo(StringStream* stream) override;
1726 1726
1727 DECLARE_CONCRETE_INSTRUCTION(StoreCodeEntry, "store-code-entry") 1727 DECLARE_CONCRETE_INSTRUCTION(StoreCodeEntry, "store-code-entry")
1728 DECLARE_HYDROGEN_ACCESSOR(StoreCodeEntry) 1728 DECLARE_HYDROGEN_ACCESSOR(StoreCodeEntry)
1729 }; 1729 };
1730 1730
1731 1731
1732 class LInnerAllocatedObject FINAL : public LTemplateInstruction<1, 2, 0> { 1732 class LInnerAllocatedObject final : public LTemplateInstruction<1, 2, 0> {
1733 public: 1733 public:
1734 LInnerAllocatedObject(LOperand* base_object, LOperand* offset) { 1734 LInnerAllocatedObject(LOperand* base_object, LOperand* offset) {
1735 inputs_[0] = base_object; 1735 inputs_[0] = base_object;
1736 inputs_[1] = offset; 1736 inputs_[1] = offset;
1737 } 1737 }
1738 1738
1739 LOperand* base_object() const { return inputs_[0]; } 1739 LOperand* base_object() const { return inputs_[0]; }
1740 LOperand* offset() const { return inputs_[1]; } 1740 LOperand* offset() const { return inputs_[1]; }
1741 1741
1742 void PrintDataTo(StringStream* stream) OVERRIDE; 1742 void PrintDataTo(StringStream* stream) override;
1743 1743
1744 DECLARE_CONCRETE_INSTRUCTION(InnerAllocatedObject, "inner-allocated-object") 1744 DECLARE_CONCRETE_INSTRUCTION(InnerAllocatedObject, "inner-allocated-object")
1745 }; 1745 };
1746 1746
1747 1747
1748 class LThisFunction FINAL : public LTemplateInstruction<1, 0, 0> { 1748 class LThisFunction final : public LTemplateInstruction<1, 0, 0> {
1749 public: 1749 public:
1750 DECLARE_CONCRETE_INSTRUCTION(ThisFunction, "this-function") 1750 DECLARE_CONCRETE_INSTRUCTION(ThisFunction, "this-function")
1751 DECLARE_HYDROGEN_ACCESSOR(ThisFunction) 1751 DECLARE_HYDROGEN_ACCESSOR(ThisFunction)
1752 }; 1752 };
1753 1753
1754 1754
1755 class LContext FINAL : public LTemplateInstruction<1, 0, 0> { 1755 class LContext final : public LTemplateInstruction<1, 0, 0> {
1756 public: 1756 public:
1757 DECLARE_CONCRETE_INSTRUCTION(Context, "context") 1757 DECLARE_CONCRETE_INSTRUCTION(Context, "context")
1758 DECLARE_HYDROGEN_ACCESSOR(Context) 1758 DECLARE_HYDROGEN_ACCESSOR(Context)
1759 }; 1759 };
1760 1760
1761 1761
1762 class LDeclareGlobals FINAL : public LTemplateInstruction<0, 1, 0> { 1762 class LDeclareGlobals final : public LTemplateInstruction<0, 1, 0> {
1763 public: 1763 public:
1764 explicit LDeclareGlobals(LOperand* context) { inputs_[0] = context; } 1764 explicit LDeclareGlobals(LOperand* context) { inputs_[0] = context; }
1765 1765
1766 LOperand* context() { return inputs_[0]; } 1766 LOperand* context() { return inputs_[0]; }
1767 1767
1768 DECLARE_CONCRETE_INSTRUCTION(DeclareGlobals, "declare-globals") 1768 DECLARE_CONCRETE_INSTRUCTION(DeclareGlobals, "declare-globals")
1769 DECLARE_HYDROGEN_ACCESSOR(DeclareGlobals) 1769 DECLARE_HYDROGEN_ACCESSOR(DeclareGlobals)
1770 }; 1770 };
1771 1771
1772 1772
1773 class LCallJSFunction FINAL : public LTemplateInstruction<1, 1, 0> { 1773 class LCallJSFunction final : public LTemplateInstruction<1, 1, 0> {
1774 public: 1774 public:
1775 explicit LCallJSFunction(LOperand* function) { inputs_[0] = function; } 1775 explicit LCallJSFunction(LOperand* function) { inputs_[0] = function; }
1776 1776
1777 LOperand* function() { return inputs_[0]; } 1777 LOperand* function() { return inputs_[0]; }
1778 1778
1779 DECLARE_CONCRETE_INSTRUCTION(CallJSFunction, "call-js-function") 1779 DECLARE_CONCRETE_INSTRUCTION(CallJSFunction, "call-js-function")
1780 DECLARE_HYDROGEN_ACCESSOR(CallJSFunction) 1780 DECLARE_HYDROGEN_ACCESSOR(CallJSFunction)
1781 1781
1782 void PrintDataTo(StringStream* stream) OVERRIDE; 1782 void PrintDataTo(StringStream* stream) override;
1783 1783
1784 int arity() const { return hydrogen()->argument_count() - 1; } 1784 int arity() const { return hydrogen()->argument_count() - 1; }
1785 }; 1785 };
1786 1786
1787 1787
1788 class LCallWithDescriptor FINAL : public LTemplateResultInstruction<1> { 1788 class LCallWithDescriptor final : public LTemplateResultInstruction<1> {
1789 public: 1789 public:
1790 LCallWithDescriptor(CallInterfaceDescriptor descriptor, 1790 LCallWithDescriptor(CallInterfaceDescriptor descriptor,
1791 const ZoneList<LOperand*>& operands, Zone* zone) 1791 const ZoneList<LOperand*>& operands, Zone* zone)
1792 : descriptor_(descriptor), 1792 : descriptor_(descriptor),
1793 inputs_(descriptor.GetRegisterParameterCount() + 1, zone) { 1793 inputs_(descriptor.GetRegisterParameterCount() + 1, zone) {
1794 DCHECK(descriptor.GetRegisterParameterCount() + 1 == operands.length()); 1794 DCHECK(descriptor.GetRegisterParameterCount() + 1 == operands.length());
1795 inputs_.AddAll(operands, zone); 1795 inputs_.AddAll(operands, zone);
1796 } 1796 }
1797 1797
1798 LOperand* target() const { return inputs_[0]; } 1798 LOperand* target() const { return inputs_[0]; }
1799 1799
1800 const CallInterfaceDescriptor descriptor() { return descriptor_; } 1800 const CallInterfaceDescriptor descriptor() { return descriptor_; }
1801 1801
1802 DECLARE_HYDROGEN_ACCESSOR(CallWithDescriptor) 1802 DECLARE_HYDROGEN_ACCESSOR(CallWithDescriptor)
1803 1803
1804 private: 1804 private:
1805 DECLARE_CONCRETE_INSTRUCTION(CallWithDescriptor, "call-with-descriptor") 1805 DECLARE_CONCRETE_INSTRUCTION(CallWithDescriptor, "call-with-descriptor")
1806 1806
1807 void PrintDataTo(StringStream* stream) OVERRIDE; 1807 void PrintDataTo(StringStream* stream) override;
1808 1808
1809 int arity() const { return hydrogen()->argument_count() - 1; } 1809 int arity() const { return hydrogen()->argument_count() - 1; }
1810 1810
1811 CallInterfaceDescriptor descriptor_; 1811 CallInterfaceDescriptor descriptor_;
1812 ZoneList<LOperand*> inputs_; 1812 ZoneList<LOperand*> inputs_;
1813 1813
1814 // Iterator support. 1814 // Iterator support.
1815 int InputCount() FINAL { return inputs_.length(); } 1815 int InputCount() final { return inputs_.length(); }
1816 LOperand* InputAt(int i) FINAL { return inputs_[i]; } 1816 LOperand* InputAt(int i) final { return inputs_[i]; }
1817 1817
1818 int TempCount() FINAL { return 0; } 1818 int TempCount() final { return 0; }
1819 LOperand* TempAt(int i) FINAL { return NULL; } 1819 LOperand* TempAt(int i) final { return NULL; }
1820 }; 1820 };
1821 1821
1822 1822
1823 class LInvokeFunction FINAL : public LTemplateInstruction<1, 2, 0> { 1823 class LInvokeFunction final : public LTemplateInstruction<1, 2, 0> {
1824 public: 1824 public:
1825 LInvokeFunction(LOperand* context, LOperand* function) { 1825 LInvokeFunction(LOperand* context, LOperand* function) {
1826 inputs_[0] = context; 1826 inputs_[0] = context;
1827 inputs_[1] = function; 1827 inputs_[1] = function;
1828 } 1828 }
1829 1829
1830 LOperand* context() { return inputs_[0]; } 1830 LOperand* context() { return inputs_[0]; }
1831 LOperand* function() { return inputs_[1]; } 1831 LOperand* function() { return inputs_[1]; }
1832 1832
1833 DECLARE_CONCRETE_INSTRUCTION(InvokeFunction, "invoke-function") 1833 DECLARE_CONCRETE_INSTRUCTION(InvokeFunction, "invoke-function")
1834 DECLARE_HYDROGEN_ACCESSOR(InvokeFunction) 1834 DECLARE_HYDROGEN_ACCESSOR(InvokeFunction)
1835 1835
1836 void PrintDataTo(StringStream* stream) OVERRIDE; 1836 void PrintDataTo(StringStream* stream) override;
1837 1837
1838 int arity() const { return hydrogen()->argument_count() - 1; } 1838 int arity() const { return hydrogen()->argument_count() - 1; }
1839 }; 1839 };
1840 1840
1841 1841
1842 class LCallFunction FINAL : public LTemplateInstruction<1, 2, 2> { 1842 class LCallFunction final : public LTemplateInstruction<1, 2, 2> {
1843 public: 1843 public:
1844 LCallFunction(LOperand* context, LOperand* function, LOperand* slot, 1844 LCallFunction(LOperand* context, LOperand* function, LOperand* slot,
1845 LOperand* vector) { 1845 LOperand* vector) {
1846 inputs_[0] = context; 1846 inputs_[0] = context;
1847 inputs_[1] = function; 1847 inputs_[1] = function;
1848 temps_[0] = slot; 1848 temps_[0] = slot;
1849 temps_[1] = vector; 1849 temps_[1] = vector;
1850 } 1850 }
1851 1851
1852 LOperand* context() { return inputs_[0]; } 1852 LOperand* context() { return inputs_[0]; }
1853 LOperand* function() { return inputs_[1]; } 1853 LOperand* function() { return inputs_[1]; }
1854 LOperand* temp_slot() { return temps_[0]; } 1854 LOperand* temp_slot() { return temps_[0]; }
1855 LOperand* temp_vector() { return temps_[1]; } 1855 LOperand* temp_vector() { return temps_[1]; }
1856 1856
1857 DECLARE_CONCRETE_INSTRUCTION(CallFunction, "call-function") 1857 DECLARE_CONCRETE_INSTRUCTION(CallFunction, "call-function")
1858 DECLARE_HYDROGEN_ACCESSOR(CallFunction) 1858 DECLARE_HYDROGEN_ACCESSOR(CallFunction)
1859 1859
1860 int arity() const { return hydrogen()->argument_count() - 1; } 1860 int arity() const { return hydrogen()->argument_count() - 1; }
1861 void PrintDataTo(StringStream* stream) OVERRIDE; 1861 void PrintDataTo(StringStream* stream) override;
1862 }; 1862 };
1863 1863
1864 1864
1865 class LCallNew FINAL : public LTemplateInstruction<1, 2, 0> { 1865 class LCallNew final : public LTemplateInstruction<1, 2, 0> {
1866 public: 1866 public:
1867 LCallNew(LOperand* context, LOperand* constructor) { 1867 LCallNew(LOperand* context, LOperand* constructor) {
1868 inputs_[0] = context; 1868 inputs_[0] = context;
1869 inputs_[1] = constructor; 1869 inputs_[1] = constructor;
1870 } 1870 }
1871 1871
1872 LOperand* context() { return inputs_[0]; } 1872 LOperand* context() { return inputs_[0]; }
1873 LOperand* constructor() { return inputs_[1]; } 1873 LOperand* constructor() { return inputs_[1]; }
1874 1874
1875 DECLARE_CONCRETE_INSTRUCTION(CallNew, "call-new") 1875 DECLARE_CONCRETE_INSTRUCTION(CallNew, "call-new")
1876 DECLARE_HYDROGEN_ACCESSOR(CallNew) 1876 DECLARE_HYDROGEN_ACCESSOR(CallNew)
1877 1877
1878 void PrintDataTo(StringStream* stream) OVERRIDE; 1878 void PrintDataTo(StringStream* stream) override;
1879 1879
1880 int arity() const { return hydrogen()->argument_count() - 1; } 1880 int arity() const { return hydrogen()->argument_count() - 1; }
1881 }; 1881 };
1882 1882
1883 1883
1884 class LCallNewArray FINAL : public LTemplateInstruction<1, 2, 0> { 1884 class LCallNewArray final : public LTemplateInstruction<1, 2, 0> {
1885 public: 1885 public:
1886 LCallNewArray(LOperand* context, LOperand* constructor) { 1886 LCallNewArray(LOperand* context, LOperand* constructor) {
1887 inputs_[0] = context; 1887 inputs_[0] = context;
1888 inputs_[1] = constructor; 1888 inputs_[1] = constructor;
1889 } 1889 }
1890 1890
1891 LOperand* context() { return inputs_[0]; } 1891 LOperand* context() { return inputs_[0]; }
1892 LOperand* constructor() { return inputs_[1]; } 1892 LOperand* constructor() { return inputs_[1]; }
1893 1893
1894 DECLARE_CONCRETE_INSTRUCTION(CallNewArray, "call-new-array") 1894 DECLARE_CONCRETE_INSTRUCTION(CallNewArray, "call-new-array")
1895 DECLARE_HYDROGEN_ACCESSOR(CallNewArray) 1895 DECLARE_HYDROGEN_ACCESSOR(CallNewArray)
1896 1896
1897 void PrintDataTo(StringStream* stream) OVERRIDE; 1897 void PrintDataTo(StringStream* stream) override;
1898 1898
1899 int arity() const { return hydrogen()->argument_count() - 1; } 1899 int arity() const { return hydrogen()->argument_count() - 1; }
1900 }; 1900 };
1901 1901
1902 1902
1903 class LCallRuntime FINAL : public LTemplateInstruction<1, 1, 0> { 1903 class LCallRuntime final : public LTemplateInstruction<1, 1, 0> {
1904 public: 1904 public:
1905 explicit LCallRuntime(LOperand* context) { inputs_[0] = context; } 1905 explicit LCallRuntime(LOperand* context) { inputs_[0] = context; }
1906 1906
1907 LOperand* context() { return inputs_[0]; } 1907 LOperand* context() { return inputs_[0]; }
1908 1908
1909 DECLARE_CONCRETE_INSTRUCTION(CallRuntime, "call-runtime") 1909 DECLARE_CONCRETE_INSTRUCTION(CallRuntime, "call-runtime")
1910 DECLARE_HYDROGEN_ACCESSOR(CallRuntime) 1910 DECLARE_HYDROGEN_ACCESSOR(CallRuntime)
1911 1911
1912 bool ClobbersDoubleRegisters(Isolate* isolate) const OVERRIDE { 1912 bool ClobbersDoubleRegisters(Isolate* isolate) const override {
1913 return save_doubles() == kDontSaveFPRegs; 1913 return save_doubles() == kDontSaveFPRegs;
1914 } 1914 }
1915 1915
1916 const Runtime::Function* function() const { return hydrogen()->function(); } 1916 const Runtime::Function* function() const { return hydrogen()->function(); }
1917 int arity() const { return hydrogen()->argument_count(); } 1917 int arity() const { return hydrogen()->argument_count(); }
1918 SaveFPRegsMode save_doubles() const { return hydrogen()->save_doubles(); } 1918 SaveFPRegsMode save_doubles() const { return hydrogen()->save_doubles(); }
1919 }; 1919 };
1920 1920
1921 1921
1922 class LInteger32ToDouble FINAL : public LTemplateInstruction<1, 1, 0> { 1922 class LInteger32ToDouble final : public LTemplateInstruction<1, 1, 0> {
1923 public: 1923 public:
1924 explicit LInteger32ToDouble(LOperand* value) { inputs_[0] = value; } 1924 explicit LInteger32ToDouble(LOperand* value) { inputs_[0] = value; }
1925 1925
1926 LOperand* value() { return inputs_[0]; } 1926 LOperand* value() { return inputs_[0]; }
1927 1927
1928 DECLARE_CONCRETE_INSTRUCTION(Integer32ToDouble, "int32-to-double") 1928 DECLARE_CONCRETE_INSTRUCTION(Integer32ToDouble, "int32-to-double")
1929 }; 1929 };
1930 1930
1931 1931
1932 class LUint32ToDouble FINAL : public LTemplateInstruction<1, 1, 0> { 1932 class LUint32ToDouble final : public LTemplateInstruction<1, 1, 0> {
1933 public: 1933 public:
1934 explicit LUint32ToDouble(LOperand* value) { inputs_[0] = value; } 1934 explicit LUint32ToDouble(LOperand* value) { inputs_[0] = value; }
1935 1935
1936 LOperand* value() { return inputs_[0]; } 1936 LOperand* value() { return inputs_[0]; }
1937 1937
1938 DECLARE_CONCRETE_INSTRUCTION(Uint32ToDouble, "uint32-to-double") 1938 DECLARE_CONCRETE_INSTRUCTION(Uint32ToDouble, "uint32-to-double")
1939 }; 1939 };
1940 1940
1941 1941
1942 class LNumberTagI FINAL : public LTemplateInstruction<1, 1, 2> { 1942 class LNumberTagI final : public LTemplateInstruction<1, 1, 2> {
1943 public: 1943 public:
1944 LNumberTagI(LOperand* value, LOperand* temp1, LOperand* temp2) { 1944 LNumberTagI(LOperand* value, LOperand* temp1, LOperand* temp2) {
1945 inputs_[0] = value; 1945 inputs_[0] = value;
1946 temps_[0] = temp1; 1946 temps_[0] = temp1;
1947 temps_[1] = temp2; 1947 temps_[1] = temp2;
1948 } 1948 }
1949 1949
1950 LOperand* value() { return inputs_[0]; } 1950 LOperand* value() { return inputs_[0]; }
1951 LOperand* temp1() { return temps_[0]; } 1951 LOperand* temp1() { return temps_[0]; }
1952 LOperand* temp2() { return temps_[1]; } 1952 LOperand* temp2() { return temps_[1]; }
1953 1953
1954 DECLARE_CONCRETE_INSTRUCTION(NumberTagI, "number-tag-i") 1954 DECLARE_CONCRETE_INSTRUCTION(NumberTagI, "number-tag-i")
1955 }; 1955 };
1956 1956
1957 1957
1958 class LNumberTagU FINAL : public LTemplateInstruction<1, 1, 2> { 1958 class LNumberTagU final : public LTemplateInstruction<1, 1, 2> {
1959 public: 1959 public:
1960 LNumberTagU(LOperand* value, LOperand* temp1, LOperand* temp2) { 1960 LNumberTagU(LOperand* value, LOperand* temp1, LOperand* temp2) {
1961 inputs_[0] = value; 1961 inputs_[0] = value;
1962 temps_[0] = temp1; 1962 temps_[0] = temp1;
1963 temps_[1] = temp2; 1963 temps_[1] = temp2;
1964 } 1964 }
1965 1965
1966 LOperand* value() { return inputs_[0]; } 1966 LOperand* value() { return inputs_[0]; }
1967 LOperand* temp1() { return temps_[0]; } 1967 LOperand* temp1() { return temps_[0]; }
1968 LOperand* temp2() { return temps_[1]; } 1968 LOperand* temp2() { return temps_[1]; }
1969 1969
1970 DECLARE_CONCRETE_INSTRUCTION(NumberTagU, "number-tag-u") 1970 DECLARE_CONCRETE_INSTRUCTION(NumberTagU, "number-tag-u")
1971 }; 1971 };
1972 1972
1973 1973
1974 class LNumberTagD FINAL : public LTemplateInstruction<1, 1, 2> { 1974 class LNumberTagD final : public LTemplateInstruction<1, 1, 2> {
1975 public: 1975 public:
1976 LNumberTagD(LOperand* value, LOperand* temp, LOperand* temp2) { 1976 LNumberTagD(LOperand* value, LOperand* temp, LOperand* temp2) {
1977 inputs_[0] = value; 1977 inputs_[0] = value;
1978 temps_[0] = temp; 1978 temps_[0] = temp;
1979 temps_[1] = temp2; 1979 temps_[1] = temp2;
1980 } 1980 }
1981 1981
1982 LOperand* value() { return inputs_[0]; } 1982 LOperand* value() { return inputs_[0]; }
1983 LOperand* temp() { return temps_[0]; } 1983 LOperand* temp() { return temps_[0]; }
1984 LOperand* temp2() { return temps_[1]; } 1984 LOperand* temp2() { return temps_[1]; }
1985 1985
1986 DECLARE_CONCRETE_INSTRUCTION(NumberTagD, "number-tag-d") 1986 DECLARE_CONCRETE_INSTRUCTION(NumberTagD, "number-tag-d")
1987 DECLARE_HYDROGEN_ACCESSOR(Change) 1987 DECLARE_HYDROGEN_ACCESSOR(Change)
1988 }; 1988 };
1989 1989
1990 1990
1991 class LDoubleToSmi FINAL : public LTemplateInstruction<1, 1, 0> { 1991 class LDoubleToSmi final : public LTemplateInstruction<1, 1, 0> {
1992 public: 1992 public:
1993 explicit LDoubleToSmi(LOperand* value) { inputs_[0] = value; } 1993 explicit LDoubleToSmi(LOperand* value) { inputs_[0] = value; }
1994 1994
1995 LOperand* value() { return inputs_[0]; } 1995 LOperand* value() { return inputs_[0]; }
1996 1996
1997 DECLARE_CONCRETE_INSTRUCTION(DoubleToSmi, "double-to-smi") 1997 DECLARE_CONCRETE_INSTRUCTION(DoubleToSmi, "double-to-smi")
1998 DECLARE_HYDROGEN_ACCESSOR(UnaryOperation) 1998 DECLARE_HYDROGEN_ACCESSOR(UnaryOperation)
1999 1999
2000 bool truncating() { return hydrogen()->CanTruncateToInt32(); } 2000 bool truncating() { return hydrogen()->CanTruncateToInt32(); }
2001 }; 2001 };
2002 2002
2003 2003
2004 // Sometimes truncating conversion from a tagged value to an int32. 2004 // Sometimes truncating conversion from a tagged value to an int32.
2005 class LDoubleToI FINAL : public LTemplateInstruction<1, 1, 0> { 2005 class LDoubleToI final : public LTemplateInstruction<1, 1, 0> {
2006 public: 2006 public:
2007 explicit LDoubleToI(LOperand* value) { inputs_[0] = value; } 2007 explicit LDoubleToI(LOperand* value) { inputs_[0] = value; }
2008 2008
2009 LOperand* value() { return inputs_[0]; } 2009 LOperand* value() { return inputs_[0]; }
2010 2010
2011 DECLARE_CONCRETE_INSTRUCTION(DoubleToI, "double-to-i") 2011 DECLARE_CONCRETE_INSTRUCTION(DoubleToI, "double-to-i")
2012 DECLARE_HYDROGEN_ACCESSOR(UnaryOperation) 2012 DECLARE_HYDROGEN_ACCESSOR(UnaryOperation)
2013 2013
2014 bool truncating() { return hydrogen()->CanTruncateToInt32(); } 2014 bool truncating() { return hydrogen()->CanTruncateToInt32(); }
2015 }; 2015 };
2016 2016
2017 2017
2018 // Truncating conversion from a tagged value to an int32. 2018 // Truncating conversion from a tagged value to an int32.
2019 class LTaggedToI FINAL : public LTemplateInstruction<1, 1, 2> { 2019 class LTaggedToI final : public LTemplateInstruction<1, 1, 2> {
2020 public: 2020 public:
2021 LTaggedToI(LOperand* value, LOperand* temp, LOperand* temp2) { 2021 LTaggedToI(LOperand* value, LOperand* temp, LOperand* temp2) {
2022 inputs_[0] = value; 2022 inputs_[0] = value;
2023 temps_[0] = temp; 2023 temps_[0] = temp;
2024 temps_[1] = temp2; 2024 temps_[1] = temp2;
2025 } 2025 }
2026 2026
2027 LOperand* value() { return inputs_[0]; } 2027 LOperand* value() { return inputs_[0]; }
2028 LOperand* temp() { return temps_[0]; } 2028 LOperand* temp() { return temps_[0]; }
2029 LOperand* temp2() { return temps_[1]; } 2029 LOperand* temp2() { return temps_[1]; }
2030 2030
2031 DECLARE_CONCRETE_INSTRUCTION(TaggedToI, "tagged-to-i") 2031 DECLARE_CONCRETE_INSTRUCTION(TaggedToI, "tagged-to-i")
2032 DECLARE_HYDROGEN_ACCESSOR(Change) 2032 DECLARE_HYDROGEN_ACCESSOR(Change)
2033 2033
2034 bool truncating() { return hydrogen()->CanTruncateToInt32(); } 2034 bool truncating() { return hydrogen()->CanTruncateToInt32(); }
2035 }; 2035 };
2036 2036
2037 2037
2038 class LSmiTag FINAL : public LTemplateInstruction<1, 1, 0> { 2038 class LSmiTag final : public LTemplateInstruction<1, 1, 0> {
2039 public: 2039 public:
2040 explicit LSmiTag(LOperand* value) { inputs_[0] = value; } 2040 explicit LSmiTag(LOperand* value) { inputs_[0] = value; }
2041 2041
2042 LOperand* value() { return inputs_[0]; } 2042 LOperand* value() { return inputs_[0]; }
2043 2043
2044 DECLARE_CONCRETE_INSTRUCTION(SmiTag, "smi-tag") 2044 DECLARE_CONCRETE_INSTRUCTION(SmiTag, "smi-tag")
2045 DECLARE_HYDROGEN_ACCESSOR(Change) 2045 DECLARE_HYDROGEN_ACCESSOR(Change)
2046 }; 2046 };
2047 2047
2048 2048
2049 class LNumberUntagD FINAL : public LTemplateInstruction<1, 1, 0> { 2049 class LNumberUntagD final : public LTemplateInstruction<1, 1, 0> {
2050 public: 2050 public:
2051 explicit LNumberUntagD(LOperand* value) { inputs_[0] = value; } 2051 explicit LNumberUntagD(LOperand* value) { inputs_[0] = value; }
2052 2052
2053 LOperand* value() { return inputs_[0]; } 2053 LOperand* value() { return inputs_[0]; }
2054 2054
2055 DECLARE_CONCRETE_INSTRUCTION(NumberUntagD, "double-untag") 2055 DECLARE_CONCRETE_INSTRUCTION(NumberUntagD, "double-untag")
2056 DECLARE_HYDROGEN_ACCESSOR(Change) 2056 DECLARE_HYDROGEN_ACCESSOR(Change)
2057 }; 2057 };
2058 2058
2059 2059
2060 class LSmiUntag FINAL : public LTemplateInstruction<1, 1, 0> { 2060 class LSmiUntag final : public LTemplateInstruction<1, 1, 0> {
2061 public: 2061 public:
2062 LSmiUntag(LOperand* value, bool needs_check) : needs_check_(needs_check) { 2062 LSmiUntag(LOperand* value, bool needs_check) : needs_check_(needs_check) {
2063 inputs_[0] = value; 2063 inputs_[0] = value;
2064 } 2064 }
2065 2065
2066 LOperand* value() { return inputs_[0]; } 2066 LOperand* value() { return inputs_[0]; }
2067 bool needs_check() const { return needs_check_; } 2067 bool needs_check() const { return needs_check_; }
2068 2068
2069 DECLARE_CONCRETE_INSTRUCTION(SmiUntag, "smi-untag") 2069 DECLARE_CONCRETE_INSTRUCTION(SmiUntag, "smi-untag")
2070 2070
2071 private: 2071 private:
2072 bool needs_check_; 2072 bool needs_check_;
2073 }; 2073 };
2074 2074
2075 2075
2076 class LStoreNamedField FINAL : public LTemplateInstruction<0, 2, 1> { 2076 class LStoreNamedField final : public LTemplateInstruction<0, 2, 1> {
2077 public: 2077 public:
2078 LStoreNamedField(LOperand* object, LOperand* value, LOperand* temp) { 2078 LStoreNamedField(LOperand* object, LOperand* value, LOperand* temp) {
2079 inputs_[0] = object; 2079 inputs_[0] = object;
2080 inputs_[1] = value; 2080 inputs_[1] = value;
2081 temps_[0] = temp; 2081 temps_[0] = temp;
2082 } 2082 }
2083 2083
2084 LOperand* object() { return inputs_[0]; } 2084 LOperand* object() { return inputs_[0]; }
2085 LOperand* value() { return inputs_[1]; } 2085 LOperand* value() { return inputs_[1]; }
2086 LOperand* temp() { return temps_[0]; } 2086 LOperand* temp() { return temps_[0]; }
2087 2087
2088 DECLARE_CONCRETE_INSTRUCTION(StoreNamedField, "store-named-field") 2088 DECLARE_CONCRETE_INSTRUCTION(StoreNamedField, "store-named-field")
2089 DECLARE_HYDROGEN_ACCESSOR(StoreNamedField) 2089 DECLARE_HYDROGEN_ACCESSOR(StoreNamedField)
2090 2090
2091 void PrintDataTo(StringStream* stream) OVERRIDE; 2091 void PrintDataTo(StringStream* stream) override;
2092 2092
2093 Representation representation() const { 2093 Representation representation() const {
2094 return hydrogen()->field_representation(); 2094 return hydrogen()->field_representation();
2095 } 2095 }
2096 }; 2096 };
2097 2097
2098 2098
2099 class LStoreNamedGeneric FINAL : public LTemplateInstruction<0, 3, 0> { 2099 class LStoreNamedGeneric final : public LTemplateInstruction<0, 3, 0> {
2100 public: 2100 public:
2101 LStoreNamedGeneric(LOperand* context, LOperand* object, LOperand* value) { 2101 LStoreNamedGeneric(LOperand* context, LOperand* object, LOperand* value) {
2102 inputs_[0] = context; 2102 inputs_[0] = context;
2103 inputs_[1] = object; 2103 inputs_[1] = object;
2104 inputs_[2] = value; 2104 inputs_[2] = value;
2105 } 2105 }
2106 2106
2107 LOperand* context() { return inputs_[0]; } 2107 LOperand* context() { return inputs_[0]; }
2108 LOperand* object() { return inputs_[1]; } 2108 LOperand* object() { return inputs_[1]; }
2109 LOperand* value() { return inputs_[2]; } 2109 LOperand* value() { return inputs_[2]; }
2110 2110
2111 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic") 2111 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic")
2112 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric) 2112 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric)
2113 2113
2114 void PrintDataTo(StringStream* stream) OVERRIDE; 2114 void PrintDataTo(StringStream* stream) override;
2115 2115
2116 Handle<Object> name() const { return hydrogen()->name(); } 2116 Handle<Object> name() const { return hydrogen()->name(); }
2117 LanguageMode language_mode() { return hydrogen()->language_mode(); } 2117 LanguageMode language_mode() { return hydrogen()->language_mode(); }
2118 }; 2118 };
2119 2119
2120 2120
2121 class LStoreKeyed FINAL : public LTemplateInstruction<0, 3, 0> { 2121 class LStoreKeyed final : public LTemplateInstruction<0, 3, 0> {
2122 public: 2122 public:
2123 LStoreKeyed(LOperand* object, LOperand* key, LOperand* value) { 2123 LStoreKeyed(LOperand* object, LOperand* key, LOperand* value) {
2124 inputs_[0] = object; 2124 inputs_[0] = object;
2125 inputs_[1] = key; 2125 inputs_[1] = key;
2126 inputs_[2] = value; 2126 inputs_[2] = value;
2127 } 2127 }
2128 2128
2129 bool is_external() const { return hydrogen()->is_external(); } 2129 bool is_external() const { return hydrogen()->is_external(); }
2130 bool is_fixed_typed_array() const { 2130 bool is_fixed_typed_array() const {
2131 return hydrogen()->is_fixed_typed_array(); 2131 return hydrogen()->is_fixed_typed_array();
2132 } 2132 }
2133 bool is_typed_elements() const { 2133 bool is_typed_elements() const {
2134 return is_external() || is_fixed_typed_array(); 2134 return is_external() || is_fixed_typed_array();
2135 } 2135 }
2136 LOperand* elements() { return inputs_[0]; } 2136 LOperand* elements() { return inputs_[0]; }
2137 LOperand* key() { return inputs_[1]; } 2137 LOperand* key() { return inputs_[1]; }
2138 LOperand* value() { return inputs_[2]; } 2138 LOperand* value() { return inputs_[2]; }
2139 ElementsKind elements_kind() const { return hydrogen()->elements_kind(); } 2139 ElementsKind elements_kind() const { return hydrogen()->elements_kind(); }
2140 2140
2141 DECLARE_CONCRETE_INSTRUCTION(StoreKeyed, "store-keyed") 2141 DECLARE_CONCRETE_INSTRUCTION(StoreKeyed, "store-keyed")
2142 DECLARE_HYDROGEN_ACCESSOR(StoreKeyed) 2142 DECLARE_HYDROGEN_ACCESSOR(StoreKeyed)
2143 2143
2144 void PrintDataTo(StringStream* stream) OVERRIDE; 2144 void PrintDataTo(StringStream* stream) override;
2145 bool NeedsCanonicalization() { 2145 bool NeedsCanonicalization() {
2146 if (hydrogen()->value()->IsAdd() || hydrogen()->value()->IsSub() || 2146 if (hydrogen()->value()->IsAdd() || hydrogen()->value()->IsSub() ||
2147 hydrogen()->value()->IsMul() || hydrogen()->value()->IsDiv()) { 2147 hydrogen()->value()->IsMul() || hydrogen()->value()->IsDiv()) {
2148 return false; 2148 return false;
2149 } 2149 }
2150 return hydrogen()->NeedsCanonicalization(); 2150 return hydrogen()->NeedsCanonicalization();
2151 } 2151 }
2152 uint32_t base_offset() const { return hydrogen()->base_offset(); } 2152 uint32_t base_offset() const { return hydrogen()->base_offset(); }
2153 }; 2153 };
2154 2154
2155 2155
2156 class LStoreKeyedGeneric FINAL : public LTemplateInstruction<0, 4, 0> { 2156 class LStoreKeyedGeneric final : public LTemplateInstruction<0, 4, 0> {
2157 public: 2157 public:
2158 LStoreKeyedGeneric(LOperand* context, LOperand* obj, LOperand* key, 2158 LStoreKeyedGeneric(LOperand* context, LOperand* obj, LOperand* key,
2159 LOperand* value) { 2159 LOperand* value) {
2160 inputs_[0] = context; 2160 inputs_[0] = context;
2161 inputs_[1] = obj; 2161 inputs_[1] = obj;
2162 inputs_[2] = key; 2162 inputs_[2] = key;
2163 inputs_[3] = value; 2163 inputs_[3] = value;
2164 } 2164 }
2165 2165
2166 LOperand* context() { return inputs_[0]; } 2166 LOperand* context() { return inputs_[0]; }
2167 LOperand* object() { return inputs_[1]; } 2167 LOperand* object() { return inputs_[1]; }
2168 LOperand* key() { return inputs_[2]; } 2168 LOperand* key() { return inputs_[2]; }
2169 LOperand* value() { return inputs_[3]; } 2169 LOperand* value() { return inputs_[3]; }
2170 2170
2171 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic") 2171 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic")
2172 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric) 2172 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric)
2173 2173
2174 void PrintDataTo(StringStream* stream) OVERRIDE; 2174 void PrintDataTo(StringStream* stream) override;
2175 2175
2176 LanguageMode language_mode() { return hydrogen()->language_mode(); } 2176 LanguageMode language_mode() { return hydrogen()->language_mode(); }
2177 }; 2177 };
2178 2178
2179 2179
2180 class LTransitionElementsKind FINAL : public LTemplateInstruction<0, 2, 1> { 2180 class LTransitionElementsKind final : public LTemplateInstruction<0, 2, 1> {
2181 public: 2181 public:
2182 LTransitionElementsKind(LOperand* object, LOperand* context, 2182 LTransitionElementsKind(LOperand* object, LOperand* context,
2183 LOperand* new_map_temp) { 2183 LOperand* new_map_temp) {
2184 inputs_[0] = object; 2184 inputs_[0] = object;
2185 inputs_[1] = context; 2185 inputs_[1] = context;
2186 temps_[0] = new_map_temp; 2186 temps_[0] = new_map_temp;
2187 } 2187 }
2188 2188
2189 LOperand* context() { return inputs_[1]; } 2189 LOperand* context() { return inputs_[1]; }
2190 LOperand* object() { return inputs_[0]; } 2190 LOperand* object() { return inputs_[0]; }
2191 LOperand* new_map_temp() { return temps_[0]; } 2191 LOperand* new_map_temp() { return temps_[0]; }
2192 2192
2193 DECLARE_CONCRETE_INSTRUCTION(TransitionElementsKind, 2193 DECLARE_CONCRETE_INSTRUCTION(TransitionElementsKind,
2194 "transition-elements-kind") 2194 "transition-elements-kind")
2195 DECLARE_HYDROGEN_ACCESSOR(TransitionElementsKind) 2195 DECLARE_HYDROGEN_ACCESSOR(TransitionElementsKind)
2196 2196
2197 void PrintDataTo(StringStream* stream) OVERRIDE; 2197 void PrintDataTo(StringStream* stream) override;
2198 2198
2199 Handle<Map> original_map() { return hydrogen()->original_map().handle(); } 2199 Handle<Map> original_map() { return hydrogen()->original_map().handle(); }
2200 Handle<Map> transitioned_map() { 2200 Handle<Map> transitioned_map() {
2201 return hydrogen()->transitioned_map().handle(); 2201 return hydrogen()->transitioned_map().handle();
2202 } 2202 }
2203 ElementsKind from_kind() { return hydrogen()->from_kind(); } 2203 ElementsKind from_kind() { return hydrogen()->from_kind(); }
2204 ElementsKind to_kind() { return hydrogen()->to_kind(); } 2204 ElementsKind to_kind() { return hydrogen()->to_kind(); }
2205 }; 2205 };
2206 2206
2207 2207
2208 class LTrapAllocationMemento FINAL : public LTemplateInstruction<0, 1, 1> { 2208 class LTrapAllocationMemento final : public LTemplateInstruction<0, 1, 1> {
2209 public: 2209 public:
2210 LTrapAllocationMemento(LOperand* object, LOperand* temp) { 2210 LTrapAllocationMemento(LOperand* object, LOperand* temp) {
2211 inputs_[0] = object; 2211 inputs_[0] = object;
2212 temps_[0] = temp; 2212 temps_[0] = temp;
2213 } 2213 }
2214 2214
2215 LOperand* object() { return inputs_[0]; } 2215 LOperand* object() { return inputs_[0]; }
2216 LOperand* temp() { return temps_[0]; } 2216 LOperand* temp() { return temps_[0]; }
2217 2217
2218 DECLARE_CONCRETE_INSTRUCTION(TrapAllocationMemento, "trap-allocation-memento") 2218 DECLARE_CONCRETE_INSTRUCTION(TrapAllocationMemento, "trap-allocation-memento")
2219 }; 2219 };
2220 2220
2221 2221
2222 class LStringAdd FINAL : public LTemplateInstruction<1, 3, 0> { 2222 class LStringAdd final : public LTemplateInstruction<1, 3, 0> {
2223 public: 2223 public:
2224 LStringAdd(LOperand* context, LOperand* left, LOperand* right) { 2224 LStringAdd(LOperand* context, LOperand* left, LOperand* right) {
2225 inputs_[0] = context; 2225 inputs_[0] = context;
2226 inputs_[1] = left; 2226 inputs_[1] = left;
2227 inputs_[2] = right; 2227 inputs_[2] = right;
2228 } 2228 }
2229 2229
2230 LOperand* context() { return inputs_[0]; } 2230 LOperand* context() { return inputs_[0]; }
2231 LOperand* left() { return inputs_[1]; } 2231 LOperand* left() { return inputs_[1]; }
2232 LOperand* right() { return inputs_[2]; } 2232 LOperand* right() { return inputs_[2]; }
2233 2233
2234 DECLARE_CONCRETE_INSTRUCTION(StringAdd, "string-add") 2234 DECLARE_CONCRETE_INSTRUCTION(StringAdd, "string-add")
2235 DECLARE_HYDROGEN_ACCESSOR(StringAdd) 2235 DECLARE_HYDROGEN_ACCESSOR(StringAdd)
2236 }; 2236 };
2237 2237
2238 2238
2239 class LStringCharCodeAt FINAL : public LTemplateInstruction<1, 3, 0> { 2239 class LStringCharCodeAt final : public LTemplateInstruction<1, 3, 0> {
2240 public: 2240 public:
2241 LStringCharCodeAt(LOperand* context, LOperand* string, LOperand* index) { 2241 LStringCharCodeAt(LOperand* context, LOperand* string, LOperand* index) {
2242 inputs_[0] = context; 2242 inputs_[0] = context;
2243 inputs_[1] = string; 2243 inputs_[1] = string;
2244 inputs_[2] = index; 2244 inputs_[2] = index;
2245 } 2245 }
2246 2246
2247 LOperand* context() { return inputs_[0]; } 2247 LOperand* context() { return inputs_[0]; }
2248 LOperand* string() { return inputs_[1]; } 2248 LOperand* string() { return inputs_[1]; }
2249 LOperand* index() { return inputs_[2]; } 2249 LOperand* index() { return inputs_[2]; }
2250 2250
2251 DECLARE_CONCRETE_INSTRUCTION(StringCharCodeAt, "string-char-code-at") 2251 DECLARE_CONCRETE_INSTRUCTION(StringCharCodeAt, "string-char-code-at")
2252 DECLARE_HYDROGEN_ACCESSOR(StringCharCodeAt) 2252 DECLARE_HYDROGEN_ACCESSOR(StringCharCodeAt)
2253 }; 2253 };
2254 2254
2255 2255
2256 class LStringCharFromCode FINAL : public LTemplateInstruction<1, 2, 0> { 2256 class LStringCharFromCode final : public LTemplateInstruction<1, 2, 0> {
2257 public: 2257 public:
2258 explicit LStringCharFromCode(LOperand* context, LOperand* char_code) { 2258 explicit LStringCharFromCode(LOperand* context, LOperand* char_code) {
2259 inputs_[0] = context; 2259 inputs_[0] = context;
2260 inputs_[1] = char_code; 2260 inputs_[1] = char_code;
2261 } 2261 }
2262 2262
2263 LOperand* context() { return inputs_[0]; } 2263 LOperand* context() { return inputs_[0]; }
2264 LOperand* char_code() { return inputs_[1]; } 2264 LOperand* char_code() { return inputs_[1]; }
2265 2265
2266 DECLARE_CONCRETE_INSTRUCTION(StringCharFromCode, "string-char-from-code") 2266 DECLARE_CONCRETE_INSTRUCTION(StringCharFromCode, "string-char-from-code")
2267 DECLARE_HYDROGEN_ACCESSOR(StringCharFromCode) 2267 DECLARE_HYDROGEN_ACCESSOR(StringCharFromCode)
2268 }; 2268 };
2269 2269
2270 2270
2271 class LCheckValue FINAL : public LTemplateInstruction<0, 1, 0> { 2271 class LCheckValue final : public LTemplateInstruction<0, 1, 0> {
2272 public: 2272 public:
2273 explicit LCheckValue(LOperand* value) { inputs_[0] = value; } 2273 explicit LCheckValue(LOperand* value) { inputs_[0] = value; }
2274 2274
2275 LOperand* value() { return inputs_[0]; } 2275 LOperand* value() { return inputs_[0]; }
2276 2276
2277 DECLARE_CONCRETE_INSTRUCTION(CheckValue, "check-value") 2277 DECLARE_CONCRETE_INSTRUCTION(CheckValue, "check-value")
2278 DECLARE_HYDROGEN_ACCESSOR(CheckValue) 2278 DECLARE_HYDROGEN_ACCESSOR(CheckValue)
2279 }; 2279 };
2280 2280
2281 2281
2282 class LCheckInstanceType FINAL : public LTemplateInstruction<0, 1, 0> { 2282 class LCheckInstanceType final : public LTemplateInstruction<0, 1, 0> {
2283 public: 2283 public:
2284 explicit LCheckInstanceType(LOperand* value) { inputs_[0] = value; } 2284 explicit LCheckInstanceType(LOperand* value) { inputs_[0] = value; }
2285 2285
2286 LOperand* value() { return inputs_[0]; } 2286 LOperand* value() { return inputs_[0]; }
2287 2287
2288 DECLARE_CONCRETE_INSTRUCTION(CheckInstanceType, "check-instance-type") 2288 DECLARE_CONCRETE_INSTRUCTION(CheckInstanceType, "check-instance-type")
2289 DECLARE_HYDROGEN_ACCESSOR(CheckInstanceType) 2289 DECLARE_HYDROGEN_ACCESSOR(CheckInstanceType)
2290 }; 2290 };
2291 2291
2292 2292
2293 class LCheckMaps FINAL : public LTemplateInstruction<0, 1, 1> { 2293 class LCheckMaps final : public LTemplateInstruction<0, 1, 1> {
2294 public: 2294 public:
2295 explicit LCheckMaps(LOperand* value = NULL, LOperand* temp = NULL) { 2295 explicit LCheckMaps(LOperand* value = NULL, LOperand* temp = NULL) {
2296 inputs_[0] = value; 2296 inputs_[0] = value;
2297 temps_[0] = temp; 2297 temps_[0] = temp;
2298 } 2298 }
2299 2299
2300 LOperand* value() { return inputs_[0]; } 2300 LOperand* value() { return inputs_[0]; }
2301 LOperand* temp() { return temps_[0]; } 2301 LOperand* temp() { return temps_[0]; }
2302 2302
2303 DECLARE_CONCRETE_INSTRUCTION(CheckMaps, "check-maps") 2303 DECLARE_CONCRETE_INSTRUCTION(CheckMaps, "check-maps")
2304 DECLARE_HYDROGEN_ACCESSOR(CheckMaps) 2304 DECLARE_HYDROGEN_ACCESSOR(CheckMaps)
2305 }; 2305 };
2306 2306
2307 2307
2308 class LCheckSmi FINAL : public LTemplateInstruction<1, 1, 0> { 2308 class LCheckSmi final : public LTemplateInstruction<1, 1, 0> {
2309 public: 2309 public:
2310 explicit LCheckSmi(LOperand* value) { inputs_[0] = value; } 2310 explicit LCheckSmi(LOperand* value) { inputs_[0] = value; }
2311 2311
2312 LOperand* value() { return inputs_[0]; } 2312 LOperand* value() { return inputs_[0]; }
2313 2313
2314 DECLARE_CONCRETE_INSTRUCTION(CheckSmi, "check-smi") 2314 DECLARE_CONCRETE_INSTRUCTION(CheckSmi, "check-smi")
2315 }; 2315 };
2316 2316
2317 2317
2318 class LCheckNonSmi FINAL : public LTemplateInstruction<0, 1, 0> { 2318 class LCheckNonSmi final : public LTemplateInstruction<0, 1, 0> {
2319 public: 2319 public:
2320 explicit LCheckNonSmi(LOperand* value) { inputs_[0] = value; } 2320 explicit LCheckNonSmi(LOperand* value) { inputs_[0] = value; }
2321 2321
2322 LOperand* value() { return inputs_[0]; } 2322 LOperand* value() { return inputs_[0]; }
2323 2323
2324 DECLARE_CONCRETE_INSTRUCTION(CheckNonSmi, "check-non-smi") 2324 DECLARE_CONCRETE_INSTRUCTION(CheckNonSmi, "check-non-smi")
2325 DECLARE_HYDROGEN_ACCESSOR(CheckHeapObject) 2325 DECLARE_HYDROGEN_ACCESSOR(CheckHeapObject)
2326 }; 2326 };
2327 2327
2328 2328
2329 class LClampDToUint8 FINAL : public LTemplateInstruction<1, 1, 0> { 2329 class LClampDToUint8 final : public LTemplateInstruction<1, 1, 0> {
2330 public: 2330 public:
2331 explicit LClampDToUint8(LOperand* unclamped) { inputs_[0] = unclamped; } 2331 explicit LClampDToUint8(LOperand* unclamped) { inputs_[0] = unclamped; }
2332 2332
2333 LOperand* unclamped() { return inputs_[0]; } 2333 LOperand* unclamped() { return inputs_[0]; }
2334 2334
2335 DECLARE_CONCRETE_INSTRUCTION(ClampDToUint8, "clamp-d-to-uint8") 2335 DECLARE_CONCRETE_INSTRUCTION(ClampDToUint8, "clamp-d-to-uint8")
2336 }; 2336 };
2337 2337
2338 2338
2339 class LClampIToUint8 FINAL : public LTemplateInstruction<1, 1, 0> { 2339 class LClampIToUint8 final : public LTemplateInstruction<1, 1, 0> {
2340 public: 2340 public:
2341 explicit LClampIToUint8(LOperand* unclamped) { inputs_[0] = unclamped; } 2341 explicit LClampIToUint8(LOperand* unclamped) { inputs_[0] = unclamped; }
2342 2342
2343 LOperand* unclamped() { return inputs_[0]; } 2343 LOperand* unclamped() { return inputs_[0]; }
2344 2344
2345 DECLARE_CONCRETE_INSTRUCTION(ClampIToUint8, "clamp-i-to-uint8") 2345 DECLARE_CONCRETE_INSTRUCTION(ClampIToUint8, "clamp-i-to-uint8")
2346 }; 2346 };
2347 2347
2348 2348
2349 class LClampTToUint8 FINAL : public LTemplateInstruction<1, 1, 1> { 2349 class LClampTToUint8 final : public LTemplateInstruction<1, 1, 1> {
2350 public: 2350 public:
2351 LClampTToUint8(LOperand* unclamped, LOperand* temp) { 2351 LClampTToUint8(LOperand* unclamped, LOperand* temp) {
2352 inputs_[0] = unclamped; 2352 inputs_[0] = unclamped;
2353 temps_[0] = temp; 2353 temps_[0] = temp;
2354 } 2354 }
2355 2355
2356 LOperand* unclamped() { return inputs_[0]; } 2356 LOperand* unclamped() { return inputs_[0]; }
2357 LOperand* temp() { return temps_[0]; } 2357 LOperand* temp() { return temps_[0]; }
2358 2358
2359 DECLARE_CONCRETE_INSTRUCTION(ClampTToUint8, "clamp-t-to-uint8") 2359 DECLARE_CONCRETE_INSTRUCTION(ClampTToUint8, "clamp-t-to-uint8")
2360 }; 2360 };
2361 2361
2362 2362
2363 class LDoubleBits FINAL : public LTemplateInstruction<1, 1, 0> { 2363 class LDoubleBits final : public LTemplateInstruction<1, 1, 0> {
2364 public: 2364 public:
2365 explicit LDoubleBits(LOperand* value) { inputs_[0] = value; } 2365 explicit LDoubleBits(LOperand* value) { inputs_[0] = value; }
2366 2366
2367 LOperand* value() { return inputs_[0]; } 2367 LOperand* value() { return inputs_[0]; }
2368 2368
2369 DECLARE_CONCRETE_INSTRUCTION(DoubleBits, "double-bits") 2369 DECLARE_CONCRETE_INSTRUCTION(DoubleBits, "double-bits")
2370 DECLARE_HYDROGEN_ACCESSOR(DoubleBits) 2370 DECLARE_HYDROGEN_ACCESSOR(DoubleBits)
2371 }; 2371 };
2372 2372
2373 2373
2374 class LConstructDouble FINAL : public LTemplateInstruction<1, 2, 0> { 2374 class LConstructDouble final : public LTemplateInstruction<1, 2, 0> {
2375 public: 2375 public:
2376 LConstructDouble(LOperand* hi, LOperand* lo) { 2376 LConstructDouble(LOperand* hi, LOperand* lo) {
2377 inputs_[0] = hi; 2377 inputs_[0] = hi;
2378 inputs_[1] = lo; 2378 inputs_[1] = lo;
2379 } 2379 }
2380 2380
2381 LOperand* hi() { return inputs_[0]; } 2381 LOperand* hi() { return inputs_[0]; }
2382 LOperand* lo() { return inputs_[1]; } 2382 LOperand* lo() { return inputs_[1]; }
2383 2383
2384 DECLARE_CONCRETE_INSTRUCTION(ConstructDouble, "construct-double") 2384 DECLARE_CONCRETE_INSTRUCTION(ConstructDouble, "construct-double")
2385 }; 2385 };
2386 2386
2387 2387
2388 class LAllocate FINAL : public LTemplateInstruction<1, 2, 2> { 2388 class LAllocate final : public LTemplateInstruction<1, 2, 2> {
2389 public: 2389 public:
2390 LAllocate(LOperand* context, LOperand* size, LOperand* temp1, 2390 LAllocate(LOperand* context, LOperand* size, LOperand* temp1,
2391 LOperand* temp2) { 2391 LOperand* temp2) {
2392 inputs_[0] = context; 2392 inputs_[0] = context;
2393 inputs_[1] = size; 2393 inputs_[1] = size;
2394 temps_[0] = temp1; 2394 temps_[0] = temp1;
2395 temps_[1] = temp2; 2395 temps_[1] = temp2;
2396 } 2396 }
2397 2397
2398 LOperand* context() { return inputs_[0]; } 2398 LOperand* context() { return inputs_[0]; }
2399 LOperand* size() { return inputs_[1]; } 2399 LOperand* size() { return inputs_[1]; }
2400 LOperand* temp1() { return temps_[0]; } 2400 LOperand* temp1() { return temps_[0]; }
2401 LOperand* temp2() { return temps_[1]; } 2401 LOperand* temp2() { return temps_[1]; }
2402 2402
2403 DECLARE_CONCRETE_INSTRUCTION(Allocate, "allocate") 2403 DECLARE_CONCRETE_INSTRUCTION(Allocate, "allocate")
2404 DECLARE_HYDROGEN_ACCESSOR(Allocate) 2404 DECLARE_HYDROGEN_ACCESSOR(Allocate)
2405 }; 2405 };
2406 2406
2407 2407
2408 class LRegExpLiteral FINAL : public LTemplateInstruction<1, 1, 0> { 2408 class LRegExpLiteral final : public LTemplateInstruction<1, 1, 0> {
2409 public: 2409 public:
2410 explicit LRegExpLiteral(LOperand* context) { inputs_[0] = context; } 2410 explicit LRegExpLiteral(LOperand* context) { inputs_[0] = context; }
2411 2411
2412 LOperand* context() { return inputs_[0]; } 2412 LOperand* context() { return inputs_[0]; }
2413 2413
2414 DECLARE_CONCRETE_INSTRUCTION(RegExpLiteral, "regexp-literal") 2414 DECLARE_CONCRETE_INSTRUCTION(RegExpLiteral, "regexp-literal")
2415 DECLARE_HYDROGEN_ACCESSOR(RegExpLiteral) 2415 DECLARE_HYDROGEN_ACCESSOR(RegExpLiteral)
2416 }; 2416 };
2417 2417
2418 2418
2419 class LFunctionLiteral FINAL : public LTemplateInstruction<1, 1, 0> { 2419 class LFunctionLiteral final : public LTemplateInstruction<1, 1, 0> {
2420 public: 2420 public:
2421 explicit LFunctionLiteral(LOperand* context) { inputs_[0] = context; } 2421 explicit LFunctionLiteral(LOperand* context) { inputs_[0] = context; }
2422 2422
2423 LOperand* context() { return inputs_[0]; } 2423 LOperand* context() { return inputs_[0]; }
2424 2424
2425 DECLARE_CONCRETE_INSTRUCTION(FunctionLiteral, "function-literal") 2425 DECLARE_CONCRETE_INSTRUCTION(FunctionLiteral, "function-literal")
2426 DECLARE_HYDROGEN_ACCESSOR(FunctionLiteral) 2426 DECLARE_HYDROGEN_ACCESSOR(FunctionLiteral)
2427 }; 2427 };
2428 2428
2429 2429
2430 class LToFastProperties FINAL : public LTemplateInstruction<1, 1, 0> { 2430 class LToFastProperties final : public LTemplateInstruction<1, 1, 0> {
2431 public: 2431 public:
2432 explicit LToFastProperties(LOperand* value) { inputs_[0] = value; } 2432 explicit LToFastProperties(LOperand* value) { inputs_[0] = value; }
2433 2433
2434 LOperand* value() { return inputs_[0]; } 2434 LOperand* value() { return inputs_[0]; }
2435 2435
2436 DECLARE_CONCRETE_INSTRUCTION(ToFastProperties, "to-fast-properties") 2436 DECLARE_CONCRETE_INSTRUCTION(ToFastProperties, "to-fast-properties")
2437 DECLARE_HYDROGEN_ACCESSOR(ToFastProperties) 2437 DECLARE_HYDROGEN_ACCESSOR(ToFastProperties)
2438 }; 2438 };
2439 2439
2440 2440
2441 class LTypeof FINAL : public LTemplateInstruction<1, 2, 0> { 2441 class LTypeof final : public LTemplateInstruction<1, 2, 0> {
2442 public: 2442 public:
2443 LTypeof(LOperand* context, LOperand* value) { 2443 LTypeof(LOperand* context, LOperand* value) {
2444 inputs_[0] = context; 2444 inputs_[0] = context;
2445 inputs_[1] = value; 2445 inputs_[1] = value;
2446 } 2446 }
2447 2447
2448 LOperand* context() { return inputs_[0]; } 2448 LOperand* context() { return inputs_[0]; }
2449 LOperand* value() { return inputs_[1]; } 2449 LOperand* value() { return inputs_[1]; }
2450 2450
2451 DECLARE_CONCRETE_INSTRUCTION(Typeof, "typeof") 2451 DECLARE_CONCRETE_INSTRUCTION(Typeof, "typeof")
2452 }; 2452 };
2453 2453
2454 2454
2455 class LTypeofIsAndBranch FINAL : public LControlInstruction<1, 0> { 2455 class LTypeofIsAndBranch final : public LControlInstruction<1, 0> {
2456 public: 2456 public:
2457 explicit LTypeofIsAndBranch(LOperand* value) { inputs_[0] = value; } 2457 explicit LTypeofIsAndBranch(LOperand* value) { inputs_[0] = value; }
2458 2458
2459 LOperand* value() { return inputs_[0]; } 2459 LOperand* value() { return inputs_[0]; }
2460 2460
2461 DECLARE_CONCRETE_INSTRUCTION(TypeofIsAndBranch, "typeof-is-and-branch") 2461 DECLARE_CONCRETE_INSTRUCTION(TypeofIsAndBranch, "typeof-is-and-branch")
2462 DECLARE_HYDROGEN_ACCESSOR(TypeofIsAndBranch) 2462 DECLARE_HYDROGEN_ACCESSOR(TypeofIsAndBranch)
2463 2463
2464 Handle<String> type_literal() { return hydrogen()->type_literal(); } 2464 Handle<String> type_literal() { return hydrogen()->type_literal(); }
2465 2465
2466 void PrintDataTo(StringStream* stream) OVERRIDE; 2466 void PrintDataTo(StringStream* stream) override;
2467 }; 2467 };
2468 2468
2469 2469
2470 class LIsConstructCallAndBranch FINAL : public LControlInstruction<0, 1> { 2470 class LIsConstructCallAndBranch final : public LControlInstruction<0, 1> {
2471 public: 2471 public:
2472 explicit LIsConstructCallAndBranch(LOperand* temp) { temps_[0] = temp; } 2472 explicit LIsConstructCallAndBranch(LOperand* temp) { temps_[0] = temp; }
2473 2473
2474 LOperand* temp() { return temps_[0]; } 2474 LOperand* temp() { return temps_[0]; }
2475 2475
2476 DECLARE_CONCRETE_INSTRUCTION(IsConstructCallAndBranch, 2476 DECLARE_CONCRETE_INSTRUCTION(IsConstructCallAndBranch,
2477 "is-construct-call-and-branch") 2477 "is-construct-call-and-branch")
2478 }; 2478 };
2479 2479
2480 2480
2481 class LOsrEntry FINAL : public LTemplateInstruction<0, 0, 0> { 2481 class LOsrEntry final : public LTemplateInstruction<0, 0, 0> {
2482 public: 2482 public:
2483 LOsrEntry() {} 2483 LOsrEntry() {}
2484 2484
2485 bool HasInterestingComment(LCodeGen* gen) const OVERRIDE { return false; } 2485 bool HasInterestingComment(LCodeGen* gen) const override { return false; }
2486 DECLARE_CONCRETE_INSTRUCTION(OsrEntry, "osr-entry") 2486 DECLARE_CONCRETE_INSTRUCTION(OsrEntry, "osr-entry")
2487 }; 2487 };
2488 2488
2489 2489
2490 class LStackCheck FINAL : public LTemplateInstruction<0, 1, 0> { 2490 class LStackCheck final : public LTemplateInstruction<0, 1, 0> {
2491 public: 2491 public:
2492 explicit LStackCheck(LOperand* context) { inputs_[0] = context; } 2492 explicit LStackCheck(LOperand* context) { inputs_[0] = context; }
2493 2493
2494 LOperand* context() { return inputs_[0]; } 2494 LOperand* context() { return inputs_[0]; }
2495 2495
2496 DECLARE_CONCRETE_INSTRUCTION(StackCheck, "stack-check") 2496 DECLARE_CONCRETE_INSTRUCTION(StackCheck, "stack-check")
2497 DECLARE_HYDROGEN_ACCESSOR(StackCheck) 2497 DECLARE_HYDROGEN_ACCESSOR(StackCheck)
2498 2498
2499 Label* done_label() { return &done_label_; } 2499 Label* done_label() { return &done_label_; }
2500 2500
2501 private: 2501 private:
2502 Label done_label_; 2502 Label done_label_;
2503 }; 2503 };
2504 2504
2505 2505
2506 class LForInPrepareMap FINAL : public LTemplateInstruction<1, 2, 0> { 2506 class LForInPrepareMap final : public LTemplateInstruction<1, 2, 0> {
2507 public: 2507 public:
2508 LForInPrepareMap(LOperand* context, LOperand* object) { 2508 LForInPrepareMap(LOperand* context, LOperand* object) {
2509 inputs_[0] = context; 2509 inputs_[0] = context;
2510 inputs_[1] = object; 2510 inputs_[1] = object;
2511 } 2511 }
2512 2512
2513 LOperand* context() { return inputs_[0]; } 2513 LOperand* context() { return inputs_[0]; }
2514 LOperand* object() { return inputs_[1]; } 2514 LOperand* object() { return inputs_[1]; }
2515 2515
2516 DECLARE_CONCRETE_INSTRUCTION(ForInPrepareMap, "for-in-prepare-map") 2516 DECLARE_CONCRETE_INSTRUCTION(ForInPrepareMap, "for-in-prepare-map")
2517 }; 2517 };
2518 2518
2519 2519
2520 class LForInCacheArray FINAL : public LTemplateInstruction<1, 1, 0> { 2520 class LForInCacheArray final : public LTemplateInstruction<1, 1, 0> {
2521 public: 2521 public:
2522 explicit LForInCacheArray(LOperand* map) { inputs_[0] = map; } 2522 explicit LForInCacheArray(LOperand* map) { inputs_[0] = map; }
2523 2523
2524 LOperand* map() { return inputs_[0]; } 2524 LOperand* map() { return inputs_[0]; }
2525 2525
2526 DECLARE_CONCRETE_INSTRUCTION(ForInCacheArray, "for-in-cache-array") 2526 DECLARE_CONCRETE_INSTRUCTION(ForInCacheArray, "for-in-cache-array")
2527 2527
2528 int idx() { return HForInCacheArray::cast(this->hydrogen_value())->idx(); } 2528 int idx() { return HForInCacheArray::cast(this->hydrogen_value())->idx(); }
2529 }; 2529 };
2530 2530
2531 2531
2532 class LCheckMapValue FINAL : public LTemplateInstruction<0, 2, 0> { 2532 class LCheckMapValue final : public LTemplateInstruction<0, 2, 0> {
2533 public: 2533 public:
2534 LCheckMapValue(LOperand* value, LOperand* map) { 2534 LCheckMapValue(LOperand* value, LOperand* map) {
2535 inputs_[0] = value; 2535 inputs_[0] = value;
2536 inputs_[1] = map; 2536 inputs_[1] = map;
2537 } 2537 }
2538 2538
2539 LOperand* value() { return inputs_[0]; } 2539 LOperand* value() { return inputs_[0]; }
2540 LOperand* map() { return inputs_[1]; } 2540 LOperand* map() { return inputs_[1]; }
2541 2541
2542 DECLARE_CONCRETE_INSTRUCTION(CheckMapValue, "check-map-value") 2542 DECLARE_CONCRETE_INSTRUCTION(CheckMapValue, "check-map-value")
2543 }; 2543 };
2544 2544
2545 2545
2546 class LLoadFieldByIndex FINAL : public LTemplateInstruction<1, 2, 0> { 2546 class LLoadFieldByIndex final : public LTemplateInstruction<1, 2, 0> {
2547 public: 2547 public:
2548 LLoadFieldByIndex(LOperand* object, LOperand* index) { 2548 LLoadFieldByIndex(LOperand* object, LOperand* index) {
2549 inputs_[0] = object; 2549 inputs_[0] = object;
2550 inputs_[1] = index; 2550 inputs_[1] = index;
2551 } 2551 }
2552 2552
2553 LOperand* object() { return inputs_[0]; } 2553 LOperand* object() { return inputs_[0]; }
2554 LOperand* index() { return inputs_[1]; } 2554 LOperand* index() { return inputs_[1]; }
2555 2555
2556 DECLARE_CONCRETE_INSTRUCTION(LoadFieldByIndex, "load-field-by-index") 2556 DECLARE_CONCRETE_INSTRUCTION(LoadFieldByIndex, "load-field-by-index")
(...skipping 21 matching lines...) Expand all
2578 LOperand* function() { return inputs_[1]; } 2578 LOperand* function() { return inputs_[1]; }
2579 2579
2580 Handle<ScopeInfo> scope_info() { return hydrogen()->scope_info(); } 2580 Handle<ScopeInfo> scope_info() { return hydrogen()->scope_info(); }
2581 2581
2582 DECLARE_CONCRETE_INSTRUCTION(AllocateBlockContext, "allocate-block-context") 2582 DECLARE_CONCRETE_INSTRUCTION(AllocateBlockContext, "allocate-block-context")
2583 DECLARE_HYDROGEN_ACCESSOR(AllocateBlockContext) 2583 DECLARE_HYDROGEN_ACCESSOR(AllocateBlockContext)
2584 }; 2584 };
2585 2585
2586 2586
2587 class LChunkBuilder; 2587 class LChunkBuilder;
2588 class LPlatformChunk FINAL : public LChunk { 2588 class LPlatformChunk final : public LChunk {
2589 public: 2589 public:
2590 LPlatformChunk(CompilationInfo* info, HGraph* graph) : LChunk(info, graph) {} 2590 LPlatformChunk(CompilationInfo* info, HGraph* graph) : LChunk(info, graph) {}
2591 2591
2592 int GetNextSpillIndex(RegisterKind kind); 2592 int GetNextSpillIndex(RegisterKind kind);
2593 LOperand* GetNextSpillSlot(RegisterKind kind); 2593 LOperand* GetNextSpillSlot(RegisterKind kind);
2594 }; 2594 };
2595 2595
2596 2596
2597 class LChunkBuilder FINAL : public LChunkBuilderBase { 2597 class LChunkBuilder final : public LChunkBuilderBase {
2598 public: 2598 public:
2599 LChunkBuilder(CompilationInfo* info, HGraph* graph, LAllocator* allocator) 2599 LChunkBuilder(CompilationInfo* info, HGraph* graph, LAllocator* allocator)
2600 : LChunkBuilderBase(info, graph), 2600 : LChunkBuilderBase(info, graph),
2601 current_instruction_(NULL), 2601 current_instruction_(NULL),
2602 current_block_(NULL), 2602 current_block_(NULL),
2603 next_block_(NULL), 2603 next_block_(NULL),
2604 allocator_(allocator) {} 2604 allocator_(allocator) {}
2605 2605
2606 // Build the sequence for the graph. 2606 // Build the sequence for the graph.
2607 LPlatformChunk* Build(); 2607 LPlatformChunk* Build();
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
2671 2671
2672 // An input operand in a register or a constant operand. 2672 // An input operand in a register or a constant operand.
2673 MUST_USE_RESULT LOperand* UseRegisterOrConstant(HValue* value); 2673 MUST_USE_RESULT LOperand* UseRegisterOrConstant(HValue* value);
2674 MUST_USE_RESULT LOperand* UseRegisterOrConstantAtStart(HValue* value); 2674 MUST_USE_RESULT LOperand* UseRegisterOrConstantAtStart(HValue* value);
2675 2675
2676 // An input operand in a constant operand. 2676 // An input operand in a constant operand.
2677 MUST_USE_RESULT LOperand* UseConstant(HValue* value); 2677 MUST_USE_RESULT LOperand* UseConstant(HValue* value);
2678 2678
2679 // An input operand in register, stack slot or a constant operand. 2679 // An input operand in register, stack slot or a constant operand.
2680 // Will not be moved to a register even if one is freely available. 2680 // Will not be moved to a register even if one is freely available.
2681 MUST_USE_RESULT LOperand* UseAny(HValue* value) OVERRIDE; 2681 MUST_USE_RESULT LOperand* UseAny(HValue* value) override;
2682 2682
2683 // Temporary operand that must be in a register. 2683 // Temporary operand that must be in a register.
2684 MUST_USE_RESULT LUnallocated* TempRegister(); 2684 MUST_USE_RESULT LUnallocated* TempRegister();
2685 MUST_USE_RESULT LUnallocated* TempDoubleRegister(); 2685 MUST_USE_RESULT LUnallocated* TempDoubleRegister();
2686 MUST_USE_RESULT LOperand* FixedTemp(Register reg); 2686 MUST_USE_RESULT LOperand* FixedTemp(Register reg);
2687 MUST_USE_RESULT LOperand* FixedTemp(DoubleRegister reg); 2687 MUST_USE_RESULT LOperand* FixedTemp(DoubleRegister reg);
2688 2688
2689 // Methods for setting up define-use relationships. 2689 // Methods for setting up define-use relationships.
2690 // Return the same instruction that they are passed. 2690 // Return the same instruction that they are passed.
2691 LInstruction* Define(LTemplateResultInstruction<1>* instr, 2691 LInstruction* Define(LTemplateResultInstruction<1>* instr,
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
2725 2725
2726 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2726 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2727 }; 2727 };
2728 2728
2729 #undef DECLARE_HYDROGEN_ACCESSOR 2729 #undef DECLARE_HYDROGEN_ACCESSOR
2730 #undef DECLARE_CONCRETE_INSTRUCTION 2730 #undef DECLARE_CONCRETE_INSTRUCTION
2731 } 2731 }
2732 } // namespace v8::internal 2732 } // namespace v8::internal
2733 2733
2734 #endif // V8_PPC_LITHIUM_PPC_H_ 2734 #endif // V8_PPC_LITHIUM_PPC_H_
OLDNEW
« no previous file with comments | « src/ppc/lithium-gap-resolver-ppc.h ('k') | src/preparser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698