This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 10/10] C11 threads: Move implementation to sysdeps/pthread
Adhemerval Zanella, le mar. 21 janv. 2020 09:39:31 -0300, a ecrit:
> LGTM with a small nit below.
>
> Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
>
> > --- /dev/null
> > +++ b/sysdeps/htl/thrd_current.c
> > @@ -0,0 +1,31 @@
> > +/* C11 threads current thread implementation.
> > + Copyright (C) 2018-2020 Free Software Foundation, Inc.
>
> I think this is new file.
Right, I did copy from another file, but nothing copyrightable was kept
from the original file.
> > diff --git a/sysdeps/mach/htl/thrd_yield.c b/sysdeps/mach/htl/thrd_yield.c
> > new file mode 100644
> > index 0000000000..09e218cf2e
> > --- /dev/null
> > +++ b/sysdeps/mach/htl/thrd_yield.c
> > @@ -0,0 +1,26 @@
> > +/* sched_yield -- yield the processor. Mach version.
> > + Copyright (C) 2000-2020 Free Software Foundation, Inc.
>
> I think this is new file (even though it is based on sched_yield).
Ditto, not really something copyrightable.
> > diff --git a/sysdeps/nptl/thrd_create.c b/sysdeps/nptl/thrd_create.c
> > new file mode 100644
> > index 0000000000..a9219db7bc
> > --- /dev/null
> > +++ b/sysdeps/nptl/thrd_create.c
> > @@ -0,0 +1,2 @@
> > +#define __pthread_create __pthread_create_2_1
> > +#include "../pthread/thrd_create.c"
>
> I think it better to include fall path instead of relative one.
Do you mean using #include_next ? That does not work, gcc warns that it's
discouraged in primary source file.
Samuel