Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 1 May 2001 03:26:10 -0700
From:      Rich Morin <rdm@cfcl.com>
To:        chat@FreeBSD.ORG
Subject:   Re: BSD libc for Linux?
Message-ID:  <p05001909b7143ae910ea@[192.168.168.205]>
In-Reply-To: <20010430172143.A9910@Odin.AC.HMC.Edu>
References:  <20010430172143.A9910@Odin.AC.HMC.Edu>

next in thread | previous in thread | raw e-mail | index | archive | help
At 5:21 PM -0700 4/30/01, Brooks Davis wrote:
>For lack of any where better to ask, I'll try chat.  Does any one know
>of a working port of a BSD libc for a modern Linux (RedHat 6.x, SuSE 6.y,
>etc.)  I ask because I've got some scientific code that's more or less
>pure ANSI C that works just fine producing the same or nearly the same
>results on FreeBSD, Solaris, Irix, and even Alpha Linux, but on i386
>Linux it produces wildly different (though consistant) results.  I'm
>hoping for an easy to way to figure out it it's the kernel or glibc.

I'm not sure that's the best debugging strategy.  For one thing, the
culprit might be neither one of these.  And, even if you find out which
library (or other system component) the problem lies in, you will still
be far from having a useful bug report.

So, I would suggest a different strategy.  Using a series of carefully-
instrumented runs, find out where the program is going astray.  Then,
attempt to create a subset of the program which replicates the problem.
Rinse, repeat until you get down to a specific system call or function.

Here are some possibly useful techniques:

   Compare the output streams of the running and bogus systems,
   looking for the first instance of an error.

   For finer granularity, add trace messages of values that might
   be relevant to the problem.

   To test hypotheses (and keep the output stream manageable),
   insert conditional trace statements that track specific values.

-r
-- 
http://www.cfcl.com/rdm - home page, resume, etc.
http://www.cfcl.com/Meta/md_fb.html - The FreeBSD Browser
email: rdm@cfcl.com; phone: +1 650-873-7841

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-chat" in the body of the message




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