[PATCH vkd3d v7 4/6] vkd3d-shader/hlsl: Perform a copy propagation pass.

Zebediah Figura zfigura at codeweavers.com
Fri Nov 19 11:41:31 CST 2021


On 11/19/21 11:39 AM, Matteo Bruni wrote:
> On Fri, Nov 19, 2021 at 6:36 PM Zebediah Figura <zfigura at codeweavers.com> wrote:
>>
>> On 11/19/21 10:12 AM, Matteo Bruni wrote:
>>> On Fri, Nov 19, 2021 at 4:55 PM Giovanni Mascellani
>>> <gmascellani at codeweavers.com> wrote:
>>>>
>>>> Hi,
>>>>
>>>> On 18/11/21 18:28, Matteo Bruni wrote:
>>>>>> +struct copy_propagation_value
>>>>>> +{
>>>>>> +    struct hlsl_ir_node *node;
>>>>>> +    unsigned int component;
>>>>>> +};
>>>>>> +
>>>>>> +struct copy_propagation_variable
>>>>>> +{
>>>>>> +    struct rb_entry entry;
>>>>>> +    struct hlsl_ir_var *var;
>>>>>> +    struct copy_propagation_value *values;
>>>>>> +};
>>>>>
>>>>> I still haven't gotten warm to these names. What about
>>>>> copy_propagation_definition (or just copy_propagation_def)?
>>>>
>>>> I don't understand why it's appropriate for this structure, but fine.
>>>
>>> It's in the sense of "definition of the current value", more or less
>>> like the "def" in use-def chains.
>>
>> I don't really like this, though, because both copy_propagation_variable
>> and copy_propagation_value are "def"s, but we need some way of
>> disambiguating what's being defined.
> 
> Okay, but I don't see how copy_propagation_variable is any better.
> 
> I'm fine with whatever, FWIW.

I suppose "copy_propagation_variable_def" is the correct solution :-)

Though it does get long. I would have abbreviated to "copy_prop_*" in 
the first place (and then "copy_prop_var_def" I guess.)



More information about the wine-devel mailing list