aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/compiler/xla/service/hlo_parser.cc
Commit message (Collapse)AuthorAge
* [XLA] Add documentation and HLO-level support for multi-value sort.Gravatar Michael Kuperstein2018-10-09
| | | | | | No support in any of the backends, and not yet exposed through XlaBuilder. PiperOrigin-RevId: 216465753
* Add custom call with layout constraints.Gravatar Mark Heffernan2018-10-08
| | | | | | Add a variant of CustomCall which specifies arbitrary layout constraints on the operands and result. The existing non-layout-constrained CustomCall is changed to have no layout preference and can now be assigned arbitrary layouts by layout assignment. PiperOrigin-RevId: 216249615
* [XLA] In the HLO parser, give the module a non-empty default name.Gravatar A. Unique TensorFlower2018-10-02
| | | | | | Otherwise, when parsing a single instruction, the parsed module doesn't have a name, which won't pass the hlo verifier check. PiperOrigin-RevId: 215519412
* [XLA] Merge the single instruction parsing and the full module parsing in ↵Gravatar A. Unique TensorFlower2018-10-02
| | | | | | one function. PiperOrigin-RevId: 215501702
* [XLA] Support parsing the canonical format of HLO text.Gravatar A. Unique TensorFlower2018-10-02
| | | | | | Also stop truncating operands in the canonical format. PiperOrigin-RevId: 215466465
* Add opaque field to custom call.Gravatar Mark Heffernan2018-09-27
| | | | | | The intent of this field is to enable more information to be encoded in the custom call and passed through to the backend. PiperOrigin-RevId: 214800539
* Add VerifiedHloModule class.Gravatar Mark Heffernan2018-09-19
| | | | | | | | VerifiedHloModule is derived from HloModule and verifies itself on destruction. This is designed to be used in HloVerifiedTestBase. This replaces the current mechanism which verifies HloModules in the TearDown method. The VerifiedHloModule approach is cleaner (less state on the test object) and more capable because these verified HLO modules can be passed to methods which require taking ownership of the module (eg, HlotestBase::Execute). This change required some changes to the parser which enables constructing the parsed HloModule into an already allocated HloModule. Some trivial changes to HloModule are required as well. PiperOrigin-RevId: 213718126
* Global de-std::unique_ptr cleanup for xla::Literal.Gravatar A. Unique TensorFlower2018-09-10
| | | | PiperOrigin-RevId: 212313258
* Add HloSchedule to HloModule.Gravatar Mark Heffernan2018-09-06
| | | | | | | | Add HloSchedule as a field on HloModule. This will enable scheduling to be a normal HLO pass and enable some passes such as copy insertion to more easily use tighter instruction live ranges based on the schedule. This change required adding HloSchedule to the "hlo" library because of circular dependencies. Nothing except for tests actually sets the schedule at the moment, but follow up cls will add a scheduling pass which will do so. PiperOrigin-RevId: 211815293
* Parse feature_group_count attributes of CustomCall ops.Gravatar Adrian Kuegel2018-09-06
| | | | PiperOrigin-RevId: 211762464
* [XLA] Rename PrecisionConfigProto to PrecisionConfigGravatar David Majnemer2018-09-05
| | | | | | The "Proto" suffix adds little clarity but makes a long type name even longer. PiperOrigin-RevId: 211693871
* [XLA] Make kConvolution, kDot HLO attributes mandatoryGravatar David Majnemer2018-09-04
| | | | | | | | HLO transformations would forget to propagate the feature depth attribute. Making these attributes mandatory, while slightly less convenient for tests, makes HLO transformations more robust. PiperOrigin-RevId: 211490160
* [XLA] Add ParsePaddingConfigOnly to HLO parser.Gravatar Justin Lebar2018-08-30
| | | | PiperOrigin-RevId: 211023297
* [XLA] Rename all (Mutable)ArraySlice to absl::Span.Gravatar Tim Shen2018-08-30
| | | | PiperOrigin-RevId: 210998142
* Remove (Mutable)ArraySlice implementation and alias them to absl::Span.Gravatar Tim Shen2018-08-30
| | | | | | | | There are several API migrations happening: * ArraySlice's sub-slice constructor => .subspan * MutableArraySlice's container pointer constructor => absl::MakeSpan PiperOrigin-RevId: 210946124
* [XLA] Implement kIota for CPU & GPU, extend it w/ broadcast semanticsGravatar David Majnemer2018-08-28
| | | | | | | This extends the Iota HLO to have a broadcast field. This allows for higher rank kIota operations. PiperOrigin-RevId: 210600435
* [XLA] Add the xla interface for CollectivePermute.Gravatar A. Unique TensorFlower2018-08-28
| | | | PiperOrigin-RevId: 210576458
* Removed redundant std::string -> string conversions.Gravatar A. Unique TensorFlower2018-08-28
| | | | PiperOrigin-RevId: 210565027
* [XLA] Switch to absl::StrFormat.Gravatar Justin Lebar2018-08-27
| | | | | | | | Unlike Printf, StrFormat does not require type-length qualifiers, e.g %z, %ll. Nor does it require that you call c_str() to print strings. So these are fixed up here as well. PiperOrigin-RevId: 210435915
* [XLA] Use "absl::" rather than "::absl".Gravatar Justin Lebar2018-08-23
| | | | | | Also move 'using' statements into namespaces. PiperOrigin-RevId: 210055083
* [XLA] Remove uses of tensorflow::str_util::SplitAndParseAsInts.Gravatar Justin Lebar2018-08-23
| | | | PiperOrigin-RevId: 210040036
* [XLA] Get rid of some straggling references to tensorflow::str_util.Gravatar Justin Lebar2018-08-23
| | | | PiperOrigin-RevId: 210031885
* [XLA] Switch from tensorflow::str_util::Join to absl::StrJoin.Gravatar Justin Lebar2018-08-23
| | | | PiperOrigin-RevId: 210018843
* [XLA] Use absl string types and functions instead of the TF versions.Gravatar Justin Lebar2018-08-23
| | | | | | | Unfortunately this has to be one big patch, because e.g. absl::StrCat doesn't accept a TF StringPiece, but as soon as we switch to absl::string_view, we have to switch away from all of the TF functions. PiperOrigin-RevId: 209957896
* [XLA] Cleanup Alltoall.Gravatar A. Unique TensorFlower2018-08-22
| | | | | | | | - Remove unused field 'cross_replica_sum_barrier' for Alltoall. - Update cost analysis. There's no computation in Alltoall. - Cleanup stale TODOs. PiperOrigin-RevId: 209814190
* Change subgroup interface for CrossReplicaSumGravatar HyoukJoong Lee2018-08-22
| | | | PiperOrigin-RevId: 209780185
* [XLA] Expose a way to control dot/conv precisionGravatar David Majnemer2018-08-22
| | | | | | | | | | This adds a field to the proto so that we may serialize it. On TPUs, we can simulate higher precision by splitting a float32 number into several bfloat16 numbers such that their sum closely approximates the original number. A tensor contraction operation like convolution or a dot product can be computed by forming several partial products which approximate the correct answer to a closer margin. PiperOrigin-RevId: 209720948
* [XLA] Parse a single HLO instruction's text into a module.Gravatar Chris Leary2018-08-21
| | | | | | Converts "free variable" operands into parameters. PiperOrigin-RevId: 209691261
* [XLA] gtl::optional->absl::optionalGravatar Yunxing Dai2018-08-21
| | | | PiperOrigin-RevId: 209686671
* Remove HostCompute HLO.Gravatar Tong Shen2018-08-21
| | | | | | Now for host compute, we just emit SendToHost & RecvFromHost pairs, and use token to ensure dependency. PiperOrigin-RevId: 209671416
* [XLA] Use absl::make_unique instead of xla::MakeUnique.Gravatar Justin Lebar2018-08-20
| | | | | | Same for WrapUnique. PiperOrigin-RevId: 209531124
* [XLA] Switch to absl versions of the c_foo functions.Gravatar Justin Lebar2018-08-20
| | | | PiperOrigin-RevId: 209502513
* Automated rollback of commit 4a41f50648929197954d892559587cb76458d306Gravatar A. Unique TensorFlower2018-08-17
| | | | PiperOrigin-RevId: 209248552
* [XLA] Switch to absl versions of the c_foo functions.Gravatar Justin Lebar2018-08-17
| | | | PiperOrigin-RevId: 209247783
* Improve gather ergonomics by renaming fields.Gravatar Sanjoy Das2018-08-16
| | | | | | | | | | | | | This CL renames the various inputs to the Gather HLO to be more mnemonic by making it more obviously a batch dynamic-slice. The replacements I made are: s/elided_window_dims/collapsed_slice_dims/g s/window_bounds/slice_sizes/g s/gather_dims_to_operand_dims/start_index_map/g s/gather_indices/start_indices/g s/output_window_dims/offset_dims/g PiperOrigin-RevId: 209051067
* Add a feature_group_size parameter to the Convolution HLO op.Gravatar Adrian Kuegel2018-08-16
| | | | | | | This is a first step towards supporting grouped convolutions, which are a generalization of depthwise convolution. PiperOrigin-RevId: 208950311
* Require token operand for infeed and outfeed.Gravatar Mark Heffernan2018-08-15
| | | | | | For expediency in rolling out support for tokens used for ordering side-effecting ops, infeed and outfeed *optionally* took a token operand. This CL removes that option so all infeed and outfeed instructions take a token operand. PiperOrigin-RevId: 208927968
* Enable arbitrary comments in HLO in both /*...*/ and // forms.Gravatar Mark Heffernan2018-08-13
| | | | | | Allow '/*...*/' and '//' comments to appear anywhere in HLO text, including multi-line comments. Previously only '/*...*/' comments were only allowed and only in certain locations in a serialized Literal. PiperOrigin-RevId: 208519204
* [XLA] Add the xla interface for AllToAll.Gravatar A. Unique TensorFlower2018-08-08
| | | | PiperOrigin-RevId: 207971529
* Remove tile shape from HloShardingGravatar A. Unique TensorFlower2018-08-08
| | | | | | | | The tile shape can be deduced based on the tile assignment and then HLO shape and by not storing it in the sharding we can give more flexibility to the compiler to decide the data layout. PiperOrigin-RevId: 207860794
* [XLA] Add parsing for Scatter.Gravatar A. Unique TensorFlower2018-08-03
| | | | PiperOrigin-RevId: 207349071
* [XLA] Introduce variadic version of reduce.Gravatar Michael Kuperstein2018-08-02
| | | | | | This defines the semantics, and adds parser and shape inference support. Since support is not plumbed through the rest of the compiler here, multi-output reduce is still rejected by the HLO verifier, and is not exposed through XlaBuilder. PiperOrigin-RevId: 207148035
* [XLA] Add Scatter HLO.Gravatar A. Unique TensorFlower2018-08-01
| | | | PiperOrigin-RevId: 207045468
* Fix HLO Parser for checking constant unsigned ranges.Gravatar A. Unique TensorFlower2018-08-01
| | | | PiperOrigin-RevId: 206959456
* [XLA] Parse window and dim_labels that appear on a custom call.Gravatar Justin Lebar2018-07-27
| | | | | | XLA:GPU uses a custom-call with window/dim_labels to represent a call to cudnn. PiperOrigin-RevId: 206339219
* Start implementation of Iota HLO.Gravatar Nick Desaulniers2018-07-20
| | | | PiperOrigin-RevId: 205447892
* Add single-sided host send and receive operations.Gravatar Mark Heffernan2018-07-17
| | | | | | | | Adds a bit on kSend/kReceive instructions and their Done variants indicated whether the operations communicates with the host or another device (the default). Host send/recv operations are single-sided without a complementary recv/send instruction in another module. Host send/recv operations are exposed in the XLA builder API as SendToHost and RecvFromHost. PiperOrigin-RevId: 205008138
* [XLA] Split out HloGatherInstruction as subclass from HloInstruction.Gravatar A. Unique TensorFlower2018-07-12
| | | | PiperOrigin-RevId: 204421652
* [XLA] Generalize sort semantics to Rk.Gravatar Michael Kuperstein2018-07-10
| | | | PiperOrigin-RevId: 203997296
* Add WithToken variants to Send/Recv/Infeed/Outfeed ops in XLA builder.Gravatar Mark Heffernan2018-07-09
| | | | | | | | In HLO side-effecting ops now take and produce a token-shaped value used for ordering. This CL exposes the tokens in the XLA builder interface by adding builder variants suffixed with "WithToken". These variants have an extra token-shaped operand and produce a token, sometimes as a element in the tuple-shaped output of the op. Also, at the HLO level, add new method CreateToken for creating an instruction which produces token-shaped value out of thin air using an AfterAll instruction. This is explicitly broken out from CreateAfterAll to facilitate remove of zero-operand AfterAll instructions (b/110532604). PiperOrigin-RevId: 203834271