OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 3903 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3914 | 3914 |
3915 | 3915 |
3916 void LCodeGen::DoCallNew(LCallNew* instr) { | 3916 void LCodeGen::DoCallNew(LCallNew* instr) { |
3917 ASSERT(ToRegister(instr->context()).is(rsi)); | 3917 ASSERT(ToRegister(instr->context()).is(rsi)); |
3918 ASSERT(ToRegister(instr->constructor()).is(rdi)); | 3918 ASSERT(ToRegister(instr->constructor()).is(rdi)); |
3919 ASSERT(ToRegister(instr->result()).is(rax)); | 3919 ASSERT(ToRegister(instr->result()).is(rax)); |
3920 | 3920 |
3921 __ Set(rax, instr->arity()); | 3921 __ Set(rax, instr->arity()); |
3922 // No cell in ebx for construct type feedback in optimized code | 3922 // No cell in ebx for construct type feedback in optimized code |
3923 __ LoadRoot(rbx, Heap::kUndefinedValueRootIndex); | 3923 __ LoadRoot(rbx, Heap::kUndefinedValueRootIndex); |
3924 CallConstructStub stub(NO_CALL_FUNCTION_FLAGS); | 3924 CallConstructStub stub(NO_CALL_CONSTRUCTOR_FLAGS); |
3925 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); | 3925 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); |
3926 } | 3926 } |
3927 | 3927 |
3928 | 3928 |
3929 void LCodeGen::DoCallNewArray(LCallNewArray* instr) { | 3929 void LCodeGen::DoCallNewArray(LCallNewArray* instr) { |
3930 ASSERT(ToRegister(instr->context()).is(rsi)); | 3930 ASSERT(ToRegister(instr->context()).is(rsi)); |
3931 ASSERT(ToRegister(instr->constructor()).is(rdi)); | 3931 ASSERT(ToRegister(instr->constructor()).is(rdi)); |
3932 ASSERT(ToRegister(instr->result()).is(rax)); | 3932 ASSERT(ToRegister(instr->result()).is(rax)); |
3933 | 3933 |
3934 __ Set(rax, instr->arity()); | 3934 __ Set(rax, instr->arity()); |
(...skipping 1788 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5723 __ bind(deferred->exit()); | 5723 __ bind(deferred->exit()); |
5724 __ bind(&done); | 5724 __ bind(&done); |
5725 } | 5725 } |
5726 | 5726 |
5727 | 5727 |
5728 #undef __ | 5728 #undef __ |
5729 | 5729 |
5730 } } // namespace v8::internal | 5730 } } // namespace v8::internal |
5731 | 5731 |
5732 #endif // V8_TARGET_ARCH_X64 | 5732 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |