[PATCH] ARM ISel: Don't create illegal types during LowerMUL
Jim Grosbach
grosbach at apple.com
Tue May 14 14:06:45 PDT 2013
Very cool. Thanks, Arnold.
Trivial nitpick: s/GetExtensionTo64Bits/getExtensionTo64Bits/.
Assuming Renato’s tests come back OK, this looks good to me.
-Jim
On May 14, 2013, at 12:52 PM, Arnold Schwaighofer <aschwaighofer at apple.com> wrote:
> The transformation happening here is that we want to turn a
> "mul(ext(X), ext(X))" into a "vmull(X, X)", stripping off the extension. We have
> to make sure that X still has a valid vector type - possibly recreate an
> extension to a smaller type. In case of a extload of a memory type smaller than
> 64 bit we used create a ext(load()). The problem with doing this - instead of
> recreating an extload - is that an illegal type is exposed.
>
> This patch fixes this by creating extloads instead of ext(load()) sequences.
>
> Fixes PR15970.
>
> radar://13871383
>
> From the bug report:
>
> Initially we had a
>
> mul (v4i32 zextload(from v4i8), v4i32 zextload(from v4i8))
>
> the transform should create
>
> vmull(v4i16 zextload(from v4i8), ...)
>
> out of this. But instead it creates a
>
> vmull(v4i16 zext( v4i8 load()), ...
>
> where an illegal type is exposed.
>
> (This would only be exposed if this transform would run during normal legalization because vector legalization is allowed to create illegal types.)
>
> <0001-ARM-ISel-Don-t-create-illegal-types-during-LowerMUL.patch>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130514/3000f719/attachment.html>
More information about the llvm-commits
mailing list