diff --git a/src/intel/compiler/brw_fs_generator.cpp b/src/intel/compiler/brw_fs_generator.cpp index 7fffdc2fc39..66aff2becc7 100644 --- a/src/intel/compiler/brw_fs_generator.cpp +++ b/src/intel/compiler/brw_fs_generator.cpp @@ -75,7 +75,7 @@ brw_reg_from_fs_reg(const struct intel_device_info *devinfo, fs_inst *inst, case FIXED_GRF: case IMM: assert(reg->offset == 0); - brw_reg = reg->as_brw_reg(); + brw_reg = *reg; break; case BAD_FILE: /* Probably unused. */ diff --git a/src/intel/compiler/brw_fs_validate.cpp b/src/intel/compiler/brw_fs_validate.cpp index 214a41c5238..3388918d62a 100644 --- a/src/intel/compiler/brw_fs_validate.cpp +++ b/src/intel/compiler/brw_fs_validate.cpp @@ -204,7 +204,7 @@ brw_fs_validate(const fs_visitor &s) */ if (intel_needs_workaround(devinfo, 14014617373) && inst->dst.is_accumulator() && - phys_subnr(devinfo, inst->dst.as_brw_reg()) == 0) { + phys_subnr(devinfo, inst->dst) == 0) { fsv_assert_eq(inst->dst.hstride, 1); } diff --git a/src/intel/compiler/brw_ir_fs.h b/src/intel/compiler/brw_ir_fs.h index f449487f5e0..51a90a6addc 100644 --- a/src/intel/compiler/brw_ir_fs.h +++ b/src/intel/compiler/brw_ir_fs.h @@ -36,20 +36,6 @@ public: fs_reg(struct ::brw_reg reg); fs_reg(enum brw_reg_file file, unsigned nr); fs_reg(enum brw_reg_file file, unsigned nr, enum brw_reg_type type); - - const brw_reg &as_brw_reg() const - { - assert(file == ARF || file == FIXED_GRF || file == IMM); - assert(offset == 0); - return static_cast(*this); - } - - brw_reg &as_brw_reg() - { - assert(file == ARF || file == FIXED_GRF || file == IMM); - assert(offset == 0); - return static_cast(*this); - } }; static inline fs_reg