MLIR Team
41d90a85bd
Automated rollback of changelist 247778391.
...
PiperOrigin-RevId: 247778691
2019-05-20 13:37:20 -07:00
River Riddle
02e03b9bf4
Add support for using llvm::dyn_cast/cast/isa for operation casts and replace usages of Operation::dyn_cast with llvm::dyn_cast.
...
--
PiperOrigin-RevId: 247778391
2019-05-20 13:37:10 -07:00
Mehdi Amini
bd8ed0d215
Fix unused variable warning in the Toy tutorial (NFC)
...
--
PiperOrigin-RevId: 247672377
2019-05-10 19:29:58 -07:00
River Riddle
3b930b0d70
Add explicit friendship with Operation to each derived op class to ensure access to the inherited protected constructor of `Op`. Some compiler versions have different rules for the visibility of inherited constructors.
...
--
PiperOrigin-RevId: 246661686
2019-05-06 08:28:50 -07:00
Guangda Lai
7977e62b96
Fix typo (transpose -> reshape).
...
--
PiperOrigin-RevId: 244270801
2019-04-23 22:00:45 -07:00
Mehdi Amini
6c6ed466a6
Expose `setupTargetTriple` as a public static method on ExecutionEngine
...
This allows client to be able to reuse the same logic to setup a module
for the ExecutionEngine without instanciating one. One use case is running
the optimization pipeline but not JIT-ing.
--
PiperOrigin-RevId: 242614380
2019-04-11 10:51:24 -07:00
Mehdi Amini
c4dee61c0e
Fix Toy cmake build: add missing includes
...
--
PiperOrigin-RevId: 242609231
2019-04-08 23:27:02 -07:00
Mehdi Amini
c39592b09c
Toy tutorial Chapter 5: Lowering to Linalg and LLVM
...
--
PiperOrigin-RevId: 242606796
2019-04-08 23:26:54 -07:00
Mehdi Amini
89d5d36964
Fix bug in Toy tutorial where IR emission stopped after any `print`
...
--
PiperOrigin-RevId: 242407970
2019-04-08 18:54:25 -07:00
Chris Lattner
72441fcbf2
Change the asmprinter to use pretty syntax for dialect types when it can,
...
making the IR dumps much nicer.
This is part 2/3 of the path to making dialect types more nice. Part 3/3 will
slightly generalize the set of characters allowed in pretty types and make it
more principled.
--
PiperOrigin-RevId: 242249955
2019-04-07 18:21:13 -07:00
River Riddle
e4628b79fb
Add new utilities for RTTI Operation casting: dyn_cast_or_null and isa_nonnull
...
* dyn_cast_or_null
- This will first check if the operation is null before trying to 'dyn_cast':
Value *v = ...;
if (auto forOp = dyn_cast_or_null<AffineForOp>(v->getDefiningOp()))
...
* isa_nonnull
- This will first check if the pointer is null before trying to 'isa':
Value *v = ...;
if (isa_nonnull<AffineForOp>(v->getDefiningOp());
...
--
PiperOrigin-RevId: 242171343
2019-04-07 18:20:07 -07:00
Mehdi Amini
01e8ec94c3
Fix CMake build: account for renamed files and add missing include on MacOS
...
--
PiperOrigin-RevId: 242101364
2019-04-05 07:43:23 -07:00
River Riddle
fde21c6faf
NFC: Fix a few typos in the tutorials and one in the comment of FunctionAttr::dropFunctionReference.
...
--
PiperOrigin-RevId: 242050934
2019-04-05 07:43:05 -07:00
Mehdi Amini
d33a9dcc73
Add Chapter 4 for the Toy tutorial: shape inference, function specialization, and basic combines
...
--
PiperOrigin-RevId: 242050514
2019-04-05 07:42:56 -07:00
River Riddle
a83181cd20
NFC: Fix erroneous use of 'OpaqueType' with 'Type' when setting the ToyTypeKind, as well as a few mistakes in Chapter 2 of the Toy tutorial.
...
--
PiperOrigin-RevId: 242021477
2019-04-05 07:42:10 -07:00
Mehdi Amini
f0a328b6d5
Chapter 3 for Toy tutorial: introduction of a dialect
...
--
PiperOrigin-RevId: 241849162
2019-04-03 19:22:32 -07:00
Mehdi Amini
3a2955fa1f
Rename UnknownType to OpaqueType (NFC)
...
This came up in a review of the tutorial, it was suggested that "opaque" is more
descriptive than "unknown" here.
--
PiperOrigin-RevId: 241832927
2019-04-03 19:21:47 -07:00
Mehdi Amini
a261ce5b40
Move the top-level `tutorial` as `Linalg` nested in the examples folder
...
--
PiperOrigin-RevId: 241831176
2019-04-03 19:21:38 -07:00
Mehdi Amini
5854fb9b94
Fix Toy tutorial gcc 7 build (NFC)
...
--
PiperOrigin-RevId: 241613710
2019-04-02 15:16:30 -07:00
Mehdi Amini
213dda687b
Chapter 2 of the Toy tutorial
...
This introduces a basic MLIRGen through straight AST traversal,
without dialect registration at this point.
--
PiperOrigin-RevId: 241588354
2019-04-02 13:41:00 -07:00
Mehdi Amini
38b71d6b84
Initial version for chapter 1 of the Toy tutorial
...
--
PiperOrigin-RevId: 241549247
2019-04-02 13:40:06 -07:00