提交 6c712321 编写于 作者: A Aurelien Jarno

target-ppc: don't print invalid opcode messages on the console

Invalid opcode messages can be perfectly normal, for example if this
code is never executed. Don't print an error message on the console,
but keep the message in the log for debugging purposes.
Signed-off-by: NAurelien Jarno <aurelien@aurel32.net>
上级 db9a231d
...@@ -9053,11 +9053,6 @@ static inline void gen_intermediate_code_internal(CPUState *env, ...@@ -9053,11 +9053,6 @@ static inline void gen_intermediate_code_internal(CPUState *env,
"%02x - %02x - %02x (%08x) " TARGET_FMT_lx " %d\n", "%02x - %02x - %02x (%08x) " TARGET_FMT_lx " %d\n",
opc1(ctx.opcode), opc2(ctx.opcode), opc1(ctx.opcode), opc2(ctx.opcode),
opc3(ctx.opcode), ctx.opcode, ctx.nip - 4, (int)msr_ir); opc3(ctx.opcode), ctx.opcode, ctx.nip - 4, (int)msr_ir);
} else {
printf("invalid/unsupported opcode: "
"%02x - %02x - %02x (%08x) " TARGET_FMT_lx " %d\n",
opc1(ctx.opcode), opc2(ctx.opcode),
opc3(ctx.opcode), ctx.opcode, ctx.nip - 4, (int)msr_ir);
} }
} else { } else {
if (unlikely((ctx.opcode & handler->inval) != 0)) { if (unlikely((ctx.opcode & handler->inval) != 0)) {
...@@ -9067,12 +9062,6 @@ static inline void gen_intermediate_code_internal(CPUState *env, ...@@ -9067,12 +9062,6 @@ static inline void gen_intermediate_code_internal(CPUState *env,
ctx.opcode & handler->inval, opc1(ctx.opcode), ctx.opcode & handler->inval, opc1(ctx.opcode),
opc2(ctx.opcode), opc3(ctx.opcode), opc2(ctx.opcode), opc3(ctx.opcode),
ctx.opcode, ctx.nip - 4); ctx.opcode, ctx.nip - 4);
} else {
printf("invalid bits: %08x for opcode: "
"%02x - %02x - %02x (%08x) " TARGET_FMT_lx "\n",
ctx.opcode & handler->inval, opc1(ctx.opcode),
opc2(ctx.opcode), opc3(ctx.opcode),
ctx.opcode, ctx.nip - 4);
} }
gen_inval_exception(ctxp, POWERPC_EXCP_INVAL_INVAL); gen_inval_exception(ctxp, POWERPC_EXCP_INVAL_INVAL);
break; break;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册