public override FieldLayoutAlgorithm GetLayoutAlgorithmForType(DefType type) { if (type.IsObject) { return(_systemObjectFieldLayoutAlgorithm); } else if (type == UniversalCanonType) { throw new NotImplementedException(); } else if (type.IsRuntimeDeterminedType) { throw new NotImplementedException(); } else if (_simdHelper.IsVectorOfT(type)) { return(_vectorFieldLayoutAlgorithm); } else if (VectorIntrinsicFieldLayoutAlgorithm.IsVectorType(type)) { return(_vectorIntrinsicFieldLayoutAlgorithm); } else { Debug.Assert(_r2rFieldLayoutAlgorithm != null); return(_r2rFieldLayoutAlgorithm); } }
public override FieldLayoutAlgorithm GetLayoutAlgorithmForType(DefType type) { if (type.IsObject) { return(_systemObjectFieldLayoutAlgorithm); } else if (type == UniversalCanonType) { throw new NotImplementedException(); } else if (type.IsRuntimeDeterminedType) { throw new NotImplementedException(); } else if (type.IsIntrinsic && (type.Name == "Vector`1") && (type.Namespace == "System.Numerics")) { return(_vectorFieldLayoutAlgorithm); } else if (VectorIntrinsicFieldLayoutAlgorithm.IsVectorType(type)) { return(_vectorIntrinsicFieldLayoutAlgorithm); } else { Debug.Assert(_r2rFieldLayoutAlgorithm != null); return(_r2rFieldLayoutAlgorithm); } }