OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 548 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
559 | 559 |
560 // Ensure the object is fully initialized. | 560 // Ensure the object is fully initialized. |
561 STATIC_ASSERT(JSValue::kSize == 4 * kPointerSize); | 561 STATIC_ASSERT(JSValue::kSize == 4 * kPointerSize); |
562 | 562 |
563 __ Ret(); | 563 __ Ret(); |
564 | 564 |
565 // The argument was not found in the number to string cache. Check | 565 // The argument was not found in the number to string cache. Check |
566 // if it's a string already before calling the conversion builtin. | 566 // if it's a string already before calling the conversion builtin. |
567 Label convert_argument; | 567 Label convert_argument; |
568 __ bind(¬_cached); | 568 __ bind(¬_cached); |
569 __ BranchOnSmi(r0, &convert_argument); | 569 __ JumpIfSmi(r0, &convert_argument); |
570 | 570 |
571 // Is it a String? | 571 // Is it a String? |
572 __ ldr(r2, FieldMemOperand(r0, HeapObject::kMapOffset)); | 572 __ ldr(r2, FieldMemOperand(r0, HeapObject::kMapOffset)); |
573 __ ldrb(r3, FieldMemOperand(r2, Map::kInstanceTypeOffset)); | 573 __ ldrb(r3, FieldMemOperand(r2, Map::kInstanceTypeOffset)); |
574 ASSERT(kNotStringTag != 0); | 574 ASSERT(kNotStringTag != 0); |
575 __ tst(r3, Operand(kIsNotStringMask)); | 575 __ tst(r3, Operand(kIsNotStringMask)); |
576 __ b(ne, &convert_argument); | 576 __ b(ne, &convert_argument); |
577 __ mov(argument, r0); | 577 __ mov(argument, r0); |
578 __ IncrementCounter(&Counters::string_ctor_conversions, 1, r3, r4); | 578 __ IncrementCounter(&Counters::string_ctor_conversions, 1, r3, r4); |
579 __ b(&argument_is_string); | 579 __ b(&argument_is_string); |
(...skipping 985 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1565 __ bind(&dont_adapt_arguments); | 1565 __ bind(&dont_adapt_arguments); |
1566 __ Jump(r3); | 1566 __ Jump(r3); |
1567 } | 1567 } |
1568 | 1568 |
1569 | 1569 |
1570 #undef __ | 1570 #undef __ |
1571 | 1571 |
1572 } } // namespace v8::internal | 1572 } } // namespace v8::internal |
1573 | 1573 |
1574 #endif // V8_TARGET_ARCH_ARM | 1574 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |