From owner-freebsd-current Fri Aug 20 5:33:30 1999 Delivered-To: freebsd-current@freebsd.org Received: from overcee.netplex.com.au (overcee.netplex.com.au [202.12.86.7]) by hub.freebsd.org (Postfix) with ESMTP id 7954D14E1A; Fri, 20 Aug 1999 05:33:24 -0700 (PDT) (envelope-from peter@netplex.com.au) Received: from netplex.com.au (localhost [127.0.0.1]) by overcee.netplex.com.au (Postfix) with ESMTP id A5E621C1F; Fri, 20 Aug 1999 20:32:25 +0800 (WST) (envelope-from peter@netplex.com.au) X-Mailer: exmh version 2.0.2 2/24/98 To: Doug Rabson Cc: Andrew Gallatin , current@FreeBSD.ORG, alpha@FreeBSD.ORG Subject: Re: cc -O broken in -current for Alpha KLDs In-reply-to: Your message of "Fri, 20 Aug 1999 03:28:06 +0100." Date: Fri, 20 Aug 1999 20:32:25 +0800 From: Peter Wemm Message-Id: <19990820123225.A5E621C1F@overcee.netplex.com.au> Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Doug Rabson wrote: > On Thu, 19 Aug 1999, Andrew Gallatin wrote: > > > > > I do most of my development on alphas & I just turned some local code > > into a loadable kernel module. It works fine when compiled into the > > kernel statically, but fails miserably when loaded into an alpha > > kernel as a module. This alpha is running -current from monday or > > so. > > > > After a day or so of debugging, I decided to run > > it on an x86 -- it ran just fine. I've narrowed the problem down to > > one involving optimization and have extracted a simple, reproducable > > test case. > > > > When the test module is loaded without optimization (CFLAGS += -g > > -O0), it prints the following (which is correct): > > It looks like we aren't handling the relocations correctly. When I get a > chance, I will try to look at it. If you want to have another look, the > code at fault is probably in alpha/alpha/elf_machdep.c and you can get a > list of relocations in the module with 'objdump --dynamic-reloc foo.ko'. I thought of that before I went to sleep this morning too.. Cheers, -Peter To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message