Short-circuit if the store has no writes.

This commit is contained in:
Dr. Chat 2016-02-21 16:30:57 -06:00
parent d2e3b5533d
commit fa3ca4a5d7
1 changed files with 4 additions and 0 deletions

View File

@ -1289,6 +1289,10 @@ void SpirvShaderTranslator::StoreToResult(Id source_value_id,
return;
}
if (!result.has_any_writes()) {
return;
}
Id storage_pointer = 0;
Id storage_type = vec4_float_type_;
spv::StorageClass storage_class;