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

Side by Side Diff: runtime/vm/intermediate_language.h

Issue 10702195: Equality compare should record two arguments in IC data. INline double equality comparison. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/il_printer.cc ('k') | runtime/vm/intermediate_language_ia32.cc » ('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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_INTERMEDIATE_LANGUAGE_H_ 5 #ifndef VM_INTERMEDIATE_LANGUAGE_H_
6 #define VM_INTERMEDIATE_LANGUAGE_H_ 6 #define VM_INTERMEDIATE_LANGUAGE_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 #include "vm/ast.h" 9 #include "vm/ast.h"
10 #include "vm/growable_array.h" 10 #include "vm/growable_array.h"
(...skipping 614 matching lines...) Expand 10 before | Expand all | Expand 10 after
625 625
626 626
627 class EqualityCompareComp : public ComparisonComp { 627 class EqualityCompareComp : public ComparisonComp {
628 public: 628 public:
629 EqualityCompareComp(intptr_t token_pos, 629 EqualityCompareComp(intptr_t token_pos,
630 intptr_t try_index, 630 intptr_t try_index,
631 Value* left, 631 Value* left,
632 Value* right) 632 Value* right)
633 : ComparisonComp(left, right), 633 : ComparisonComp(left, right),
634 token_pos_(token_pos), 634 token_pos_(token_pos),
635 try_index_(try_index) { 635 try_index_(try_index),
636 receiver_class_id_(kObject) {
636 } 637 }
637 638
638 DECLARE_COMPUTATION(EqualityCompare) 639 DECLARE_COMPUTATION(EqualityCompare)
639 640
640 intptr_t token_pos() const { return token_pos_; } 641 intptr_t token_pos() const { return token_pos_; }
641 intptr_t try_index() const { return try_index_; } 642 intptr_t try_index() const { return try_index_; }
643
644 void set_receiver_class_id(intptr_t value) { receiver_class_id_ = value; }
645 intptr_t receiver_class_id() const { return receiver_class_id_; }
642 virtual void PrintOperandsTo(BufferFormatter* f) const; 646 virtual void PrintOperandsTo(BufferFormatter* f) const;
643 647
644 private: 648 private:
645 const intptr_t token_pos_; 649 const intptr_t token_pos_;
646 const intptr_t try_index_; 650 const intptr_t try_index_;
651 intptr_t receiver_class_id_; // Set by optimizer.
647 652
648 DISALLOW_COPY_AND_ASSIGN(EqualityCompareComp); 653 DISALLOW_COPY_AND_ASSIGN(EqualityCompareComp);
649 }; 654 };
650 655
651 656
652 class RelationalOpComp : public ComparisonComp { 657 class RelationalOpComp : public ComparisonComp {
653 public: 658 public:
654 RelationalOpComp(intptr_t token_pos, 659 RelationalOpComp(intptr_t token_pos,
655 intptr_t try_index, 660 intptr_t try_index,
656 Token::Kind kind, 661 Token::Kind kind,
(...skipping 1827 matching lines...) Expand 10 before | Expand all | Expand 10 after
2484 const GrowableArray<BlockEntryInstr*>& block_order_; 2489 const GrowableArray<BlockEntryInstr*>& block_order_;
2485 2490
2486 private: 2491 private:
2487 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); 2492 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor);
2488 }; 2493 };
2489 2494
2490 2495
2491 } // namespace dart 2496 } // namespace dart
2492 2497
2493 #endif // VM_INTERMEDIATE_LANGUAGE_H_ 2498 #endif // VM_INTERMEDIATE_LANGUAGE_H_
OLDNEW
« no previous file with comments | « runtime/vm/il_printer.cc ('k') | runtime/vm/intermediate_language_ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698