OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 8879 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8890 } | 8890 } |
8891 | 8891 |
8892 | 8892 |
8893 HInstruction* HOptimizedGraphBuilder::BuildBinaryOperation( | 8893 HInstruction* HOptimizedGraphBuilder::BuildBinaryOperation( |
8894 BinaryOperation* expr, | 8894 BinaryOperation* expr, |
8895 HValue* left, | 8895 HValue* left, |
8896 HValue* right) { | 8896 HValue* right) { |
8897 HValue* context = environment()->LookupContext(); | 8897 HValue* context = environment()->LookupContext(); |
8898 Handle<Type> left_type = expr->left()->lower_type(); | 8898 Handle<Type> left_type = expr->left()->lower_type(); |
8899 Handle<Type> right_type = expr->right()->lower_type(); | 8899 Handle<Type> right_type = expr->right()->lower_type(); |
8900 Handle<Type> result_type = expr->lower_type(); | 8900 Handle<Type> result_type = expr->result_type(); |
8901 Maybe<int> fixed_right_arg = expr->fixed_right_arg(); | 8901 Maybe<int> fixed_right_arg = expr->fixed_right_arg(); |
8902 Representation left_rep = ToRepresentation(left_type); | 8902 Representation left_rep = ToRepresentation(left_type); |
8903 Representation right_rep = ToRepresentation(right_type); | 8903 Representation right_rep = ToRepresentation(right_type); |
8904 Representation result_rep = ToRepresentation(result_type); | 8904 Representation result_rep = ToRepresentation(result_type); |
8905 if (left_type->Is(Type::None())) { | 8905 if (left_type->Is(Type::None())) { |
8906 AddSoftDeoptimize(); | 8906 AddSoftDeoptimize(); |
8907 // TODO(rossberg): we should be able to get rid of non-continuous defaults. | 8907 // TODO(rossberg): we should be able to get rid of non-continuous defaults. |
8908 left_type = handle(Type::Any(), isolate()); | 8908 left_type = handle(Type::Any(), isolate()); |
8909 } | 8909 } |
8910 if (right_type->Is(Type::None())) { | 8910 if (right_type->Is(Type::None())) { |
(...skipping 2109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11020 if (ShouldProduceTraceOutput()) { | 11020 if (ShouldProduceTraceOutput()) { |
11021 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); | 11021 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); |
11022 } | 11022 } |
11023 | 11023 |
11024 #ifdef DEBUG | 11024 #ifdef DEBUG |
11025 graph_->Verify(false); // No full verify. | 11025 graph_->Verify(false); // No full verify. |
11026 #endif | 11026 #endif |
11027 } | 11027 } |
11028 | 11028 |
11029 } } // namespace v8::internal | 11029 } } // namespace v8::internal |
OLD | NEW |