[llvm-bugs] [Bug 49366] New: CGRecordLayoutBuilder.cpp:747 assert triggered when capturing a VLA in a untied task

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Feb 26 08:30:53 PST 2021


https://bugs.llvm.org/show_bug.cgi?id=49366

            Bug ID: 49366
           Summary: CGRecordLayoutBuilder.cpp:747 assert triggered when
                    capturing a VLA in a untied task
           Product: OpenMP
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Clang Compiler Support
          Assignee: unassignedclangbugs at nondot.org
          Reporter: rpenacob at bsc.es
                CC: llvm-bugs at lists.llvm.org

The following code triggers the assert
https://github.com/llvm/llvm-project/blob/a01a406bba8ac624a876f8d5720e1d4949a5b0fa/clang/lib/CodeGen/CGRecordLayoutBuilder.cpp#L747 

void foo(int n) {
    #pragma omp task untied
    {
        int array[n];
    }
}

Assertion `Prior->FD->hasAttr<NoUniqueAddressAttr>() && "should not have reused
this field's tail padding"' failed.
PLEASE submit a bug report to mailto:pm-tools at bsc.es and include the crash
backtrace, preprocessed source, and associated run script.
Stack dump:
0.      Program arguments: /home/user/llvm-mono/build/bin/clang-13 -cc1 -triple
x86_64-unknown-linux-gnu -emit-obj -mrelax-all --mrelax-relocations
-disable-free -main-file-name t1.c -mrelocation-model static
-mframe-pointer=all -fmath-errno -fno-rounding-math -mconstructor-aliases
-munwind-tables -target-cpu x86-64 -tune-cpu generic -fno-split-dwarf-inlining
-debugger-tuning=gdb -fcoverage-compilation-dir=/home/user/tmp -resource-dir
/home/user/llvm-mono/build/lib/clang/13.0.0 -internal-isystem
/usr/local/include -internal-isystem
/home/user/llvm-mono/build/lib/clang/13.0.0/include -internal-externc-isystem
/usr/include/x86_64-linux-gnu -internal-externc-isystem /include
-internal-externc-isystem /usr/include -fdebug-compilation-dir=/home/user/tmp
-ferror-limit 19 -fopenmp -fopenmp-cuda-parallel-target-regions
-fgnuc-version=4.2.1 -fcolor-diagnostics -faddrsig -o /tmp/t1-71672c.o -x c
t1.c
1.      <eof> parser at end of file
2.      Per-file LLVM IR generation
3.      t1.c:1:6: Generating code for declaration 'foo'

Kind regards,

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210226/25d9203a/attachment.html>


More information about the llvm-bugs mailing list