Skip to content

Conversation

@whitequark
Copy link
Member

This is a rollup PR of several pending improvements that I have:

  • a fix for an annoying asignal bug which would sometimes show a backtrace on ^C
  • an improvement to the registers module that improves compatibility with components and reduces boilerplate, extracted from [Addon in validation] Add Ram-Pak support #483
  • throughput improvements for the Linux TAP interface driver
  • a new pipelined accumulator module that can be used for things such as packet counters, without affecting your timing no matter how fast you're going, as long as you don't need the results right away

This happens often when hitting ^C, but did not happen when I committed
this code originally. Possibly the cause is the use of a newer Python
version.
This significantly improves throughput, in particular with `recv`.
By default (without a send buffer configured), the `write` call never
blocks, and there scarcely be a reason for it to block on a modern
system that can process many more packets with much more data than we
can put into it. However, by using the loop to detect readiness, this
function would incur latency in the calling asyncio task each time it
was used, even if the write would succeed, which impacted throughput.
@whitequark whitequark added this pull request to the merge queue Apr 20, 2024
@whitequark whitequark removed this pull request from the merge queue due to a manual request Apr 20, 2024
Wide counters (24-bit and wider) are problematic on the fairly slow
iCE40 architecture, and this module allows using counters of any width
by pipelining them.

Co-authored-by: Wanda <wanda@phinode.net>
@whitequark whitequark enabled auto-merge April 20, 2024 03:15
@whitequark whitequark added this pull request to the merge queue Apr 20, 2024
Merged via the queue into GlasgowEmbedded:main with commit ff7f6f2 Apr 20, 2024
@whitequark whitequark deleted the fixes branch April 20, 2024 03:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant