OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 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 1748 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1759 | 1759 |
1760 if (var != NULL && var->is_possibly_eval()) { | 1760 if (var != NULL && var->is_possibly_eval()) { |
1761 // In a call to eval, we first call %ResolvePossiblyDirectEval to | 1761 // In a call to eval, we first call %ResolvePossiblyDirectEval to |
1762 // resolve the function we need to call and the receiver of the | 1762 // resolve the function we need to call and the receiver of the |
1763 // call. Then we call the resolved function using the given | 1763 // call. Then we call the resolved function using the given |
1764 // arguments. | 1764 // arguments. |
1765 ZoneList<Expression*>* args = expr->arguments(); | 1765 ZoneList<Expression*>* args = expr->arguments(); |
1766 int arg_count = args->length(); | 1766 int arg_count = args->length(); |
1767 | 1767 |
1768 { PreserveStatementPositionScope pos_scope(masm()->positions_recorder()); | 1768 { PreserveStatementPositionScope pos_scope(masm()->positions_recorder()); |
1769 | |
1770 VisitForStackValue(fun); | 1769 VisitForStackValue(fun); |
1771 __ LoadRoot(r2, Heap::kUndefinedValueRootIndex); | 1770 __ LoadRoot(r2, Heap::kUndefinedValueRootIndex); |
1772 __ push(r2); // Reserved receiver slot. | 1771 __ push(r2); // Reserved receiver slot. |
1773 | 1772 |
1774 // Push the arguments. | 1773 // Push the arguments. |
1775 for (int i = 0; i < arg_count; i++) { | 1774 for (int i = 0; i < arg_count; i++) { |
1776 VisitForStackValue(args->at(i)); | 1775 VisitForStackValue(args->at(i)); |
1777 } | 1776 } |
1778 | 1777 |
1779 // Push copy of the function - found below the arguments. | 1778 // Push copy of the function - found below the arguments. |
(...skipping 1643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3423 __ mov(r1, Operand(r1, ASR, 1)); // Un-smi-tag value. | 3422 __ mov(r1, Operand(r1, ASR, 1)); // Un-smi-tag value. |
3424 __ add(pc, r1, Operand(masm_->CodeObject())); | 3423 __ add(pc, r1, Operand(masm_->CodeObject())); |
3425 } | 3424 } |
3426 | 3425 |
3427 | 3426 |
3428 #undef __ | 3427 #undef __ |
3429 | 3428 |
3430 } } // namespace v8::internal | 3429 } } // namespace v8::internal |
3431 | 3430 |
3432 #endif // V8_TARGET_ARCH_ARM | 3431 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |