Page MenuHomePhabricator

[MLIR] Improve support for 0-dimensional Affine Maps.

Authored by jbruestle on Apr 15 2020, 11:35 AM.



Modified AffineMap::get to remove support for the overload which allowed
an ArrayRef of AffineExpr but no context (and gathered the context from a
presumed first entry, resulting in bugs when there were 0 results).

Instead, we support only a ArrayRef and a context, and a version which
takes a single AffineExpr.

Additionally, removed some now needless case logic which previously
special cased which call to AffineMap::get to use.

Diff Detail

Event Timeline

jbruestle created this revision.Apr 15 2020, 11:35 AM
Herald added 1 blocking reviewer(s): rriddle. · View Herald Transcript
Herald added a reviewer: aartbik. · View Herald Transcript
Herald added a project: Restricted Project. · View Herald Transcript
rriddle accepted this revision.Apr 15 2020, 11:41 AM
rriddle marked an inline comment as done.
rriddle added inline comments.

Unrelated to this revision, but I don't see why this ArrayAttr needs to be generated.


nit: prefer empty instead of size.


Is this wrapped at 80 characters?


Same here, is this formatted?

This revision is now accepted and ready to land.Apr 15 2020, 11:41 AM
flaub added inline comments.Apr 15 2020, 11:45 AM

This comment appears obsolete.

Fixes from code review

jbruestle marked 3 inline comments as done.

Another minor issue found during review

Harbormaster failed remote builds in B53399: Diff 257788!
Harbormaster failed remote builds in B53402: Diff 257791!
ftynse accepted this revision.Apr 15 2020, 12:12 PM
ftynse added inline comments.

Nit: consider adding a message to the assertion, as in assert(condition && "message")

jbruestle marked an inline comment as done.

Having issues with arcanist and git, attempting to resolve.

Trying to fix arc happy

This revision was automatically updated to reflect the committed changes.