From: Henri Verbeet Subject: Re: [PATCH vkd3d 4/5] vkd3d-shader: Return the register space of each used UAV and UAV counter in vkd3d_shader_scan_info. Message-Id: Date: Fri, 5 Jun 2020 01:18:58 +0430 In-Reply-To: <20200604014915.986832-4-zfigura@codeweavers.com> References: <20200604014915.986832-1-zfigura@codeweavers.com> <20200604014915.986832-4-zfigura@codeweavers.com> On Thu, 4 Jun 2020 at 06:20, Zebediah Figura wrote: > +struct vkd3d_uav_scan_info > +{ > + unsigned int register_space, register_index, id; > + bool counter, read; > +}; > + It seems tempting to store the "counter" and "read" fields as a "flags" field instead. For what it's worth, note that I also have patches in this area in my own tree; we'll need to store information about the other descriptor types in the vkd3d_shader_scan_info at some point as well. I'm not sure whether there's a use for the "id" field in the public API. I'm inclined to say lookup by ID should go through the "symbol_table" tree. Perhaps more important is the question how this would work with ranges larger than a single descriptor. I.e., how would for example a "dcl_uav_raw u0[1:3], ..." declaration be represented in the vkd3d_shader_scan_info structure?