For the below case, Clang seems to regress (asserts) after https://github.com/llvm/llvm-project/commit/715f7a1bd058c64a39cc4773114dfb46ae8cc8a3
struct FOO { static const int vec_align_bytes = 32; void foo() { alignas(vec_align_bytes) double a; #pragma omp parallel // I've tried some other directives like master and target and all having same assertion failure a++; } };
We can avoid the assertion failure by either removing alignas or
OpenMP directive in the above code. It is apparent the usage of alignas
is resonable so the issue might be stem from OpenMP code.
In addition, replacing OpenMP directive with some arbitrary Clang directive
can avoid the assertion failure.