[Bug 276282] vectorized code fails on powerpc64le: typedef __vector uint8_t __m128i; in the port misc/randomx
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 12 Jan 2024 21:08:01 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=276282 Mark Millard <marklmi26-fbsd@yahoo.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |marklmi26-fbsd@yahoo.com --- Comment #1 from Mark Millard <marklmi26-fbsd@yahoo.com> --- Hmm. https://en.wikipedia.org/wiki/AltiVec reports: QUOTE In C++, the standard way of accessing AltiVec support is mutually exclusive with the use of the Standard Template Library vector<> class template due to the treatment of "vector" as a reserved word when the compiler does not implement the context-sensitive keyword version of vector. However, it may be possible to combine them using compiler-specific workarounds; for instance, in GCC one may do #undef vector to remove the vector keyword, and then use the GCC-specific __vector keyword in its place. END QUOTE The next message after what you report gives a clue: /wrkdirs/usr/ports/misc/randomx/work/RandomX-1.2.1/src/intrin_portable.h:189:25: error: expected ';' after top level declarator typedef __vector uint8_t __m128i; ^ ; In other words: __vector is not getting special handling but is being treated as a fuyll type name of itself, leading to the compiler expecting (not the codes intent): typedef __vector uint8_t; I do not know if clang has a mode supporting the __vector like GCC for powerpc64* variations or not. Seems like GCC would tolerate the non-C/C++-standard code. It might be interesting to check if GCC will build the code. -- You are receiving this mail because: You are the assignee for the bug.