This is an automated email from the ASF dual-hosted git repository.

alamb pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow-rs.git


The following commit(s) were added to refs/heads/main by this push:
     new 2a1d40d35c Reduce Miri runtime even more (#9650)
2a1d40d35c is described below

commit 2a1d40d35c3dd5cc274dd97baa413a5384006fb2
Author: Adam Gutglick <[email protected]>
AuthorDate: Wed Jun 3 21:17:25 2026 +0100

    Reduce Miri runtime even more (#9650)
    
    # Rationale for this change
    
    Follow up to #9629, as noted there miri runtime is dominated by the
    following 3 tests:
    1. `test_from_bitwise_binary_op`
    2. `sort::tests::fuzz_partition_validity`
    3. `sort::tests::test_fuzz_random_strings`
    
    # What changes are included in this PR?
    
    Under Miri, this PR reduces the amount of variations tested in 1, and
    ignores the latter two.
    
    # Are these changes tested?
    
    They are tests!
    
    # Are there any user-facing changes?
    
    No
    
    ---------
    
    Co-authored-by: Jeffrey Vo <[email protected]>
---
 arrow-buffer/src/buffer/boolean.rs | 7 ++++++-
 arrow-ord/src/sort.rs              | 2 ++
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/arrow-buffer/src/buffer/boolean.rs 
b/arrow-buffer/src/buffer/boolean.rs
index 52df67080a..52f1e3fbb5 100644
--- a/arrow-buffer/src/buffer/boolean.rs
+++ b/arrow-buffer/src/buffer/boolean.rs
@@ -1073,7 +1073,12 @@ mod tests {
         let input_buffer_left = BooleanBuffer::from(&input_bools_left[..]);
         let input_buffer_right = BooleanBuffer::from(&input_bools_right[..]);
 
-        for left_offset in 0..200 {
+        #[cfg(miri)] // Takes too long otherwise
+        let left_offsets = [0, 1, 7, 8, 63, 64, 65];
+        #[cfg(not(miri))]
+        let left_offsets = 0..200;
+
+        for left_offset in left_offsets {
             for right_offset in [0, 4, 5, 17, 33, 24, 45, 64, 65, 100, 200] {
                 for len_offset in [0, 1, 44, 100, 256, 300, 512] {
                     let len = 1024 - len_offset - 
left_offset.max(right_offset); // ensure we don't go out of bounds
diff --git a/arrow-ord/src/sort.rs b/arrow-ord/src/sort.rs
index 773d9cf12e..114ca05bb7 100644
--- a/arrow-ord/src/sort.rs
+++ b/arrow-ord/src/sort.rs
@@ -4892,6 +4892,7 @@ mod tests {
     }
 
     #[test]
+    #[cfg_attr(miri, ignore)] // Takes too long
     fn fuzz_partition_validity() {
         let mut rng = StdRng::seed_from_u64(0xF00D_CAFE);
         for _ in 0..1_000 {
@@ -5100,6 +5101,7 @@ mod tests {
 
     // Fuzz testing: generate random UTF-8 strings and verify sort correctness
     #[test]
+    #[cfg_attr(miri, ignore)] // Takes too long
     fn test_fuzz_random_strings() {
         let mut rng = StdRng::seed_from_u64(42); // Fixed seed for 
reproducibility
 

Reply via email to