This is the mail archive of the
mailing list for the GCC project.
Re: making the new if-converter not mangle IR that is already vectorizer-friendly
- From: Abe <abe_skolnik at yahoo dot com>
- To: Alan Lawrence <alan dot lawrence at arm dot com>
- Cc: "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>, Richard Biener <richard dot guenther at gmail dot com>, Sebastian Pop <sebpop at gmail dot com>
- Date: Thu, 23 Jul 2015 15:24:31 -0500
- Subject: Re: making the new if-converter not mangle IR that is already vectorizer-friendly
- Authentication-results: sourceware.org; auth=none
- References: <55946699 dot 4070803 at yahoo dot com> <559504BE dot 40207 at arm dot com> <5595AB07 dot 7040404 at yahoo dot com> <559657CA dot 4080706 at arm dot com> <559C3CAF dot 9040308 at yahoo dot com> <559CF42B dot 4010308 at arm dot com> <559D5489 dot 1040808 at yahoo dot com> <55AD2DD8 dot 9070000 at arm dot com> <55AD4DF4 dot 5060108 at yahoo dot com> <55AE1CCE dot 8020405 at arm dot com>
Ideally, I/we fix the above problem -- and the rest of the regressions in the new if converter --
OK, what are these regressions?
Each of these files` test cases currently fails to be autovectorized:
Well, any array access could introduce an extra fault (unless it's dominated by another equivalent (read/write) access)...?
I respectfully disagree. Given code such as this:
for (unsigned short index = 1; index < 9; ++index)
array[index] = index;
... and assuming that "array" is an _array_ variable, i.e. it is _not_ a [re-assignable] pointer, it should be
clear IMO to all human readers that this code will not segfault, and if any compiler cannot also correctly arrive
at the conclusion "this array access is always good", then that compiler needs to get better at analysis IMO.
AFAIK, value range propagation [in the above example, for "index"] has been in GCC for many years...
[and I`m sure there are many more]