diff options
Diffstat (limited to 'target-ppc/translate.c')
-rw-r--r-- | target-ppc/translate.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/target-ppc/translate.c b/target-ppc/translate.c index fc234a32c8..2dc6fb463a 100644 --- a/target-ppc/translate.c +++ b/target-ppc/translate.c @@ -11475,8 +11475,12 @@ static inline void gen_intermediate_code_internal(PowerPCCPU *cpu, #endif num_insns = 0; max_insns = tb->cflags & CF_COUNT_MASK; - if (max_insns == 0) + if (max_insns == 0) { max_insns = CF_COUNT_MASK; + } + if (max_insns > TCG_MAX_INSNS) { + max_insns = TCG_MAX_INSNS; + } gen_tb_start(tb); tcg_clear_temp_count(); |