Attention is currently required from: falconia, pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/37558?usp=email )
Change subject: codec: add osmo_hr_sid_classify()
......................................................................
Patch Set 2:
(1 comment)
File src/codec/hr_sid_class.c:
https://gerrit.osmocom.org/c/libosmocore/+/37558/comment/3ccf4f4d_bed88a69
PS2, Line 31: static unsigned ones_in_byte(uint8_t byte)
> __builtin_popcount() […]
Without testing, we don't know if this built-in function is actually faster than the look-up table approach I suggested, since it's expecting an `unsigned int` argument. The look-up approach might be faster because we're limited to 8 bits.
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/37558?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I5f4eb65379646125b966cf182775b6e9348900bd
Gerrit-Change-Number: 37558
Gerrit-PatchSet: 2
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: falconia <falcon(a)freecalypso.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 29 Jul 2024 09:12:23 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: laforge, pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645?usp=email )
Change subject: library/GTPv1U_Templates: Mark parameters as templates
......................................................................
Patch Set 2:
(2 comments)
File library/GTPv1U_Templates.ttcn:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645/comment/ae42e5b9_05e6…
PS1, Line 58: template (value)
> It helps in easying the posibility to pass both values and template.
As I said, yes, it helps for complex types like records and unions. But I still don't see why would you want to pass e.g. `teid` in form of a template. Do we even have templates for `teid` or `seq`? I don't think so.
By commenting here I don't want to block your patchset. I just wanted to bring up a general trend that I am seeing in our code base: are we doing this for a specific reason or just because it looks prettier if all parameters of a template are templates too ;)
For now I don't see a clear motivation for doing that.
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645/comment/51e25797_617a…
PS1, Line 61: template (value) GTPU_IEs ies
> It doesn't cause a problem either, and allows for more freedom to the caller/user of the template.
If this was the actual IUT and not tests, I would argue that this freedom comes at the cost of performance. However, this is tests and we don't care much... we can even create functions returning const values, just because we can.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I278f7dbc64704c1ba2b8a75d6f540ac52b067598
Gerrit-Change-Number: 37645
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 29 Jul 2024 09:00:49 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: fixeria, laforge.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645?usp=email )
Change subject: library/GTPv1U_Templates: Mark parameters as templates
......................................................................
Patch Set 2:
(4 comments)
File library/GTPv1U_Templates.ttcn:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645/comment/2b790366_1353…
PS1, Line 58: template (value)
> What do we win by doing so? IMO, template parameters are useful for complex parameters, like records […]
It helps in easying the posibility to pass both values and template.
This way also one doesn't need to be calling valueof() everytime it uses the template.
After lots of cleanup of errors and use cases I find this the best approach:
Keep using tmeplate parameters for parent template parameters, until an explicit value is required.
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645/comment/5f62d481_c52e…
PS1, Line 61: template (value) GTPU_IEs ies
> It's fine making this one a template param, so that you can pass templates like `ts_UEchoReqPDU` dir […]
It doesn't cause a problem either, and allows for more freedom to the caller/user of the template.
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645/comment/8d36a78c_cf7e…
PS1, Line 122: valueof(ts_UEchoReqPDU
> ... so you turned this param into a template, but still doing unnecessary `valueof()`.
I forgot these ones, I'm cleaning them up now.
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645/comment/ae8c9bea_083d…
PS1, Line 145: valueof(ip_addr)
> ... […]
See my first comment.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37645?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I278f7dbc64704c1ba2b8a75d6f540ac52b067598
Gerrit-Change-Number: 37645
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 29 Jul 2024 08:42:07 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: comment