conda-forge / ctng-compilers-feedstock

A conda-smithy repository for ctng-compilers.
BSD 3-Clause "New" or "Revised" License
12 stars 28 forks source link

Debug build of libgomp? #94

Open timsnyder opened 2 years ago

timsnyder commented 2 years ago

Comment:

@conda-forge/ctng-compilers maintainers, I'm debugging a segfault issue in a simple libgomp program. I have a feeling -fsanitize=threads might help me pinpoint the issue. I'm reading to use TSan, libgomp needs to be recompiled with --disable-linux-futex (something you would never want to have in a production build).

Since I'm going to muck around with building this locally for myself, if you guys think it would be useful, I can do one of the following:

  1. PR changes to the buildscripts that make it 'easy' for someone to do a local build and document how to do it. I'm thinking that I possibly create a new variable in conda_build_config.yaml that we only put one value in and then
  2. Build out an alternate version of _openmp_mutex that can be installed with something like conda install openmp_mutex=*=*_gnu_nofutex and also probably do the same for the llvm openmp implementation because it has to be build explicilty with -DLIBOMP_TSAN_SUPPORT=ON. It might be better to just name them _gnu_debug and _llvm_debug.

I'm happy to just do my experiment of rebuilding libgomp for debug but since I'm doing the work, if others would find it useful, I'm willing to share. I don't think I've seen a cfep regarding debug builds of things but maybe I should go look again.