From owner-p4-projects@FreeBSD.ORG Tue Sep 29 15:22:28 2009 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id C0F031065679; Tue, 29 Sep 2009 15:22:28 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 843E31065670 for ; Tue, 29 Sep 2009 15:22:28 +0000 (UTC) (envelope-from stas@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 70E398FC1A for ; Tue, 29 Sep 2009 15:22:28 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id n8TFMSUl087701 for ; Tue, 29 Sep 2009 15:22:28 GMT (envelope-from stas@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id n8TFMSMD087699 for perforce@freebsd.org; Tue, 29 Sep 2009 15:22:28 GMT (envelope-from stas@freebsd.org) Date: Tue, 29 Sep 2009 15:22:28 GMT Message-Id: <200909291522.n8TFMSMD087699@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to stas@freebsd.org using -f From: Stanislav Sedov To: Perforce Change Reviews Cc: Subject: PERFORCE change 169013 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Sep 2009 15:22:29 -0000 http://perforce.freebsd.org/chv.cgi?CH=169013 Change 169013 by stas@stas_yandex on 2009/09/29 15:22:00 - Fix 32 bit on amd64 operation. Affected files ... .. //depot/projects/valgrind/coregrind/m_ume/elf.c#4 edit Differences ... ==== //depot/projects/valgrind/coregrind/m_ume/elf.c#4 (text+ko) ==== @@ -400,6 +400,15 @@ VG_(pread)(fd, buf, ph->p_filesz, ph->p_offset); buf[ph->p_filesz] = '\0'; +#if defined(VGP_x86_freebsd) + sres._isError = True; + /* Hack. FreeBSD's kernel overloads the interpreter name. */ + if (VG_(strcmp)(buf, "/libexec/ld-elf.so.1") == 0 || + VG_(strcmp)(buf, "/usr/libexec/ld-elf.so.1") == 0) { + sres = VG_(open)("/libexec/ld-elf32.so.1", VKI_O_RDONLY, 0); + } + if (sr_isError(sres)) +#endif sres = VG_(open)(buf, VKI_O_RDONLY, 0); if (sr_isError(sres)) { VG_(printf)("valgrind: m_ume.c: can't open interpreter\n");