This repository was archived by the owner on Nov 1, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 506
This repository was archived by the owner on Nov 1, 2020. It is now read-only.
[Linux] crash upon generating debug symbols #7907
Copy link
Copy link
Open
Description
Software version:
ILCompiler 1.0.0-alpha-28407-01
.NET Core 3.1
Ubuntu 18.04 x64 (native/VirtualBox)
Symptoms:
Segmentation fault upon generating debug symbols.
Compiling [S.P.TypeLoader]Internal.Runtime.TypeLoader.ConstrainedCallSupport+GenericConstrainedCallDesc+<>c..ctor()...
Compiling [S.P.TypeLoader]Internal.Runtime.TypeLoader.ConstrainedCallSupport+NonGenericConstrainedCallDesc+<>c..ctor()...
Compiling [S.P.TypeLoader]Internal.Runtime.TypeLoader.ConstrainedCallSupport.GetThunkThatDereferencesThisPointerAndTailCallsTarget(native int)...
Segmentation fault (core dumped)
gdb output:
Thread 1 "ilc" received signal SIGSEGV, Segmentation fault.
DwarfMemberFunctionIdTypeInfo::DumpTypes (this=<optimized out>, TypeBuilder=<optimized out>, Streamer=<optimized out>, TypeSection=<optimized out>, StrSection=<optimized out>)
at /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfTypeBuilder.cpp:559
559 in /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfTypeBuilder.cpp
(gdb) where
#0 DwarfMemberFunctionIdTypeInfo::DumpTypes (this=<optimized out>, TypeBuilder=<optimized out>, Streamer=<optimized out>, TypeSection=<optimized out>, StrSection=<optimized out>)
at /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfTypeBuilder.cpp:559
#1 0x00007fff5e289a76 in DwarfClassTypeInfo::DumpTypes (this=<optimized out>, TypeBuilder=<optimized out>, Streamer=<optimized out>, TypeSection=<optimized out>, StrSection=<optimized out>)
at /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfTypeBuilder.cpp:375
#2 0x00007fff5e288c2b in DwarfInfo::Dump (this=0x83d2870, TypeBuilder=<optimized out>, Streamer=0x1a0dd30, TypeSection=0x18ffb18, StrSection=0x1901ee0)
at /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfTypeBuilder.cpp:34
#3 0x00007fff5e289ac5 in DwarfClassTypeInfo::Dump (this=0x83d2870, TypeBuilder=0x1a0cb00, Streamer=0x1a0dd30, TypeSection=0x18ffb18, StrSection=0x1901ee0)
at /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfTypeBuilder.cpp:384
#4 0x00007fff5e28a287 in UserDefinedDwarfTypesBuilder::EmitTypeInformation (this=<optimized out>, TypeSection=<optimized out>, StrSection=<optimized out>)
at /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfTypeBuilder.cpp:641
#5 0x00007fff5e28fc38 in DwarfGen::Finish (this=0x1a2bf10) at /root/corert_3112221/bin/obj/Native/Linux.x64.Release/ObjWriter/llvmCap/LLVM-prefix/src/LLVM/tools/ObjWriter/debugInfo/dwarf/dwarfGen.cpp:1038
Expected behavior:
The compiler succeeds and the executable with proper debug symbols is generated.
Workaround:
Specify <DebugSymbols>false</DebugSymbols> and <DebugType>none</DebugType> in your project configuration file to avoid executing the problematic code path, e.g.:
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<DebugSymbols>false</DebugSymbols>
<DebugType>none</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
</PropertyGroup>
DjArt
Metadata
Metadata
Assignees
Labels
No labels