From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.redhat.com (mail.redhat.com [199.183.24.239]) by listman.redhat.com (Postfix) with ESMTP id 8541C2F31A for ; Wed, 8 Nov 2000 09:02:26 -0500 (EST) Received: (from mail@localhost) by mail.redhat.com (8.11.0/8.8.7) id eA8E2QH02025 for axp-list@listman.redhat.com; Wed, 8 Nov 2000 09:02:26 -0500 Received: from stegosaurus.bristol.quadrics.com (stegosaurus.quadrics.com [194.202.174.3]) by mail.redhat.com (8.11.0/8.8.7) with ESMTP id eA8E2PD02017 for ; Wed, 8 Nov 2000 09:02:25 -0500 Received: by stegosaurus.bristol.quadrics.com with Internet Mail Service (5.5.2650.21) id ; Wed, 8 Nov 2000 14:02:23 -0000 Message-ID: <010C86D15E4D1247B9A5DD312B7F5AA70BEC9B@stegosaurus.bristol.quadrics.com> From: David Addison To: "'axp-list@redhat.com'" Subject: kernel compilation and -relax flag Date: Wed, 8 Nov 2000 14:02:14 -0000 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C0498C.8438AC8B" X-Loop: axp-list@redhat.com Sender: axp-list-admin@redhat.com Errors-To: axp-list-admin@redhat.com X-BeenThere: axp-list@redhat.com X-Mailman-Version: 2.0beta4 Precedence: bulk Reply-To: axp-list@redhat.com List-Id: Linux and Red Hat on Alpha processors This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. ------_=_NextPart_001_01C0498C.8438AC8B Content-Type: text/plain; charset="iso-8859-1" Hi, I've been having trouble with the -relax flag again. Basically I have added this to the kernel linkage to get the .got table size below 64k - otherwise the kernel exception table stuff gets broken. This was working fine until I merged in the API EV6 2.2.17 assembler patch and it then broke everything in that init seems to fail to parse command line options correctly. Simply turning off -relax makes the patched kernel work again. But the vmunix got table is now above 64k again. I just tried adding the -relax flag to CFLAGS as '-Wa,-relax' and now the arch/alpha/lib/copy_user.S code fails to compile; cc -D__KERNEL__ -I/usr/src/linux/include -D__ASSEMBLY__ -D__SMP__ -Wall -Wstrict-prototypes -O2 -g -fno-strict-aliasing -D__SMP__ -pipe -mno-fp-regs -ffixed-8 -mcpu=ev6 -Wa,-relax -Wa,-mev6 -c -o copy_user.o copy_user.S copy_user.S: Assembler messages: copy_user.S:187: Error: non-absolute expression in constant field copy_user.S:196: Error: non-absolute expression in constant field copy_user.S:208: Error: non-absolute expression in constant field etc. This seems to be related to the expansion of the EXI() macro line; lda $31, $exitin-99b($31); Any idea what this means ? Is -relax not permitted for such code and if so, what does it do to this object file when used to do the final vmunix linkage ? Cheers, Addy. ------_=_NextPart_001_01C0498C.8438AC8B Content-Type: text/html; charset="iso-8859-1"
Hi, I've been having trouble with the -relax flag again. Basically I have added this to the kernel linkage to get the .got table size below 64k - otherwise the kernel exception table stuff gets broken.
 
This was working fine until I merged in the API EV6 2.2.17 assembler patch and it then broke everything in that init seems to fail to parse command line options correctly. Simply turning off -relax makes the patched kernel work again. But the vmunix got table is now above 64k again.
 
I just tried adding the -relax flag to CFLAGS as '-Wa,-relax' and now the arch/alpha/lib/copy_user.S code fails to compile;
 
cc -D__KERNEL__ -I/usr/src/linux/include -D__ASSEMBLY__ -D__SMP__ -Wall -Wstrict-prototypes -O2 -g -fno-strict-aliasing
-D__SMP__ -pipe -mno-fp-regs -ffixed-8 -mcpu=ev6 -Wa,-relax -Wa,-mev6 -c -o copy_user.o copy_user.S
copy_user.S: Assembler messages:
copy_user.S:187: Error: non-absolute expression in constant field
copy_user.S:196: Error: non-absolute expression in constant field
copy_user.S:208: Error: non-absolute expression in constant field
 
etc.
 
This seems to be related to the expansion of the EXI() macro line;
 
lda $31, $exitin-99b($31);
 
 
Any idea what this means ? Is -relax not permitted for such code and if so, what does it do to this object file when used to do the final vmunix linkage ?
 
Cheers,
Addy.

 
------_=_NextPart_001_01C0498C.8438AC8B-- From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.redhat.com (mail.redhat.com [199.183.24.239]) by listman.redhat.com (Postfix) with ESMTP id B57FB2F253 for ; Wed, 8 Nov 2000 12:48:03 -0500 (EST) Received: (from mail@localhost) by mail.redhat.com (8.11.0/8.8.7) id eA8Hm3U16442 for axp-list@listman.redhat.com; Wed, 8 Nov 2000 12:48:03 -0500 Received: from piglet.twiddle.net (piglet.twiddle.net [207.104.6.26]) by mail.redhat.com (8.11.0/8.8.7) with ESMTP id eA8Hm2D16438 for ; Wed, 8 Nov 2000 12:48:02 -0500 Received: (from rth@localhost) by piglet.twiddle.net (8.9.3/8.9.3) id JAA27461 for axp-list@redhat.com; Wed, 8 Nov 2000 09:48:27 -0800 Date: Wed, 8 Nov 2000 09:48:26 -0800 From: Richard Henderson To: axp-list@redhat.com Subject: Re: kernel compilation and -relax flag Message-ID: <20001108094826.E27324@twiddle.net> References: <010C86D15E4D1247B9A5DD312B7F5AA70BEC9B@stegosaurus.bristol.quadrics.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0pre3us In-Reply-To: <010C86D15E4D1247B9A5DD312B7F5AA70BEC9B@stegosaurus.bristol.quadrics.com> X-Loop: axp-list@redhat.com Sender: axp-list-admin@redhat.com Errors-To: axp-list-admin@redhat.com X-BeenThere: axp-list@redhat.com X-Mailman-Version: 2.0beta4 Precedence: bulk Reply-To: axp-list@redhat.com List-Id: Linux and Red Hat on Alpha processors On Wed, Nov 08, 2000 at 02:02:14PM -0000, David Addison wrote: > This was working fine until I merged in the API EV6 2.2.17 assembler patch > and it then broke everything in that init seems to fail to parse command > line options correctly. That means that the new ev6 code is not being careful with the .prologue directives. Those indicate if and how the incoming r27 value is used. > I just tried adding the -relax flag to CFLAGS as '-Wa,-relax' and now the > arch/alpha/lib/copy_user.S code fails to compile; [...] > lda $31, $exitin-99b($31); The -relax option as given to the assembler tries to leave enough relocations in the object file that the linker could delete instructions out of the middle of a function. (The linker doesn't do that at the moment, merely nops them out.) We do not have a 16-bit pc-relative relocation, which means that we cannot represent this instruction, thus the error. r~