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

Unified Diff: src/scopeinfo.cc

Issue 20078: Remove unused code. This code used to be used to "decide" if a call... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 10 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/scopeinfo.h ('k') | src/scopes.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/scopeinfo.cc
===================================================================
--- src/scopeinfo.cc (revision 1226)
+++ src/scopeinfo.cc (working copy)
@@ -50,7 +50,6 @@
template<class Allocator>
ScopeInfo<Allocator>::ScopeInfo(Scope* scope)
: function_name_(Factory::empty_symbol()),
- supports_eval_(scope->SupportsEval()),
parameters_(scope->num_parameters()),
stack_slots_(scope->num_stack_slots()),
context_slots_(scope->num_heap_slots()),
@@ -151,7 +150,6 @@
// Encoding format in the Code object:
//
// - function name
-// - supports eval info
//
// - number of variables in the context object (smi) (= function context
// slot index + 1)
@@ -247,7 +245,6 @@
template<class Allocator>
ScopeInfo<Allocator>::ScopeInfo(Code* code)
: function_name_(Factory::empty_symbol()),
- supports_eval_(false),
parameters_(4),
stack_slots_(8),
context_slots_(8),
@@ -257,7 +254,6 @@
Object** p0 = &Memory::Object_at(code->sinfo_start());
Object** p = p0;
p = ReadSymbol(p, &function_name_);
- p = ReadBool(p, &supports_eval_);
p = ReadList<Allocator>(p, &context_slots_, &context_modes_);
p = ReadList<Allocator>(p, &parameters_);
p = ReadList<Allocator>(p, &stack_slots_);
@@ -310,8 +306,8 @@
template<class Allocator>
int ScopeInfo<Allocator>::Serialize(Code* code) {
- // function name, supports eval, length & sentinel for 3 tables:
- const int extra_slots = 1 + 1 + 2 * 3;
+ // function name, length & sentinel for 3 tables:
+ const int extra_slots = 1 + 2 * 3;
int size = (extra_slots +
context_slots_.length() * 2 +
parameters_.length() +
@@ -322,7 +318,6 @@
Object** p0 = &Memory::Object_at(code->sinfo_start());
Object** p = p0;
p = WriteSymbol(p, function_name_);
- p = WriteInt(p, supports_eval_);
p = WriteList(p, &context_slots_, &context_modes_);
p = WriteList(p, &parameters_);
p = WriteList(p, &stack_slots_);
@@ -343,8 +338,8 @@
static Object** ContextEntriesAddr(Code* code) {
ASSERT(code->sinfo_size() > 0);
- // +2 for function name, supports eval:
- return &Memory::Object_at(code->sinfo_start()) + 2;
+ // +1 for function name:
+ return &Memory::Object_at(code->sinfo_start()) + 1;
}
@@ -367,21 +362,6 @@
template<class Allocator>
-bool ScopeInfo<Allocator>::SupportsEval(Code* code) {
- bool result = false;
- if (code->sinfo_size() > 0) {
- ReadBool(&Memory::Object_at(code->sinfo_start()) + 1, &result);
- }
-#ifdef DEBUG
- { ScopeInfo info(code);
- ASSERT(result == info.supports_eval_);
- }
-#endif
- return result;
-}
-
-
-template<class Allocator>
int ScopeInfo<Allocator>::NumberOfStackSlots(Code* code) {
if (code->sinfo_size() > 0) {
Object** p = StackSlotEntriesAddr(code);
@@ -551,9 +531,6 @@
PrintF("/* no function name */");
PrintF("{");
- if (supports_eval_)
- PrintF("\n // supports eval\n");
-
PrintList<Allocator>("parameters", 0, parameters_);
PrintList<Allocator>("stack slots", 0, stack_slots_);
PrintList<Allocator>("context slots", Context::MIN_CONTEXT_SLOTS,
« no previous file with comments | « src/scopeinfo.h ('k') | src/scopes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698