From ba1d18fe299cc6e44be7b5d10be004d7e3f3e6ea Mon Sep 17 00:00:00 2001 From: Michael Woerister Date: Fri, 1 Jun 2018 12:54:15 +0200 Subject: [PATCH] Add comments to analzye_filemap(). --- src/libsyntax_pos/analyze_filemap.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/libsyntax_pos/analyze_filemap.rs b/src/libsyntax_pos/analyze_filemap.rs index 7828c55ce781..99fc3f190090 100644 --- a/src/libsyntax_pos/analyze_filemap.rs +++ b/src/libsyntax_pos/analyze_filemap.rs @@ -102,6 +102,8 @@ cfg_if! { for chunk_index in 0 .. chunk_count { let ptr = src_bytes.as_ptr() as *const __m128i; + // We don't know if the pointer is aligned to 16 bytes, so we + // use `loadu`, which supports unaligned loading. let chunk = _mm_loadu_si128(ptr.offset(chunk_index as isize)); // For character in the chunk, see if its byte value is < 0, which