Skip to content

Instantly share code, notes, and snippets.

@FrankNiemeyer
Created August 28, 2015 16:34
Show Gist options
  • Save FrankNiemeyer/7dad43ee87445ae6cf46 to your computer and use it in GitHub Desktop.
Save FrankNiemeyer/7dad43ee87445ae6cf46 to your computer and use it in GitHub Desktop.
static void Dot3SoaScalar(float[] xs, float[] ys, float[] zs, float[] dp) {
for (var j = 0; j < reps; ++j) {
for (var i = 0; i < dp.Length; ++i) {
dp[i] = xs[i] * xs[i] + ys[i] * ys[i] + zs[i] * zs[i];
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment