OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 2076 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2087 | 2087 |
2088 // Push the receiver of the enclosing function and do runtime call. | 2088 // Push the receiver of the enclosing function and do runtime call. |
2089 __ push(Operand(rbp, (2 + info_->scope()->num_parameters()) * kPointerSize)); | 2089 __ push(Operand(rbp, (2 + info_->scope()->num_parameters()) * kPointerSize)); |
2090 | 2090 |
2091 // Push the strict mode flag. In harmony mode every eval call | 2091 // Push the strict mode flag. In harmony mode every eval call |
2092 // is a strict mode eval call. | 2092 // is a strict mode eval call. |
2093 StrictModeFlag strict_mode = | 2093 StrictModeFlag strict_mode = |
2094 FLAG_harmony_scoping ? kStrictMode : strict_mode_flag(); | 2094 FLAG_harmony_scoping ? kStrictMode : strict_mode_flag(); |
2095 __ Push(Smi::FromInt(strict_mode)); | 2095 __ Push(Smi::FromInt(strict_mode)); |
2096 | 2096 |
2097 __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 4); | 2097 // Push the start position of the scope the calls resides in. |
| 2098 __ Push(Smi::FromInt(scope()->start_position())); |
| 2099 |
| 2100 __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 5); |
2098 } | 2101 } |
2099 | 2102 |
2100 | 2103 |
2101 void FullCodeGenerator::VisitCall(Call* expr) { | 2104 void FullCodeGenerator::VisitCall(Call* expr) { |
2102 #ifdef DEBUG | 2105 #ifdef DEBUG |
2103 // We want to verify that RecordJSReturnSite gets called on all paths | 2106 // We want to verify that RecordJSReturnSite gets called on all paths |
2104 // through this function. Avoid early returns. | 2107 // through this function. Avoid early returns. |
2105 expr->return_is_recorded_ = false; | 2108 expr->return_is_recorded_ = false; |
2106 #endif | 2109 #endif |
2107 | 2110 |
(...skipping 2194 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4302 *context_length = 0; | 4305 *context_length = 0; |
4303 return previous_; | 4306 return previous_; |
4304 } | 4307 } |
4305 | 4308 |
4306 | 4309 |
4307 #undef __ | 4310 #undef __ |
4308 | 4311 |
4309 } } // namespace v8::internal | 4312 } } // namespace v8::internal |
4310 | 4313 |
4311 #endif // V8_TARGET_ARCH_X64 | 4314 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |