From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14785 invoked by alias); 9 Jun 2011 15:41:27 -0000 Received: (qmail 14776 invoked by uid 22791); 9 Jun 2011 15:41:26 -0000 X-SWARE-Spam-Status: No, hits=-2.7 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 09 Jun 2011 15:41:10 +0000 From: "rth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/49257] -mfpmath=sse generates x87 instructions on 32 bits OS X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: rth at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: ubizjak at gmail dot com X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Thu, 09 Jun 2011 15:41:00 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2011-06/txt/msg00772.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49257 --- Comment #17 from Richard Henderson 2011-06-09 15:39:33 UTC --- The Problem here is that using the 387 for these conversions is normally a Good Thing. Even when we're not mixing 387 and SSE math, the 387 can do the conversion in 1 insn. Add a couple more for pushing the data between functional units and we've *still* got code that's significantly smaller and faster than any pure SSE alternative. Ignoring SSE and -mfpmath=sse for a moment, we've said that you simply can't use FP math in a region that's using MMX operations because that must needs use the FPU in 387 mode. I'm not sure that this stance should be altered just because -mfpmath=sse is in effect. Is there some Really Good Reason you're using MMX at all? I mean, you've explicitly said via compiler flags that the target cpu is SSE enabled. What can MMX do that SSE2 cannot? We could do something with the code written in this thread in the context of -mno-80387 -msse, but I'm not really sure it's worth it. How often would it really be used, honestly? I'm inclined to mark this bug as either INVALID or WONTFIX.