This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Two more doloop patches

Zdenek Dvorak wrote:

These two patches strengthen functions in loop-iv.c so that we allow frame and stack pointers in the expressions we're examining. For loops that walk an array on the stack, the exit test often is a pointer comparison involving addresses based on fp or sp, and the compiler can make useful simplifications if these substitutions are allowed.

Bootstrapped and regression tested on i686-linux (irrelevant extra failures in libmudflap due to expect truncating compilre output). Equivalent patches have been in our Blackfin 4.3 tree for a while now and had a fair amount of testing.

+      note = find_reg_equal_equiv_note (DF_REF_INSN (adef));
+      if (note && function_invariant_p (XEXP (note, 0)))
+	src = XEXP (note, 0);
+      else
+	src = SET_SRC (set);
+      if (REG_P (SET_SRC (set)))
+	{
+	  regno = REGNO (SET_SRC (set));
+	  continue;
+	}
+      break;


if (note && function_invariant_p (XEXP (note, 0)))
    src = XEXP (note, 0);
src = SET_SRC (set);

if (REG_P (src))


Otherwise OK,

Changed, retested to make sure that bfin-elf produces identical output, and bootstrapped on i686-linux. Committed.

Bernd -- This footer brought to you by insane German lawmakers. Analog Devices GmbH Wilhelm-Wagenfeld-Str. 6 80807 Muenchen Sitz der Gesellschaft Muenchen, Registergericht Muenchen HRB 40368 Geschaeftsfuehrer Thomas Wessel, William A. Martin, Margaret Seif

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]