Skip to content

Instantly share code, notes, and snippets.

@FrankNiemeyer
Created August 28, 2015 16:54
Show Gist options
  • Select an option

  • Save FrankNiemeyer/7fa84d49bab32c6e85c5 to your computer and use it in GitHub Desktop.

Select an option

Save FrankNiemeyer/7fa84d49bab32c6e85c5 to your computer and use it in GitHub Desktop.
void dot3_aos_scalar(const vector<Vec3f>& vs, vector<float>& dp) {
for (auto j = 0; j < reps; ++j) {
auto i = vector_len;
while (i--) {
dp[i] = vs[i].x * vs[i].x + vs[i].y * vs[i].y + vs[i].z * vs[i].z;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment