Is this a bug in the VS 2017 watch, or am I doing something daft? It doesn't show half the contents of a Vector. (On my system, Vector.Count is 8).
[Test]
public void inspectVector()
{
var numbers = new float[] { 1, 2, 3, 4, 5, 6, 7, 8 };
var inputVector = new Vector<float>(numbers);
var five = inputVector[4]; //this is fine - 5
float[] numbersCopiedBack = new float[8];
inputVector.CopyTo(numbersCopiedBack); //this is fine - 1, 2, 3, 4, 5, 6, 7, 8
}
This seems odd. Why does the watch for inputVector not show half of the numbers, even though it seems to behave correctly otherwise? The problem is also there in the Watch window - however, ToString() correctly shows <1, 2, 3, 4, 5, 6, 7, 8>
I'm running Microsoft Visual Studio Professional 2017,
Version 15.4.2 15.7.5, and using v 4.5.0 of System.Numerics.Vectors. I've tried in debug and release; I'm running with optimisations off (AFAIK you don't actually get the SIMD optimisations in that case; but here, I just want to debug an algorithm).
Vector<float>
the vector defined inSystem.Numerics
? – Theodosia