[Mesa-dev] [PATCH 01/13] i965: Use immediate storage in brw_reg for visitor regs.

Chris Forbes chrisf at ijw.co.nz
Mon Jun 30 14:46:53 PDT 2014


On Tue, Jul 1, 2014 at 9:40 AM, Matt Turner <mattst88 at gmail.com> wrote:
>
>  /** Fixed brw_reg. */
> @@ -452,7 +452,7 @@ fs_reg::equals(const fs_reg &r) const
>             memcmp(&fixed_hw_reg, &r.fixed_hw_reg,
>                    sizeof(fixed_hw_reg)) == 0 &&
>             stride == r.stride &&
> -           imm.u == r.imm.u);
> +           fixed_hw_reg.dw1.ud == r.fixed_hw_reg.dw1.ud);

This check is redundant with the memcmp above

>
>  src_reg::src_reg(struct brw_reg reg)
> @@ -334,7 +334,7 @@ src_reg::equals(const src_reg &r) const
>            !reladdr && !r.reladdr &&
>            memcmp(&fixed_hw_reg, &r.fixed_hw_reg,
>                   sizeof(fixed_hw_reg)) == 0 &&
> -          imm.u == r.imm.u);
> +          fixed_hw_reg.dw1.ud == r.fixed_hw_reg.dw1.ud);

Ditto


More information about the mesa-dev mailing list