OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 7711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7722 instr = HMul::New(zone(), context, left, right); | 7722 instr = HMul::New(zone(), context, left, right); |
7723 break; | 7723 break; |
7724 case Token::MOD: | 7724 case Token::MOD: |
7725 instr = HMod::New(zone(), context, left, right, fixed_right_arg); | 7725 instr = HMod::New(zone(), context, left, right, fixed_right_arg); |
7726 break; | 7726 break; |
7727 case Token::DIV: | 7727 case Token::DIV: |
7728 instr = HDiv::New(zone(), context, left, right); | 7728 instr = HDiv::New(zone(), context, left, right); |
7729 break; | 7729 break; |
7730 case Token::BIT_XOR: | 7730 case Token::BIT_XOR: |
7731 case Token::BIT_AND: | 7731 case Token::BIT_AND: |
7732 instr = New<HBitwise>(expr->op(), left, right); | 7732 instr = NewUncasted<HBitwise>(expr->op(), left, right); |
7733 break; | 7733 break; |
7734 case Token::BIT_OR: { | 7734 case Token::BIT_OR: { |
7735 HValue* operand, *shift_amount; | 7735 HValue* operand, *shift_amount; |
7736 if (left_type->Is(Type::Signed32()) && | 7736 if (left_type->Is(Type::Signed32()) && |
7737 right_type->Is(Type::Signed32()) && | 7737 right_type->Is(Type::Signed32()) && |
7738 MatchRotateRight(left, right, &operand, &shift_amount)) { | 7738 MatchRotateRight(left, right, &operand, &shift_amount)) { |
7739 instr = new(zone()) HRor(context, operand, shift_amount); | 7739 instr = new(zone()) HRor(context, operand, shift_amount); |
7740 } else { | 7740 } else { |
7741 instr = New<HBitwise>(expr->op(), left, right); | 7741 instr = NewUncasted<HBitwise>(expr->op(), left, right); |
7742 } | 7742 } |
7743 break; | 7743 break; |
7744 } | 7744 } |
7745 case Token::SAR: | 7745 case Token::SAR: |
7746 instr = HSar::New(zone(), context, left, right); | 7746 instr = HSar::New(zone(), context, left, right); |
7747 break; | 7747 break; |
7748 case Token::SHR: | 7748 case Token::SHR: |
7749 instr = HShr::New(zone(), context, left, right); | 7749 instr = HShr::New(zone(), context, left, right); |
7750 if (FLAG_opt_safe_uint32_operations && instr->IsShr() && | 7750 if (FLAG_opt_safe_uint32_operations && instr->IsShr() && |
7751 CanBeZero(right)) { | 7751 CanBeZero(right)) { |
(...skipping 2013 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9765 if (ShouldProduceTraceOutput()) { | 9765 if (ShouldProduceTraceOutput()) { |
9766 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); | 9766 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); |
9767 } | 9767 } |
9768 | 9768 |
9769 #ifdef DEBUG | 9769 #ifdef DEBUG |
9770 graph_->Verify(false); // No full verify. | 9770 graph_->Verify(false); // No full verify. |
9771 #endif | 9771 #endif |
9772 } | 9772 } |
9773 | 9773 |
9774 } } // namespace v8::internal | 9774 } } // namespace v8::internal |
OLD | NEW |