Commit 80a8b9a9 authored by Richard Henderson's avatar Richard Henderson

tcg: Fix types in tcg_regset_{set,reset}_reg

There was a potential problem here with an ILP32 host
with 64 host registers.
Signed-off-by: 's avatarRichard Henderson <richard.henderson@linaro.org>
parent f46934df
......@@ -186,9 +186,9 @@ typedef enum TCGOpcode {
NB_OPS,
} TCGOpcode;
#define tcg_regset_set_reg(d, r) (d) |= 1L << (r)
#define tcg_regset_reset_reg(d, r) (d) &= ~(1L << (r))
#define tcg_regset_test_reg(d, r) (((d) >> (r)) & 1)
#define tcg_regset_set_reg(d, r) ((d) |= (TCGRegSet)1 << (r))
#define tcg_regset_reset_reg(d, r) ((d) &= ~((TCGRegSet)1 << (r)))
#define tcg_regset_test_reg(d, r) (((d) >> (r)) & 1)
#ifndef TCG_TARGET_INSN_UNIT_SIZE
# error "Missing TCG_TARGET_INSN_UNIT_SIZE"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment