title: How to copy from an array to a Vector256 and vice versa based on the array index?
body: <p>Supposedly I have either an <code>int[]</code> array or <code>Vector256&lt;int&gt;</code>s. How can I copy the values from one to another using an array index?</p>
  <p>At the moment I have to iterate over the array indices and copy the values one by one:</p>
  <pre class="lang-cs prettyprint-override"><code>int[] input = ...; // length divisible by Vector256&lt;int&gt;.Count
  int[] output = new int[intput.Length];
  
  for (int i = 0; i &lt; input.Length; i += Vector256&lt;int&gt;.Count)
  {
      Vector256&lt;int&gt; v = Vector256.Create(
                  array[i], array[i + 1], array[i + 2], array[i + 3],
                  array[i + 4], array[i + 5], array[i + 6], array[i + 7]);
  
      Vector256&lt;int&gt; v2 = DoSomeWork(v);
  
      for (int j = 0; j &lt; Vector256&lt;int&gt;.Count; ++j)
      {
          output[i + j] = v2.GetElement(i + j);
      }
  }
  </code></pre>
  <p>In Java SDK 16, there are functions that can do exactly what I need. Is there any similar function in C#?</p>
  <pre class="lang-java prettyprint-override"><code>int[] input = ...;
  int[] output = new int[values.length];
  
  for (int i = 0; i &lt; input.length; i += IntVector.SPECIES_256.length()) {
      IntVector v = IntVector.fromArray(IntVector.SPECIES_256, input, i);
      IntVector v2 = DoSomeWork(v);
      v2.intoArray(output, i);
  }
  </code></pre>