@@ -19,6 +19,10 @@ namespace impl {
1919LogicalResult verifyHasDefaultDLTIDataLayoutTrait (Operation *op);
2020DataLayoutSpecInterface getDataLayoutSpec (Operation *op);
2121TargetSystemSpecInterface getTargetSystemSpec (Operation *op);
22+ TargetAttrInterface getTargetAttr (Operation *op);
23+ void setDataLayoutSpec (Operation *op, DataLayoutSpecInterface spec);
24+ void setTargetSystemSpec (Operation *op, TargetSystemSpecInterface spec);
25+ void setTargetAttr (Operation *op, TargetAttrInterface target);
2226} // namespace impl
2327
2428// / Trait to be used by operations willing to use the implementation of the
@@ -39,11 +43,27 @@ class HasDefaultDLTIDataLayout
3943 return impl::getDataLayoutSpec (this ->getOperation ());
4044 }
4145
46+ // / Sets the data layout specification.
47+ void setDataLayoutSpec (DataLayoutSpecInterface spec) {
48+ impl::setDataLayoutSpec (this ->getOperation (), spec);
49+ }
4250 // / Returns the target system description specification as provided by DLTI
4351 // / dialect
4452 TargetSystemSpecInterface getTargetSystemSpec () {
4553 return impl::getTargetSystemSpec (this ->getOperation ());
4654 }
55+ // / Sets the target system description specification.
56+ void setTargetSystemSpec (TargetSystemSpecInterface spec) {
57+ impl::setTargetSystemSpec (this ->getOperation (), spec);
58+ }
59+ // / Returns the target information as provided by DLTI dialect.
60+ TargetAttrInterface getTargetAttr () {
61+ return impl::getTargetAttr (this ->getOperation ());
62+ }
63+ // / Sets the target information.
64+ void setTargetAttr (TargetAttrInterface target) {
65+ impl::setTargetAttr (this ->getOperation (), target);
66+ }
4767};
4868} // namespace mlir
4969
0 commit comments