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

Side by Side Diff: src/compiler/js-global-object-specialization.cc

Issue 2233673003: Remove CONST_LEGACY VariableMode (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased Created 4 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 | « src/compiler/ast-graph-builder.cc ('k') | 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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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 #include "src/compiler/js-global-object-specialization.h" 5 #include "src/compiler/js-global-object-specialization.h"
6 6
7 #include "src/compilation-dependencies.h" 7 #include "src/compilation-dependencies.h"
8 #include "src/compiler/access-builder.h" 8 #include "src/compiler/access-builder.h"
9 #include "src/compiler/common-operator.h" 9 #include "src/compiler/common-operator.h"
10 #include "src/compiler/js-graph.h" 10 #include "src/compiler/js-graph.h"
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 Handle<ScriptContextTable> script_context_table( 239 Handle<ScriptContextTable> script_context_table(
240 global_object->native_context()->script_context_table(), isolate()); 240 global_object->native_context()->script_context_table(), isolate());
241 ScriptContextTable::LookupResult lookup_result; 241 ScriptContextTable::LookupResult lookup_result;
242 if (!ScriptContextTable::Lookup(script_context_table, 242 if (!ScriptContextTable::Lookup(script_context_table,
243 Handle<String>::cast(name), &lookup_result)) { 243 Handle<String>::cast(name), &lookup_result)) {
244 return false; 244 return false;
245 } 245 }
246 Handle<Context> script_context = ScriptContextTable::GetContext( 246 Handle<Context> script_context = ScriptContextTable::GetContext(
247 script_context_table, lookup_result.context_index); 247 script_context_table, lookup_result.context_index);
248 result->context = script_context; 248 result->context = script_context;
249 result->immutable = IsImmutableVariableMode(lookup_result.mode); 249 result->immutable = lookup_result.mode == CONST;
250 result->index = lookup_result.slot_index; 250 result->index = lookup_result.slot_index;
251 return true; 251 return true;
252 } 252 }
253 253
254 254
255 Graph* JSGlobalObjectSpecialization::graph() const { 255 Graph* JSGlobalObjectSpecialization::graph() const {
256 return jsgraph()->graph(); 256 return jsgraph()->graph();
257 } 257 }
258 258
259 259
(...skipping 12 matching lines...) Expand all
272 } 272 }
273 273
274 274
275 SimplifiedOperatorBuilder* JSGlobalObjectSpecialization::simplified() const { 275 SimplifiedOperatorBuilder* JSGlobalObjectSpecialization::simplified() const {
276 return jsgraph()->simplified(); 276 return jsgraph()->simplified();
277 } 277 }
278 278
279 } // namespace compiler 279 } // namespace compiler
280 } // namespace internal 280 } // namespace internal
281 } // namespace v8 281 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/ast-graph-builder.cc ('k') | src/contexts.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698