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: [patch, 4.1, 4.2, 4.3] Fix PR tree-optimization/29925 - bug in data-ref analysis

On 3/5/07, Ira Rosen <> wrote:

In analysis of data-ref's offset expression, negation should be added to the subtrahend part of the expression in case of subtraction. Thanks to Harsha for problem analysis and testing on x86-64.

In addition, the analysis should fail if both operands contain constants
(we assume that constants are folded beforehand). This problem was revealed
by this patch

Bootstrapped and tested on the vectorizer testcases (4.1, 4.2 and mainline)
on ppc-linux.
O.K. for 4.1, 4.2 and mainline once passes complete make-check?


Maybe you can add some commentary above the negation code. Also while you changed the return type of analyze_offset you are not checking for it at the call sites. Was that part of the patch omitted?


ChangeLog entry:

      * tree-data-ref.c (analyze_offset): Add a return value (bool) to
      success/failure of the analysis. Add negation to subtrahend in case
      of subtraction. Fail if both operands contain constants.
      (create_data_ref): Fail if analyze_offset fails.

(See attached file: pr29925.txt)

:ADDPATCH tree-ssa (non-algorithmic):

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