C++ Logo

liaison

Advanced search

Re: [isocpp-wg14/wg21-liaison] P3248R0 Require [u]intptr_t

From: Gonzalo Brito <gonzalob_at_[hidden]>
Date: Fri, 24 May 2024 07:26:04 +0000
Hi Jens!

> There are only a few platforms that don't have these types, the only ones we found have 128 bit pointers and 64 bit `uintmax_t`.

The only one I’ve found is IBM AS/4000, which are supported both via their ILC compiler (which is stuck on only supporting an old C standard), but also has GCC 11 support, and through g++ also C++ support, which lacks uintptr_t to avoid breaking their ABI, but could add it post C23 without breaking it.

I’ve tried to get in contact with the IBM AS/4000 stakeholders through my network, but have been unsuccesful…
- Do you know of other platforms beyond IBM AS/4000 ? (I’d like to include a comprehensive list in the paper)
- Do you have the contact of these stakeholders and can put us in contact with them, so that we can involve them?

I’ll keep trying to get in contact with them regardless.

Thanks
Gonzalo

From: Jₑₙₛ Gustedt <jens.gustedt_at_[hidden]>
Date: Friday, 24. May 2024 at 08:38
To: Nina Dinka Ranns via Liaison <liaison_at_[hidden]>
Cc: Nina Dinka Ranns <dinka.ranns_at_[hidden]>, Gonzalo Brito <gonzalob_at_[hidden]>
Subject: Re: [isocpp-wg14/wg21-liaison] P3248R0 Require [u]intptr_t
Hi,

on Thu, 23 May 2024 11:17:44 +0100 you (Nina Dinka Ranns via Liaison
<liaison_at_[hidden]>) wrote:

> We have a question from the author of P3248R0
> <https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwg21.link%2Fp3248r0&data=05%7C02%7Cgonzalob%40nvidia.com%7C9dac179da7ea47fe57e808dc7bbc0b06%7C43083d15727340c1b7db39efd9ccc17a%7C0%7C0%7C638521294851544589%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=QRGOWKSA%2BsKgzoAmYk3hM5Yqok1FaeKRa3t%2BWw6XHZE%3D&reserved=0<https://wg21.link/p3248r0>> Require
> [u]intptr_t :
>
> - If C++ requires [u]intptr_t with the proposed semantics (same as
> C), does SG22 have any concerns w.r.t. C++ compatibility with C on
> platforms C++ supports?
>
> Thoughts ?

C also wants to go into that direction but is for the moment more
careful by only placing this in TS 6010 (provenance). I don't think
that it would be reasonable for any platform that has a C++
implementation not to support this also in their C implementation.

So putting this into C++ might actually force the very few platforms
that don't have `uintptr_t`, yet, into implementing it, respectively,
what is much more important, to work out their ABI for doing this. As
the paper correctly states, with C23 this is now possible under all
circumstances. There are only a few platforms that don't have
these types, the only ones we found have 128 bit pointers and 64 bit
`uintmax_t`. I suspect that all of these have C++ implementations.

To summarize, this would be kind-of a bold move from C++ to force
something on basically all C implementations. Whether or not this is
politically advisable I don't know.

Thanks
Jₑₙₛ

--
:: ICube :::::::::::::::::::::::::::::: deputy director ::
:: Université de Strasbourg :::::::::::::::::::::: ICPS ::
:: INRIA Nancy Grand Est :::::::::::::::::::::::: Camus ::
:: :::::::::::::::::::::::::::::::::::: ☎ +33 368854536 ::
:: https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Ficube-icps.unistra.fr%2Findex.php%2FJens_Gustedt&data=05%7C02%7Cgonzalob%40nvidia.com%7C9dac179da7ea47fe57e808dc7bbc0b06%7C43083d15727340c1b7db39efd9ccc17a%7C0%7C0%7C638521294851556329%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=ord8KvJoQdHw8VgNkl5F%2FqJ2iu8FxfguYWZVuudEqkg%3D&reserved=0<https://icube-icps.unistra.fr/index.php/Jens_Gustedt> ::

Received on 2024-05-24 07:26:14