[PATCH] D41962: Fix TestYMMRegisters for older machines without AVX2

Jason Molenda via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 12 14:00:20 PST 2018


jasonmolenda added a comment.

In https://reviews.llvm.org/D41962#975168, @aprantl wrote:

> > there's a new skipUnlessFeature() method added to decorators.py which runs sysctl to detect hardware features (in this case, hw.optional.avx512f)
>
> How does one execute a program like `sysctl` on the remote? I have seen code in TestLldbGdbServer.py that uses `platform get-file /proc/cpuinfo` to achieve something similar for Linux, but that works without executing a new process.


this skipUnlessFeature sysctl check was all performed on the system running the testsuite.  Checking whether the feature exists in the program (the approach you're taking) is more correct.  We usually do host != target testsuite runs for arm devices, but there's no reason why someone couldn't do a macos x freebsd testsuite run and the sysctl check would be invalid in that case.


https://reviews.llvm.org/D41962





More information about the llvm-commits mailing list