Bug 23564 – [REG 2.099.0] SIGSEGV during compilation

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2022-12-16T21:38:54Z
Last change time
2023-01-01T06:25:13Z
Keywords
pull
Assigned to
No Owner
Creator
petr.silhavy

Attachments

IDFilenameSummaryContent-TypeSize
1864fix.diffno more SIGSEGV, same test results heretext/plain723

Comments

Comment #0 by petr.silhavy — 2022-12-16T21:38:54Z
linux 6.0.7, DMD64 D Compiler v2.101.1 and 2.101.0 code to reproduce (no small sample) : git clone https://git.code.sf.net/p/vs4/code vs4 cd vs4 meson setup --native-file dmd.ini Builddir cd Builddir ninja SIGSEGV while compiling mm/block.d gdc (GCC) 12.2.0 and LDC - the LLVM D compiler (1.30.0) are affected too. gdb session : gdb /usr/bin/dmd GNU gdb (GDB) 12.1 ... (gdb) r -I=libvs4.a.p -I=. -I=.. -I=grammar -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/dmd/phobos -I/m/sw/bug/vs4 -I/m/sw/bug/vs4/grammar -I/m/sw/bug/vs4/tree -I/m/sw/bug/vs4/mm -I/m/sw/bug/vs4/tools -I/m/sw/bug/vs4/B -I/m/sw/bug/vs4/B/grammar -color=on -wi -g -debug -Xcc=-fuse-ld=mold -color=off -gdwarf=3 -version=alpha -mcpu=native -gs -gf -vcolumns -verror-style=gnu -fPIC -makedeps=libvs4.a.p/mm_block.d.o.deps -of=libvs4.a.p/mm_block.d.o -c ../mm/block.d ... Starting program: /usr/bin/dmd -I=libvs4.a.p -I=. -I=.. -I=grammar -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/dmd/phobos -I/m/sw/bug/vs4 -I/m/sw/bug/vs4/grammar -I/m/sw/bug/vs4/tree -I/m/sw/bug/vs4/mm -I/m/sw/bug/vs4/tools -I/m/sw/bug/vs4/B -I/m/sw/bug/vs4/B/grammar -color=on -wi -g -debug -Xcc=-fuse-ld=mold -color=off -gdwarf=3 -version=alpha -mcpu=native -gs -gf -vcolumns -verror-style=gnu -fPIC -makedeps=libvs4.a.p/mm_block.d.o.deps -of=libvs4.a.p/mm_block.d.o -c ../mm/block.d [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". Program received signal SIGSEGV, Segmentation fault. 0x0000555555841262 in ExpressionSemanticVisitor::visit(NewExp*) () (gdb) bt #0 0x0000555555841262 in ExpressionSemanticVisitor::visit(NewExp*) () #1 0x000055555585876f in ExpressionSemanticVisitor::visit(AssignExp*) () #2 0x000055555573691a in StatementSemanticVisitor::visit(ExpStatement*) () #3 0x0000555555736eac in StatementSemanticVisitor::visit(CompoundStatement*) () #4 0x00005555556c05a8 in Semantic3Visitor::visit(FuncDeclaration*) () #5 0x00005555556be28a in Semantic3Visitor::visit(AggregateDeclaration*) () #6 0x00005555556c438a in Semantic3Visitor::visit(Module*) () #7 0x00005555558f8de4 in dmd.mars.tryMain(ulong, const(char)**, ref dmd.globals.Param) () #8 0x0000555555905c71 in D main ()
Comment #1 by petr.silhavy — 2022-12-17T13:55:42Z
Created attachment 1864 no more SIGSEGV, same test results here
Comment #2 by ibuclaw — 2022-12-17T19:09:40Z
Reduced test --- class BlockHeader { this() { new FreeList; } } class RBTree { class FreeList { } void _each_reverse( ) { } } alias FreeList = RBTree.FreeList; ---
Comment #3 by ibuclaw — 2022-12-17T20:36:57Z
Comment #4 by dlang-bot — 2022-12-17T21:00:16Z
@ibuclaw created dlang/dmd pull request #14709 "fix Issue 23564 - [REG 2.099.0] SIGSEGV during compilation" fixing this issue: - fix Issue 23564 - [REG 2.099.0] SIGSEGV during compilation https://github.com/dlang/dmd/pull/14709
Comment #5 by dlang-bot — 2022-12-18T13:41:44Z
dlang/dmd pull request #14709 "fix Issue 23564 - [REG 2.099.0] SIGSEGV during compilation" was merged into stable: - dafdd8d7a0c9f7b250c4fe007441f40502e219c2 by Iain Buclaw: fix Issue 23564 - [REG 2.099.0] SIGSEGV during compilation https://github.com/dlang/dmd/pull/14709
Comment #6 by dlang-bot — 2023-01-01T06:25:13Z
dlang/dmd pull request #14765 "merge stable" was merged into master: - 344694551cb79ca5e2c180f8c9f3e5f2963e3043 by Iain Buclaw: fix Issue 23564 - [REG 2.099.0] SIGSEGV during compilation https://github.com/dlang/dmd/pull/14765