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

Side by Side Diff: src/contexts.h

Issue 1335633002: Do not look for the slot in the ScopeInfo's global range when it's not necessary. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Cleanup Created 5 years, 3 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 unified diff | Download patch
« no previous file with comments | « no previous file | src/contexts.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_CONTEXTS_H_ 5 #ifndef V8_CONTEXTS_H_
6 #define V8_CONTEXTS_H_ 6 #define V8_CONTEXTS_H_
7 7
8 #include "src/heap/heap.h" 8 #include "src/heap/heap.h"
9 #include "src/objects.h" 9 #include "src/objects.h"
10 10
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
295 // the subsequent slots 1..used contain ScriptContexts. 295 // the subsequent slots 1..used contain ScriptContexts.
296 class ScriptContextTable : public FixedArray { 296 class ScriptContextTable : public FixedArray {
297 public: 297 public:
298 // Conversions. 298 // Conversions.
299 static inline ScriptContextTable* cast(Object* context); 299 static inline ScriptContextTable* cast(Object* context);
300 300
301 struct LookupResult { 301 struct LookupResult {
302 int context_index; 302 int context_index;
303 int slot_index; 303 int slot_index;
304 VariableMode mode; 304 VariableMode mode;
305 VariableLocation location;
306 InitializationFlag init_flag; 305 InitializationFlag init_flag;
307 MaybeAssignedFlag maybe_assigned_flag; 306 MaybeAssignedFlag maybe_assigned_flag;
308 }; 307 };
309 308
310 inline int used() const; 309 inline int used() const;
311 inline void set_used(int used); 310 inline void set_used(int used);
312 311
313 static inline Handle<Context> GetContext(Handle<ScriptContextTable> table, 312 static inline Handle<Context> GetContext(Handle<ScriptContextTable> table,
314 int i); 313 int i);
315 314
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
582 static bool IsBootstrappingOrGlobalObject(Isolate* isolate, Object* object); 581 static bool IsBootstrappingOrGlobalObject(Isolate* isolate, Object* object);
583 #endif 582 #endif
584 583
585 STATIC_ASSERT(kHeaderSize == Internals::kContextHeaderSize); 584 STATIC_ASSERT(kHeaderSize == Internals::kContextHeaderSize);
586 STATIC_ASSERT(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex); 585 STATIC_ASSERT(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex);
587 }; 586 };
588 587
589 } } // namespace v8::internal 588 } } // namespace v8::internal
590 589
591 #endif // V8_CONTEXTS_H_ 590 #endif // V8_CONTEXTS_H_
OLDNEW
« no previous file with comments | « no previous file | src/contexts.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698