Commit 9a390d66 authored by Tomas Matheson's avatar Tomas Matheson
Browse files

[AArch64][GISel] fix G_ADD*/G_SUB* legalization

widenScalarDst updates the insert point to after MI, so
widenScalarSrc must be called before widenScalarDst. Otherwise
The updated Src values will appear after MI and break SSA. e.g.:

  %14:_(s64), %15:_(s1) = G_UADDE %9:_, %11:_, %13:_

becomes

  %14:_(s64), %16:_(s32) = G_UADDE %9:_, %11:_, %17:_
  %15:_(s1) = G_TRUNC %16:_(s32)
  %17:_(s32) = G_ZEXT %13:_(s1)

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

Change-Id: Ie3458747a6879433f4d5ab9939d2bd102dd0f2db
parent 84a71d52
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment