[mlir][python] Aggressively avoid name collisions in generated python ODS code.
authorStella Laurenzo <stellaraccident@gmail.com>
Wed, 30 Dec 2020 01:43:04 +0000 (17:43 -0800)
committerStella Laurenzo <stellaraccident@gmail.com>
Wed, 30 Dec 2020 01:43:04 +0000 (17:43 -0800)
commit8a1f1a100cce6ed9b52aedbbf03da887833508be
treedc008fde52dad3035467eb07826c44299eb18ad6
parent9b25b8068df3b2f34938eea17749c72939131d84
[mlir][python] Aggressively avoid name collisions in generated python ODS code.

* When porting npcomp to use these bindings, I ran into enough patterns of collisions that I decided to be somewhat draconian about not polluting the namespace.
* With these changes all of the npcomp dialects generate and pass what tests we have.

Reviewed By: mehdi_amini

Differential Revision: https://reviews.llvm.org/D93920
mlir/include/mlir/Bindings/Python/Attributes.td
mlir/test/mlir-tblgen/op-python-bindings.td
mlir/tools/mlir-tblgen/OpPythonBindingGen.cpp