forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit396ef15
committed
Fix busy-wait in pgbench, with --rate.
If --rate was used to throttle pgbench, it failed to sleep when it hadnothing to do, leading to a busy-wait with 100% CPU usage. This bug wasintroduced in the refactoring in v10. Before that, sleep() was called witha timeout, even when there were no file descriptors to wait for.Reported by Jeff Janes, patch by Fabien COELHO. Backpatch to v10.Discussion:https://www.postgresql.org/message-id/CAMkU%3D1x5hoX0pLLKPRnXCy0T8uHoDvXdq%2B7kAM9eoC9_z72ucw%40mail.gmail.com1 parent2632bcc commit396ef15
1 file changed
+18
-8
lines changedLines changed: 18 additions & 8 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
4578 | 4578 |
| |
4579 | 4579 |
| |
4580 | 4580 |
| |
4581 |
| - | |
| 4581 | + | |
4582 | 4582 |
| |
4583 |
| - | |
| 4583 | + | |
4584 | 4584 |
| |
4585 | 4585 |
| |
4586 | 4586 |
| |
4587 |
| - | |
| 4587 | + | |
| 4588 | + | |
| 4589 | + | |
4588 | 4590 |
| |
4589 |
| - | |
4590 |
| - | |
4591 |
| - | |
| 4591 | + | |
| 4592 | + | |
| 4593 | + | |
| 4594 | + | |
| 4595 | + | |
| 4596 | + | |
| 4597 | + | |
| 4598 | + | |
4592 | 4599 |
| |
4593 |
| - | |
| 4600 | + | |
| 4601 | + | |
4594 | 4602 |
| |
| 4603 | + | |
| 4604 | + | |
4595 | 4605 |
| |
4596 | 4606 |
| |
4597 | 4607 |
| |
| |||
4604 | 4614 |
| |
4605 | 4615 |
| |
4606 | 4616 |
| |
4607 |
| - | |
| 4617 | + | |
4608 | 4618 |
| |
4609 | 4619 |
| |
4610 | 4620 |
| |
|
0 commit comments
Comments
(0)