Comment out unimplemented check
codespell / Check for spelling errors (push) Successful in 11s Details
codespell / Check for spelling errors (pull_request) Successful in 10s Details
suyu-ci / Check REUSE Specification (pull_request) Successful in 10s Details
suyu verify / Verify Format (pull_request) Successful in 2m23s Details
suyu verify / test build (linux-fresh, clang) (pull_request) Successful in 10m19s Details
suyu verify / android (pull_request) Successful in 16m59s Details
suyu verify / test build (linux-fresh, linux) (pull_request) Successful in 18m56s Details

In my testing on macOS, MK8 sometimes crashed at this function, giving a void type instead of u32.
I've temporarily commented this out until (if) this is implemented and added a check for if it is implemented
This commit is contained in:
Exverge 2024-03-30 19:34:32 -04:00
parent a3c8b29607
commit 89468f90a2
Signed by: Exverge
GPG Key ID: 19AAFC0AC6A9B35A
1 changed files with 10 additions and 4 deletions

View File

@ -196,8 +196,11 @@ Id Texture(EmitContext& ctx, IR::TextureInstInfo info, [[maybe_unused]] const IR
}
Id TextureImage(EmitContext& ctx, IR::TextureInstInfo info, const IR::Value& index) {
if (!index.IsImmediate() || index.U32() != 0) {
throw NotImplementedException("Indirect image indexing");
// if (!index.IsImmediate() || index.Type() != Shader::IR::Type::U32 || index.U32() != 0) {
// throw NotImplementedException("Indirect image indexing");
// }
if (index.Type() != Shader::IR::Type::U32) {
LOG_WARNING(Shader_SPIRV, "Non-U32 type provided as index: {}", index.Type());
}
if (info.type == TextureType::Buffer) {
const TextureBufferDefinition& def{ctx.texture_buffers.at(info.descriptor_index)};
@ -215,8 +218,11 @@ Id TextureImage(EmitContext& ctx, IR::TextureInstInfo info, const IR::Value& ind
}
std::pair<Id, bool> Image(EmitContext& ctx, const IR::Value& index, IR::TextureInstInfo info) {
if (!index.IsImmediate() || index.U32() != 0) {
throw NotImplementedException("Indirect image indexing");
// if (!index.IsImmediate() || index.Type() != Shader::IR::Type::U32 || index.U32() != 0) {
// throw NotImplementedException("Indirect image indexing");
// }
if (index.Type() != Shader::IR::Type::U32) {
LOG_WARNING(Shader_SPIRV, "Non-U32 type provided as index: {}", index.Type());
}
if (info.type == TextureType::Buffer) {
const ImageBufferDefinition def{ctx.image_buffers.at(info.descriptor_index)};