HomePhabricator

[ARM] Recognize "double extend" reduction patterns

Authored by dmgreen on Sep 12 2020, 5:51 AM.

Description

[ARM] Recognize "double extend" reduction patterns

We can sometimes get code that does:

xe = zext i16 x to i32
ye = zext i16 y to i32
m = mul i32 xe, ye
me = zext i32 m to i64
r = vecreduce.add(me)

This "double extend" can trip up the reduction identification, but
should give identical results.

This extends the pattern matching to handle them.

Differential Revision: https://reviews.llvm.org/D87276