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

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

Issue 22892002: Fix issue 12369: compare kind of unary math instruction and not only the inputs to determine if at… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 4 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 | « no previous file | tests/language/math_vm_test.dart » ('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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 4609 matching lines...) Expand 10 before | Expand all | Expand 10 after
4620 // was inherited from another instruction that could deoptimize. 4620 // was inherited from another instruction that could deoptimize.
4621 return deopt_id_; 4621 return deopt_id_;
4622 } 4622 }
4623 4623
4624 DECLARE_INSTRUCTION(MathUnary) 4624 DECLARE_INSTRUCTION(MathUnary)
4625 virtual CompileType ComputeType() const; 4625 virtual CompileType ComputeType() const;
4626 4626
4627 virtual bool AllowsCSE() const { return true; } 4627 virtual bool AllowsCSE() const { return true; }
4628 virtual EffectSet Effects() const { return EffectSet::None(); } 4628 virtual EffectSet Effects() const { return EffectSet::None(); }
4629 virtual EffectSet Dependencies() const { return EffectSet::None(); } 4629 virtual EffectSet Dependencies() const { return EffectSet::None(); }
4630 virtual bool AttributesEqual(Instruction* other) const { return true; } 4630 virtual bool AttributesEqual(Instruction* other) const {
4631 return kind() == other->AsMathUnary()->kind();
4632 }
4631 4633
4632 virtual bool MayThrow() const { return false; } 4634 virtual bool MayThrow() const { return false; }
4633 4635
4634 private: 4636 private:
4635 const MethodRecognizer::Kind kind_; 4637 const MethodRecognizer::Kind kind_;
4636 4638
4637 DISALLOW_COPY_AND_ASSIGN(MathUnaryInstr); 4639 DISALLOW_COPY_AND_ASSIGN(MathUnaryInstr);
4638 }; 4640 };
4639 4641
4640 4642
(...skipping 1976 matching lines...) Expand 10 before | Expand all | Expand 10 after
6617 ForwardInstructionIterator* current_iterator_; 6619 ForwardInstructionIterator* current_iterator_;
6618 6620
6619 private: 6621 private:
6620 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); 6622 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor);
6621 }; 6623 };
6622 6624
6623 6625
6624 } // namespace dart 6626 } // namespace dart
6625 6627
6626 #endif // VM_INTERMEDIATE_LANGUAGE_H_ 6628 #endif // VM_INTERMEDIATE_LANGUAGE_H_
OLDNEW
« no previous file with comments | « no previous file | tests/language/math_vm_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698