This is the mail archive of the gcc-patches@gcc.gnu.org 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]

[PATCH] Fix a -ftree-vectorize ICE (PR tree-optimization/33017)


Hi!

The attached testcase ICEs on i?86-linux with -O2 -ftree-vectorize.
The problem is that DR_OFFSET (dr) in this case is fairly complex
(involves pure function call) and tree-vect-transform.c
doesn't call mark_symbols_for_renaming on the statements
force_gimple_operand creates.  I have started writing a patch to do
so (second attachment), but it only covers a small part of the
force_gimple_operand calls (though enough to fix the ICE).

Then it occured to me that I don't see how having a const or pure
function call inside of DR_OFFSET etc. can be really helpful for
optimizations, the only effect it IMHO has is that optimizations
that use tree-data-ref.c might duplicate that const/pure call
and then other optimizations need to clean that up again.
So, the first attachment just stops in split_constant_offset
when it sees a call - the LHS will be IMHO better than the RHS.
This has been regtested on x86_64-linux, ok for trunk?

	Jakub

Attachment: E2
Description: Text document

Attachment: E
Description: Text document


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