Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 4867 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 4878 | 4878 |
| 4879 HAllocate(HValue* context, HValue* size, HType type, Flags flags) | 4879 HAllocate(HValue* context, HValue* size, HType type, Flags flags) |
| 4880 : type_(type), | 4880 : type_(type), |
| 4881 flags_(flags) { | 4881 flags_(flags) { |
| 4882 SetOperandAt(0, context); | 4882 SetOperandAt(0, context); |
| 4883 SetOperandAt(1, size); | 4883 SetOperandAt(1, size); |
| 4884 set_representation(Representation::Tagged()); | 4884 set_representation(Representation::Tagged()); |
| 4885 SetGVNFlag(kChangesNewSpacePromotion); | 4885 SetGVNFlag(kChangesNewSpacePromotion); |
| 4886 } | 4886 } |
| 4887 | 4887 |
| 4888 static Flags DefaultFlags() { | |
| 4889 return CAN_ALLOCATE_IN_NEW_SPACE; | |
| 4890 } | |
|
Hannes Payer (out of office)
2013/04/18 11:14:39
add newline
mvstanton
2013/04/18 13:39:26
Done.
| |
| 4891 static Flags DefaultFlags(ElementsKind kind) { | |
| 4892 Flags flags = CAN_ALLOCATE_IN_NEW_SPACE; | |
| 4893 if (IsFastDoubleElementsKind(kind)) { | |
| 4894 flags = static_cast<HAllocate::Flags>( | |
| 4895 flags | HAllocate::ALLOCATE_DOUBLE_ALIGNED); | |
| 4896 } | |
| 4897 return flags; | |
| 4898 } | |
| 4899 | |
| 4888 HValue* context() { return OperandAt(0); } | 4900 HValue* context() { return OperandAt(0); } |
| 4889 HValue* size() { return OperandAt(1); } | 4901 HValue* size() { return OperandAt(1); } |
| 4890 | 4902 |
| 4891 virtual Representation RequiredInputRepresentation(int index) { | 4903 virtual Representation RequiredInputRepresentation(int index) { |
| 4892 if (index == 0) { | 4904 if (index == 0) { |
| 4893 return Representation::Tagged(); | 4905 return Representation::Tagged(); |
| 4894 } else { | 4906 } else { |
| 4895 return Representation::Integer32(); | 4907 return Representation::Integer32(); |
| 4896 } | 4908 } |
| 4897 } | 4909 } |
| (...skipping 1533 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 6431 virtual bool IsDeletable() const { return true; } | 6443 virtual bool IsDeletable() const { return true; } |
| 6432 }; | 6444 }; |
| 6433 | 6445 |
| 6434 | 6446 |
| 6435 #undef DECLARE_INSTRUCTION | 6447 #undef DECLARE_INSTRUCTION |
| 6436 #undef DECLARE_CONCRETE_INSTRUCTION | 6448 #undef DECLARE_CONCRETE_INSTRUCTION |
| 6437 | 6449 |
| 6438 } } // namespace v8::internal | 6450 } } // namespace v8::internal |
| 6439 | 6451 |
| 6440 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 6452 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
| OLD | NEW |