From patchwork Sun Sep 9 19:47:32 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Wakely X-Patchwork-Id: 182648 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id D22B32C0089 for ; Mon, 10 Sep 2012 05:47:54 +1000 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1347824875; h=Comment: DomainKey-Signature:Received:Received:Received:Received: MIME-Version:Received:Received:In-Reply-To:References:Date: Message-ID:Subject:From:To:Cc:Content-Type:Mailing-List: Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:Sender:Delivered-To; bh=qXx7CpkkyoWnNYgE6qiatgGmxGU=; b=Kd04I/CfACcEXq9mL86Bj+zyz9z8wzyoyS6YKr9j6BgxtrkvtbkaPiAu+wzyLY uMSEDy8OmBRWiQU/6Kw8YZSd9ZdHgWfugvPiFZG4y0M9MYX0UgetpnAjegeMEtLU /uinZUDL1bcaUAOS4GKXcelJbWX2sQuTQwzEVid74QYJM= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:MIME-Version:Received:Received:In-Reply-To:References:Date:Message-ID:Subject:From:To:Cc:Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=WXaQ9OEMatQVNuXp2d4IafeFL04sCQCllPc69BOnUtkRXbMitYgOlinOPzQvpP Dl+8G0o+oMD0tpGMgG9cAn6P4Yg97fh0AN9xO3WOog0FMYSEyRoh5KrnqWsyviHp 2FfePwQPzBiksHejS32rzJ/6wfppkT1FX6HZyEsszIffg=; Received: (qmail 13289 invoked by alias); 9 Sep 2012 19:47:49 -0000 Received: (qmail 13264 invoked by uid 22791); 9 Sep 2012 19:47:47 -0000 X-SWARE-Spam-Status: No, hits=-5.2 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, KHOP_RCVD_TRUST, KHOP_THREADED, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_YE X-Spam-Check-By: sourceware.org Received: from mail-ie0-f175.google.com (HELO mail-ie0-f175.google.com) (209.85.223.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 09 Sep 2012 19:47:33 +0000 Received: by iebc11 with SMTP id c11so2062789ieb.20 for ; Sun, 09 Sep 2012 12:47:32 -0700 (PDT) MIME-Version: 1.0 Received: by 10.50.193.202 with SMTP id hq10mr7405281igc.35.1347220052396; Sun, 09 Sep 2012 12:47:32 -0700 (PDT) Received: by 10.42.49.81 with HTTP; Sun, 9 Sep 2012 12:47:32 -0700 (PDT) In-Reply-To: References: Date: Sun, 9 Sep 2012 20:47:32 +0100 Message-ID: Subject: Re: [v3] fix bootstrap/54419 From: Jonathan Wakely To: Gerald Pfeifer Cc: "libstdc++" , gcc-patches , Ulrich Drepper , "Dominique d'Humieres" , Jack Howarth Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org On 9 September 2012 20:43, Gerald Pfeifer wrote: > On Sun, 9 Sep 2012, Jonathan Wakely wrote: >> I've committed the patch from >> http://gcc.gnu.org/ml/gcc-patches/2012-09/msg00466.html (with some >> fixes to the changelog entry) >> >> 2012-09-09 Ulrich Drepper >> Dominique d'Humieres >> Jack Howarth >> >> PR bootstrap/54419 >> * acinclude.m4: Define GLIBCXX_CHECK_X86_RDRAND. >> * configure.ac: Use GLIBCXX_CHECK_X86_RDRAND to test for rdrand >> support in assembler. >> * src/c++11/random.cc (__x86_rdrand): Depend on _GLIBCXX_X86_RDRAND. >> (random_device::_M_init): Likewise. >> (random_device::_M_getval): Likewise. >> * configure: Regenerated. >> * config.h.in: Regenerated. > > amd64-unknown-freebsd8.3 doesn't like this, I'm afraid: > > configure: visibility supported: yes > checking for rdrand support in assembler... eval: ${+...}: Bad substitution > gmake[2]: *** [configure-stage1-target-libstdc++-v3] Error 2 > > Note, this is BSD sh, not bash. I'll admit that I had a look, and > did not find the culprit right away. Yes, I don't know why it didn't show up in testing, but that patch was not correct, it failed on netbsd too. Fixed by this patch. Tested x86_64-linux and x86_64-netbsd, committed to trunk. Also, Jack, why is the variable called ac_cv_x86_rdrand rather than glibcxx_x86_rdrand to be consistent with every other variable in libstdc++-v3/acinclude.m4? And why _GLIBCXX_X86_RDRAND not something like _GLIBCXX_HAVE_AS_X86_RDRAND? The bootstrap failure is fixed, but I think we should change those names. commit 1594fd2acc7453aeed22cec16dff41e0dc490eee Author: Jonathan Wakely Date: Sun Sep 9 20:00:16 2012 +0100 PR bootstrap/54419 * acinclude.m4 (GLIBCXX_CHECK_X86_RDRAND): Remove stray character. * configure: Regenerated. diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4 index 267302d..c9b8d37 100644 --- a/libstdc++-v3/acinclude.m4 +++ b/libstdc++-v3/acinclude.m4 @@ -3363,7 +3363,7 @@ dnl dnl Check whether rdrand is supported in the assembler. AC_DEFUN([GLIBCXX_CHECK_X86_RDRAND], [ AC_MSG_CHECKING([for rdrand support in assembler]) - AC_CACHE_VAL($ac_cv_x86_rdrand, [ + AC_CACHE_VAL(ac_cv_x86_rdrand, [ ac_cv_x86_rdrand=no case "$target" in i?86-*-* | \