Remove the ability to directly construct a DenseElementsAttr with a raw character...
authorRiver Riddle <riverriddle@google.com>
Fri, 7 Jun 2019 16:57:29 +0000 (09:57 -0700)
committerMehdi Amini <joker.eph@gmail.com>
Sun, 9 Jun 2019 23:23:34 +0000 (16:23 -0700)
commit0cadec8ae67aa078c3225748ad75d4c3cc7d0b60
tree9f3e717c10fa8c2fe6c0169aaa3935c47f80c72f
parent62facfaf42a05281ec20126ba9943ebf3dda1295
Remove the ability to directly construct a DenseElementsAttr with a raw character buffer. This made assumptions about how DenseElementsAttr structured its internal storage, which may change in the future. To replace the existing use cases, a few utility methods have been added:

* 'get' methods that allow constructing from an ArrayRef of integer or floating point values.
* A 'reshape' method to allow for changing the shape without changing the underlying data.

PiperOrigin-RevId: 252067898
mlir/examples/toy/Ch4/mlir/ToyCombine.cpp
mlir/examples/toy/Ch5/mlir/ToyCombine.cpp
mlir/include/mlir/IR/Attributes.h
mlir/include/mlir/IR/Builders.h
mlir/lib/IR/Attributes.cpp
mlir/lib/IR/Builders.cpp