Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Jan 2012 11:44:21 +0200
From:      Dirk Kotze <dk@Nanoteq.com>
To:        "'freebsd-questions@freebsd.org'" <freebsd-questions@freebsd.org>
Subject:   RE: Makeopts DEBUG=-g kernel option
Message-ID:  <F46C10D2F60F034BB106EAB4CD7E833C7A463EFBCD@ntq-ex.nanoteq.co.za>
In-Reply-To: <F46C10D2F60F034BB106EAB4CD7E833C7A463EFBBF@ntq-ex.nanoteq.co.za>
References:  <F46C10D2F60F034BB106EAB4CD7E833C7A463EFBBF@ntq-ex.nanoteq.co.za>

next in thread | previous in thread | raw e-mail | index | archive | help
--_002_F46C10D2F60F034BB106EAB4CD7E833C7A463EFBCDntqexnanoteqc_
Content-Type: text/plain; charset="iso-8859-1"
content-transfer-encoding: quoted-printable



Hi again

Just some feedback - it seems that I have isolated the problem below with th=
e help of a 2005 post by John Nielsen to freebsd-questions (http://lists.fre=
ebsd.org/pipermail/freebsd-sparc64/2005-August/003423.html).

I have isolated the problem as being caused by the compiler optimization fla=
gs, specifically the "-O2 -pipe" flags (the default flags used when "makeopt=
ions  DEBUG=3D-g" is not specified in the kernel configuration).  I have pro=
ved that the DEBUG flag per se has nothing to do with it by removing it, and=
 then adding makeoptions COPTFLAGS=3D"-O -pipe" to the kernel config.  This=
 boots fine.

Funny though, the exact original kernel used (without DEBUG and compiled wit=
h -O2) works fine on other hardware (e.g. the Tyan Tank G20 B5211 motherboar=
d with an Intel Core2Duo CPU).  It only fails on the WADE-8020 board. It mus=
t be some specific hardware driver used on the WADE-8020 motherboard that br=
eaks when compiled with -O2.

If anyone has suggestions as to how I can trace the problem further (so that=
 I can log a bug with the BSD community), this will be appreciated.  Hopeful=
ly I can ensure that a future user does not struggle with the same problem I=
 did.

As always, thanks for the help.

Regards,
Dirk Kotze
Developer

> From: Dirk Kotze 
> Sent: Monday, January 23, 2012 4:27 PM
> To: 'freebsd-questions@freebsd.org'
> Subject: Makeopts DEBUG=3D-g kernel option
>
> Hi there
>
> I'm experiencing the following problem: All is well when I boot the standa=
rd FreeBSD 8.2 GENERIC kernel.=A0 The moment 
> however when I comment out the line the line below, the kernel hangs upon=
 boot after detecting the em0 device (the 
> motherboard has 2 Intel 8257x dual Gigabit Ethernet cards).
> makeopts=A0=A0 DEBUG=3D-g
>
> I'm using FreeBSD 8.2 on a WADE-8020 motherboard with an Intel QM57 chipse=
t and Intel Core i5 CPU.=A0 
>
> The reason I'm trying to remove debugging options from the kernel is that=
 I am trying to make the kernel footprint 
> smaller.
>
> This leaves me with a few questions:
> 1) What are the risks/drawbacks/advantages of leaving debugging symbols in=
 the kernel?
> 2) Why would debug symbols (of all things!) make the difference between a=
 working and non-working kernel?
> 3) Does this point in the direction of some other (more serious problem pe=
rhaps?) with the hardware and/or other 
> kernel drivers?
>
> Thanks so much for any assistance.
>
> Regards,
> Dirk Kotze
> Developer
>
>
>=A0=A0=A0=A0=A0=A0=A0 =A0Tel: +27 12 672 7281
>      Fax: +27 12 665 1343
> Postal: P.O. Box 7991, Centurion, 0046
> Physical: 1 Pieter street, Highveld Park, Centurion
>

Important Notice:=0A=
=0A=
This e-mail and its contents are subject to the Nanoteq (Pty) Ltd e-mail leg=
al notice available at:=0A=
http://www.nanoteq.com/corp_profile/disclaimer.asp


Important Notice:

This e-mail and its contents are subject to the Nanoteq (Pty) Ltd e-mail legal notice available at:
http://www.nanoteq.com/corp_profile/disclaimer.asp
--_002_F46C10D2F60F034BB106EAB4CD7E833C7A463EFBCDntqexnanoteqc_
Content-Type: text/plain; name="AVG Certification.txt"
Content-Description: AVG Certification.txt
Content-Disposition: attachment; filename="AVG Certification.txt"; size=92;
	creation-date="Wed, 25 Jan 2012 09:44:22 GMT";
	modification-date="Wed, 25 Jan 2012 09:44:22 GMT"
Content-Transfer-Encoding: base64


VGhlIG1lc3NhZ2UgZG9lcyBub3QgY29udGFpbiBhbnkgdGhyZWF0cw0KQVZHIGZvciBNUyBFeGNo
YW5nZSBTZXJ2ZXIgKDEwLjAuMTQxNiAtIDIxMDkvNDc1Nik=

--_002_F46C10D2F60F034BB106EAB4CD7E833C7A463EFBCDntqexnanoteqc_--





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?F46C10D2F60F034BB106EAB4CD7E833C7A463EFBCD>