提交 083dbf48 编写于 作者: P Peter A. G. Crosthwaite 提交者: Edgar E. Iglesias

target-microblaze: fix swx build breakage

The lazy initialisation of r_check was throwing an error on --enable-debug.
Removed the lazy initialisation of r_check and swx_addr.
Signed-off-by: NPeter A. G. Crosthwaite <peter.crosthwaite@petalogix.com>
Signed-off-by: NEdgar E. Iglesias <edgar.iglesias@gmail.com>
上级 34941700
...@@ -1105,7 +1105,7 @@ static void gen_store(DisasContext *dc, TCGv addr, TCGv val, ...@@ -1105,7 +1105,7 @@ static void gen_store(DisasContext *dc, TCGv addr, TCGv val,
static void dec_store(DisasContext *dc) static void dec_store(DisasContext *dc)
{ {
TCGv t, *addr, swx_addr, r_check = 0; TCGv t, *addr, swx_addr, r_check;
int swx_skip = 0; int swx_skip = 0;
unsigned int size, rev = 0, ex = 0; unsigned int size, rev = 0, ex = 0;
...@@ -1129,9 +1129,9 @@ static void dec_store(DisasContext *dc) ...@@ -1129,9 +1129,9 @@ static void dec_store(DisasContext *dc)
sync_jmpstate(dc); sync_jmpstate(dc);
addr = compute_ldst_addr(dc, &t); addr = compute_ldst_addr(dc, &t);
r_check = tcg_temp_new();
swx_addr = tcg_temp_local_new();
if (ex) { /* swx */ if (ex) { /* swx */
r_check = tcg_temp_new();
swx_addr = tcg_temp_local_new();
/* Force addr into the swx_addr. */ /* Force addr into the swx_addr. */
tcg_gen_mov_tl(swx_addr, *addr); tcg_gen_mov_tl(swx_addr, *addr);
...@@ -1221,11 +1221,12 @@ static void dec_store(DisasContext *dc) ...@@ -1221,11 +1221,12 @@ static void dec_store(DisasContext *dc)
gen_helper_memalign(*addr, tcg_const_tl(dc->rd), gen_helper_memalign(*addr, tcg_const_tl(dc->rd),
tcg_const_tl(1), tcg_const_tl(size - 1)); tcg_const_tl(1), tcg_const_tl(size - 1));
} }
if (ex) { if (ex) {
gen_set_label(swx_skip); gen_set_label(swx_skip);
tcg_temp_free(r_check);
tcg_temp_free(swx_addr);
} }
tcg_temp_free(r_check);
tcg_temp_free(swx_addr);
if (addr == &t) if (addr == &t)
tcg_temp_free(t); tcg_temp_free(t);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册