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 1287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1298 // Make a2 the space we have left. The stack might already be overflowed | 1298 // Make a2 the space we have left. The stack might already be overflowed |
1299 // here which will cause a2 to become negative. | 1299 // here which will cause a2 to become negative. |
1300 __ subu(a2, sp, a2); | 1300 __ subu(a2, sp, a2); |
1301 // Check if the arguments will overflow the stack. | 1301 // Check if the arguments will overflow the stack. |
1302 __ sll(t3, v0, kPointerSizeLog2 - kSmiTagSize); | 1302 __ sll(t3, v0, kPointerSizeLog2 - kSmiTagSize); |
1303 __ Branch(&okay, gt, a2, Operand(t3)); // Signed comparison. | 1303 __ Branch(&okay, gt, a2, Operand(t3)); // Signed comparison. |
1304 | 1304 |
1305 // Out of stack space. | 1305 // Out of stack space. |
1306 __ lw(a1, MemOperand(fp, kFunctionOffset)); | 1306 __ lw(a1, MemOperand(fp, kFunctionOffset)); |
1307 __ Push(a1, v0); | 1307 __ Push(a1, v0); |
1308 __ InvokeBuiltin(Builtins::STACK_OVERFLOW, CALL_FUNCTION); | 1308 __ InvokeBuiltin(Builtins::APPLY_OVERFLOW, CALL_FUNCTION); |
1309 // End of stack check. | 1309 // End of stack check. |
1310 | 1310 |
1311 // Push current limit and index. | 1311 // Push current limit and index. |
1312 __ bind(&okay); | 1312 __ bind(&okay); |
1313 __ mov(a1, zero_reg); | 1313 __ mov(a1, zero_reg); |
1314 __ Push(v0, a1); // Limit and initial index. | 1314 __ Push(v0, a1); // Limit and initial index. |
1315 | 1315 |
1316 // Get the receiver. | 1316 // Get the receiver. |
1317 __ lw(a0, MemOperand(fp, kRecvOffset)); | 1317 __ lw(a0, MemOperand(fp, kRecvOffset)); |
1318 | 1318 |
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1569 __ bind(&dont_adapt_arguments); | 1569 __ bind(&dont_adapt_arguments); |
1570 __ Jump(a3); | 1570 __ Jump(a3); |
1571 } | 1571 } |
1572 | 1572 |
1573 | 1573 |
1574 #undef __ | 1574 #undef __ |
1575 | 1575 |
1576 } } // namespace v8::internal | 1576 } } // namespace v8::internal |
1577 | 1577 |
1578 #endif // V8_TARGET_ARCH_MIPS | 1578 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |