Commit 41f3c60b authored by Drew Noakes's avatar Drew Noakes

Use aligned SSE register load intrinsic.

The code goes to the trouble of ensuring that data is aligned at a
16-byte boundary, then goes ahead and uses the unaligned form of the
load intrinsic _mm_loadu_si128.

Either the code shouldn't bother aligning the data to the start of the
whitespace, or it should use the aligned form of the intrinsic.
parent 24dd7ef8
......@@ -277,7 +277,7 @@ inline const char *SkipWhitespace_SIMD(const char* p) {
// The rest of string using SIMD
static const char whitespace[16] = " \n\r\t";
const __m128i w = _mm_loadu_si128((const __m128i *)&whitespace[0]);
const __m128i w = _mm_load_si128((const __m128i *)&whitespace[0]);
for (;; p += 16) {
const __m128i s = _mm_load_si128((const __m128i *)p);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment