Parsed test spec with 3 sessions starting permutation: s1_open s2_vacuum s2_insert s1_drain s1_check s3_whole injection_points_set_local -------------------------- (1 row) step s1_open: BEGIN ISOLATION LEVEL REPEATABLE READ; DECLARE c CURSOR FOR SELECT id FROM lvv ORDER BY v <-> lvv_vec(-3, 0.2); SELECT lvv_take('c', 5); lvv_take -------- 5 (1 row) step s2_vacuum: VACUUM lvv; step s2_insert: INSERT INTO lvv SELECT 5000 + i, lvv_vec(-3, 0.2) + lvv_vec(7000 + i, 0.05) FROM generate_series(1, 2500) i; step s1_drain: SELECT lvv_take('c', NULL); lvv_take -------- 495 (1 row) step s1_check: SET LOCAL enable_seqscan = on; SET LOCAL enable_sort = on; SET LOCAL enable_indexscan = off; SELECT count(*) AS rows, count(DISTINCT g.id) AS distinct_rows, count(*) = count(*) FILTER (WHERE g.id = s.id) AS sort_order FROM lvv_got g JOIN (SELECT row_number() OVER (ORDER BY v <-> lvv_vec(-3, 0.2), id) AS n, id FROM lvv) s USING (n); COMMIT; rows|distinct_rows|sort_order ----+-------------+---------- 500| 500|t (1 row) step s3_whole: SELECT count(*) AS rows, count(DISTINCT id) AS distinct_rows, count(*) FILTER (WHERE id > 5000) AS new_rows FROM (SELECT id FROM lvv ORDER BY v <-> lvv_vec(5, 0.7)) s; rows|distinct_rows|new_rows ----+-------------+-------- 3000| 3000| 2500 (1 row) starting permutation: s1_park s1_scan s2_vacuum s2_insert s3_wake s1_check s3_whole injection_points_set_local -------------------------- (1 row) step s1_park: SELECT injection_points_attach('lionvec-probe-page', 'wait'); injection_points_attach ----------------------- (1 row) step s1_scan: BEGIN ISOLATION LEVEL REPEATABLE READ; INSERT INTO lvv_got (id) SELECT id FROM (SELECT id FROM lvv ORDER BY v <-> lvv_vec(-3, 0.2) LIMIT 400) s; step s2_vacuum: VACUUM lvv; step s2_insert: INSERT INTO lvv SELECT 5000 + i, lvv_vec(-3, 0.2) + lvv_vec(7000 + i, 0.05) FROM generate_series(1, 2500) i; step s3_wake: SELECT injection_points_detach('lionvec-probe-page'); SELECT injection_points_wakeup('lionvec-probe-page'); injection_points_detach ----------------------- (1 row) injection_points_wakeup ----------------------- (1 row) step s1_scan: <... completed> step s1_check: SET LOCAL enable_seqscan = on; SET LOCAL enable_sort = on; SET LOCAL enable_indexscan = off; SELECT count(*) AS rows, count(DISTINCT g.id) AS distinct_rows, count(*) = count(*) FILTER (WHERE g.id = s.id) AS sort_order FROM lvv_got g JOIN (SELECT row_number() OVER (ORDER BY v <-> lvv_vec(-3, 0.2), id) AS n, id FROM lvv) s USING (n); COMMIT; rows|distinct_rows|sort_order ----+-------------+---------- 400| 400|t (1 row) step s3_whole: SELECT count(*) AS rows, count(DISTINCT id) AS distinct_rows, count(*) FILTER (WHERE id > 5000) AS new_rows FROM (SELECT id FROM lvv ORDER BY v <-> lvv_vec(5, 0.7)) s; rows|distinct_rows|new_rows ----+-------------+-------- 3000| 3000| 2500 (1 row)