[libcxx-commits] [PATCH] D86704: [libcxx] Add testing infrastructure for EXTERNAL_THREAD_API mode

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Sep 30 10:00:55 PDT 2020


ldionne added a comment.

In D86704#2303842 <https://reviews.llvm.org/D86704#2303842>, @miyuki wrote:

>> Given this new setup where build bots are checked into the repo, I think adding a bot that test this configuration would be a good way of making sure this doesn't regress. What do you think?
>
> Yes, setting up a build bot is part of my original plan. I will be on holiday for the next two weeks, but I do plan to continue working on this after returning.
>
>> Is there a reason why your platform can't simply provide the pthread or the C11 threading APIs, and libc++ has to provide this bridge instead?
>
> The original intent of the external threading API was to make it usable with bare-metal real-time OS-es which tend not to have POSIX or POSIX-like APIs. For example, __libcpp_mutex_t can include the OS structure representing a mutex, instead of allocating it elsewhere.

Right -- my question is why is it not possible for these bare-metal real-time OS-es to implement these APIs? Or, alternatively, for whoever's trying to build libc++ on top of these systems to provide the right API as-if the system provided it. Doesn't this seem like a better solution than defining customization points at the libc++ level?

I'm not trying to push back -- this has been supported and we can continue supporting it, and I'm grateful for your desire to improve the test coverage in that area. However, I'm genuinely interested to find out whether/why this is the best solution.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D86704/new/

https://reviews.llvm.org/D86704



More information about the libcxx-commits mailing list