Skip to content

Commit

Permalink
target-s390x: Fix wrong argument in call of tcg_gen_shl_i64()
Browse files Browse the repository at this point in the history
tcg_gen_shl_i64 needs a 3rd argument of type TCGv_i64.
Set tmp4 so it can be used here.

v2:
Don't call tcg_const_i64() inside of the loop
because it creates additional code.

Signed-off-by: Stefan Weil <[email protected]>
Signed-off-by: Alexander Graf <[email protected]>
  • Loading branch information
Stefan Weil authored and agraf committed Jun 3, 2011
1 parent d4a3ef6 commit be82ee2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions target-s390x/translate.c
Original file line number Diff line number Diff line change
Expand Up @@ -2056,7 +2056,7 @@ static void disas_eb(DisasContext *s, int op, int r1, int r3, int b2, int d2)
even for very long ones... */
tmp = get_address(s, 0, b2, d2);
tmp3 = tcg_const_i64(stm_len);
tmp4 = tcg_const_i64(32);
tmp4 = tcg_const_i64(op == 0x26 ? 32 : 4);
for (i = r1;; i = (i + 1) % 16) {
switch (op) {
case 0x4:
Expand All @@ -2070,7 +2070,7 @@ static void disas_eb(DisasContext *s, int op, int r1, int r3, int b2, int d2)
#else
tmp2 = tcg_temp_new_i64();
tcg_gen_qemu_ld32u(tmp2, tmp, get_mem_index(s));
tcg_gen_shl_i64(tmp2, tmp2, 4);
tcg_gen_shl_i64(tmp2, tmp2, tmp4);
tcg_gen_ext32u_i64(regs[i], regs[i]);
tcg_gen_or_i64(regs[i], regs[i], tmp2);
#endif
Expand Down

0 comments on commit be82ee2

Please sign in to comment.