public inbox for newlib@sourceware.org
 help / color / mirror / Atom feed
From: Jeff Johnston <jjohnstn@redhat.com>
To: joel@rtems.org
Cc: Newlib <newlib@sourceware.org>, Chris Johns <chrisj@rtems.org>,
	 Gedare Bloom <gedare@rtems.org>
Subject: Re: LDBL_EQ_DBL Multilib Issues
Date: Tue, 26 Sep 2023 18:39:47 -0400	[thread overview]
Message-ID: <CAOox84v3HKR-EKVvGBGfw2kDZ555OHpKw4Bfmxt45mDbHjAeDw@mail.gmail.com> (raw)
In-Reply-To: <CAF9ehCVdL2TMem1aOpznbGnASn9d9NmJShcx-t25DY4L23Qaag@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1084 bytes --]

Have you thought about adding a special case in sys/config.h which
when it has the appropriate conditions (platform plus compiler flag) will
define/redefine _LDBL_EQ_DBL?

It gets included as part of _ansi.h and after newlib.h.

-- Jeff J.


On Tue, Sep 26, 2023 at 10:43 AM Joel Sherrill <joel@rtems.org> wrote:

> Hi
>
> I wondered when we reorganized LDBL_EQ_DBL logic if there wouldn't be a
> multilib edge case. Chris encountered it.
>
> Attached is a simple test program based on the autoconf probe in
> configure.ac that can be preprocessed with different CPU/ABI flags. The
> following shows that the default on m68k is not the same as for the 5282.
>
> $ m68k-rtems6-gcc -O2 -E ldbl.c | less
>
> $ m68k-rtems6-gcc -O2 -E -mcpu=5282 ldbl.c | less
>
> Turns out the default flags end up with LDBL_EQ_DBL isn't defined but it
> should be for -mcpu=5282 builds.
>
> I don't know any mechanism to add header file variants in newlib by
> multilib, so I we need to consider moving this to a dynamic check.
>
> Any thoughts on where to move this?
>

  reply	other threads:[~2023-09-26 22:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-26 14:42 Joel Sherrill
2023-09-26 22:39 ` Jeff Johnston [this message]
2023-09-26 23:18   ` Joel Sherrill

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAOox84v3HKR-EKVvGBGfw2kDZ555OHpKw4Bfmxt45mDbHjAeDw@mail.gmail.com \
    --to=jjohnstn@redhat.com \
    --cc=chrisj@rtems.org \
    --cc=gedare@rtems.org \
    --cc=joel@rtems.org \
    --cc=newlib@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).