Adding a new reduction pattern match for vectorizing code similar to TSVC s3111:
for (int i = 0; i < N; i++)
if (a[i] > b) sum += a[i];
This patch adds support for fadd, fsub and fmull, as well as multiple
branches and different (but compatible) instructions (ex. add+sub) in
The difference from the previous patch(https://reviews.llvm.org/D49168) is as follows.
- Added check of fast-math property of fp-instruction to the previous patch.
- Fix/add some pattern for if-reduction.ll.