Re: [PATCH v17 2/2] c: Add __countof__ operator

2024-10-26 Thread Thorsten Glaser
Hi Alejandro, >On Sun, Oct 27, 2024 at 01:40:23AM GMT, mirabilos wrote: >> Not too sure what the root context of this thread is, but in BSD land > >The root context is that > >- _Lengthof was added to C2y in the Minnesota meeting. It was proposed where/how would this be used for? Also, do you h

Re: [PATCH v17 2/2] c: Add __countof__ operator

2024-10-26 Thread Alejandro Colomar via Gcc
Hi mirabilos, On Sun, Oct 27, 2024 at 01:40:23AM GMT, mirabilos wrote: > Not too sure what the root context of this thread is, but in BSD land The root context is that - _Lengthof was added to C2y in the Minnesota meeting. It was proposed by me, although they pushed me to rename the operato

Re: [PATCH v17 2/2] c: Add __countof__ operator

2024-10-26 Thread mirabilos
On Sat, 26 Oct 2024, Alejandro Colomar wrote: >> It would also be interesting to hear the opinion of people from the BSDs >> >#define sizeof_array(a) (countof(a) * sizeof((a)[0])) >> >#define sizeof_array(a) (array_size(a) * sizeof((a)[0])) Not too sure what the root context of this th

gcc-14-20241026 is now available

2024-10-26 Thread GCC Administrator via Gcc
Snapshot gcc-14-20241026 is now available on https://gcc.gnu.org/pub/gcc/snapshots/14-20241026/ and on various mirrors, see https://gcc.gnu.org/mirrors.html for details. This snapshot has been generated from the GCC 14 git branch with the following options: git://gcc.gnu.org/git/gcc.git branch

Re: examples of (so called) time-travel optimisations in GCC?

2024-10-26 Thread Martin Uecker via Gcc
Am Samstag, dem 26.10.2024 um 18:55 +0200 schrieb Richard Biener via Gcc: > > > Am 26.10.2024 um 17:30 schrieb Iain Sandoe : > > > > Hi, > > > > The background here is that I made a trial implementation of P1494r4 - > > std::observable() - and want to produce testcases. > > > > —— so ….. > >

Re: examples of (so called) time-travel optimisations in GCC?

2024-10-26 Thread Richard Biener via Gcc
> Am 26.10.2024 um 17:30 schrieb Iain Sandoe : > > Hi, > > The background here is that I made a trial implementation of P1494r4 - > std::observable() - and want to produce testcases. > > —— so ….. > > I am looking for either examples where GCC produces time-travel optimisation > (or alter

examples of (so called) time-travel optimisations in GCC?

2024-10-26 Thread Iain Sandoe
Hi, The background here is that I made a trial implementation of P1494r4 - std::observable() - and want to produce testcases. —— so ….. I am looking for either examples where GCC produces time-travel optimisation (or alternately some evidence that these are not expected). (In case someone is

Re: [PATCH v17 2/2] c: Add __countof__ operator

2024-10-26 Thread Alejandro Colomar via Gcc
On Sat, Oct 26, 2024 at 12:12:39PM GMT, Alejandro Colomar wrote: > On Sat, Oct 26, 2024 at 12:07:04PM GMT, Alejandro Colomar wrote: > > [Moved from gcc-patches@ to gcc@] > > > > Hi JeanHeyd, наб, > > > > I see you (JeanHeyd) are developing yet another survey about the names > > for this new opera

Re: [PATCH v17 2/2] c: Add __countof__ operator

2024-10-26 Thread Alejandro Colomar via Gcc
On Sat, Oct 26, 2024 at 12:27:03PM GMT, Alejandro Colomar wrote: > On Sat, Oct 26, 2024 at 12:12:39PM GMT, Alejandro Colomar wrote: > > On Sat, Oct 26, 2024 at 12:07:04PM GMT, Alejandro Colomar wrote: > > > [Moved from gcc-patches@ to gcc@] > > > > > > Hi JeanHeyd, наб, > > > > > > I see you (Jea

Re: [PATCH v17 2/2] c: Add __countof__ operator

2024-10-26 Thread Alejandro Colomar via Gcc
On Sat, Oct 26, 2024 at 12:07:04PM GMT, Alejandro Colomar wrote: > [Moved from gcc-patches@ to gcc@] > > Hi JeanHeyd, наб, > > I see you (JeanHeyd) are developing yet another survey about the names > for this new operator. Let me ask you to be clear about my fear of > ambiguity with null-termina

Re: [PATCH v17 2/2] c: Add __countof__ operator

2024-10-26 Thread Alejandro Colomar via Gcc
[Moved from gcc-patches@ to gcc@] Hi JeanHeyd, наб, I see you (JeanHeyd) are developing yet another survey about the names for this new operator. Let me ask you to be clear about my fear of ambiguity with null-terminated strings which are stored within arrays and the length of both entities diff