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

Side by Side Diff: src/types.cc

Issue 187353005: Use Representation::Integer32() for smi types on 32-bit-tagged systems. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed nit Created 6 years, 9 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.cc ('k') | test/mjsunit/regress/regress-crbug-349079.js » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 550 matching lines...) Expand 10 before | Expand all | Expand 10 after
561 Convert<OtherType>(OtherType::UnionGet(unioned, i), region)); 561 Convert<OtherType>(OtherType::UnionGet(unioned, i), region));
562 } 562 }
563 return Config::from_union(new_unioned); 563 return Config::from_union(new_unioned);
564 } 564 }
565 } 565 }
566 566
567 567
568 // TODO(rossberg): this does not belong here. 568 // TODO(rossberg): this does not belong here.
569 Representation Representation::FromType(Type* type) { 569 Representation Representation::FromType(Type* type) {
570 if (type->Is(Type::None())) return Representation::None(); 570 if (type->Is(Type::None())) return Representation::None();
571 if (type->Is(Type::Smi())) return Representation::Smi(); 571 if (type->Is(Type::Smi())) return SmiValuesAre31Bits()
572 ? Representation::Smi() : Representation::Integer32();
572 if (type->Is(Type::Signed32())) return Representation::Integer32(); 573 if (type->Is(Type::Signed32())) return Representation::Integer32();
573 if (type->Is(Type::Number())) return Representation::Double(); 574 if (type->Is(Type::Number())) return Representation::Double();
574 return Representation::Tagged(); 575 return Representation::Tagged();
575 } 576 }
576 577
577 578
578 #ifdef OBJECT_PRINT 579 #ifdef OBJECT_PRINT
579 template<class Config> 580 template<class Config>
580 void TypeImpl<Config>::TypePrint() { 581 void TypeImpl<Config>::TypePrint() {
581 TypePrint(stdout); 582 TypePrint(stdout);
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
647 648
648 template TypeImpl<ZoneTypeConfig>::TypeHandle 649 template TypeImpl<ZoneTypeConfig>::TypeHandle
649 TypeImpl<ZoneTypeConfig>::Convert<HeapType>( 650 TypeImpl<ZoneTypeConfig>::Convert<HeapType>(
650 TypeImpl<HeapTypeConfig>::TypeHandle, TypeImpl<ZoneTypeConfig>::Region*); 651 TypeImpl<HeapTypeConfig>::TypeHandle, TypeImpl<ZoneTypeConfig>::Region*);
651 template TypeImpl<HeapTypeConfig>::TypeHandle 652 template TypeImpl<HeapTypeConfig>::TypeHandle
652 TypeImpl<HeapTypeConfig>::Convert<Type>( 653 TypeImpl<HeapTypeConfig>::Convert<Type>(
653 TypeImpl<ZoneTypeConfig>::TypeHandle, TypeImpl<HeapTypeConfig>::Region*); 654 TypeImpl<ZoneTypeConfig>::TypeHandle, TypeImpl<HeapTypeConfig>::Region*);
654 655
655 656
656 } } // namespace v8::internal 657 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/hydrogen-instructions.cc ('k') | test/mjsunit/regress/regress-crbug-349079.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698