Program received signal SIGSEGV, Segmentation fault.
0x0000555555daae30 in
spvtools::fuzz::FuzzerPassInterchangeZeroLikeConstants::FindOrCreateToggledConstant
at source/fuzz/fuzzer_pass_interchange_zero_like_constants.cpp:41
Debugging spirv-fuzz, I found that the segmentation fault is caused because FindDeclaredConstant returns a null pointer that is used to call a function.
auto constant = GetIRContext()->get_constant_mgr()->FindDeclaredConstant(declaration->result_id());
if (!constant->IsZero()) {
return 0;
}
declaration is %10 = OpSpecConstant %5 1, but opt::analysis::ConstantManager does not support OpSpecConstant.