(gdb) bt
#0 0x0000555556964add in llvm::BasicBlock::getSinglePredecessor() const ()
#1 0x0000555557ca638d in (anonymous namespace)::EarlyCSE::run() ()
#2 0x0000555557ca91f3 in llvm::EarlyCSEPass::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
#3 0x00005555565b5f41 in llvm::detail::PassModel<llvm::Function, llvm::EarlyCSEPass, llvm::PreservedAnalyses, llvm::AnalysisManager<llvm::Function>>::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) (this=0x555561725dc0, IR=..., AM=...)
at /home/eslaught/sw/llvm-17/install/include/llvm/IR/PassManagerInternal.h:89
#4 0x0000555556af08d9 in llvm::PassManager<llvm::Function, llvm::AnalysisManager<llvm::Function>>::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
#5 0x00005555565601a1 in FunctionEmitter::emitConstantExpression (this=0x7fffffffd650, exp=0x7fffffffd7c0)
at /scratch/eslaught/terra/src/tcompiler.cpp:1979
#6 0x0000555556548112 in EmitConstantInitializer (CU=0x55556171f920, v=0x7fffffffd7c0) at /scratch/eslaught/terra/src/tcompiler.cpp:3554
#7 0x00005555565453d9 in CreateGlobalVariable (CU=0x55556171f920, global=0x7fffffffd900, name=0x7ffff79f4bc0 "<constant>")
at /scratch/eslaught/terra/src/tcompiler.cpp:1614
#8 0x0000555556545757 in EmitGlobalVariable (CU=0x55556171f920, global=0x7fffffffd900, name=0x7ffff79f4bc0 "<constant>")
at /scratch/eslaught/terra/src/tcompiler.cpp:1647
#9 0x000055555654852a in terra_compilationunitaddvalue (L=0x7ffff7a22380) at /scratch/eslaught/terra/src/tcompiler.cpp:3595
#10 0x000055555cbeed16 in lj_BC_FUNCC ()
#11 0x000055555cb9fadf in lua_pcall (L=<optimized out>, nargs=<optimized out>, nresults=<optimized out>, errfunc=<optimized out>)
at lj_api.c:1116
#12 0x0000555556541746 in docall (L=0x7ffff7a22380, narg=0, clear=0) at /scratch/eslaught/terra/src/main.cpp:339
#13 0x0000555556540d4f in main (argc=2, argv=0x7fffffffdbd8) at /scratch/eslaught/terra/src/main.cpp:119
Documenting the test failure so I can move on with the PR.
Failure looks like:
Backtrace: