This is an archive of the discontinued LLVM Phabricator instance.

Demo fix for bugprone-copy-constructor-init (WIP)
ClosedPublic

Authored by mehdi_amini on Dec 23 2021, 2:20 PM.

Diff Detail

Event Timeline

mehdi_amini created this revision.Dec 23 2021, 2:20 PM
mehdi_amini requested review of this revision.Dec 23 2021, 2:20 PM
Mogball added inline comments.Dec 23 2021, 3:28 PM
mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
517

Wouldn't the appropriate fix for these be = default?

Full repo run

Mogball accepted this revision.Dec 29 2021, 8:46 AM
This revision is now accepted and ready to land.Dec 29 2021, 8:46 AM
rriddle accepted this revision.Jan 1 2022, 3:30 AM
rriddle added inline comments.
mlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferizePass.cpp
39–40

Can we just do = default? Or just elide it?

mlir/lib/Dialect/Linalg/Transforms/Detensorize.cpp
604–607 ↗(On Diff #396466)

This should be specified in tablegen, which should remove the need for the explicit copy constructor.

mehdi_amini marked 2 inline comments as done.Jan 1 2022, 1:21 PM
mehdi_amini added inline comments.
mlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferizePass.cpp
39–40

Good point, there is another clang-tidy transform that is supposed to make it = default ; not sure why it does not kick in here.

mlir/lib/Dialect/Linalg/Transforms/Detensorize.cpp
604–607 ↗(On Diff #396466)
This revision was automatically updated to reflect the committed changes.
mehdi_amini marked 2 inline comments as done.