Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 252179
Summary: | test_altivec fails with SIGILL | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Bastien Nocera <bnocera> | ||||
Component: | liboil | Assignee: | Behdad Esfahbod <behdad> | ||||
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | low | Docs Contact: | |||||
Priority: | low | ||||||
Version: | 7 | CC: | matthias | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | ppc64 | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | 0.3.12-9.fc7 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2007-08-27 21:49:36 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Bug Depends On: | |||||||
Bug Blocks: | 238953, 179260 | ||||||
Attachments: |
|
Description
Bastien Nocera
2007-08-14 15:09:06 UTC
This problem makes totem not compile on PPC and PPC64 (see upstream bug, the problem occurs on both arches), adding to the blocker bugs. Looks like: https://bugs.freedesktop.org/show_bug.cgi?id=10247 which was fixed by: http://webcvs.freedesktop.org/liboil/liboil/liboil/liboilcpu.c?r1=1.40&r2=1.41 Created attachment 161278 [details]
liboil-0.3.12-altivec-fix.patch
For some reason, I'm not in the ACLs for it, so can't commit.
Let me know when the patch is in so I can update the reqs in
gstreamer-plugins-good and gstreamer-plugins-base and gstreamer-plugins-good
Note that this needs to go in rawhide and probably F7 (although I won't be updating deps for F7, takes too long to go through the rebuilds/updates cycles). Never mind, this patch is already in our version of liboil, so it's something else. Note that you seem to have committed the patch and spec file changes, though :-/ My mistake, I was so sure this would fix it... I reverted the changes already. Here's the second part of the patch that David committed: http://webcvs.freedesktop.org/liboil/liboil/liboil/liboilcpu.c?r1=1.42&r2=1.43&view=patch I believe this would fix it. Matthias, do you want to do the updates, or you want me to do them? We're in for a fun ride, the patch doesn't compile (I tested locally first this time ;): https://bugs.freedesktop.org/show_bug.cgi?id=10247#c10 The fix is simple though, building in rawhide now. And we need to remove the hand-made signal saving code as well: http://webcvs.freedesktop.org/liboil/liboil/liboil/liboilcpu.c?r1=1.43&r2=1.44 Testing now on a pSeries machine. Hopefully will finally fix the problem. You wish it would work by now: https://bugs.freedesktop.org/show_bug.cgi?id=12027 The problem here is nothing to do with the explicit altivec test. The problem here is because you've told the compiler it's allowed to use altivec in normal C code, and recently is grew smart enough to actually do so. Just #if 0 the altivec tests in oil_cpu_detect_powerpc() and see it still die... Program received signal SIGILL, Illegal instruction. oil_prototype_from_string ( s=0x10032c98 "float *dest, int dstr, float *src, int sstr, int n") at liboilprototype.c:189 189 OilParameter param = { 0 }; (gdb) bt #0 oil_prototype_from_string ( s=0x10032c98 "float *dest, int dstr, float *src, int sstr, int n") at liboilprototype.c:189 #1 0x10002f18 in oil_test_new (klass=0x10042d58) at liboiltest.c:73 #2 0x100011a8 in oil_class_optimize (klass=0x10042d58) at liboilfunction.c:350 #3 0x28000488 in ?? () #4 0x100014a0 in oil_optimize_all () at liboilfunction.c:179 #5 0x100015b4 in oil_init () at liboilfunction.c:140 #6 0x10000adc in main () (gdb) x/i $pc 0x1002fe04 <oil_prototype_from_string+4>: vxor v0,v0,v0 Adding -fno-tree-vectorize to CFLAGS might help but since this project unfortunately uses autocrap instead of proper makefiles, I cannot test. I changed ALTIVEC_CFLAGS and LIBOIL_CFLAGS in both the top-level and liboil/Makefile but it still seems not to use what I set. Just -fno-tree-vectorize isn't sufficient. Removing -maltivec seems to work: $ sed -i s/-maltivec/-Wa,-maltivec/ configure Although it might be nice to build it both ways and to link at runtime against the version which is appropriate. Glibc manages this kind of thing... how hard would it be for liboil? After some changes: sed -i 's/CFLAGS="$CFLAGS "-maltivec""/CFLAGS="$CFLAGS "-fno-tree-vectorize -Wa,-maltivec""/' configure sed -i 's/LIBOIL_CFLAGS -maltivec/LIBOIL_CFLAGS -fno-tree-vectorize -Wa,-maltivec/' configure It still crashes: Starting program: /home/hadess/packages/BUILD/liboil-0.3.12/examples/.libs/lt-example1 Program received signal SIGILL, Illegal instruction. test_altivec (ignored=0x0) at liboilcpu.c:651 651 asm volatile ("vor v0, v0, v0\n"); (gdb) continue Continuing. Program received signal SIGSEGV, Segmentation fault. 0x00000080154bab88 in .__libc_malloc () from /lib64/libc.so.6 (gdb) bt #0 0x00000080154bab88 in .__libc_malloc () from /lib64/libc.so.6 #1 0x0000040000038f10 in oil_prototype_from_string (s=0x4000006ce10 "uint8_t *d_4xn, uint8_t* s_3xn, int n") at liboilprototype.c:195 #2 0x000004000003b518 in oil_test_new (klass=0x40000087fe8) at liboiltest.c:73 #3 0x0000040000036fbc in oil_class_optimize (klass=0x40000087fe8) at liboilfunction.c:350 #4 0x0000040000037370 in oil_optimize_all () at liboilfunction.c:181 #5 0x00000400000374f0 in oil_init () at liboilfunction.c:140 #6 0x0000000010000708 in main (argc=24, argv=0x0) at example1.c:41 (gdb) x/i $pc 0x80154bab88 <.__libc_malloc+136>: ld r31,0(r9) I'm at loss. Filed as: http://bugs.freedesktop.org/show_bug.cgi?id=12111 I disabled PPC's altivec tests altogether, and managed to get it running. No altivec optimisations, but no crashes either. Testing in 0.3.12-9 now. "Fixed" in 0.3.12-9. https://bugs.freedesktop.org/show_bug.cgi?id=12111 and https://bugs.freedesktop.org/show_bug.cgi?id=12027 are still there, and there's no Altivec optimisations on PPC though. liboil-0.3.12-9.fc7 has been pushed to the Fedora 7 stable repository. If problems still persist, please make note of it in this bug report. David Woodhouse has a build for this that selectively enables Altivec on PPC platforms that support it: http://koji.fedoraproject.org/koji/taskinfo?taskID=141552 |