Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-17 Thread Andi Kleen
> Great. Does it also work in a non-template function? Sadly it did not because there needs to be more AGGR_VIEW_EXPR handling, as you predicted at some point. I fixed it now. Will send updated patches. -Andi

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Jason Merrill
On 7/16/24 6:54 PM, Andi Kleen wrote: On Tue, Jul 16, 2024 at 06:06:42PM -0400, Jason Merrill wrote: On 7/16/24 5:55 PM, Andi Kleen wrote: On Tue, Jul 16, 2024 at 12:52:31PM -0700, Andi Kleen wrote: On Tue, Jul 16, 2024 at 02:51:13PM -0400, Jason Merrill wrote: On 7/16/24 12:18 PM, Andi Kleen

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Andi Kleen
On Tue, Jul 16, 2024 at 06:06:42PM -0400, Jason Merrill wrote: > On 7/16/24 5:55 PM, Andi Kleen wrote: > > On Tue, Jul 16, 2024 at 12:52:31PM -0700, Andi Kleen wrote: > > > On Tue, Jul 16, 2024 at 02:51:13PM -0400, Jason Merrill wrote: > > > > On 7/16/24 12:18 PM, Andi Kleen wrote: > > > > > On Tue

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Jason Merrill
On 7/16/24 5:55 PM, Andi Kleen wrote: On Tue, Jul 16, 2024 at 12:52:31PM -0700, Andi Kleen wrote: On Tue, Jul 16, 2024 at 02:51:13PM -0400, Jason Merrill wrote: On 7/16/24 12:18 PM, Andi Kleen wrote: On Tue, Jul 16, 2024 at 11:17:14AM -0400, Jason Merrill wrote: On 7/16/24 11:15 AM, Andi Klee

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Andi Kleen
On Tue, Jul 16, 2024 at 12:52:31PM -0700, Andi Kleen wrote: > On Tue, Jul 16, 2024 at 02:51:13PM -0400, Jason Merrill wrote: > > On 7/16/24 12:18 PM, Andi Kleen wrote: > > > On Tue, Jul 16, 2024 at 11:17:14AM -0400, Jason Merrill wrote: > > > > On 7/16/24 11:15 AM, Andi Kleen wrote: > > > > > > In

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Andi Kleen
On Tue, Jul 16, 2024 at 02:51:13PM -0400, Jason Merrill wrote: > On 7/16/24 12:18 PM, Andi Kleen wrote: > > On Tue, Jul 16, 2024 at 11:17:14AM -0400, Jason Merrill wrote: > > > On 7/16/24 11:15 AM, Andi Kleen wrote: > > > > > In the adjusted test it looks like the types of f and g match, so I > >

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Jason Merrill
On 7/16/24 12:18 PM, Andi Kleen wrote: On Tue, Jul 16, 2024 at 11:17:14AM -0400, Jason Merrill wrote: On 7/16/24 11:15 AM, Andi Kleen wrote: In the adjusted test it looks like the types of f and g match, so I wouldn't expect an error. Good point! Missing the forest for the trees. Anyways are

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Andi Kleen
On Tue, Jul 16, 2024 at 11:17:14AM -0400, Jason Merrill wrote: > On 7/16/24 11:15 AM, Andi Kleen wrote: > > > In the adjusted test it looks like the types of f and g match, so I > > > wouldn't > > > expect an error. > > > > Good point! Missing the forest for the trees. > > > > Anyways are the C+

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Jason Merrill
On 7/16/24 11:15 AM, Andi Kleen wrote: In the adjusted test it looks like the types of f and g match, so I wouldn't expect an error. Good point! Missing the forest for the trees. Anyways are the C++ patches ok with this change? I'm still looking for a test which does error because the types

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Andi Kleen
> In the adjusted test it looks like the types of f and g match, so I wouldn't > expect an error. Good point! Missing the forest for the trees. Anyways are the C++ patches ok with this change? Thanks, -Andi

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-16 Thread Jason Merrill
On 7/15/24 11:24 PM, Andi Kleen wrote: On Mon, Jul 15, 2024 at 06:57:57PM -0400, Jason Merrill wrote: On 7/8/24 12:56 PM, Andi Kleen wrote: diff --git a/gcc/testsuite/g++.dg/musttail10.C b/gcc/testsuite/g++.dg/musttail10.C new file mode 100644 index ..9b7043b8a306 --- /dev/null +++

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-15 Thread Andi Kleen
On Mon, Jul 15, 2024 at 06:57:57PM -0400, Jason Merrill wrote: > On 7/8/24 12:56 PM, Andi Kleen wrote: > > diff --git a/gcc/testsuite/g++.dg/musttail10.C > > b/gcc/testsuite/g++.dg/musttail10.C > > new file mode 100644 > > index ..9b7043b8a306 > > --- /dev/null > > +++ b/gcc/testsuite/

Re: [PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-15 Thread Jason Merrill
On 7/8/24 12:56 PM, Andi Kleen wrote: diff --git a/gcc/testsuite/g++.dg/musttail10.C b/gcc/testsuite/g++.dg/musttail10.C new file mode 100644 index ..9b7043b8a306 --- /dev/null +++ b/gcc/testsuite/g++.dg/musttail10.C @@ -0,0 +1,34 @@ +/* { dg-do compile { target { tail_call } } } */

[PATCH v9 08/10] Add tests for C/C++ musttail attributes

2024-07-08 Thread Andi Kleen
Some adopted from the existing C musttail plugin tests. gcc/testsuite/ChangeLog: * c-c++-common/musttail1.c: New test. * c-c++-common/musttail2.c: New test. * c-c++-common/musttail3.c: New test. * c-c++-common/musttail4.c: New test. * c-c++-common/musttail7