From: Eric Botcazou Date: Fri, 25 Oct 2013 08:57:06 +0000 (+0000) Subject: recog.c (search_ofs): New static variable moved from... X-Git-Tag: releases/gcc-4.7.4~437 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0b15107f3a51da2a23408df8279d5697e953f742;p=thirdparty%2Fgcc.git recog.c (search_ofs): New static variable moved from... * recog.c (search_ofs): New static variable moved from... (peep2_find_free_register): ...here. (peephole2_optimize): Initialize it. From-SVN: r204052 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 63e265a7782d..9738fbc57ac4 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2013-10-25 Eric Botcazou + + * recog.c (search_ofs): New static variable moved from... + (peep2_find_free_register): ...here. + (peephole2_optimize): Initialize it. + 2013-10-02 John David Anglin * config.gcc (hppa*64*-*-linux*): Don't add pa/t-linux to tmake_file. diff --git a/gcc/recog.c b/gcc/recog.c index 43711620aae8..32ed021bb979 100644 --- a/gcc/recog.c +++ b/gcc/recog.c @@ -3030,6 +3030,9 @@ peep2_reg_dead_p (int ofs, rtx reg) return 1; } +/* Regno offset to be used in the register search. */ +static int search_ofs; + /* Try to find a hard register of mode MODE, matching the register class in CLASS_STR, which is available at the beginning of insn CURRENT_INSN and remains available until the end of LAST_INSN. LAST_INSN may be NULL_RTX, @@ -3045,7 +3048,6 @@ rtx peep2_find_free_register (int from, int to, const char *class_str, enum machine_mode mode, HARD_REG_SET *reg_set) { - static int search_ofs; enum reg_class cl; HARD_REG_SET live; df_ref *def_rec; @@ -3488,6 +3490,7 @@ peephole2_optimize (void) /* Initialize the regsets we're going to use. */ for (i = 0; i < MAX_INSNS_PER_PEEP2 + 1; ++i) peep2_insn_data[i].live_before = BITMAP_ALLOC (®_obstack); + search_ofs = 0; live = BITMAP_ALLOC (®_obstack); FOR_EACH_BB_REVERSE (bb)