Attention is currently required from: kirr.
lynxis lazus has posted comments on this change by kirr. ( https://gerrit.osmocom.org/c/osmocom-bb/+/39534?usp=email )
Change subject: trx_toolkit/transceiver: Do not scan tx_queue twice on tx path ......................................................................
Patch Set 1:
(1 comment)
File src/target/trx_toolkit/transceiver.py:
https://gerrit.osmocom.org/c/osmocom-bb/+/39534/comment/6d0f7bff_e45f0b22?us... : PS1, Line 315: self._tx_queue_lock.acquire() It should be faster if you would do this as 3x list comprehensive:
drop = [msg for msg in self._tx_queue if msg.fn < fn] emit = [msg for msg in self._tx_queue if msg.fn == fn] wait = [msg for msg in self._tx_queue if msg.fn > fn]
I did a short benchmark:
1024: lcomp 4.5777000000000006e-05 1024: forloop 0.00022187000000000002 100: lcomp 6.552e-06 100: forloop 2.3484e-05 10: lcomp 2.6650000000000003e-06 10: forloop 6.582000000000001e-06 1: lcomp 1.6030000000000002e-06 1: forloop 2.3440000000000003e-06
https://gist.github.com/lynxis/b75bb8426ec9ae7a487527b5258e4358