Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error on 32bit PowerPC #2279

Open
novomesk opened this issue Jul 23, 2024 · 5 comments
Open

Build error on 32bit PowerPC #2279

novomesk opened this issue Jul 23, 2024 · 5 comments

Comments

@novomesk
Copy link

Hello,

I am getting following errors when trying to build on Gentoo Linux:

FAILED: CMakeFiles/hwy_contrib.dir/hwy/contrib/sort/vqsort_128a.cc.o
/usr/bin/powerpc-unknown-linux-gnu-g++ -DHWY_SHARED_DEFINE -DTOOLCHAIN_MISS_ASM_HWCAP_H -Dhwy_contrib_EXPORTS -I/var/tmp/portage/dev-cpp/highway-1.0.7/work/highway-1.0.7  -Og -mcpu=7400 -fPIC -fvisibility=hidden -fvisibility-inlines-hidden -Wno-builtin-macro-redefined -D__DATE__=\"redacted\" -D__TIMESTAMP__=\"redacted\" -D__TIME__=\"redacted\" -fmerge-all-constants -Wall -Wextra -Wconversion -Wsign-conversion -Wvla -Wnon-virtual-dtor -fmath-errno -fno-exceptions -MD -MT CMakeFiles/hwy_contrib.dir/hwy/contrib/sort/vqsort_128a.cc.o -MF CMakeFiles/hwy_contrib.dir/hwy/contrib/sort/vqsort_128a.cc.o.d -o CMakeFiles/hwy_contrib.dir/hwy/contrib/sort/vqsort_128a.cc.o -c /var/tmp/portage/dev-cpp/highway-1.0.7/work/highway-1.0.7/hwy/contrib/sort/vqsort_128a.cc
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s: Assembler messages:
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:237: Error: unrecognized opcode: `lxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:239: Error: unrecognized opcode: `lxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:240: Error: unrecognized opcode: `vcmpequd'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:241: Error: unrecognized opcode: `vcmpgtud'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:244: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:245: Error: unrecognized opcode: `xxpermdi'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:246: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:247: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:248: Error: unrecognized opcode: `stxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:249: Error: unrecognized opcode: `stxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:267: Error: unrecognized opcode: `stxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:273: Error: unrecognized opcode: `lxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:275: Error: unrecognized opcode: `lxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:277: Error: unrecognized opcode: `lxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:278: Error: unrecognized opcode: `lxvd2x'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:279: Error: unrecognized opcode: `vcmpequd'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:280: Error: unrecognized opcode: `vcmpgtud'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:283: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:284: Error: unrecognized opcode: `xxpermdi'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:285: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:286: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:287: Error: unrecognized opcode: `vcmpequd'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:288: Error: unrecognized opcode: `vcmpgtud'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:290: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:291: Error: unrecognized opcode: `xxpermdi'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:292: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:293: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:294: Error: unrecognized opcode: `vcmpequd'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:295: Error: unrecognized opcode: `vcmpgtud'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:297: Error: unrecognized opcode: `xxsel'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:298: Error: unrecognized opcode: `xxpermdi'
/var/tmp/portage/dev-cpp/highway-1.0.7/temp/cceTwyMG.s:299: Error: unrecognized opcode: `xxsel'
cat /proc/cpuinfo
processor       : 0
cpu             : 7400, altivec supported
temperature     : 50-126 C (uncalibrated)
clock           : 900.000000MHz
revision        : 2.9 (pvr 000c 0209)
bogomips        : 50.00

total bogomips  : 50.00
timebase        : 25000000
platform        : PowerMac
model           : PowerMac3,1
machine         : PowerMac3,1
motherboard     : PowerMac3,1 MacRISC MacRISC2 Power Macintosh
detected as     : 65 (PowerMac G4 AGP Graphics)
pmac flags      : 00000004
pmac-generation : NewWorld
Memory          : 2048 MB
@johnplatts
Copy link
Contributor

johnplatts commented Jul 23, 2024

PowerPC-based Macs do not support the HWY_PPC8/HWY_PPC9/HWY_PPC10 targets as the HWY_PPC8 target uses some SIMD instructions added in POWER8 (such as VSX or I64/U64/I128/U128 arithmetic ops) that are not available on any PowerPC-based Mac (including G4/G5 Macs that support the original AltiVec instruction set but not VSX), and the HWY_PPC8/HWY_PPC9/HWY_PPC10 targets should be disabled when compiling for 32-bit PowerPC by compiling with -DHWY_COMPILE_ONLY_EMU128=1 or -DHWY_COMPILE_ONLY_SCALAR=1.

@jan-wassenberg
Copy link
Member

Can we automate this by checking HWY_ARCH_PPC && !HWY_ARCH_PPC_64 and if so, marking all the HWY_PPC as broken?

@johnplatts
Copy link
Contributor

Can we automate this by checking HWY_ARCH_PPC && !HWY_ARCH_PPC_64 and if so, marking all the HWY_PPC as broken?

Yes, we can check this.

@jan-wassenberg
Copy link
Member

Thank you @johnplatts !

@malaterre
Copy link
Contributor

Symptoms have been hidden with commit 10c48a9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants