OLD | NEW |
1 // Copyright 2006-2009 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2009 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 463 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
474 | 474 |
475 // Jump to the generic construct code in case the specialized code cannot | 475 // Jump to the generic construct code in case the specialized code cannot |
476 // handle the construction. | 476 // handle the construction. |
477 __ bind(&generic_constructor); | 477 __ bind(&generic_constructor); |
478 Code* code = Builtins::builtin(Builtins::JSConstructStubGeneric); | 478 Code* code = Builtins::builtin(Builtins::JSConstructStubGeneric); |
479 Handle<Code> generic_construct_stub(code); | 479 Handle<Code> generic_construct_stub(code); |
480 __ Jump(generic_construct_stub, RelocInfo::CODE_TARGET); | 480 __ Jump(generic_construct_stub, RelocInfo::CODE_TARGET); |
481 } | 481 } |
482 | 482 |
483 | 483 |
| 484 void Builtins::Generate_StringConstructCode(MacroAssembler* masm) { |
| 485 // TODO(bug): implement custom construct stub. |
| 486 // Generate a copy of the generic stub for now. |
| 487 Generate_JSConstructStubGeneric(masm); |
| 488 } |
| 489 |
| 490 |
484 void Builtins::Generate_JSConstructCall(MacroAssembler* masm) { | 491 void Builtins::Generate_JSConstructCall(MacroAssembler* masm) { |
485 // ----------- S t a t e ------------- | 492 // ----------- S t a t e ------------- |
486 // -- r0 : number of arguments | 493 // -- r0 : number of arguments |
487 // -- r1 : constructor function | 494 // -- r1 : constructor function |
488 // -- lr : return address | 495 // -- lr : return address |
489 // -- sp[...]: constructor arguments | 496 // -- sp[...]: constructor arguments |
490 // ----------------------------------- | 497 // ----------------------------------- |
491 | 498 |
492 Label non_function_call; | 499 Label non_function_call; |
493 // Check that the function is not a smi. | 500 // Check that the function is not a smi. |
(...skipping 835 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1329 __ bind(&dont_adapt_arguments); | 1336 __ bind(&dont_adapt_arguments); |
1330 __ Jump(r3); | 1337 __ Jump(r3); |
1331 } | 1338 } |
1332 | 1339 |
1333 | 1340 |
1334 #undef __ | 1341 #undef __ |
1335 | 1342 |
1336 } } // namespace v8::internal | 1343 } } // namespace v8::internal |
1337 | 1344 |
1338 #endif // V8_TARGET_ARCH_ARM | 1345 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |