OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/crankshaft/hydrogen.h" | 5 #include "src/crankshaft/hydrogen.h" |
6 | 6 |
7 #include <sstream> | 7 #include <sstream> |
8 | 8 |
9 #include "src/allocation-site-scopes.h" | 9 #include "src/allocation-site-scopes.h" |
10 #include "src/ast/ast-numbering.h" | 10 #include "src/ast/ast-numbering.h" |
(...skipping 11516 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11527 HCompareObjectEqAndBranch* result = | 11527 HCompareObjectEqAndBranch* result = |
11528 New<HCompareObjectEqAndBranch>(left, right); | 11528 New<HCompareObjectEqAndBranch>(left, right); |
11529 if (top_info()->is_tracking_positions()) { | 11529 if (top_info()->is_tracking_positions()) { |
11530 result->set_operand_position(zone(), 0, left_position); | 11530 result->set_operand_position(zone(), 0, left_position); |
11531 result->set_operand_position(zone(), 1, right_position); | 11531 result->set_operand_position(zone(), 1, right_position); |
11532 } | 11532 } |
11533 return result; | 11533 return result; |
11534 } else { | 11534 } else { |
11535 BuildCheckHeapObject(operand_to_check); | 11535 BuildCheckHeapObject(operand_to_check); |
11536 Add<HCheckInstanceType>(operand_to_check, | 11536 Add<HCheckInstanceType>(operand_to_check, |
11537 HCheckInstanceType::IS_SPEC_OBJECT); | 11537 HCheckInstanceType::IS_JS_RECEIVER); |
11538 HCompareObjectEqAndBranch* result = | 11538 HCompareObjectEqAndBranch* result = |
11539 New<HCompareObjectEqAndBranch>(left, right); | 11539 New<HCompareObjectEqAndBranch>(left, right); |
11540 return result; | 11540 return result; |
11541 } | 11541 } |
11542 } else { | 11542 } else { |
11543 if (combined_type->IsClass()) { | 11543 if (combined_type->IsClass()) { |
11544 // TODO(bmeurer): This is an optimized version of an x < y, x > y, | 11544 // TODO(bmeurer): This is an optimized version of an x < y, x > y, |
11545 // x <= y or x >= y, where both x and y are spec objects with the | 11545 // x <= y or x >= y, where both x and y are spec objects with the |
11546 // same map. The CompareIC collects this map for us. So if we know | 11546 // same map. The CompareIC collects this map for us. So if we know |
11547 // that there's no @@toPrimitive on the map (including the prototype | 11547 // that there's no @@toPrimitive on the map (including the prototype |
(...skipping 2071 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
13619 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); | 13619 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); |
13620 } | 13620 } |
13621 | 13621 |
13622 #ifdef DEBUG | 13622 #ifdef DEBUG |
13623 graph_->Verify(false); // No full verify. | 13623 graph_->Verify(false); // No full verify. |
13624 #endif | 13624 #endif |
13625 } | 13625 } |
13626 | 13626 |
13627 } // namespace internal | 13627 } // namespace internal |
13628 } // namespace v8 | 13628 } // namespace v8 |
OLD | NEW |