Page MenuHomePhabricator

mravishankar (Mahesh Ravishankar)
User

Projects

User does not belong to any projects.

User Details

User Since
Jan 6 2015, 1:11 PM (326 w, 6 d)

Recent Activity

Yesterday

mravishankar accepted D100337: [mlir][spirv] Fix runtime array stride when emulating bitwidth.
Mon, Apr 12, 1:44 PM · Restricted Project
mravishankar accepted D100335: [mlir][spirv] Allow bitwidth emulation on runtime arrays.
Mon, Apr 12, 1:40 PM · Restricted Project
mravishankar accepted D100326: [mlir] Move memref.subview patterns to Memref/Transforms/.
Mon, Apr 12, 1:36 PM · Restricted Project
mravishankar committed rGb0fc712b14ff: [mlir][Linalg] Disable const -> linalg.generic when fused op is illegal. (authored by mravishankar).
[mlir][Linalg] Disable const -> linalg.generic when fused op is illegal.
Mon, Apr 12, 10:16 AM
mravishankar closed D100272: [mlir][Linalg] Disable const -> linalg.generic when fused op is illegal..
Mon, Apr 12, 10:16 AM · Restricted Project
mravishankar added inline comments to D100272: [mlir][Linalg] Disable const -> linalg.generic when fused op is illegal..
Mon, Apr 12, 8:48 AM · Restricted Project

Sun, Apr 11

mravishankar added reviewers for D100272: [mlir][Linalg] Disable const -> linalg.generic when fused op is illegal.: asaadaldien, hanchung.
Sun, Apr 11, 1:58 PM · Restricted Project
mravishankar requested review of D100272: [mlir][Linalg] Disable const -> linalg.generic when fused op is illegal..
Sun, Apr 11, 1:58 PM · Restricted Project

Thu, Apr 8

mravishankar committed rGf4eb681dc37a: [mlir][Linalg] Drop unit-trip loops of reductions only if other reduction loops… (authored by mravishankar).
[mlir][Linalg] Drop unit-trip loops of reductions only if other reduction loops…
Thu, Apr 8, 10:32 PM
mravishankar closed D100145: [mlir][Linalg] Drop unit-trip loops of reductions only if other reduction loops exists..
Thu, Apr 8, 10:31 PM · Restricted Project
mravishankar accepted D99824: [mlir][tosa] Add tosa.max_pool2d lowering to linalg int max pooling additions.

Looks fine to me except for use of C++-14 feature which might cause build issues. So LGTM apart from that issue. Please make sure no bots are broken

Thu, Apr 8, 5:21 PM · Restricted Project
mravishankar requested changes to D99824: [mlir][tosa] Add tosa.max_pool2d lowering to linalg int max pooling additions.
Thu, Apr 8, 4:09 PM · Restricted Project
mravishankar added reviewers for D100145: [mlir][Linalg] Drop unit-trip loops of reductions only if other reduction loops exists.: hanchung, antiagainst.
Thu, Apr 8, 2:52 PM · Restricted Project
mravishankar requested review of D100145: [mlir][Linalg] Drop unit-trip loops of reductions only if other reduction loops exists..
Thu, Apr 8, 2:51 PM · Restricted Project
mravishankar accepted D100112: [mlir][linalg] Fix loop upper bounds in conv fusion test.
Thu, Apr 8, 9:09 AM · Restricted Project

Wed, Apr 7

mravishankar requested changes to D99824: [mlir][tosa] Add tosa.max_pool2d lowering to linalg int max pooling additions.
Wed, Apr 7, 11:47 AM · Restricted Project

Mon, Apr 5

mravishankar committed rG944a2fe7633f: [mlir][Linalg] Add callbacks to fusion of elementwise operations to control… (authored by mravishankar).
[mlir][Linalg] Add callbacks to fusion of elementwise operations to control…
Mon, Apr 5, 4:09 PM
mravishankar closed D99820: [mlir][Linalg] Add callbacks to fusion of elementwise operations to control fusion..
Mon, Apr 5, 4:09 PM · Restricted Project
mravishankar updated the diff for D99820: [mlir][Linalg] Add callbacks to fusion of elementwise operations to control fusion..

Fixing builds

Mon, Apr 5, 3:44 PM · Restricted Project
mravishankar added inline comments to D99820: [mlir][Linalg] Add callbacks to fusion of elementwise operations to control fusion..
Mon, Apr 5, 3:35 PM · Restricted Project
mravishankar updated the diff for D99820: [mlir][Linalg] Add callbacks to fusion of elementwise operations to control fusion..

Addressing comments.

Mon, Apr 5, 3:34 PM · Restricted Project
mravishankar committed rGea069aebccd3: [mlir][Linalg] NFC: Move populatePatterns* method into linalg namespace. (authored by mravishankar).
[mlir][Linalg] NFC: Move populatePatterns* method into linalg namespace.
Mon, Apr 5, 11:16 AM
mravishankar closed D99819: [mlir][Linalg] NFC: Move populatePatterns* method into linalg namespace..
Mon, Apr 5, 11:16 AM · Restricted Project
mravishankar updated the diff for D99819: [mlir][Linalg] NFC: Move populatePatterns* method into linalg namespace..

Drop "Linalg" in populateLinalgFoldUnitExtentDimsPattern.

Mon, Apr 5, 11:01 AM · Restricted Project
mravishankar added a reviewer for D99819: [mlir][Linalg] NFC: Move populatePatterns* method into linalg namespace.: silvas.
Mon, Apr 5, 9:35 AM · Restricted Project

Fri, Apr 2

mravishankar added reviewers for D99820: [mlir][Linalg] Add callbacks to fusion of elementwise operations to control fusion.: hanchung, antiagainst.
Fri, Apr 2, 3:24 PM · Restricted Project
mravishankar requested review of D99820: [mlir][Linalg] Add callbacks to fusion of elementwise operations to control fusion..
Fri, Apr 2, 3:24 PM · Restricted Project
mravishankar added reviewers for D99819: [mlir][Linalg] NFC: Move populatePatterns* method into linalg namespace.: hanchung, antiagainst.
Fri, Apr 2, 3:24 PM · Restricted Project
mravishankar requested review of D99819: [mlir][Linalg] NFC: Move populatePatterns* method into linalg namespace..
Fri, Apr 2, 3:24 PM · Restricted Project
mravishankar added a comment to D99779: [mlir] Rename linalg.pooling operations to have a FOp postfix for floating point.

Just a thought if we want to just rename them to F32. But this path is on deprecation, so I dont really care.

Fri, Apr 2, 9:49 AM · Restricted Project

Thu, Apr 1

mravishankar accepted D99779: [mlir] Rename linalg.pooling operations to have a FOp postfix for floating point.
Thu, Apr 1, 11:07 PM · Restricted Project
mravishankar accepted D99725: [mlir][spirv] Add utilities for push constant value.
Thu, Apr 1, 2:30 PM · Restricted Project
mravishankar committed rG3ba1b1cd201d: Add a pattern to combine composed subview ops (authored by agrue).
Add a pattern to combine composed subview ops
Thu, Apr 1, 10:57 AM
mravishankar closed D99229: Add a pattern to combine composed subview ops.
Thu, Apr 1, 10:57 AM · Restricted Project

Wed, Mar 31

mravishankar accepted D99229: Add a pattern to combine composed subview ops.

LGTM-ing this based on the strides being checked ahead of time (instead of in the loop)

Wed, Mar 31, 2:21 PM · Restricted Project
mravishankar requested changes to D99229: Add a pattern to combine composed subview ops.

Thanks. Just a few minor nits, this time around.

Wed, Mar 31, 11:26 AM · Restricted Project

Mon, Mar 29

mravishankar added a comment to D99558: [mlir][linalg] Add extra pattern to AffineMinSCFCanonicalization.

It is very specific use case :) .
I am fine with this since it is probably a stop-gap solution. Ill let @nicolasvasilache decide if this lives in core.
Treat as LGTM from me, but just dont want to stamp it till I see what Nicolas has to say.

Mon, Mar 29, 10:34 PM · Restricted Project
mravishankar committed rGc4d5b956170d: Fix broken build for commit 9b0517035faee275ce1feabb03d0c7606ea7f819 (authored by mravishankar).
Fix broken build for commit 9b0517035faee275ce1feabb03d0c7606ea7f819
Mon, Mar 29, 12:49 PM
mravishankar closed D99533: Fix broken build for commit 9b0517035faee275ce1feabb03d0c7606ea7f819.
Mon, Mar 29, 12:48 PM · Restricted Project
mravishankar added a reviewer for D99533: Fix broken build for commit 9b0517035faee275ce1feabb03d0c7606ea7f819: mehdi_amini.
Mon, Mar 29, 12:35 PM · Restricted Project
mravishankar requested review of D99533: Fix broken build for commit 9b0517035faee275ce1feabb03d0c7606ea7f819.
Mon, Mar 29, 12:34 PM · Restricted Project
mravishankar committed rG9b0517035fae: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them. (authored by mravishankar).
[mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them.
Mon, Mar 29, 11:40 AM
mravishankar closed D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Mon, Mar 29, 11:40 AM · Restricted Project
mravishankar committed rGf0a2fe7f79d7: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend… (authored by mravishankar).
[mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend…
Mon, Mar 29, 9:20 AM
mravishankar closed D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..
Mon, Mar 29, 9:19 AM · Restricted Project
mravishankar committed rG7d8b478ce13c: [mlir][Linalg] Drop spurious error message (authored by mravishankar).
[mlir][Linalg] Drop spurious error message
Mon, Mar 29, 9:18 AM
mravishankar closed D99485: [mlir][Linalg] Drop spurious error message.
Mon, Mar 29, 9:17 AM · Restricted Project
mravishankar updated the diff for D99485: [mlir][Linalg] Drop spurious error message.

Remove unnecessary flag from test.

Mon, Mar 29, 9:16 AM · Restricted Project

Sun, Mar 28

mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Rebase

Sun, Mar 28, 11:37 PM · Restricted Project
mravishankar added reviewers for D99485: [mlir][Linalg] Drop spurious error message: hanchung, antiagainst.
Sun, Mar 28, 10:28 PM · Restricted Project
mravishankar updated the diff for D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..

Rebase.

Sun, Mar 28, 10:28 PM · Restricted Project
mravishankar requested review of D99485: [mlir][Linalg] Drop spurious error message.
Sun, Mar 28, 10:27 PM · Restricted Project
mravishankar added a comment to D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..

@nicolasvasilache did you mean to approve the patch?

Sun, Mar 28, 9:57 PM · Restricted Project

Sat, Mar 27

mravishankar requested changes to D99229: Add a pattern to combine composed subview ops.
Sat, Mar 27, 3:02 PM · Restricted Project

Fri, Mar 26

mravishankar added a comment to D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..

Still, it seems we aggressively use reshape to drop 1 dimensions even in the absence of function boundaries.

Maybe a solution would be to have extra canonicalizations:

  • subtensor + reshape -> rank-reducing subtensor
  • reshape + subtensor_insert -> rank-expanding subtensor_insert
Fri, Mar 26, 12:14 AM · Restricted Project

Wed, Mar 24

mravishankar accepted D99116: [mlir][linalg] Fold init_tensor -> fill -> tensor_reshape chain.

LGTM. Just a few renaming nits.

Wed, Mar 24, 2:57 PM · Restricted Project
mravishankar accepted D99015: [mlir][affine] Deduplicate affine min/max op expressions.
Wed, Mar 24, 2:55 PM · Restricted Project
mravishankar added inline comments to D99116: [mlir][linalg] Fold init_tensor -> fill -> tensor_reshape chain.
Wed, Mar 24, 11:59 AM · Restricted Project
mravishankar added a comment to D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..

THis is doing something different. It is reducing the rank of both the source and the dest, so

Wed, Mar 24, 9:50 AM · Restricted Project
mravishankar updated the diff for D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..

Actually fix the test

Wed, Mar 24, 8:57 AM · Restricted Project

Tue, Mar 23

mravishankar updated the diff for D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..

Fix test error.

Tue, Mar 23, 9:49 PM · Restricted Project
mravishankar added reviewers for D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension.: antiagainst, hanchung.
Tue, Mar 23, 4:53 PM · Restricted Project
mravishankar requested review of D99226: [mlir][Linalg] Rewrite SubTensors that take a slice out of a unit-extend dimension..
Tue, Mar 23, 4:52 PM · Restricted Project
mravishankar abandoned D98478: [mlir] Remove unsafe tensor_to_memref -> load canonicalization pattern..

Abandoning this for now (see https://llvm.discourse.group/t/tensor-to-memref-and-its-folding/3033)

Tue, Mar 23, 11:59 AM · Restricted Project
mravishankar accepted D99016: [mlir][affine] Add canonicalization to merge affine min/max ops.

Mostly looks fine to me, but probably someone with more context on these (like Nicolas or Uday) might have comments.

Tue, Mar 23, 11:39 AM · Restricted Project
mravishankar requested changes to D99015: [mlir][affine] Deduplicate affine min/max op expressions.
Tue, Mar 23, 11:35 AM · Restricted Project
mravishankar accepted D99013: [linalg] NFC: Move makeTiledShapes into Utils.{h|cpp}.

This looks fine to me too. I dont know if @nicolasvasilache has comments here.

Tue, Mar 23, 11:33 AM · Restricted Project

Mon, Mar 22

mravishankar resigned from D98937: [mlir] introduce data layout entry for index type.
Mon, Mar 22, 10:45 PM · Restricted Project
mravishankar requested changes to D99116: [mlir][linalg] Fold init_tensor -> fill -> tensor_reshape chain.
Mon, Mar 22, 10:42 PM · Restricted Project
mravishankar accepted D99115: [mlir][linalg] Support dropping unit dimensions for init tensors.

LGTM after minor nit is addressed

Mon, Mar 22, 10:41 PM · Restricted Project
mravishankar accepted D99114: [mlir][linalg] Allow controlling folding unit dim reshapes.

THanks!

Mon, Mar 22, 10:40 PM · Restricted Project
mravishankar accepted D99014: [mlir][linalg] Fuse producers with non-permutation indexing maps.

Nice! Mostly looks fine to me.

Mon, Mar 22, 10:39 PM · Restricted Project

Fri, Mar 19

mravishankar added inline comments to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Fri, Mar 19, 4:38 PM · Restricted Project
mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Addressing comments.

Fri, Mar 19, 4:37 PM · Restricted Project

Thu, Mar 18

mravishankar added inline comments to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Thu, Mar 18, 9:47 PM · Restricted Project
mravishankar retitled D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them. from [mlir][Linalg] Add an interface in Linalg to infer shapes of Linalg Ops. to [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Thu, Mar 18, 9:41 PM · Restricted Project
mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Going back to the implementation which updated the interface of
InferShapedTypeInterface but dropping the use of OpFoldResult.

Thu, Mar 18, 9:40 PM · Restricted Project
mravishankar added a comment to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

I have not yet dug into the guts of the discussion and the implementation details, I'll just comment on 2 things:

There was push back against using OpFoldResult instead of Value. From experience the use of OpFoldResult is really important.

Where it makes sense, it is crucial to move towards a ValueOrAttr abstraction rather than stay stuck in Value land.
Maybe it does not (yet?) make sense for the Shape world and that is perfectly fine.

I find it funny how folks (excl Stephan) miss something very simple here: the method that was being changed is called reify. It reifies the shape computation, it doesn't potential reify. So Attributes doesn't makes sense. The caller expects a Value corresponding to the reified shape computation. This would be like having a build method and the build may or may not build (even createOrFold returns a Value rather than an attribute), or materializeConstant which decides to not materialize. It means the caller would need to check which state is made and then create a constant op or not, so this pushes work on to the caller if we were to relax it.

Attributes aren't free here either: if you wanted to avoid overhead during inference an int or an arrayref<int> or ShapedComponentType is better as for intermediate shapes during inference or when using existing shapes from a ShapedType, you don't want to create an attribute. That is uniqueing it in the context without need, it never needs to be a attribute (it isn't one in the final result type contrary to folding where it may be part of the constant op finally created, so there it is only potentially wasteful to make an attribute, here it would always be). But again that is a different method than reify.

Thu, Mar 18, 11:17 AM · Restricted Project

Mon, Mar 15

mravishankar requested changes to D98507: [mlir][spirv] Avoid struct wrapping in non-interface storage class.

Wondering if there is a problem if we have the struct all the time. One of the issues on SPIR-V side is that we cannot do pointer casts. So a memref_cast where the operand is from something that doesnt need layout to something that does need layout would be not possible support. In general, there is no information of where the memref came from, so we might end up in situations where we cannot lower such memref_cast. If there is no reason to not have a struct, it seems more uniform to have a struct by default for all memref types.

Mon, Mar 15, 12:27 PM · Restricted Project

Mar 11 2021

mravishankar added a reviewer for D98478: [mlir] Remove unsafe tensor_to_memref -> load canonicalization pattern.: silvas.
Mar 11 2021, 9:07 PM · Restricted Project
mravishankar requested review of D98478: [mlir] Remove unsafe tensor_to_memref -> load canonicalization pattern..
Mar 11 2021, 9:07 PM · Restricted Project
mravishankar requested changes to D98390: Added static verification for Linalg Ops..

Probably need a test that fails as well and verify the error message. You can use -verify-diagnostics on the command line, and match the error using // expected-error . See other tests that have this.

Mar 11 2021, 12:00 PM · Restricted Project
mravishankar added inline comments to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Mar 11 2021, 11:27 AM · Restricted Project
mravishankar added inline comments to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Mar 11 2021, 11:24 AM · Restricted Project
mravishankar added inline comments to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Mar 11 2021, 11:23 AM · Restricted Project
mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Document the interface scope better.

Mar 11 2021, 11:22 AM · Restricted Project

Mar 10 2021

mravishankar added a comment to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

I think there are larger disagreements about how the shape inference work should evolve. I am not aware of all the opinions here and cannot comment on those.

I'm not plugged into the details here, but if there is a disagreement it should be addressed. I reiterate what I wrote above: it seems like moving this to Linalg is kind of working around the lack of consensus, do I miss something here?

Any suggestions of how to proceed. I am honestly not the person who can drive consensus here cause I do not have the larger context in which the upstream interface is designed. Based on offline discussion this was decided as an intermediate step till the pieces can be merged. This is going to be a simple interface with very fixed functionality. I'll leave it to @nicolasvasilache and @stellaraccident to decide if this is worth landing here or not. I need this functionality so if this is a no-go, I will have to find less diserable WAR solutions (either in Linalg or in IREE).

I can review the thread and try to catch up later, but if there is a conflicting opinion on the shape side, we probably need to resolve it with jpienaar, and i think he is out until next week.

Mar 10 2021, 9:12 PM · Restricted Project
mravishankar added a comment to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

I think there are larger disagreements about how the shape inference work should evolve. I am not aware of all the opinions here and cannot comment on those.

I'm not plugged into the details here, but if there is a disagreement it should be addressed. I reiterate what I wrote above: it seems like moving this to Linalg is kind of working around the lack of consensus, do I miss something here?

Mar 10 2021, 7:01 PM · Restricted Project
mravishankar added a comment to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

For the time being moving the interface into Linalg. We can unify them once we iron out all the API of the interface. I am happy to pick that up based on what is finally converged upon.

What's the plan to get there? It seems like moving this to linalg is kind of working around the lack of consensus on the API, in practice it seems like it can split the implementation into "Linalg-specific" things and the general case, which will lead to implementations of analysis that are linalg specific. While there are many reasons to have Linalg-specific analysis/transformations, I'm not sure this is such a case (which seems acknowledge by your sentence I'm quoting here).

Mar 10 2021, 3:51 PM · Restricted Project
mravishankar added inline comments to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Mar 10 2021, 3:29 PM · Restricted Project
mravishankar retitled D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them. from [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them. to [mlir][Linalg] Add an interface in Linalg to infer shapes of Linalg Ops..
Mar 10 2021, 3:17 PM · Restricted Project
mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Fix build file.

Mar 10 2021, 2:59 PM · Restricted Project
mravishankar added a comment to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

@herhut Had some offline discussions with Jacques. For the time being moving the interface into Linalg. We can unify them once we iron out all the API of the interface. I am happy to pick that up based on what is finally converged upon.

Mar 10 2021, 2:56 PM · Restricted Project
mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Moving the interface into Linalg for now till can converge on using InferShapedTypeOpInterface

Mar 10 2021, 2:44 PM · Restricted Project

Mar 9 2021

mravishankar added inline comments to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..
Mar 9 2021, 3:04 PM · Restricted Project

Mar 8 2021

mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Rebase and remove unused methods.

Mar 8 2021, 4:34 PM · Restricted Project
mravishankar accepted D98171: [mlir] Use affine.apply when distributing to processors.

Awesome! Thanks Lei for tracking this down! LGTM

Mar 8 2021, 3:21 PM · Restricted Project
mravishankar updated the diff for D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

Rebase and address concerns from offline conversation

Mar 8 2021, 3:18 PM · Restricted Project

Mar 4 2021

mravishankar accepted D97893: [MLIR][TOSA] Added lowerings for Reduce operations to Linalg.

Looks good. Just one nit.

Mar 4 2021, 10:00 PM · Restricted Project
mravishankar added a comment to D97887: [mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them..

I folded things into a single patch. (Was planning to do that, sorry wasnt explicit before).

Mar 4 2021, 10:14 AM · Restricted Project