Open chenrui333 opened 2 years ago
Hi! Vc is now in maintenance mode and no longer actively developed. However, if you can provide us with a pull requests we an try to get it in.
Got it, thanks!
I just encountered the same issue. Turns out brew's compiler wrapper script filters out any -march
flags now, unless the formula opts in to not remove it. See https://github.com/Homebrew/brew/commit/0404da7ba7d22379b236c503d6a87746a848776c.
Adding this to the beginning of the install step could successfully compile Vc 1.4.3 (https://github.com/FairRootGroup/homebrew-fairsoft/commit/718bf9292e9a2b73a20b33765052c93ed93c3bfc):
def install
ENV.runtime_cpu_detection
#...
end
I just encountered the same issue. Turns out brew's compiler wrapper script filters out any
-march
flags now, unless the formula opts in to not remove it. See Homebrew/brew@0404da7.Adding this to the beginning of the install step could successfully compile Vc 1.4.3 (FairRootGroup/homebrew-fairsoft@718bf92):
def install ENV.runtime_cpu_detection #... end
Gonna give ENV.runtime_cpu_detection
a shot
Got some audit failure, but the build is successful
vc:
* No `cpuid` instruction detected. vc should not use `ENV.runtime_cpu_detection`.
Got some audit failure, but the build is successful
vc: * No `cpuid` instruction detected. vc should not use `ENV.runtime_cpu_detection`.
That seems to be a shortcoming of brew's Formula linter currently, which only considers dylibs and executables. However, Vc only emits a libVc.a
file.
I guess, if you teach this code to also include libVc.a
in the set of checked files, the audit will succeed: https://github.com/Homebrew/brew/blob/36d14ae49cc4cd410b0b77e7d4f01e1836fd3be8/Library/Homebrew/formula_cellar_checks.rb#L312-L316
I see š I will look into more this weekend
š trying to build the latest release, but run into some build issue. The error log is as below:
build error
``` In file included from /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../avx/mask.h:37: /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../avx/detail.h:1182:64: error: always_inline function '_mm256_testz_ps' requires target feature 'avx', but would be inlined into function 'testz' that is compiled without support for 'avx' Vc_INTRINSIC Vc_CONST int testz(__m256 a, __m256 b) { return _mm256_testz_ps(a, b); } ^ /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../avx/detail.h:1182:64: error: AVX vector argument of type '__m256' (vector of 8 'float' values) without 'avx' enabled changes the ABI /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../avx/detail.h:651:55: error: always_inline function '_mm256_and_ps' requires target feature 'avx', but would be inlined into function 'and_' that is compiled without support for 'avx' Vc_INTRINSIC __m256 and_(__m256 a, __m256 b) { return _mm256_and_ps(a, b); } ^ /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../avx/detail.h:651:55: error: AVX vector argument of type '__m256' (vector of 8 'float' values) without 'avx' enabled changes the ABI In file included from /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/build/trigonometric_AVX2+FMA+BMI2.cpp:31: In file included from /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/vector.h:35: In file included from /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../sse/vector.h:32: In file included from /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../sse/intrinsics.h:37: In file included from /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../avx/../common/storage.h:35: /tmp/vc-20220529-32959-1ggh4jf/Vc-1.4.3/Vc/scalar/../common/../sse/../avx/intrinsics.h:122:65: error: always_inline function '_mm256_broadcast_ss' requires target feature 'avx', but would be inlined into function 'setabsmask_ps' that is compiled without support for 'avx' static Vc_INTRINSIC m256 Vc_CONST setabsmask_ps() { return _mm256_broadcast_ss(reinterpret_castfull build log, https://github.com/Homebrew/homebrew-core/runs/6645127976 relates to Homebrew/homebrew-core#102079