Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 14 Sep 2024 13:27:43 -0400
From:      "Kevin P. Neal" <kpn@neutralgood.org>
To:        Ed Alley <alley3ed@gmail.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Why clang and ld.lld?
Message-ID:  <ZuXHj00wBrOQCujY@neutralgood.org>
In-Reply-To: <CAMCnavUsmwBL0yCvq0AcbFOhMXY%2BsrYH0n7zWU41crkZ44=tdg@mail.gmail.com>
References:  <CAMCnavUsmwBL0yCvq0AcbFOhMXY%2BsrYH0n7zWU41crkZ44=tdg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Aug 28, 2024 at 06:28:32PM -0700, Ed Alley wrote:
>    I have been with FreeBSD since the days of FBSD.4.x. I have always
>    been happy with its performance. I am running AMD64, currently at
>    FBSD 13.2. I was previously running FBSD 8.x and I was very happy
>    with its performance. It was running gnu software: a gcc compiler
>    and a gnu BFD loader.
>    I run a large physics code that needs to invert a large matrix
>    by Gauss elimination. The operation gets very sensitive at certain
>    time intervals. However, since I upgraded my system to FBSD 13.2
>    things have gone on the rocks: The iteration does not converge.
>    To top it off I can't seem to get gcc to compile nor am I able to
>    get the old gnu BFD loader to compile.
>    I think that there is something wrong with the clang compiler:
>    It is either not using the math unit properly (round off?) or
>    double precision doesn't mean what it used to mean. I also do

Have you tried strictfp mode? Enable it with -ffp-model=strict and it
will be much, much more careful with floating point. The performance
will be not great, but you'll get more predictable and precise results.

I've been working on strictfp mode for the past six years. I wish we had
more people working on it, but I do what I can.

>    not like the way the ld.lld loader works: for one thing it does
>    not allow me to define variables in an over all h-file, but
>    complains that the variable is multi valued! That is not how
>    C has worked for as long as I have been working with it.
>    For example: I had to put in a -Xlink --allow-.. in the command
>    line to ignore the error message, which was never was an error
>    message in Kernighan and Ritchie C.

K&R C has been outdated since 1989. What you are talking about hasn't been
a best practice in decades and I'm not surprised it gets rejected by a
compiler/linker suite that doesn't have as much history as the gcc suite.
-- 

"You know what I mean." -- US patent 8,011,992B2, "Apparatus For Facilitating
The Construction Of A Snow Man/Woman"



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