From owner-freebsd-toolchain@FreeBSD.ORG Sun Nov 14 22:47:56 2010 Return-Path: Delivered-To: freebsd-toolchain@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 083A0106564A for ; Sun, 14 Nov 2010 22:47:56 +0000 (UTC) (envelope-from erik@cederstrand.dk) Received: from csmtp3.one.com (csmtp3.one.com [91.198.169.23]) by mx1.freebsd.org (Postfix) with ESMTP id 8BA538FC12 for ; Sun, 14 Nov 2010 22:47:55 +0000 (UTC) Received: from macfeast.lan (0x573b9942.cpe.ge-1-2-0-1101.ronqu1.customer.tele.dk [87.59.153.66]) by csmtp3.one.com (Postfix) with ESMTP id 2AFDD240632D for ; Sun, 14 Nov 2010 22:29:45 +0000 (UTC) From: Erik Cederstrand Content-Type: multipart/signed; boundary=Apple-Mail-2097-81456243; protocol="application/pkcs7-signature"; micalg=sha1 Date: Sun, 14 Nov 2010 23:29:45 +0100 Message-Id: To: freebsd-toolchain@freebsd.org Mime-Version: 1.0 (Apple Message framework v1081) X-Mailer: Apple Mail (2.1081) X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Clang and -frandom-seed X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Nov 2010 22:47:56 -0000 --Apple-Mail-2097-81456243 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Hello toolchainers, I noticed that two consecutive builds of (GCC-built) Clang don't produce = identical binaries. This is true for clang, clang++ and tblgen. I asked = on the llvm-dev list yesterday, and it turns out it's because GCC uses a = random seed on some symbols. Apparently, this can be controlled with the = -frandom-seed flag. I haven't tested if this is also the case for = Clang-built Clang. I'm not sure I understand the exact implications, but I'm wondering if = we could add the flag to the build scripts in FreeBSD in a way that both = satisfies the randomness criteria and makes builds deterministic? Thanks, Erik= --Apple-Mail-2097-81456243--