On 2017-06-30 at 15:36 +0300, Ivan Shapovalov wrote: > On 2017-06-30 at 01:46 +0000, Wang, Rander wrote: > > Hi, > > > > The abs of UD has to be done if it is encoded in instruction no > > matter it make sense or not. > > And I have discussed with my collage and refine it. > > First we inspect the HW behavior of ABS(UD), -(UD) and find > > that > > ABS(UD) = UD, > > -(UD) = the result of -(UD) on CPU. > > > > So the abs calculation can be removed and this will make it > > compiled pass. > > > > Rander > > Hi, > > OK, but what about reading from .value.ud if the corresponding .type > is > not GEN_TYPE_UD? Is this a concern? Which operand type combinations > are > possible? >
I mean, due to an || in the conditional it looks like it is possible for either of the operands to not be a GEN_TYPE_D. Suppose the first operand is a signed dword (GEN_TYPE_D) that holds a negative value and has the ABS flag. In this case the new code will yield a significantly wrong result. Is this possible? -- Ivan Shapovalov / intelfx /
signature.asc
Description: This is a digitally signed message part
_______________________________________________ Beignet mailing list Beignet@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/beignet