Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: MLIR Dialects for TensorFlow #115

Merged
merged 2 commits into from
Nov 11, 2019
Merged

Conversation

joker-eph
Copy link
Contributor

@joker-eph joker-eph commented Jun 13, 2019

This proposal is open for review until 2019-06-27

TensorFlow MLIR Dialects

Status Accepted
Author(s) Mehdi Amini (aminim@google.com)
Tatiana Schpeisman (shpeisman@google.com)
Chris Lattner (clattner@google.com)
Sponsor Alexandre Passos (apassos@google.com)
Jacques Pienaar (jpienaar@google.com)
Updated 2019-06-10

Objective

MLIR is the intermediate representation and compiler framework we are investing in to build the compiler infrastructure for TensorFlow. The representation for TensorFlow exposed in this document will be what future high-level transformations will operate on.

We make use of two different dialects to model TensorFlow graphs in MLIR: first the tf_executor dialect that represents the execution model of the TensorFlow executor (e.g. control dependencies, deadness propagation) and the tf dialect which represent the regular operations in a TensorFlow graph (the ones that don’t have special contract with the executor).

One intent of this design is that TensorFlow 2.x features can choose to target just the tf dialect, allowing us to phase out the tf_executor dialect in subsequent TensorFlow releases. The combination of the two dialects allows to represent arbitrary existing TensorFlow graphs.

The representation in this document does not address the specific needs of accelerators or "custom backends" for TensorFlow. We plan to provide a generic infrastructure for replacing the TF/XLA bridge with a more flexible and reusable system across targets. A later design proposal will address these aspects. Also this representation does not address shape inference, an independent design exploration is being conducted separately at the moment.

@ewilderj ewilderj added the RFC: Proposed RFC Design Document label Jun 13, 2019
@ewilderj
Copy link
Contributor

@joker-eph thanks for the RFC. I note it doesn't have the end of a review period annotated on it. Usually this would be two weeks, ie. 6/27. Are you good with that? If so, I'll add in.

@ewilderj ewilderj changed the title MLIR Dialects for TensorFlow RFC: MLIR Dialects for TensorFlow Jun 13, 2019
@jpienaar
Copy link
Member

@ewilderj That sounds fine yes.

@byronyi
Copy link
Contributor

byronyi commented Jun 17, 2019

I see SendRecvOps mentioned with Eager, but not later-added CollectiveOps. Ping @dubey and @mrry; is this somewhat related to what you've mentioned in the meeting last week?

@mrry
Copy link

mrry commented Jun 17, 2019

@byronyi The collective ops don't (as far as I know) require any special treatment by the executor, so I think they're handled by the TensorFlow dialect.

@ewilderj
Copy link
Contributor

@joker-eph was this RFC accepted by review? If so can you copy any notes from the review meeting here? Then I'll be able to merge it.

@joker-eph
Copy link
Contributor Author

@ewilderj it was accepted! (and implemented)
If I remember correctly, @jpienaar took some notes at the time of some clarifications that were asked to be added in the doc.

@theadactyl theadactyl added RFC: Accepted RFC Design Document: Accepted by Review and removed RFC: Proposed RFC Design Document labels Nov 8, 2019
@theadactyl
Copy link
Contributor

@ewilderj can you add your review so this can be merged?

Change status to Accepted
@ewilderj ewilderj requested a review from theadactyl as a code owner November 11, 2019 18:36
@ewilderj ewilderj merged commit c3aa72e into tensorflow:master Nov 11, 2019
@bhack bhack mentioned this pull request Nov 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes RFC: Accepted RFC Design Document: Accepted by Review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants