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

Side by Side Diff: src/hydrogen-instructions.cc

Issue 14850006: Use mutable heapnumbers to store doubles in fields. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Ported to ARM and x64 Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/ia32/full-codegen-ia32.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 // 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 2503 matching lines...) Expand 10 before | Expand all | Expand 10 after
2514 need_generic_(false) { 2514 need_generic_(false) {
2515 SetOperandAt(0, context); 2515 SetOperandAt(0, context);
2516 SetOperandAt(1, object); 2516 SetOperandAt(1, object);
2517 set_representation(Representation::Tagged()); 2517 set_representation(Representation::Tagged());
2518 SetGVNFlag(kDependsOnMaps); 2518 SetGVNFlag(kDependsOnMaps);
2519 SmallMapList negative_lookups; 2519 SmallMapList negative_lookups;
2520 for (int i = 0; 2520 for (int i = 0;
2521 i < types->length() && types_.length() < kMaxLoadPolymorphism; 2521 i < types->length() && types_.length() < kMaxLoadPolymorphism;
2522 ++i) { 2522 ++i) {
2523 Handle<Map> map = types->at(i); 2523 Handle<Map> map = types->at(i);
2524 // Deprecated maps are updated to the current map in the type oracle.
2525 ASSERT(!map->is_deprecated());
2524 LookupResult lookup(map->GetIsolate()); 2526 LookupResult lookup(map->GetIsolate());
2525 map->LookupDescriptor(NULL, *name, &lookup); 2527 map->LookupDescriptor(NULL, *name, &lookup);
2526 if (lookup.IsFound()) { 2528 if (lookup.IsFound()) {
2527 switch (lookup.type()) { 2529 switch (lookup.type()) {
2528 case FIELD: { 2530 case FIELD: {
2529 int index = lookup.GetLocalFieldIndexFromMap(*map); 2531 int index = lookup.GetLocalFieldIndexFromMap(*map);
2530 if (index < 0) { 2532 if (index < 0) {
2531 SetGVNFlag(kDependsOnInobjectFields); 2533 SetGVNFlag(kDependsOnInobjectFields);
2532 } else { 2534 } else {
2533 SetGVNFlag(kDependsOnBackingStoreFields); 2535 SetGVNFlag(kDependsOnBackingStoreFields);
2534 } 2536 }
2537 if (FLAG_track_double_fields &&
2538 lookup.representation().IsDouble()) {
2539 // Since the value needs to be boxed, use a generic handler for
2540 // loading doubles.
2541 continue;
2542 }
2535 types_.Add(types->at(i), zone); 2543 types_.Add(types->at(i), zone);
2536 break; 2544 break;
2537 } 2545 }
2538 case CONSTANT_FUNCTION: 2546 case CONSTANT_FUNCTION:
2539 types_.Add(types->at(i), zone); 2547 types_.Add(types->at(i), zone);
2540 break; 2548 break;
2541 case CALLBACKS: 2549 case CALLBACKS:
2542 break; 2550 break;
2543 case TRANSITION: 2551 case TRANSITION:
2544 case INTERCEPTOR: 2552 case INTERCEPTOR:
(...skipping 1077 matching lines...) Expand 10 before | Expand all | Expand 10 after
3622 3630
3623 3631
3624 void HCheckFunction::Verify() { 3632 void HCheckFunction::Verify() {
3625 HInstruction::Verify(); 3633 HInstruction::Verify();
3626 ASSERT(HasNoUses()); 3634 ASSERT(HasNoUses());
3627 } 3635 }
3628 3636
3629 #endif 3637 #endif
3630 3638
3631 } } // namespace v8::internal 3639 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/ia32/full-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698