Commit a3c2123
committed
Stop two tests failing for reasons that are not about this client
Both have been red on main since the Rust 1.98 build change, which
changed no code and is a coincidence of timing rather than a cause.
The first is the appender against INSERT. It wants inserting to take
more than five times what appending takes, which is the number that
says the appender is still batching rather than doing a commit per row.
It read three on a hosted runner and failed, and it fails on some jobs
of a run and not others, which is what a threshold sitting in the
middle of the measurement looks like.
The row count was the problem. What an INSERT costs is what a commit
costs, and that is a property of the disk rather than of the engine:
24 ms a row on a server with a real disk under contention, 80 us a row
on a hosted runner where the commit is plainly not reaching a platter.
Three hundred times apart from the same build. Two hundred rows is
therefore four seconds of INSERT on the first machine and sixteen
milliseconds on the second, and sixteen milliseconds is not enough work
for the appender's one commit to have amortised, so the second machine
was measuring what the appender costs to start rather than what it
costs to run.
So the row count is worked out on the machine instead of written down.
Forty INSERTs say what one costs here, and the count is whatever spends
about a second and a half on the INSERT side, floored at two hundred so
the appender always has rows to amortise over and capped at forty
thousand for memory. Measured on a real disk the ratio is 44 at two
hundred rows, 81 at a thousand and 659 at five thousand, so the gate
stays at five: the number that says the appender is batching, not the
number any machine hits.
The second is the test that counts how far the main thread gets while
another one is inside the engine, which is how the released GIL is
checked. It reads no clock, so it was not marked timing, so the
sanitizer job runs it, and valgrind runs one thread at a time by
design. The count is zero there whatever the binding does, and the test
reports a held GIL that is not held. There is nothing to fix in the
binding for that, so it takes the timing marker like the tests that
read a clock, and the marker's description now covers both.1 parent a8a8330 commit a3c2123
3 files changed
Lines changed: 78 additions & 21 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
92 | | - | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
93 | 102 | | |
94 | 103 | | |
95 | 104 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
425 | 425 | | |
426 | 426 | | |
427 | 427 | | |
428 | | - | |
429 | | - | |
430 | | - | |
431 | | - | |
432 | | - | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
433 | 460 | | |
434 | 461 | | |
435 | 462 | | |
436 | 463 | | |
437 | 464 | | |
438 | 465 | | |
439 | | - | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
440 | 473 | | |
441 | 474 | | |
442 | 475 | | |
443 | | - | |
444 | | - | |
445 | | - | |
446 | | - | |
| 476 | + | |
447 | 477 | | |
448 | 478 | | |
449 | 479 | | |
450 | 480 | | |
451 | 481 | | |
452 | 482 | | |
453 | 483 | | |
454 | | - | |
455 | | - | |
456 | | - | |
457 | | - | |
458 | | - | |
459 | | - | |
460 | | - | |
461 | | - | |
462 | | - | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
463 | 501 | | |
464 | | - | |
| 502 | + | |
| 503 | + | |
465 | 504 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
62 | 63 | | |
63 | 64 | | |
64 | 65 | | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
65 | 74 | | |
66 | 75 | | |
67 | 76 | | |
| |||
0 commit comments