| 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 918 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 929 } | 929 } |
| 930 } | 930 } |
| 931 result = EnforceNumberType(result, result_type); | 931 result = EnforceNumberType(result, result_type); |
| 932 } | 932 } |
| 933 | 933 |
| 934 // Reuse the double box of one of the operands if we are allowed to (i.e. | 934 // Reuse the double box of one of the operands if we are allowed to (i.e. |
| 935 // chained binops). | 935 // chained binops). |
| 936 if (state.CanReuseDoubleBox()) { | 936 if (state.CanReuseDoubleBox()) { |
| 937 HValue* operand = (state.mode() == OVERWRITE_LEFT) ? left : right; | 937 HValue* operand = (state.mode() == OVERWRITE_LEFT) ? left : right; |
| 938 IfBuilder if_heap_number(this); | 938 IfBuilder if_heap_number(this); |
| 939 if_heap_number.IfNot<HIsSmiAndBranch>(operand); | 939 if_heap_number.If<HHasInstanceTypeAndBranch>(operand, HEAP_NUMBER_TYPE); |
| 940 if_heap_number.Then(); | 940 if_heap_number.Then(); |
| 941 Add<HStoreNamedField>(operand, HObjectAccess::ForHeapNumberValue(), result); | 941 Add<HStoreNamedField>(operand, HObjectAccess::ForHeapNumberValue(), result); |
| 942 Push(operand); | 942 Push(operand); |
| 943 if_heap_number.Else(); | 943 if_heap_number.Else(); |
| 944 Push(result); | 944 Push(result); |
| 945 if_heap_number.End(); | 945 if_heap_number.End(); |
| 946 result = Pop(); | 946 result = Pop(); |
| 947 } | 947 } |
| 948 | 948 |
| 949 return result; | 949 return result; |
| (...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1399 return BuildRegExpConstructResult(length, index, input); | 1399 return BuildRegExpConstructResult(length, index, input); |
| 1400 } | 1400 } |
| 1401 | 1401 |
| 1402 | 1402 |
| 1403 Handle<Code> RegExpConstructResultStub::GenerateCode(Isolate* isolate) { | 1403 Handle<Code> RegExpConstructResultStub::GenerateCode(Isolate* isolate) { |
| 1404 return DoGenerateCode(isolate, this); | 1404 return DoGenerateCode(isolate, this); |
| 1405 } | 1405 } |
| 1406 | 1406 |
| 1407 | 1407 |
| 1408 } } // namespace v8::internal | 1408 } } // namespace v8::internal |
| OLD | NEW |