info->images_writemask = info->images_declared;
else
info->images_writemask |= 1 << src->Register.Index;
+ } else if (src->Register.File == TGSI_FILE_BUFFER) {
+ if (src->Register.Indirect)
+ info->shader_buffers_atomic = info->shader_buffers_declared;
+ else
+ info->shader_buffers_atomic |= 1 << src->Register.Index;
+ }
+ } else {
+ if (src->Register.File == TGSI_FILE_BUFFER) {
+ if (src->Register.Indirect)
+ info->shader_buffers_load = info->shader_buffers_declared;
+ else
+ info->shader_buffers_load |= 1 << src->Register.Index;
}
}
}
info->images_writemask = info->images_declared;
else
info->images_writemask |= 1 << dst->Register.Index;
+ } else if (dst->Register.File == TGSI_FILE_BUFFER) {
+ if (dst->Register.Indirect)
+ info->shader_buffers_store = info->shader_buffers_declared;
+ else
+ info->shader_buffers_store |= 1 << dst->Register.Index;
}
}
}
info->const_buffers_declared |= 1u << buffer;
} else if (file == TGSI_FILE_IMAGE) {
info->images_declared |= 1u << reg;
+ } else if (file == TGSI_FILE_BUFFER) {
+ info->shader_buffers_declared |= 1u << reg;
} else if (file == TGSI_FILE_INPUT) {
info->input_semantic_name[reg] = (ubyte) semName;
info->input_semantic_index[reg] = (ubyte) semIndex;
* Bitmask indicating which declared image is a buffer.
*/
unsigned images_buffers;
+ unsigned shader_buffers_declared; /**< bitmask of declared shader buffers */
+ unsigned shader_buffers_load; /**< bitmask of shader buffers using loads */
+ unsigned shader_buffers_store; /**< bitmask of shader buffers using stores */
+ unsigned shader_buffers_atomic; /**< bitmask of shader buffers using atomics */
/**
* Bitmask indicating which register files are accessed with
* indirect addressing. The bits are (1 << TGSI_FILE_x), etc.