Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: src/ia32/full-codegen-ia32.cc

Issue 8518001: Make eval compilation cache calling scope sensitive. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 2132 matching lines...) Expand 10 before | Expand all | Expand 10 after
2143 2143
2144 // Push the receiver of the enclosing function. 2144 // Push the receiver of the enclosing function.
2145 __ push(Operand(ebp, (2 + info_->scope()->num_parameters()) * kPointerSize)); 2145 __ push(Operand(ebp, (2 + info_->scope()->num_parameters()) * kPointerSize));
2146 2146
2147 // Push the strict mode flag. In harmony mode every eval call 2147 // Push the strict mode flag. In harmony mode every eval call
2148 // is a strict mode eval call. 2148 // is a strict mode eval call.
2149 StrictModeFlag strict_mode = 2149 StrictModeFlag strict_mode =
2150 FLAG_harmony_scoping ? kStrictMode : strict_mode_flag(); 2150 FLAG_harmony_scoping ? kStrictMode : strict_mode_flag();
2151 __ push(Immediate(Smi::FromInt(strict_mode))); 2151 __ push(Immediate(Smi::FromInt(strict_mode)));
2152 2152
2153 __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 4); 2153 // Push the start position of the scope the calls resides in.
2154 __ push(Immediate(Smi::FromInt(scope()->start_position())));
2155
2156 __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 5);
2154 } 2157 }
2155 2158
2156 2159
2157 void FullCodeGenerator::VisitCall(Call* expr) { 2160 void FullCodeGenerator::VisitCall(Call* expr) {
2158 #ifdef DEBUG 2161 #ifdef DEBUG
2159 // We want to verify that RecordJSReturnSite gets called on all paths 2162 // We want to verify that RecordJSReturnSite gets called on all paths
2160 // through this function. Avoid early returns. 2163 // through this function. Avoid early returns.
2161 expr->return_is_recorded_ = false; 2164 expr->return_is_recorded_ = false;
2162 #endif 2165 #endif
2163 2166
(...skipping 2176 matching lines...) Expand 10 before | Expand all | Expand 10 after
4340 *context_length = 0; 4343 *context_length = 0;
4341 return previous_; 4344 return previous_;
4342 } 4345 }
4343 4346
4344 4347
4345 #undef __ 4348 #undef __
4346 4349
4347 } } // namespace v8::internal 4350 } } // namespace v8::internal
4348 4351
4349 #endif // V8_TARGET_ARCH_IA32 4352 #endif // V8_TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698