ACO: Compiler segfault on 8/16-bit integers.
This FOZ archive segfaults on ACO using master on a 5700xt with this workaround applied to get past other segfaults: !4757 (merged). LLVM works fine.
Backtrace:
vec1 8 ssa_597 = mov ssa_287.xfossilize-replay: ../src/amd/compiler/aco_instruction_selection.cpp:1065: void aco::{anonymous}::visit_alu_instr(aco::isel_context*, nir_alu_instr*): Assertion `!"Should have been lowered to scalar."' failed.
Thread 20 "fossilize-repla" received signal SIGABRT, Aborted.
[Switching to Thread 0x7fffc1ffb700 (LWP 19749)]
0x00007ffff7a852e5 in raise () from /usr/lib/libc.so.6
(gdb) bt
#0 0x00007ffff7a852e5 in raise () from /usr/lib/libc.so.6
#1 0x00007ffff7a6e853 in abort () from /usr/lib/libc.so.6
#2 0x00007ffff7a6e727 in __assert_fail_base.cold () from /usr/lib/libc.so.6
#3 0x00007ffff7a7d936 in __assert_fail () from /usr/lib/libc.so.6
#4 0x00007ffff74278be in aco::(anonymous namespace)::visit_alu_instr (ctx=0x7fffc1ff55f0, instr=0x7fff982e4710)
at ../src/amd/compiler/aco_instruction_selection.cpp:1065
#5 0x00007ffff746bb20 in aco::(anonymous namespace)::visit_block (ctx=0x7fffc1ff55f0, block=0x7fff980a89f0) at ../src/amd/compiler/aco_instruction_selection.cpp:9048
#6 0x00007ffff746e349 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff980a8730) at ../src/amd/compiler/aco_instruction_selection.cpp:9576
#7 0x00007ffff746e17c in aco::(anonymous namespace)::visit_if (ctx=0x7fffc1ff55f0, if_stmt=0x7fff980a86b0) at ../src/amd/compiler/aco_instruction_selection.cpp:9529
#8 0x00007ffff746e369 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff980a65c0) at ../src/amd/compiler/aco_instruction_selection.cpp:9579
#9 0x00007ffff746e1d6 in aco::(anonymous namespace)::visit_if (ctx=0x7fffc1ff55f0, if_stmt=0x7fff980a6560) at ../src/amd/compiler/aco_instruction_selection.cpp:9559
#10 0x00007ffff746e369 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff980d0a00) at ../src/amd/compiler/aco_instruction_selection.cpp:9579
#11 0x00007ffff746e20f in aco::(anonymous namespace)::visit_if (ctx=0x7fffc1ff55f0, if_stmt=0x7fff980d0980) at ../src/amd/compiler/aco_instruction_selection.cpp:9562
#12 0x00007ffff746e369 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff98094f30) at ../src/amd/compiler/aco_instruction_selection.cpp:9579
#13 0x00007ffff746e20f in aco::(anonymous namespace)::visit_if (ctx=0x7fffc1ff55f0, if_stmt=0x7fff98094eb0) at ../src/amd/compiler/aco_instruction_selection.cpp:9562
#14 0x00007ffff746e369 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff98093f40) at ../src/amd/compiler/aco_instruction_selection.cpp:9579
#15 0x00007ffff746e1d6 in aco::(anonymous namespace)::visit_if (ctx=0x7fffc1ff55f0, if_stmt=0x7fff98093ee0) at ../src/amd/compiler/aco_instruction_selection.cpp:9559
#16 0x00007ffff746e369 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff98064240) at ../src/amd/compiler/aco_instruction_selection.cpp:9579
#17 0x00007ffff746c3e5 in aco::(anonymous namespace)::visit_loop (ctx=0x7fffc1ff55f0, loop=0x7fff98064220) at ../src/amd/compiler/aco_instruction_selection.cpp:9152
#18 0x00007ffff746e395 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff98024170) at ../src/amd/compiler/aco_instruction_selection.cpp:9583
#19 0x00007ffff746c3e5 in aco::(anonymous namespace)::visit_loop (ctx=0x7fffc1ff55f0, loop=0x7fff98024150) at ../src/amd/compiler/aco_instruction_selection.cpp:9152
#20 0x00007ffff746e395 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff98076290) at ../src/amd/compiler/aco_instruction_selection.cpp:9583
#21 0x00007ffff746c3e5 in aco::(anonymous namespace)::visit_loop (ctx=0x7fffc1ff55f0, loop=0x7fff98076270) at ../src/amd/compiler/aco_instruction_selection.cpp:9152
#22 0x00007ffff746e395 in aco::(anonymous namespace)::visit_cf_list (ctx=0x7fffc1ff55f0, list=0x7fff98194da8) at ../src/amd/compiler/aco_instruction_selection.cpp:9583
#23 0x00007ffff7475902 in aco::select_program (program=0x7fff984161a0, shader_count=1, shaders=0x7fffc1ff71c8, config=0x7fffc1ff63b0, args=0x7fffc1ff6670)
at ../src/amd/compiler/aco_instruction_selection.cpp:10688
#24 0x00007ffff732f0ff in aco_compile_shader (shader_count=1, shaders=0x7fffc1ff71c8, binary=0x7fffc1ff6660, args=0x7fffc1ff6670)
at ../src/amd/compiler/aco_interface.cpp:89
#25 0x00007ffff726c808 in shader_variant_compile (device=0x555555cf3bf0, module=0x7fff9c0a5510, shaders=0x7fffc1ff71c8, shader_count=1, stage=MESA_SHADER_COMPUTE,
info=0x7fffc1ff9f00, options=0x7fffc1ff6e00, gs_copy_shader=false, keep_shader_info=false, keep_statistic_info=false, binary_out=0x7fffc1ff71f8)
at ../src/amd/vulkan/radv_shader.c:1134
#26 0x00007ffff726cc43 in radv_shader_variant_compile (device=0x555555cf3bf0, module=0x7fff9c0a5510, shaders=0x7fffc1ff71c8, shader_count=1, layout=0x555555c1ec80,
key=0x7fffc1ff84f0, info=0x7fffc1ff9f00, keep_shader_info=false, keep_statistic_info=false, binary_out=0x7fffc1ff71f8) at ../src/amd/vulkan/radv_shader.c:1200
#27 0x00007ffff725ac61 in radv_create_shaders (pipeline=0x7fff9808b840, device=0x555555cf3bf0, cache=0x0, key=0x7fffc1ffa4f0, pStages=0x7fffc1ffa490, flags=0,
pipeline_feedback=0x0, stage_feedbacks=0x7fffc1ffa4c0) at ../src/amd/vulkan/radv_pipeline.c:3072
#28 0x00007ffff7260d09 in radv_compute_pipeline_create (_device=0x555555cf3bf0, _cache=0x0, pCreateInfo=0x7fff98306178, pAllocator=0x0, pPipeline=0x7fffd8002350)
at ../src/amd/vulkan/radv_pipeline.c:5437
#29 0x00007ffff7260e86 in radv_CreateComputePipelines (_device=0x555555cf3bf0, pipelineCache=0x0, count=1, pCreateInfos=0x7fff98306178, pAllocator=0x0,
pPipelines=0x7fffd8002350) at ../src/amd/vulkan/radv_pipeline.c:5468