[Beignet] [PATCH 2/4] GBE: Fix the immediate data type
Zhigang Gong
zhigang.gong at linux.intel.com
Tue May 12 19:00:18 PDT 2015
LGTM, will push latter. Thanks.
On Thu, Apr 30, 2015 at 11:49:47AM +0800, Ruiling Song wrote:
> Signed-off-by: Ruiling Song <ruiling.song at intel.com>
> ---
> backend/src/ir/immediate.hpp | 12 ++++++------
> backend/src/llvm/llvm_gen_backend.cpp | 2 +-
> 2 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/backend/src/ir/immediate.hpp b/backend/src/ir/immediate.hpp
> index 6b27e8b..ff37a29 100644
> --- a/backend/src/ir/immediate.hpp
> +++ b/backend/src/ir/immediate.hpp
> @@ -130,11 +130,11 @@ namespace ir {
> DECL_CONSTRUCTOR(int8_t, s8, TYPE_S8)
> DECL_CONSTRUCTOR(uint8_t, u8, TYPE_U8)
> DECL_CONSTRUCTOR(int16_t, s16, TYPE_S16)
> - DECL_CONSTRUCTOR(uint16_t, u16, TYPE_S16)
> + DECL_CONSTRUCTOR(uint16_t, u16, TYPE_U16)
> DECL_CONSTRUCTOR(int32_t, s32, TYPE_S32)
> - DECL_CONSTRUCTOR(uint32_t, u32, TYPE_S32)
> + DECL_CONSTRUCTOR(uint32_t, u32, TYPE_U32)
> DECL_CONSTRUCTOR(int64_t, s64, TYPE_S64)
> - DECL_CONSTRUCTOR(uint64_t, u64, TYPE_S64)
> + DECL_CONSTRUCTOR(uint64_t, u64, TYPE_U64)
> DECL_CONSTRUCTOR(float, f32, TYPE_FLOAT)
> DECL_CONSTRUCTOR(double, f64, TYPE_DOUBLE)
> #undef DECL_CONSTRUCTOR
> @@ -155,11 +155,11 @@ namespace ir {
> DECL_CONSTRUCTOR(int8_t, s8, TYPE_S8, elemNum)
> DECL_CONSTRUCTOR(uint8_t, u8, TYPE_U8, elemNum)
> DECL_CONSTRUCTOR(int16_t, s16, TYPE_S16, elemNum)
> - DECL_CONSTRUCTOR(uint16_t, u16, TYPE_S16, elemNum)
> + DECL_CONSTRUCTOR(uint16_t, u16, TYPE_U16, elemNum)
> DECL_CONSTRUCTOR(int32_t, s32, TYPE_S32, elemNum)
> - DECL_CONSTRUCTOR(uint32_t, u32, TYPE_S32, elemNum)
> + DECL_CONSTRUCTOR(uint32_t, u32, TYPE_U32, elemNum)
> DECL_CONSTRUCTOR(int64_t, s64, TYPE_S64, elemNum)
> - DECL_CONSTRUCTOR(uint64_t, u64, TYPE_S64, elemNum)
> + DECL_CONSTRUCTOR(uint64_t, u64, TYPE_U64, elemNum)
> DECL_CONSTRUCTOR(float, f32, TYPE_FLOAT, elemNum)
> DECL_CONSTRUCTOR(double, f64, TYPE_DOUBLE, elemNum)
> #undef DECL_CONSTRUCTOR
> diff --git a/backend/src/llvm/llvm_gen_backend.cpp b/backend/src/llvm/llvm_gen_backend.cpp
> index f46bc79..6bde7bf 100644
> --- a/backend/src/llvm/llvm_gen_backend.cpp
> +++ b/backend/src/llvm/llvm_gen_backend.cpp
> @@ -3519,7 +3519,7 @@ namespace gbe
> if (step != 0) {
> ir::ImmediateIndex stepImm = ctx.newIntegerImmediate(step, ir::TYPE_U32);
> ir::Register stepReg = ctx.reg(ctx.getPointerFamily());
> - ctx.LOADI(ir::TYPE_S32, stepReg, stepImm);
> + ctx.LOADI(ir::TYPE_U32, stepReg, stepImm);
> ctx.ADD(ir::TYPE_U32, stack, stack, stepReg);
> ctx.getFunction().pushStackSize(step);
> }
> --
> 2.3.6
>
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/beignet
More information about the Beignet
mailing list