From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1840 invoked by alias); 9 Dec 2004 16:53:49 -0000 Mailing-List: contact binutils-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sources.redhat.com Received: (qmail 1816 invoked from network); 9 Dec 2004 16:53:45 -0000 Received: from unknown (HELO iris1.csv.ica.uni-stuttgart.de) (129.69.118.2) by sourceware.org with SMTP; 9 Dec 2004 16:53:45 -0000 Received: from rembrandt.csv.ica.uni-stuttgart.de ([129.69.118.42]) by iris1.csv.ica.uni-stuttgart.de with esmtp id 1CcRXy-0002WM-00; Thu, 09 Dec 2004 17:53:42 +0100 Received: from ica2_ts by rembrandt.csv.ica.uni-stuttgart.de with local (Exim 3.35 #1 (Debian)) id 1CcRXx-0003Ev-00; Thu, 09 Dec 2004 17:53:41 +0100 Date: Thu, 09 Dec 2004 16:53:00 -0000 To: Ian Lance Taylor Cc: binutils@sourceware.org Subject: Re: News MIPS option -mno-shared Message-ID: <20041209165341.GC8419@rembrandt.csv.ica.uni-stuttgart.de> References: <20041209153403.5294.qmail@gossamer.airs.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20041209153403.5294.qmail@gossamer.airs.com> User-Agent: Mutt/1.5.6i From: Thiemo Seufer X-SW-Source: 2004-12/txt/msg00101.txt.bz2 Ian Lance Taylor wrote: > I'd like to see whether anybody has an opinion about this patch before > I check it in. > > This patch adds a new option to the MIPS assembler: -mno-shared. > Normally the .cpload pseudo-op generates code which looks like this: > > lui $gp,%hi(_gp_disp) > addiu $gp,$gp,%lo(_gp_disp) > addu $gp,$gp,.cpload argument > > With -mno-shared, the .cpload pseudo-op will generate code that looks > like this: > > lui $gp,%hi(_gp) > addiu $gp,$gp,%lo(_gp) > > The idea is that you can use -KPIC -mno-shared and get code which > still uses the usual Unix calling convention, but is slightly more > efficient at each function entry. Of course, the resulting code is > not position independent and can not be put into a shared library. > Hence the name -mno-shared. It will also break 64bit addressing. IMHO it should check for that, and either fail or fall back to the old code sequence. Thiemo