From owner-svn-src-all@freebsd.org Sat Oct 22 13:14:04 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 18887C1C2E2; Sat, 22 Oct 2016 13:14:04 +0000 (UTC) (envelope-from chmeeedalf@gmail.com) Received: from mail-it0-x244.google.com (mail-it0-x244.google.com [IPv6:2607:f8b0:4001:c0b::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D2A132E0; Sat, 22 Oct 2016 13:14:03 +0000 (UTC) (envelope-from chmeeedalf@gmail.com) Received: by mail-it0-x244.google.com with SMTP id 139so3177532itm.2; Sat, 22 Oct 2016 06:14:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=cc:message-id:from:to:in-reply-to:content-transfer-encoding :mime-version:subject:date:references; bh=h1yeqxP+3bQr7qw2UiHya4ntEcHRWJaha2jrSqcO6nU=; b=X/Da+2QhR+1ZCy1viP8qtV/cA92wrTx/FdjdmwSzFs7z+ROZZynjJ2Np88s+MHpw8L vDqQa3fO4r/c886f2jDcvGv9JGr6jkKT98TJ/mayvAqwyKrXK8QJ/U474KytjKloJRlX twa2HIfYH2Q55y+slQ3P7EWQa7bv5HGQeRuVSnv/M6vKXUO7ubX9/ZlNFVY065cdvXBp EQQGLh3z8ufuIPTt9/N4nVZIYzOXsLn1Od/bdzDMXuWxBpdQq2Q7F10aC4CKdnA8I1jq sWhzPOB33Pcd3fqd4OuBrHOXOoZYKm+6FTHu8hKAdWOGi+dGGOjh6MsqaFzB2mQadMpV +5MQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:cc:message-id:from:to:in-reply-to :content-transfer-encoding:mime-version:subject:date:references; bh=h1yeqxP+3bQr7qw2UiHya4ntEcHRWJaha2jrSqcO6nU=; b=SxZdRoNtIEKyXZVYokvNA36sWS2p9gTjMblWu3jXALKPUPDuF0voWcVCnYt2IWFeLC kPRzbd9vjqvPCQ3IKNBg6qW7nEb5jEzSsyVcGjjzxiPutwi3+0HQvOOrEaYltoGDOHKg L70NHvhoqJfIX/9xp2LxYoUZbiVuKbN5cz7ltEd3y+SFW7aVeNdbgDOFl3aOXp6QPKbS Bvw5uCevEHtM4guXdmL8VXruaqOfRLO7P0x2AQ4bxVvPfDoSI48x9T5SLVZpyc9I7NJv UgRpouCF96nvhVICqCGONWG8Tpmo6bRxbA6DM3ETHsYP8yS6fKddCeIt+G5lQnykNM3m ozAA== X-Gm-Message-State: ABUngvfLFQpYweX1giN6MFJX3YB4xE+hjILBJBJbSpQ2ka3fwh4pSp6LsYe09uVQ6r7wQw== X-Received: by 10.107.202.69 with SMTP id a66mr6474229iog.170.1477142043055; Sat, 22 Oct 2016 06:14:03 -0700 (PDT) Received: from Triad.knownspace (50-80-150-234.client.mchsi.com. [50.80.150.234]) by smtp.gmail.com with ESMTPSA id a100sm3802948ioj.13.2016.10.22.06.14.01 (version=TLS1 cipher=AES128-SHA bits=128/128); Sat, 22 Oct 2016 06:14:02 -0700 (PDT) Cc: Justin Hibbits , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: From: Justin Hibbits To: Konstantin Belousov In-Reply-To: <20161022124301.GZ54029@kib.kiev.ua> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v936) Subject: Re: svn commit: r307761 - in head: . contrib/binutils/bfd contrib/gcc/config/rs6000 gnu/lib/libgcc gnu/lib/libgomp gnu/usr.bin/binutils gnu/usr.bin/cc gnu/usr.bin/cc/cc_tools gnu/usr.bin/cc/include gnu... Date: Sat, 22 Oct 2016 08:14:00 -0500 References: <201610220157.u9M1vFXx080331@repo.freebsd.org> <20161022122017.GY54029@kib.kiev.ua> <20161022124301.GZ54029@kib.kiev.ua> X-Mailer: Apple Mail (2.936) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Oct 2016 13:14:04 -0000 On Oct 22, 2016, at 7:43 AM, Konstantin Belousov wrote: > On Sat, Oct 22, 2016 at 03:20:17PM +0300, Konstantin Belousov wrote: >> On Sat, Oct 22, 2016 at 01:57:15AM +0000, Justin Hibbits wrote: >>> Author: jhibbits >>> Date: Sat Oct 22 01:57:15 2016 >>> New Revision: 307761 >>> URL: https://svnweb.freebsd.org/changeset/base/307761 >>> >>> Log: >>> Create a new MACHINE_ARCH for Freescale PowerPC e500v2 >> >>> Added: >>> head/lib/libc/powerpcspe/sys/ptrace.S (contents, props changed) >> >> This is not needed, libc provides MI implementation in libc/sys/ >> ptrace.c. > > Why the decision to copy whole lib/libc/powerpc to lib/libc/powerpcspe > was used to create the architecture ? I did a primitive-science > overview, and got total ~2300 lines in lib/libc/powerpcspe, while > $ diff -Nrua lib/libc/powerpc lib/libc/powerpcspe | diffstat -p0 | > tail -1 > 16 files changed, 240 insertions(+), 174 deletions(-) > > It seems to be possible to only create several new files, like > *setjmp.S and fp*.c, and reuse existing stock files from libc/powerpc > for anything else. > > I am the one who does most of the sweeping changes over libc, and > I am somewhat saddened by addition of almost identical copy of the > existing architecture files which need to be maintained together with > the original. To be honest, I didn't think it was the right way either, but wasn't completely certain (and admittedly didn't try) that I could have two files with the same names, one in powerpc one in powerpcspe, and have it ignore the powerpc one if it exists in powerpcspe. libc's Makefile includes ${MACHINE_ARCH}/Makefile.inc, unless it doesn't exist in which case it includes ${MACHINE_CPUARCH}/ Makefile.inc, I'll see if I can consolidate them, but do you have a recommendation of the best way to do it? I also didn't really like the code duplication, but couldn't think of an easy/good way to do so. Now that we've chatted on IRC a bit about this, I'll take your suggestion and create some Makefile.common files to share between powerpc and powerpcspe. It may take a couple days depending on my available time. - Justin