From owner-freebsd-hackers@FreeBSD.ORG Tue Apr 9 18:47:30 2013 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id EB1C2F56 for ; Tue, 9 Apr 2013 18:47:30 +0000 (UTC) (envelope-from etnapierala@gmail.com) Received: from mail-ee0-f46.google.com (mail-ee0-f46.google.com [74.125.83.46]) by mx1.freebsd.org (Postfix) with ESMTP id 7CCF922B for ; Tue, 9 Apr 2013 18:47:30 +0000 (UTC) Received: by mail-ee0-f46.google.com with SMTP id d49so2071762eek.5 for ; Tue, 09 Apr 2013 11:47:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:subject:mime-version:content-type:from :in-reply-to:date:cc:content-transfer-encoding:message-id:references :to:x-mailer; bh=x1nAEwftGcUxzQZNYzVwjYh1kxm82G5lF1n7/jHp1Pc=; b=hPsx5We8AXRN59G0/+DS/3k1RXWqMjpkxOnkIaRxENUNKAW7Chvd5TNBdPvuMSlZb/ DOKD5J9788yhOUXLwcfZdOL7ZO3HWeamA7BVDPdDsT/kci0+U3r+CTXcaXQcDKsQjV/v B2QRRc/FMzN32Db7LNPYK0uhjuby6lvc5NHdUx3YH+zu2iBWfXmn/s+1Bl7yMJldEGXH EK9yRFwe179kCJW9hJZ06HYbg520/Ygk2n+5QhnYK4h76qxqHhEf0ZfLC/zxSE8kVwiq TrqlVSOgh4mCi2AO1EFcNpLOdxK0x8hXCoHG22T8OhMVTVf/TmVeF2DtW0sWEGL6zYWx 4J6w== X-Received: by 10.14.107.69 with SMTP id n45mr40864720eeg.23.1365533249456; Tue, 09 Apr 2013 11:47:29 -0700 (PDT) Received: from [192.168.1.104] (45.81.datacomsa.pl. [195.34.81.45]) by mx.google.com with ESMTPS id a41sm5358699eei.4.2013.04.09.11.47.27 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Apr 2013 11:47:28 -0700 (PDT) Sender: =?UTF-8?Q?Edward_Tomasz_Napiera=C5=82a?= Subject: Re: GSOC 2013 project " Kernel Size Reduction for Embedded System " Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: text/plain; charset=us-ascii From: =?iso-8859-2?Q?Edward_Tomasz_Napiera=B3a?= In-Reply-To: Date: Tue, 9 Apr 2013 20:47:26 +0200 Content-Transfer-Encoding: 7bit Message-Id: <92799D4C-797C-4304-B299-DD1DBA49CFFC@FreeBSD.org> References: <516452C7.7040607@mu.org> To: Freddie Cash X-Mailer: Apple Mail (2.1283) Cc: Wojciech Puchar , Alfred Perlstein , Amit Rawat , FreeBSD Hackers X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Apr 2013 18:47:31 -0000 In order to optimize - in this case for size - we need a way to measure what should we focus on, and it looks like we don't have it yet. Would it be possible to write a tool - e.g. by instrumenting LLVM - that would make it possible to calculate, for every function in the call graph, the amount of code in that function and everything it "pulls in", i.e. all the code paths that it might call. When we have that, clustering the graph should give us some idea what to focus on. Or perhaps such a tool already exists? -- If you cut off my head, what would I say? Me and my head, or me and my body?