ned14/llfio

GCC12 / ArchLinux: libdispatch error

jcelerier opened this issue · 2 comments

here's how the issue manifests:

Dans le fichier inclus depuis /usr/include/dispatch/dispatch.h:32,
                 depuis /home/jcelerier/projets/packages/aur/ossia-score/src/3rdparty/llfio/include/llfio/v2.0/detail/impl/dynamic_thread_pool_group.ipp:52,
                 depuis /home/jcelerier/projets/packages/aur/ossia-score/src/3rdparty/llfio/include/llfio/v2.0/dynamic_thread_pool_group.hpp:526,
                 depuis /home/jcelerier/projets/packages/aur/ossia-score/src/3rdparty/llfio/include/llfio/v2.0/llfio.hpp:67,
                 depuis /home/jcelerier/projets/packages/aur/ossia-score/src/3rdparty/llfio/include/llfio/llfio.hpp:18,
                 depuis /home/jcelerier/projets/packages/aur/ossia-score/src/3rdparty/llfio/include/llfio.hpp:1,
                 depuis /home/jcelerier/projets/packages/aur/ossia-score/src/src/lib/score/tools/RecursiveWatch.cpp:33,
                 depuis /home/jcelerier/projets/packages/aur/ossia-score/src/build/src/lib/CMakeFiles/score_lib_base.dir/Unity/unity_0_cxx.cxx:139:
/usr/include/os/generic_unix_base.h:97:54: erreur: missing binary operator before token "("
   97 | #if __has_feature(objc_fixed_enum) || __has_extension(cxx_strong_enums)
      |                                                      ^

Well, libdispatch requires clang on linux (see their docs for further info)

ned14 commented

It didn't use to be the case that libdispatch required GCC, at least for header consumption. That error message above is definitely a clang-ism though. I'd call that a bug upstream.

Re: the proposed fix, the native Linux backend is not fully debugged. It works fine 99.999% of the time. Frustratingly, there is some very rare race condition in it. Due to my endemic lack of free non-work time, I have not had the time to get it finished. That's why the choice between GCD and the native backend on Linux was somewhat ambivalent.

I can tell you that the libdispatch port to Linux also has a rare race condition :) so my backend is in some ways superior in that sense, so your proposed fix to make the choice less ambivalent I think is a good one.

I'm currently on vacation, and next few weeks after I return I expect to either go onto a four day work week or become unemployed. In either case I expect to finally start addressing these long standing backlogs of non-work work which have been growing since covid.