Collin Funk wrote:
> It would be nice to add a test module, but I'm conflicted on whether it
> is too much of a chore. Since there isn't an easy way to check if a
> hwcap is supported at runtime.

A unit test for the hwcap_allowed function would be useful. That's a
string parsing function, that apparently needs to deal with multiple
cases:
  - GLIBC_TUNABLES not set,
  - GLIBC_TUNABLES set to empty,
  - other tunables than glibc.cpu.hwcaps,
  - glibc.cpu.hwcaps being the first one,
  - glibc.cpu.hwcaps being the last one,
  - glibc.cpu.hwcaps present but preceded and followed by other tunables,
  - glibc.cpu.hwcaps specifying multiple features.
It's complicated enough to confuse me during code review...

Bruno




Reply via email to