diff options
-rw-r--r-- | target-cris/translate.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/target-cris/translate.c b/target-cris/translate.c index e37b04e69d..76406af980 100644 --- a/target-cris/translate.c +++ b/target-cris/translate.c @@ -169,9 +169,7 @@ static int preg_sizes[] = { static inline void t_gen_mov_TN_preg(TCGv tn, int r) { - if (r < 0 || r > 15) { - fprintf(stderr, "wrong register read $p%d\n", r); - } + assert(r >= 0 && r <= 15); if (r == PR_BZ || r == PR_WZ || r == PR_DZ) { tcg_gen_mov_tl(tn, tcg_const_tl(0)); } else if (r == PR_VR) { @@ -182,9 +180,7 @@ static inline void t_gen_mov_TN_preg(TCGv tn, int r) } static inline void t_gen_mov_preg_TN(DisasContext *dc, int r, TCGv tn) { - if (r < 0 || r > 15) { - fprintf(stderr, "wrong register write $p%d\n", r); - } + assert(r >= 0 && r <= 15); if (r == PR_BZ || r == PR_WZ || r == PR_DZ) { return; } else if (r == PR_SRS) { |