From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 126929 invoked by alias); 9 May 2016 12:53:15 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 126873 invoked by uid 89); 9 May 2016 12:53:15 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.8 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,POKER_BODY,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=no version=3.3.2 spammy=hongjiuluintelcom, hongjiu.lu@intel.com, Append, Hx-languages-length:2366 X-HELO: mail-qg0-f44.google.com Received: from mail-qg0-f44.google.com (HELO mail-qg0-f44.google.com) (209.85.192.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Mon, 09 May 2016 12:52:57 +0000 Received: by mail-qg0-f44.google.com with SMTP id 90so87491128qgz.1 for ; Mon, 09 May 2016 05:52:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to:cc; bh=3tUIIEegXw+v37TUfz/a1rWj65Gp7MkzMfvYkCFjKvc=; b=bTyWnU/CfxUvltkWOsPguEYPBT+EE29DGWJ0uSNmq5uR8hxFvOXxQ0AutD5mmD+Bay Bg6VwAiFPfmNyXExoFkgHflxIy1SqRl4sDSTVdvt+/w2TMapbiWP/aE7fWzB9BrCjwSd YYF+0F2GrNQJW4Kx5gp+JlFx6RtV3EysqAJSti53U/EWcw8e6M/5G0qaML2EFg3AOXoB O+XAf6FUjRgP7/+dDm8U7bllDu3Ok7Q6KJblG7DR7NhvcBUmp8MDTHQoZ5vJsGlEFH85 8v/0soVLnU8lp13OcHp27URyoF2vqUHI10hL3nI+WQ8JXn80wctqIbVMNuuTOlm2P1qK jaXA== X-Gm-Message-State: AOPr4FVYmBMwbsMX4WxDIr0W838j9wDxYQp6sObHnRtIJN9jo3IkPP8IBVcnEwxj1D+nLXTBe2Jo30wp6Z/AIQ== MIME-Version: 1.0 X-Received: by 10.140.152.16 with SMTP id 16mr36198941qhy.77.1462798375169; Mon, 09 May 2016 05:52:55 -0700 (PDT) Received: by 10.55.34.205 with HTTP; Mon, 9 May 2016 05:52:55 -0700 (PDT) Date: Mon, 09 May 2016 12:53:00 -0000 Message-ID: Subject: PING^2: [PATCH] PR target/70454: Build x86 libgomp with -march=i486 or better From: "H.J. Lu" To: GCC Patches Cc: Jakub Jelinek , Uros Bizjak Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes X-SW-Source: 2016-05/txt/msg00616.txt.bz2 On Mon, May 2, 2016 at 6:46 AM, H.J. Lu wrote: > On Mon, Apr 25, 2016 at 1:36 PM, H.J. Lu wrote: >> If x86 libgomp isn't compiled with -march=i486 or better, append >> -march=i486 XCFLAGS for x86 libgomp build. >> >> Tested on i686 with and without --with-arch=i386. Tested on >> x86-64 with and without --with-arch_32=i386. OK for trunk? >> >> >> H.J. >> --- >> PR target/70454 >> * configure.tgt (XCFLAGS): Append -march=i486 to compile x86 >> libgomp if needed. >> --- >> libgomp/configure.tgt | 36 ++++++++++++++++-------------------- >> 1 file changed, 16 insertions(+), 20 deletions(-) >> >> diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt >> index 77e73f0..c876e80 100644 >> --- a/libgomp/configure.tgt >> +++ b/libgomp/configure.tgt >> @@ -67,28 +67,24 @@ if test x$enable_linux_futex = xyes; then >> ;; >> >> # Note that bare i386 is not included here. We need cmpxchg. >> - i[456]86-*-linux*) >> + i[456]86-*-linux* | x86_64-*-linux*) >> config_path="linux/x86 linux posix" >> - case " ${CC} ${CFLAGS} " in >> - *" -m64 "*|*" -mx32 "*) >> - ;; >> - *) >> - if test -z "$with_arch"; then >> - XCFLAGS="${XCFLAGS} -march=i486 -mtune=${target_cpu}" >> + # Need i486 or better. >> + cat > conftestx.c <> +#if defined __x86_64__ || defined __i486__ || defined __pentium__ \ >> + || defined __pentiumpro__ || defined __pentium4__ \ >> + || defined __geode__ || defined __SSE__ >> +# error Need i486 or better >> +#endif >> +EOF >> + if ${CC} ${CFLAGS} -c -o conftestx.o conftestx.c > /dev/null 2>&1; then >> + if test "${target_cpu}" = x86_64; then >> + XCFLAGS="${XCFLAGS} -march=i486 -mtune=generic" >> + else >> + XCFLAGS="${XCFLAGS} -march=i486 -mtune=${target_cpu}" >> fi >> - esac >> - ;; >> - >> - # Similar jiggery-pokery for x86_64 multilibs, except here we >> - # can't rely on the --with-arch configure option, since that >> - # applies to the 64-bit side. >> - x86_64-*-linux*) >> - config_path="linux/x86 linux posix" >> - case " ${CC} ${CFLAGS} " in >> - *" -m32 "*) >> - XCFLAGS="${XCFLAGS} -march=i486 -mtune=generic" >> - ;; >> - esac >> + fi >> + rm -f conftestx.c conftestx.o >> ;; >> >> # Note that sparcv7 and sparcv8 is not included here. We need cas. >> -- >> 2.5.5 >> > > PING. > PING. -- H.J.