From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1345 invoked by alias); 20 Jul 2011 19:28:58 -0000 Received: (qmail 1327 invoked by uid 22791); 20 Jul 2011 19:28:57 -0000 X-SWARE-Spam-Status: No, hits=-2.2 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,TW_CP X-Spam-Check-By: sourceware.org Received: from mail-vx0-f175.google.com (HELO mail-vx0-f175.google.com) (209.85.220.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 20 Jul 2011 19:28:43 +0000 Received: by vxh2 with SMTP id 2so477783vxh.20 for ; Wed, 20 Jul 2011 12:28:42 -0700 (PDT) MIME-Version: 1.0 Received: by 10.52.25.199 with SMTP id e7mr9294648vdg.363.1311190122289; Wed, 20 Jul 2011 12:28:42 -0700 (PDT) Received: by 10.52.106.193 with HTTP; Wed, 20 Jul 2011 12:28:42 -0700 (PDT) In-Reply-To: References: <4E26E775.7070802@moene.org> Date: Wed, 20 Jul 2011 20:05:00 -0000 Message-ID: Subject: Re: PATCH RFA: Build stages 2 and 3 with C++ From: David Edelsohn To: Ian Lance Taylor Cc: gcc-patches@gcc.gnu.org, gcc@gcc.gnu.org Content-Type: text/plain; charset=ISO-8859-1 X-IsSubscribed: yes Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2011-07/txt/msg00392.txt.bz2 I now can get through the build of the compiler, but stage2 and stage3 libstdc++ and libsupc++ files have many comparison failures due to tree.c:get_file_function_name() introducing explicit randomness to produce different symbols for anonymous namespaces: /* Otherwise, the name must be unique across the entire link. We don't have anything that we know to be unique to this translation unit, so use what we do have and throw in some randomness. */ unsigned len; const char *name = weak_global_object_name; const char *file = main_input_filename; if (! name) name = ""; if (! file) file = input_filename; len = strlen (file); q = (char *) alloca (9 * 2 + len + 1); memcpy (q, file, len + 1); sprintf (q + len, "_%08X_%08X", crc32_string (0, name), crc32_string (0, get_random_seed (false))); producing differences like: - .lglobl H.92.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_8F8DBED417uncatch_exceptionC2Ev - .lglobl H.100.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_8F8DBED417uncatch_exceptionC1Ev - .lglobl H.114.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_8F8DBED417uncatch_exceptionD2Ev - .lglobl H.121.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_8F8DBED417uncatch_exceptionD1Ev + .lglobl H.92.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_2322ABD117uncatch_exceptionC2Ev + .lglobl H.100.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_2322ABD117uncatch_exceptionC1Ev + .lglobl H.114.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_2322ABD117uncatch_exceptionD2Ev + .lglobl H.121.._ZN10__cxxabiv176_GLOBAL__N__farm_dje_src_src_libstdc___v3_libsupc___vec.cc_00000000_2322ABD117uncatch_exceptionD1Ev - David