cyb70289 commented on a change in pull request #11896:
URL: https://github.com/apache/arrow/pull/11896#discussion_r765449177
##########
File path: cpp/src/arrow/csv/parser.cc
##########
@@ -184,6 +184,31 @@ class SSE42Filter {
const BulkFilterType filter_;
};
+#elif defined ARROW_HAVE_NEON
+
+// NEON filter: 8 bytes at a time, comparing with all special chars
+
+class NeonFilter {
+ public:
+ using WordType = uint8x8_t;
+
+ explicit NeonFilter(const ParseOptions& options)
+ : delim_(vdup_n_u8(options.delimiter)),
+ quote_(vdup_n_u8(options.quoting ? options.quote_char : '\n')),
+ escape_(vdup_n_u8(options.escaping ? options.escape_char : '\n')) {}
+
+ bool Matches(WordType w) {
+ const uint8x8_t v = vceq_u8(w, vdup_n_u8('\r')) | vceq_u8(w,
vdup_n_u8('\n')) |
+ vceq_u8(w, delim_) | vceq_u8(w, quote_) | vceq_u8(w,
escape_);
Review comment:
See big improvement on Neoverse N1 after templating options.
No obvious difference for M1 (possibly due to good instruction parallelism).
No influence to sse4 and bloom filter.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]