OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_MIPS | 7 #if V8_TARGET_ARCH_MIPS |
8 | 8 |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 1878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1889 __ DropAndRet(3); | 1889 __ DropAndRet(3); |
1890 | 1890 |
1891 // Do the runtime call to allocate the arguments object. | 1891 // Do the runtime call to allocate the arguments object. |
1892 // a2 = argument count (tagged) | 1892 // a2 = argument count (tagged) |
1893 __ bind(&runtime); | 1893 __ bind(&runtime); |
1894 __ sw(a2, MemOperand(sp, 0 * kPointerSize)); // Patch argument count. | 1894 __ sw(a2, MemOperand(sp, 0 * kPointerSize)); // Patch argument count. |
1895 __ TailCallRuntime(Runtime::kNewSloppyArguments, 3, 1); | 1895 __ TailCallRuntime(Runtime::kNewSloppyArguments, 3, 1); |
1896 } | 1896 } |
1897 | 1897 |
1898 | 1898 |
| 1899 void LoadIndexedInterceptorStub::Generate(MacroAssembler* masm) { |
| 1900 // Return address is in ra. |
| 1901 Label slow; |
| 1902 |
| 1903 Register receiver = LoadDescriptor::ReceiverRegister(); |
| 1904 Register key = LoadDescriptor::NameRegister(); |
| 1905 |
| 1906 // Check that the key is an array index, that is Uint32. |
| 1907 __ And(t0, key, Operand(kSmiTagMask | kSmiSignMask)); |
| 1908 __ Branch(&slow, ne, t0, Operand(zero_reg)); |
| 1909 |
| 1910 // Everything is fine, call runtime. |
| 1911 __ Push(receiver, key); // Receiver, key. |
| 1912 |
| 1913 // Perform tail call to the entry. |
| 1914 __ TailCallExternalReference( |
| 1915 ExternalReference(IC_Utility(IC::kLoadElementWithInterceptor), |
| 1916 masm->isolate()), |
| 1917 2, 1); |
| 1918 |
| 1919 __ bind(&slow); |
| 1920 PropertyAccessCompiler::TailCallBuiltin( |
| 1921 masm, PropertyAccessCompiler::MissBuiltin(Code::KEYED_LOAD_IC)); |
| 1922 } |
| 1923 |
| 1924 |
1899 void ArgumentsAccessStub::GenerateNewStrict(MacroAssembler* masm) { | 1925 void ArgumentsAccessStub::GenerateNewStrict(MacroAssembler* masm) { |
1900 // sp[0] : number of parameters | 1926 // sp[0] : number of parameters |
1901 // sp[4] : receiver displacement | 1927 // sp[4] : receiver displacement |
1902 // sp[8] : function | 1928 // sp[8] : function |
1903 // Check if the calling frame is an arguments adaptor frame. | 1929 // Check if the calling frame is an arguments adaptor frame. |
1904 Label adaptor_frame, try_allocate, runtime; | 1930 Label adaptor_frame, try_allocate, runtime; |
1905 __ lw(a2, MemOperand(fp, StandardFrameConstants::kCallerFPOffset)); | 1931 __ lw(a2, MemOperand(fp, StandardFrameConstants::kCallerFPOffset)); |
1906 __ lw(a3, MemOperand(a2, StandardFrameConstants::kContextOffset)); | 1932 __ lw(a3, MemOperand(a2, StandardFrameConstants::kContextOffset)); |
1907 __ Branch(&adaptor_frame, | 1933 __ Branch(&adaptor_frame, |
1908 eq, | 1934 eq, |
(...skipping 2950 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4859 MemOperand(fp, 6 * kPointerSize), | 4885 MemOperand(fp, 6 * kPointerSize), |
4860 NULL); | 4886 NULL); |
4861 } | 4887 } |
4862 | 4888 |
4863 | 4889 |
4864 #undef __ | 4890 #undef __ |
4865 | 4891 |
4866 } } // namespace v8::internal | 4892 } } // namespace v8::internal |
4867 | 4893 |
4868 #endif // V8_TARGET_ARCH_MIPS | 4894 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |