Bug 34497 - failures on i686-apple-darwin9 in sse4 testcases
Summary: failures on i686-apple-darwin9 in sse4 testcases
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: target (show other bugs)
Version: 4.3.0
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-12-16 17:18 UTC by Jack Howarth
Modified: 2008-11-26 12:41 UTC (History)
3 users (show)

See Also:
Host: i686-apple-darwin9
Target: i686-apple-darwin9
Build: i686-apple-darwin9
Known to work:
Known to fail:
Last reconfirmed:


Attachments
preprocessed source file from sse4_1-insertps-2.c testcase on i686-apple-darwin9 (14.91 KB, text/plain)
2007-12-16 20:23 UTC, Jack Howarth
Details
assembly file from sse4_1-insertps-2.c testcase on i686-apple-darwin9 (738 bytes, text/plain)
2007-12-16 20:24 UTC, Jack Howarth
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jack Howarth 2007-12-16 17:18:38 UTC
On i686-apple-darwin9, we are seeing failures in the following sse4 related test cases...

FAIL: gcc.target/i386/sse4_1-blendvpd.c (test for excess errors)
WARNING: gcc.target/i386/sse4_1-blendvpd.c compilation failed to produce executable
FAIL: gcc.target/i386/sse4_1-blendvps.c (test for excess errors)
WARNING: gcc.target/i386/sse4_1-blendvps.c compilation failed to produce executable
FAIL: gcc.target/i386/sse4_1-insertps-1.c (test for excess errors)
WARNING: gcc.target/i386/sse4_1-insertps-1.c compilation failed to produce executable
FAIL: gcc.target/i386/sse4_1-insertps-2.c (test for excess errors)
WARNING: gcc.target/i386/sse4_1-insertps-2.c compilation failed to produce executable
FAIL: gcc.target/i386/sse4_1-pblendvb.c (test for excess errors)
WARNING: gcc.target/i386/sse4_1-pblendvb.c compilation failed to produce executable
FAIL: gcc.target/i386/sse4_2-popcntl.c (test for excess errors)
WARNING: gcc.target/i386/sse4_2-popcntl.c compilation failed to produce executable
FAIL: gcc.target/i386/sse4_2-popcntq.c (test for excess errors)
WARNING: gcc.target/i386/sse4_2-popcntq.c compilation failed to produce executable

The actual failures in gcc.log look like...

Executing on host: /sw/src/fink.build/gcc43-4.2.999-20071214/darwin_objdir/gcc/xgcc -B/sw/src/fink.build/gcc43-4.2.999-20071214/darwin_obj
dir/gcc/ /sw/src/fink.build/gcc43-4.2.999-20071214/gcc-4.3-20071214/gcc/testsuite/gcc.target/i386/sse4_1-insertps-2.c   -O2 -msse4.1 -fno-
show-column  -lm   -m32 -o ./sse4_1-insertps-2.exe    (timeout = 300)
:161:suffix or operands invalid for `insertps'
:164:suffix or operands invalid for `insertps'
:167:suffix or operands invalid for `insertps'
:168:suffix or operands invalid for `insertps'
compiler exited with status 1
output is:
:161:suffix or operands invalid for `insertps'
:164:suffix or operands invalid for `insertps'
:167:suffix or operands invalid for `insertps'
:168:suffix or operands invalid for `insertps'

FAIL: gcc.target/i386/sse4_1-insertps-2.c (test for excess errors)
Excess errors:
:161:suffix or operands invalid for `insertps'
:164:suffix or operands invalid for `insertps'
:167:suffix or operands invalid for `insertps'
:168:suffix or operands invalid for `insertps'

WARNING: gcc.target/i386/sse4_1-insertps-2.c compilation failed to produce executable
Comment 1 Jack Howarth 2007-12-16 17:19:43 UTC
These same make check failures occur at both -m32 and -m64..
Comment 2 Andrew Pinski 2007-12-16 19:23:15 UTC
This might be a bug in Apple's assembler.
Comment 3 Jack Howarth 2007-12-16 20:23:57 UTC
Created attachment 14782 [details]
preprocessed source file from sse4_1-insertps-2.c testcase on i686-apple-darwin9
Comment 4 Jack Howarth 2007-12-16 20:24:32 UTC
Created attachment 14783 [details]
assembly file from sse4_1-insertps-2.c testcase on i686-apple-darwin9
Comment 5 Jack Howarth 2007-12-16 21:27:22 UTC
Filed as Radar Problem ID: 5650346.
Comment 6 İsmail Dönmez 2008-03-01 21:18:39 UTC
Jack,

Did Apple give any reply on this. Is this their bug? If so we better close the gcc bug as invalid.
Comment 7 Jack Howarth 2008-03-01 21:36:52 UTC
No official response yet although Mike Stump agrees that it is probably a bug in their assembler.
Comment 8 İsmail Dönmez 2008-03-01 21:41:19 UTC
I think its reasonable to close this bug as invalid, do you agree? Meanwhile we can bug Apple Gcc guys to take a stab at this.

Thanks,
ismail

Comment 9 Dominique d'Humieres 2008-09-26 07:34:05 UTC
With Xcode 3.1.1 all the failures disappeared but gcc.target/i386/sse4_2-popcntl.c:

FAIL: gcc.target/i386/sse4_2-popcntl.c (test for excess errors)
WARNING: gcc.target/i386/sse4_2-popcntl.c compilation failed to produce executable

The error is:

[ibook-dhum] f90/bug% gcc44 -m64 -O2 -msse4.2 /opt/gcc/_gcc_clean/gcc/testsuite/gcc.target/i386/sse4_2-popcntl.c
/var/folders/iU/iUj3xngxGYe3MPCc0TZUcE+++TI/-Tmp-//ccsFk4uR.s:31:suffix or operands invalid for `popcnt'

and the offending line in assembly code is:

        popcntl %edx, %eax
Comment 10 Dominique d'Humieres 2008-09-26 08:00:53 UTC
Comment #9 was for -m32, with -m64 the failures are

FAIL: gcc.target/i386/sse4_2-popcntl.c (test for excess errors)
WARNING: gcc.target/i386/sse4_2-popcntl.c compilation failed to produce executable
FAIL: gcc.target/i386/sse4_2-popcntq.c (test for excess errors)
WARNING: gcc.target/i386/sse4_2-popcntq.c compilation failed to produce executable
Comment 11 Jack Howarth 2008-09-26 14:00:10 UTC
Dominique,
    The remaining failure in the sse4_2-popcntl.c testcase has been reported for awhile on radar (ID 5650346). Like the previous errors these are most likely assembler bugs.
Comment 12 Dominique d'Humieres 2008-09-26 14:19:04 UTC
>     The remaining failure in the sse4_2-popcntl.c testcase has been reported
> for awhile on radar (ID 5650346). Like the previous errors these are most
> likely assembler bugs.

Jack,

Did you get any feedback from Apple saying that the other previous errors have been fixed? (I think they were not in Xcode 3.1.0).
Comment 13 Jack Howarth 2008-09-26 14:38:33 UTC
No, I never got a message that any of the originally reported sse4 gcc test cases
were fixed. I simply noticed it during testing. The radar report is still open though. Feel free to open a duplicate to try to ping the Apple cctools developers on this issue.
Comment 14 Jack Howarth 2008-11-26 12:41:48 UTC
Fully resolved with...

------------------------------------------------------------------------
r142121 | uros | 2008-11-22 09:16:57 -0500 (Sat, 22 Nov 2008) | 18 lines


        PR target/38222
        * config/i386/i386.md (SWI248): New mode iterator.
        (SWI32): Remove mode iterator.
        (popcount<mode>2): Rename from popcounthi2, popcountsi2 and
        popcounthi2 insn patterns. Macroize pattern using SWI248 mode
        iterator.  Generate popcnt mnemonic without mode extensions
        for Darwin x86 targets.
        (*popcount<mode>2_cmp): Ditto.
        (*popcountsi2_cmp_zext): Generate popcnt mnemonic without mode
        extensions for Darwin x86 targets.

testsuite/ChangeLog:

        PR target/38222
        * gcc.target/i386/funcspec-3.c: Scan for popcnt on Darwin targets.