OLD | NEW |
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 602 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
613 M(PolymorphicInstanceCall) \ | 613 M(PolymorphicInstanceCall) \ |
614 M(StaticCall) \ | 614 M(StaticCall) \ |
615 M(LoadLocal) \ | 615 M(LoadLocal) \ |
616 M(PushTemp) \ | 616 M(PushTemp) \ |
617 M(DropTemps) \ | 617 M(DropTemps) \ |
618 M(StoreLocal) \ | 618 M(StoreLocal) \ |
619 M(StrictCompare) \ | 619 M(StrictCompare) \ |
620 M(EqualityCompare) \ | 620 M(EqualityCompare) \ |
621 M(RelationalOp) \ | 621 M(RelationalOp) \ |
622 M(NativeCall) \ | 622 M(NativeCall) \ |
| 623 M(DebugStepCheck) \ |
623 M(LoadIndexed) \ | 624 M(LoadIndexed) \ |
624 M(StoreIndexed) \ | 625 M(StoreIndexed) \ |
625 M(StoreInstanceField) \ | 626 M(StoreInstanceField) \ |
626 M(LoadStaticField) \ | 627 M(LoadStaticField) \ |
627 M(StoreStaticField) \ | 628 M(StoreStaticField) \ |
628 M(BooleanNegate) \ | 629 M(BooleanNegate) \ |
629 M(InstanceOf) \ | 630 M(InstanceOf) \ |
630 M(CreateArray) \ | 631 M(CreateArray) \ |
631 M(CreateClosure) \ | 632 M(CreateClosure) \ |
632 M(AllocateObject) \ | 633 M(AllocateObject) \ |
(...skipping 2776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3409 return true; | 3410 return true; |
3410 } | 3411 } |
3411 | 3412 |
3412 private: | 3413 private: |
3413 const NativeBodyNode& ast_node_; | 3414 const NativeBodyNode& ast_node_; |
3414 | 3415 |
3415 DISALLOW_COPY_AND_ASSIGN(NativeCallInstr); | 3416 DISALLOW_COPY_AND_ASSIGN(NativeCallInstr); |
3416 }; | 3417 }; |
3417 | 3418 |
3418 | 3419 |
| 3420 class DebugStepCheckInstr : public TemplateInstruction<0> { |
| 3421 public: |
| 3422 explicit DebugStepCheckInstr(intptr_t token_pos) |
| 3423 : token_pos_(token_pos) { |
| 3424 } |
| 3425 |
| 3426 DECLARE_INSTRUCTION(DebugStepCheck) |
| 3427 |
| 3428 intptr_t token_pos() const { return token_pos_; } |
| 3429 virtual bool MayThrow() const { return false; } |
| 3430 virtual bool CanDeoptimize() const { return false; } |
| 3431 virtual EffectSet Effects() const { return EffectSet::None(); } |
| 3432 virtual intptr_t ArgumentCount() const { return 0; } |
| 3433 virtual Instruction* Canonicalize(FlowGraph* flow_graph); |
| 3434 |
| 3435 private: |
| 3436 const intptr_t token_pos_; |
| 3437 |
| 3438 DISALLOW_COPY_AND_ASSIGN(DebugStepCheckInstr); |
| 3439 }; |
| 3440 |
| 3441 |
3419 enum StoreBarrierType { | 3442 enum StoreBarrierType { |
3420 kNoStoreBarrier, | 3443 kNoStoreBarrier, |
3421 kEmitStoreBarrier | 3444 kEmitStoreBarrier |
3422 }; | 3445 }; |
3423 | 3446 |
3424 | 3447 |
3425 class StoreInstanceFieldInstr : public TemplateDefinition<2> { | 3448 class StoreInstanceFieldInstr : public TemplateDefinition<2> { |
3426 public: | 3449 public: |
3427 StoreInstanceFieldInstr(const Field& field, | 3450 StoreInstanceFieldInstr(const Field& field, |
3428 Value* instance, | 3451 Value* instance, |
(...skipping 3656 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7085 ForwardInstructionIterator* current_iterator_; | 7108 ForwardInstructionIterator* current_iterator_; |
7086 | 7109 |
7087 private: | 7110 private: |
7088 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); | 7111 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); |
7089 }; | 7112 }; |
7090 | 7113 |
7091 | 7114 |
7092 } // namespace dart | 7115 } // namespace dart |
7093 | 7116 |
7094 #endif // VM_INTERMEDIATE_LANGUAGE_H_ | 7117 #endif // VM_INTERMEDIATE_LANGUAGE_H_ |
OLD | NEW |