save-buffer commented on code in PR #13669:
URL: https://github.com/apache/arrow/pull/13669#discussion_r956421194


##########
cpp/src/arrow/compute/light_array.h:
##########
@@ -348,11 +349,13 @@ class ARROW_EXPORT ExecBatchBuilder {
   ExecBatch Flush();
 
   int num_rows() const { return values_.empty() ? 0 : values_[0].num_rows(); }
+  bool is_full() const { return num_rows() == num_rows_max(); }
 
   static int num_rows_max() { return 1 << kLogNumRows; }
 
  private:
   static constexpr int kLogNumRows = 15;
+  static constexpr int64_t kAlignment = 512;

Review Comment:
   512 is the number I see posted most often on the internet, but supposedly 
the requirements can vary by file system or something. Anyway, I think in the 
worst case `O_DIRECT` will be a no-op.



##########
cpp/src/arrow/compute/light_array.h:
##########
@@ -348,11 +349,13 @@ class ARROW_EXPORT ExecBatchBuilder {
   ExecBatch Flush();
 
   int num_rows() const { return values_.empty() ? 0 : values_[0].num_rows(); }
+  bool is_full() const { return num_rows() == num_rows_max(); }
 
   static int num_rows_max() { return 1 << kLogNumRows; }
 
  private:
   static constexpr int kLogNumRows = 15;
+  static constexpr int64_t kAlignment = 512;

Review Comment:
   512 is the number I see posted most often on the internet, but supposedly 
the requirements can vary by file system or something. Anyway, I think in the 
worst case `O_DIRECT` will have no effect.



-- 
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]

Reply via email to