A. Unique TensorFlower
7b0a6bfeee
Integrate LLVM at llvm/llvm-project@fcf6800506
...
Updates LLVM usage to match
[fcf680050686](https://github.com/llvm/llvm-project/commit/fcf680050686 )
PiperOrigin-RevId: 366101230
2021-03-31 13:16:11 -07:00
A. Unique TensorFlower
af3bc47a8b
Integrate LLVM at llvm/llvm-project@8396aeb07c
...
Updates LLVM usage to match
[8396aeb07cdd](https://github.com/llvm/llvm-project/commit/8396aeb07cdd )
PiperOrigin-RevId: 366034463
2021-03-31 08:01:34 -07:00
A. Unique TensorFlower
bbe0aa204c
[MLIR][MHLO] Merge assuming ops with compatible witnesses
...
PiperOrigin-RevId: 366018349
2021-03-31 06:11:38 -07:00
Adrian Kuegel
c8157ba4df
Move code from helper struct to the only user.
...
We don't need the separate helper struct anymore, because it is now only used
in one place.
PiperOrigin-RevId: 366012639
2021-03-31 05:21:34 -07:00
Adrian Kuegel
4033a56750
Add special cases for SelectOp rank specialization.
...
We now use the same special cases for all ops with arity >= 2.
For binary ops, we now have only one special case if at least one of the
operands has exactly one element. In that case, we reshape both operands to
rank 1. Before, we had separate special cases whether the left-hand side
or the right-hand side have a scalar shape.
PiperOrigin-RevId: 366005835
2021-03-31 04:28:51 -07:00
A. Unique TensorFlower
9206805c58
[MLIR][MHLO] Do not yield results of ops that were moved out of assuming regions
...
When an op is moved out of an assuming region we already know statically that it
is independent of the assuming region. Hence, there is no need to yield its
results.
PiperOrigin-RevId: 366001405
2021-03-31 03:50:27 -07:00
A. Unique TensorFlower
8ade5d78c8
[MLIR][MHLO] Move `cstr_broadcastable` and `shape_of` out of `assuming` regions
...
Add pattern to move operations out of assuming op. This only valid for
constraint-independent ops, like `cstr_broadcastable` and `shape_of`. It will
eventually allow to make assuming regions' constraints independent from each
other so that they can be merged.
PiperOrigin-RevId: 365993145
2021-03-31 02:39:07 -07:00
A. Unique TensorFlower
af2aaa6144
Integrate LLVM at llvm/llvm-project@afed50a14b
...
Updates LLVM usage to match
[afed50a14b34](https://github.com/llvm/llvm-project/commit/afed50a14b34 )
PiperOrigin-RevId: 365986449
2021-03-31 01:37:43 -07:00
A. Unique TensorFlower
eade942635
[MLIR][MHLO] Add pattern to move ops into the assuming region
...
This will eventually allow to make assuming regions' constraints independent
from each other.
PiperOrigin-RevId: 365985081
2021-03-31 01:23:31 -07:00
Geoffrey Martin-Noble
5ec66775d4
Temporarily relax restriction on mhlo.while terminator
...
Some internal tests are failing, so relaxing this restriction
temporarily while we investigate.
PiperOrigin-RevId: 365949611
2021-03-30 19:44:07 -07:00
Geoffrey Martin-Noble
5d65758e8c
Canonicalize MHLO Case and If Ops with constant conditions
...
ReplaceOpWithRegion was taken directly from ScfOps. We should maybe put that somewhere common in core.
PiperOrigin-RevId: 365936724
2021-03-30 17:58:01 -07:00
Geoffrey Martin-Noble
2fb2a92c6e
Verify mhlo.if region return types match op
...
This matches the behavior of mhlo.case. Additionally, fix the verification of CaseOp in the case of nested ops with mhlo.return-containing regions.
PiperOrigin-RevId: 365936672
2021-03-30 17:57:20 -07:00
Russell Power
3be9874d82
Remove comments for license declarations. These can get out of date/stale.
...
PiperOrigin-RevId: 365936646
2021-03-30 17:55:42 -07:00
A. Unique TensorFlower
00552afdd3
Integrate LLVM at llvm/llvm-project@c06a8f9caa
...
Updates LLVM usage to match
[c06a8f9caa51](https://github.com/llvm/llvm-project/commit/c06a8f9caa51 )
PiperOrigin-RevId: 365935998
2021-03-30 17:52:35 -07:00
Geoffrey Martin-Noble
7a9394dca5
Restrict MHLO control flow ops to single-block regions
...
PiperOrigin-RevId: 365935824
2021-03-30 17:51:03 -07:00
A. Unique TensorFlower
e78c59d927
Integrate LLVM at llvm/llvm-project@73adc05ced
...
Updates LLVM usage to match
[73adc05cedb2](https://github.com/llvm/llvm-project/commit/73adc05cedb2 )
PiperOrigin-RevId: 365901717
2021-03-30 14:49:19 -07:00
A. Unique TensorFlower
3d8095a5ec
Integrate LLVM at llvm/llvm-project@77d81c2270
...
Updates LLVM usage to match
[77d81c2270c6](https://github.com/llvm/llvm-project/commit/77d81c2270c6 )
PiperOrigin-RevId: 365870238
2021-03-30 12:27:56 -07:00
A. Unique TensorFlower
f90042321a
Integrate LLVM at llvm/llvm-project@c51e91e046
...
Updates LLVM usage to match
[c51e91e04681](https://github.com/llvm/llvm-project/commit/c51e91e04681 )
PiperOrigin-RevId: 365802786
2021-03-30 07:06:04 -07:00
Adrian Kuegel
c1a6ae8994
Generalize the HloBinaryElementwiseAdaptor
...
We can use it also for ternary ops like Select if we change the signature so
that a ValueRange is passed in.
Also remove special casing for HloComplexAdaptor. It can be handled with the
generic adaptor as well.
PiperOrigin-RevId: 365777493
2021-03-30 03:53:53 -07:00
Adrian Kuegel
6388e8d9ee
mlir-hlo-opt: set preloadDialectsInContext to false.
...
This requires specifying dependent dialects in several passes.
PiperOrigin-RevId: 365758084
2021-03-30 01:07:14 -07:00
A. Unique TensorFlower
9ebadc4c4d
Integrate LLVM at llvm/llvm-project@482283042f
...
Updates LLVM usage to match
[482283042f79](https://github.com/llvm/llvm-project/commit/482283042f79 )
PiperOrigin-RevId: 365710568
2021-03-29 18:29:48 -07:00
A. Unique TensorFlower
12a82dfe44
Integrate LLVM at llvm/llvm-project@20d5c42e0e
...
Updates LLVM usage to match
[20d5c42e0ef5](https://github.com/llvm/llvm-project/commit/20d5c42e0ef5 )
PiperOrigin-RevId: 365666232
2021-03-29 14:37:03 -07:00
A. Unique TensorFlower
85a306d356
[MLIR][MHLO] Add pattern to inline broadcasted shapes
...
Simplify reasoning about `cstr_broadcastable` ops in the
`mhlo-move-up-dynamic-broadcasts-for-fusion` pass.
PiperOrigin-RevId: 365560893
2021-03-29 06:32:32 -07:00
A. Unique TensorFlower
fb819c1de8
[MLIR][MHLO] Apply patterns in MoveUpDynamicBroadcastsForFusionPass greedily
...
PiperOrigin-RevId: 365556488
2021-03-29 06:02:06 -07:00
A. Unique TensorFlower
238c1d8a92
Integrate LLVM at llvm/llvm-project@594e0ba969
...
Updates LLVM usage to match
[594e0ba96967](https://github.com/llvm/llvm-project/commit/594e0ba96967 )
PiperOrigin-RevId: 365282704
2021-03-26 16:45:20 -07:00
A. Unique TensorFlower
9b7479f907
Integrate LLVM at llvm/llvm-project@4157a079af
...
Updates LLVM usage to match
[4157a079afbf](https://github.com/llvm/llvm-project/commit/4157a079afbf )
PiperOrigin-RevId: 365150758
2021-03-25 16:39:37 -07:00
Geoffrey Martin-Noble
a2b6060c0c
Add folder for HLO NotOp
...
PiperOrigin-RevId: 364989658
2021-03-25 02:08:38 -07:00
A. Unique TensorFlower
cbef26c6a8
Integrate LLVM at llvm/llvm-project@1f6a57c1a0
...
Updates LLVM usage to match
[1f6a57c1a0fa](https://github.com/llvm/llvm-project/commit/1f6a57c1a0fa )
PiperOrigin-RevId: 364804812
2021-03-24 08:11:34 -07:00
A. Unique TensorFlower
52d1744285
Integrate LLVM at llvm/llvm-project@3e0ad11543
...
Updates LLVM usage to match
[3e0ad1154396](https://github.com/llvm/llvm-project/commit/3e0ad1154396 )
PiperOrigin-RevId: 364790509
2021-03-24 06:45:22 -07:00
Adrian Kuegel
a34aa699f8
Fix tanh lowering for NaN input.
...
If the input is NaN, the result should be NaN, too.
PiperOrigin-RevId: 364788902
2021-03-24 06:34:36 -07:00
A. Unique TensorFlower
7dd0fe4592
Integrate LLVM at llvm/llvm-project@d709dcc090
...
Updates LLVM usage to match
[d709dcc09097](https://github.com/llvm/llvm-project/commit/d709dcc09097 )
PiperOrigin-RevId: 364688656
2021-03-23 17:58:45 -07:00
Stella Laurenzo
7f2bf48b8b
Integrate LLVM at llvm/llvm-project@b24436ac96
...
Updates LLVM usage to match
[b24436ac96bd](https://github.com/llvm/llvm-project/commit/b24436ac96bd )
PiperOrigin-RevId: 364615807
2021-03-23 12:20:17 -07:00
A. Unique TensorFlower
8987dfd1d6
[MLIR][HLO] Move broadcasts over n-ary shape-preserving ops
...
This will open up more fusion opportunities.
PiperOrigin-RevId: 364577231
2021-03-23 09:38:39 -07:00
A. Unique TensorFlower
5bc4bf0834
Integrate LLVM at llvm/llvm-project@0776eca7a4
...
Updates LLVM usage to match
[0776eca7a4e7](https://github.com/llvm/llvm-project/commit/0776eca7a4e7 )
PiperOrigin-RevId: 364552759
2021-03-23 07:26:28 -07:00
A. Unique TensorFlower
618223778d
Integrate LLVM at llvm/llvm-project@5657f93e78
...
Updates LLVM usage to match
[5657f93e788f](https://github.com/llvm/llvm-project/commit/5657f93e788f )
PiperOrigin-RevId: 364541987
2021-03-23 06:15:46 -07:00
A. Unique TensorFlower
1a6483e229
Integrate LLVM at llvm/llvm-project@e990fa2170
...
Updates LLVM usage to match
[e990fa217031](https://github.com/llvm/llvm-project/commit/e990fa217031 )
PiperOrigin-RevId: 364529739
2021-03-23 04:39:42 -07:00
A. Unique TensorFlower
54f37abc28
[MHLO] Move broadcasts over elementwise ops
...
Move up dynamic broadcasts and shape computations to allow for more fusion
opportunities.
PiperOrigin-RevId: 364514158
2021-03-23 02:34:41 -07:00
Mehdi Amini
98debb127d
Update Tensorflow to prepare for changing the default value of `preloadDialectsInContext`
...
This makes tf-opt more strict on the dialect dependencies, and immediately reduces
the number of dialects loaded.
The canonicalization of TensorFlow graphs showed on the profile that Linalg pattern
were dominated the time, which is unexpected since Linalg is not even intended to be
used there.
PiperOrigin-RevId: 364087027
2021-03-20 11:01:55 -07:00
A. Unique TensorFlower
431be0e9b2
Integrate LLVM at llvm/llvm-project@cd442157cf
...
Updates LLVM usage to match
[cd442157cff4](https://github.com/llvm/llvm-project/commit/cd442157cff4 )
PiperOrigin-RevId: 363873565
2021-03-19 05:55:54 -07:00
Benjamin Kramer
59fa7c0ef7
[MHLO:linalg] Lower all dynamic broadcasts of static shapes to linalg.generic
...
We only need the memref_reinterpret_cast if we don't know whether a dimension
gets expanded or not. With static shapes we know that a dimension can only be
expanded if it's a static 1, so lower it in the same way we lower fully
static broadcasts.
PiperOrigin-RevId: 363859181
2021-03-19 03:52:02 -07:00
A. Unique TensorFlower
22b27dbaa2
Integrate LLVM at llvm/llvm-project@628f5c9da2
...
Updates LLVM usage to match
[628f5c9da29b](https://github.com/llvm/llvm-project/commit/628f5c9da29b )
PiperOrigin-RevId: 363858631
2021-03-19 03:46:45 -07:00
A. Unique TensorFlower
dc3dbb9d17
Integrate LLVM at llvm/llvm-project@80df56f7f9
...
Updates LLVM usage to match
[80df56f7f9ef](https://github.com/llvm/llvm-project/commit/80df56f7f9ef )
PiperOrigin-RevId: 363843825
2021-03-19 01:35:15 -07:00
A. Unique TensorFlower
a26e227b46
Integrate LLVM at llvm/llvm-project@16c30c3c23
...
Updates LLVM usage to match
[16c30c3c23ef](https://github.com/llvm/llvm-project/commit/16c30c3c23ef )
PiperOrigin-RevId: 363806028
2021-03-18 20:16:47 -07:00
A. Unique TensorFlower
76d61d4d51
Integrate LLVM at llvm/llvm-project@078b338ba6
...
Updates LLVM usage to match
[078b338ba67a](https://github.com/llvm/llvm-project/commit/078b338ba67a )
PiperOrigin-RevId: 363661770
2021-03-18 08:26:26 -07:00
A. Unique TensorFlower
8ac890d531
Integrate LLVM at llvm/llvm-project@388fbefb4f
...
Updates LLVM usage to match
[388fbefb4f2a](https://github.com/llvm/llvm-project/commit/388fbefb4f2a )
PiperOrigin-RevId: 363641472
2021-03-18 06:11:13 -07:00
A. Unique TensorFlower
0c4a89e52c
[MLIR][MHLO] Implement shape reification for `dynamic_broadcast_in_dim`
...
PiperOrigin-RevId: 363622714
2021-03-18 03:39:15 -07:00
A. Unique TensorFlower
aad6d39952
Integrate LLVM at llvm/llvm-project@0604e0bc68
...
Updates LLVM usage to match
[0604e0bc683e](https://github.com/llvm/llvm-project/commit/0604e0bc683e )
PiperOrigin-RevId: 363601445
2021-03-18 00:52:33 -07:00
A. Unique TensorFlower
f7464dfa62
Integrate LLVM at llvm/llvm-project@2416f24363
...
Updates LLVM usage to match
[2416f2436334](https://github.com/llvm/llvm-project/commit/2416f2436334 )
PiperOrigin-RevId: 363568447
2021-03-17 20:22:14 -07:00
A. Unique TensorFlower
f5c9955056
Integrate LLVM at llvm/llvm-project@ecfa874531
...
Updates LLVM usage to match
[ecfa87453113](https://github.com/llvm/llvm-project/commit/ecfa87453113 )
PiperOrigin-RevId: 363495160
2021-03-17 13:33:18 -07:00
A. Unique TensorFlower
f1408e791e
[MLIR][HLO] Add `Elementwise` trait to unary element-wise ops
...
PiperOrigin-RevId: 363428909
2021-03-17 08:51:17 -07:00