On Sun, Apr 2, 2023 at 1:07 PM Jeff Law <jeffreya...@gmail.com> wrote:
>
>
>
> On 4/2/23 14:06, Andrew Pinski wrote:
> > On Sun, Apr 2, 2023 at 12:55 PM Jeff Law via Gcc-patches
> > <gcc-patches@gcc.gnu.org> wrote:
> >>
> >>
> >>
> >> On 3/31/23 12:44, Sam James wrote:
> >>>
> >>> Kito Cheng <kito.ch...@gmail.com> writes:
> >>>
> >>>> It's not the RISC-V part, so this requires a global maintainer there I 
> >>>> think?
> >>>>
> >>>
> >>> Someone able to look at the system.h bit? It should be trivial, there's
> >>> no uses left and it was added purely for a bug like this in the past
> >>> (see commit message).
> >> You assert that pthread.h is no longer used...  But ISTM you really need
> >> to go back to when the include was added, understand why it was added
> >> and explain why it is no longer needed.
> >
> > It was needed for the JIT front-end at the time used pthread_mutex_*
> > and pthread.h could use a poisoned identifier (I think it was calloc);
> > the INCLUDE_PTHREAD_H was added with r13-1350-g49d508065bdd36. The JIT
> > front-end moved to using C++11's mutex in r13-4164-g0a62889c7a155f and
> > moved away from using pthread.h but didn't remove INCLUDE_PTHREAD_H
> > support.
> >
> > I hope that help explains why it is no longer needed and how it became
> > even unused.
> SO I'm confused, what does this have to do with RISC-V?

So this was originally submitted with a patch against
gcc/config/riscv/genrvv-type-indexer.cc as it was noticed that during
the development of r13-6662-g0e6f87835ccabf, that INCLUDE_PTHREAD_H
became unused. The original patch against genrvv-type-indexer.cc was
to use INCLUDE_PTHREAD_H which was obviously wrong and then I helped
sam come up with the correct fix and we found that INCLUDE_PTHREAD_H
was not being used any more so Sam submitted a patch to remove it so
it would not be used accidently by anyone again.

Thanks,
Andrew

>
> jeff

Reply via email to