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

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

Issue 2581683003: Introduce {ConstantElementsPair} struct for type safety. (Closed)
Patch Set: Rebased. Created 4 years 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/full-codegen/x64/full-codegen-x64.cc ('k') | src/interpreter/bytecode-array-builder.h » ('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 #if V8_TARGET_ARCH_X87 5 #if V8_TARGET_ARCH_X87
6 6
7 #include "src/full-codegen/full-codegen.h" 7 #include "src/full-codegen/full-codegen.h"
8 #include "src/ast/compile-time-value.h" 8 #include "src/ast/compile-time-value.h"
9 #include "src/ast/scopes.h" 9 #include "src/ast/scopes.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 1231 matching lines...) Expand 10 before | Expand all | Expand 10 after
1242 context()->PlugTOS(); 1242 context()->PlugTOS();
1243 } else { 1243 } else {
1244 context()->Plug(eax); 1244 context()->Plug(eax);
1245 } 1245 }
1246 } 1246 }
1247 1247
1248 1248
1249 void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) { 1249 void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) {
1250 Comment cmnt(masm_, "[ ArrayLiteral"); 1250 Comment cmnt(masm_, "[ ArrayLiteral");
1251 1251
1252 Handle<FixedArray> constant_elements = expr->constant_elements(); 1252 Handle<ConstantElementsPair> constant_elements = expr->constant_elements();
1253 bool has_constant_fast_elements = 1253 bool has_constant_fast_elements =
1254 IsFastObjectElementsKind(expr->constant_elements_kind()); 1254 IsFastObjectElementsKind(expr->constant_elements_kind());
1255 1255
1256 AllocationSiteMode allocation_site_mode = TRACK_ALLOCATION_SITE; 1256 AllocationSiteMode allocation_site_mode = TRACK_ALLOCATION_SITE;
1257 if (has_constant_fast_elements && !FLAG_allocation_site_pretenuring) { 1257 if (has_constant_fast_elements && !FLAG_allocation_site_pretenuring) {
1258 // If the only customer of allocation sites is transitioning, then 1258 // If the only customer of allocation sites is transitioning, then
1259 // we can turn it off if we don't have anywhere else to transition to. 1259 // we can turn it off if we don't have anywhere else to transition to.
1260 allocation_site_mode = DONT_TRACK_ALLOCATION_SITE; 1260 allocation_site_mode = DONT_TRACK_ALLOCATION_SITE;
1261 } 1261 }
1262 1262
(...skipping 1517 matching lines...) Expand 10 before | Expand all | Expand 10 after
2780 isolate->builtins()->OnStackReplacement()->entry(), 2780 isolate->builtins()->OnStackReplacement()->entry(),
2781 Assembler::target_address_at(call_target_address, unoptimized_code)); 2781 Assembler::target_address_at(call_target_address, unoptimized_code));
2782 return ON_STACK_REPLACEMENT; 2782 return ON_STACK_REPLACEMENT;
2783 } 2783 }
2784 2784
2785 2785
2786 } // namespace internal 2786 } // namespace internal
2787 } // namespace v8 2787 } // namespace v8
2788 2788
2789 #endif // V8_TARGET_ARCH_X87 2789 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « src/full-codegen/x64/full-codegen-x64.cc ('k') | src/interpreter/bytecode-array-builder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698