Page MenuHomePhabricator

Add Builder::get{I32,I64}TensorAttr.
ClosedPublic

Authored by silvas on Wed, Mar 18, 7:51 PM.

Details

Summary

Builder::get{I32,I64}VectorAttr are actually of limited applicability since
vector types can't have zero elements, whereas many uses of this kind of
attribute (such as dimension lists for "transpose"-like and other tensor
ops) often can result in empty lists.

Diff Detail

Event Timeline

silvas created this revision.Wed, Mar 18, 7:51 PM
Herald added a project: Restricted Project. · View Herald Transcript
bondhugula added inline comments.
mlir/include/mlir/IR/Builders.h
119

Nit: Cannot be empty -> values cannot be empty

123

Likewise.

silvas updated this revision to Diff 251250.Wed, Mar 18, 8:15 PM

Address comments.

silvas marked 2 inline comments as done.Wed, Mar 18, 8:16 PM
silvas updated this revision to Diff 251272.Wed, Mar 18, 9:51 PM

Fix typo

rriddle accepted this revision.Thu, Mar 19, 12:05 AM
rriddle added inline comments.
mlir/include/mlir/IR/Builders.h
119

nit: cannot -> must not

This revision is now accepted and ready to land.Thu, Mar 19, 12:05 AM
silvas updated this revision to Diff 251424.Thu, Mar 19, 11:30 AM

Address comments

silvas marked an inline comment as done.Thu, Mar 19, 11:30 AM
This revision was automatically updated to reflect the committed changes.