| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/intermediate_language.h" | 5 #include "vm/intermediate_language.h" |
| 6 | 6 |
| 7 #include "vm/bigint_operations.h" | 7 #include "vm/bigint_operations.h" |
| 8 #include "vm/bit_vector.h" | 8 #include "vm/bit_vector.h" |
| 9 #include "vm/cpu.h" | 9 #include "vm/cpu.h" |
| 10 #include "vm/dart_entry.h" | 10 #include "vm/dart_entry.h" |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 | 155 |
| 156 | 156 |
| 157 Representation LoadFieldInstr::representation() const { | 157 Representation LoadFieldInstr::representation() const { |
| 158 if (IsUnboxedLoad()) { | 158 if (IsUnboxedLoad()) { |
| 159 const intptr_t cid = field()->UnboxedFieldCid(); | 159 const intptr_t cid = field()->UnboxedFieldCid(); |
| 160 switch (cid) { | 160 switch (cid) { |
| 161 case kDoubleCid: | 161 case kDoubleCid: |
| 162 return kUnboxedDouble; | 162 return kUnboxedDouble; |
| 163 case kFloat32x4Cid: | 163 case kFloat32x4Cid: |
| 164 return kUnboxedFloat32x4; | 164 return kUnboxedFloat32x4; |
| 165 case kFloat64x2Cid: |
| 166 return kUnboxedFloat64x2; |
| 165 default: | 167 default: |
| 166 UNREACHABLE(); | 168 UNREACHABLE(); |
| 167 } | 169 } |
| 168 } | 170 } |
| 169 return kTagged; | 171 return kTagged; |
| 170 } | 172 } |
| 171 | 173 |
| 172 | 174 |
| 173 bool StoreInstanceFieldInstr::IsUnboxedStore() const { | 175 bool StoreInstanceFieldInstr::IsUnboxedStore() const { |
| 174 return FLAG_unbox_numeric_fields | 176 return FLAG_unbox_numeric_fields |
| (...skipping 12 matching lines...) Expand all Loading... |
| 187 Representation StoreInstanceFieldInstr::RequiredInputRepresentation( | 189 Representation StoreInstanceFieldInstr::RequiredInputRepresentation( |
| 188 intptr_t index) const { | 190 intptr_t index) const { |
| 189 ASSERT((index == 0) || (index == 1)); | 191 ASSERT((index == 0) || (index == 1)); |
| 190 if ((index == 1) && IsUnboxedStore()) { | 192 if ((index == 1) && IsUnboxedStore()) { |
| 191 const intptr_t cid = field().UnboxedFieldCid(); | 193 const intptr_t cid = field().UnboxedFieldCid(); |
| 192 switch (cid) { | 194 switch (cid) { |
| 193 case kDoubleCid: | 195 case kDoubleCid: |
| 194 return kUnboxedDouble; | 196 return kUnboxedDouble; |
| 195 case kFloat32x4Cid: | 197 case kFloat32x4Cid: |
| 196 return kUnboxedFloat32x4; | 198 return kUnboxedFloat32x4; |
| 199 case kFloat64x2Cid: |
| 200 return kUnboxedFloat64x2; |
| 197 default: | 201 default: |
| 198 UNREACHABLE(); | 202 UNREACHABLE(); |
| 199 } | 203 } |
| 200 } | 204 } |
| 201 return kTagged; | 205 return kTagged; |
| 202 } | 206 } |
| 203 | 207 |
| 204 | 208 |
| 205 bool GuardFieldInstr::AttributesEqual(Instruction* other) const { | 209 bool GuardFieldInstr::AttributesEqual(Instruction* other) const { |
| 206 return field().raw() == other->AsGuardField()->field().raw(); | 210 return field().raw() == other->AsGuardField()->field().raw(); |
| (...skipping 3021 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3228 case Token::kTRUNCDIV: return 0; | 3232 case Token::kTRUNCDIV: return 0; |
| 3229 case Token::kMOD: return 1; | 3233 case Token::kMOD: return 1; |
| 3230 default: UNIMPLEMENTED(); return -1; | 3234 default: UNIMPLEMENTED(); return -1; |
| 3231 } | 3235 } |
| 3232 } | 3236 } |
| 3233 | 3237 |
| 3234 | 3238 |
| 3235 #undef __ | 3239 #undef __ |
| 3236 | 3240 |
| 3237 } // namespace dart | 3241 } // namespace dart |
| OLD | NEW |