aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/compiler/xla/service/BUILD
Commit message (Collapse)AuthorAge
* [XLA] Added xla::CreateModuleFromProto(...) combining loading moduleGravatar A. Unique TensorFlower2018-10-09
| | | | | | from proto and verifying it with HloVerifier. PiperOrigin-RevId: 216447947
* Automated rollback of commit 375c109659d2d0e6265447dffdeb460693b3cccfGravatar A. Unique TensorFlower2018-10-09
| | | | PiperOrigin-RevId: 216350134
* [XLA] Introduce input/output alias config.Gravatar Yunxing Dai2018-10-08
| | | | | | | | - This CL intruduces input/output alias config in HLO module that allows any HLO pass to configure it. Once the alias_config is set, each backend needs to follow the contract during execution time to make sure the input and output are indeed aliased. - Copy insertion / buffer assignment and alias analysis has been updated to correctly honor the config and avoid any possible liveness interference. PiperOrigin-RevId: 216299501
* [XLA] Extend the HLO verifier to check that non-layout-changing instructionsGravatar Bixia Zheng2018-10-05
| | | | | | | | | | | | | | preserve operand layouts. Add an std::function member to the HloVerifier for a backend to specify the function object used to determine whether an instruction can change layouts. Use the function object to find out the non-layout-changing instructions and check that such instructions should produce results with the same layouts as its operands. Add test cases. PiperOrigin-RevId: 215941282
* Rename "Inliner" to "MapInliner".Gravatar Mark Heffernan2018-10-04
| | | | PiperOrigin-RevId: 215801897
* [XLA] Move FusionQueue class declaration into separate headerGravatar A. Unique TensorFlower2018-10-04
| | | | PiperOrigin-RevId: 215783391
* Add proto serialization/deserialization testing to the HLO parser tests.Gravatar Mark Heffernan2018-10-02
| | | | | | | | | | Many of the HLO parser tests verify that an text form of an HLO module preserves all information when running through ToString then parsing. It makes sense to also use these tests to exercise proto serialization/deserialization. This is done by adding additional instantiations of the parameterized parsing tests. This caught several bugs which are fixed in this CL: (1) Domain instructions were not being serialized properly. (2) Host send/recv instructions did not preserve the is_host_transfer bit. (3) Sparse literals could not be serialized or deserialized. PiperOrigin-RevId: 215445200
* [XLA] Fix some outdated comments referring to FlatMapGravatar Benjamin Kramer2018-10-02
| | | | | | Also convert unordered_map to flat/node_hash_map where the comments allow. PiperOrigin-RevId: 215410566
* [XLA] Migrate from gtl::FlatSet to absl::flat_hash_setGravatar Benjamin Kramer2018-10-01
| | | | PiperOrigin-RevId: 215324035
* [XLA] Migrate from gtl::FlatMap to absl::flat_hash_mapGravatar Benjamin Kramer2018-10-01
| | | | PiperOrigin-RevId: 215272497
* Add a flag that lets users override the number of host "devices" as seen by XLAGravatar Sanjoy Das2018-09-21
| | | | | | | | | | | | | | | | | | While overriding it from the default of 1 won't be great for performance, it can help writing tests. The CL is organized as follows: * xla/legacy_flags/debug_options_flags and xla/xla.proto now has a --xla_force_host_platform_device_count flag which defaults to 1. * xla/service/platform_util.cc respects this --xla_force_host_platform_device_count flag. * xla/service/cpu/... has some changes to generalize infeed and outfeed on CPU to work with multiple devices. PiperOrigin-RevId: 214078482
* 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
* Remove non-determinism in model-parallel compilationGravatar HyoukJoong Lee2018-09-19
| | | | PiperOrigin-RevId: 213667385
* Add interface for HLO passes which run on HloModuleGroup.Gravatar Mark Heffernan2018-09-19
| | | | | | Derive HloModulePass and HloModuleGroupPass from HloPassInterface which run module-scoped and module-group-scoped respectively. Replace all existing uses of HloPassInterface with HloModulePass because all existing passes are module-scoped. Also rewrite HloPassPipeline to support both module-scoped and module-group-scoped passes. PiperOrigin-RevId: 213629604
* Add ConstantScalar, WithPredicate, Disjunction, and OpAnyOrder (where OpGravatar Tim Shen2018-09-18
| | | | | | is a commutative binary operator) to the XLA pattern matcher. PiperOrigin-RevId: 213543953
* Add HloModuleGroup abstraction.Gravatar Mark Heffernan2018-09-13
| | | | | | This CL adds HloModuleGroup which is a simple container of HLO modules. The module group gathers together HLO modules which are built to run concurrently across multiple devices. This cl just adds the container class. Later CLs will tie this into other parts of XLA including adding HloModuleGroup HLO passes which operate on an entire module group. PiperOrigin-RevId: 212821390
* Convert a few more tests to hlo_verified_test_base.Gravatar Dimitris Vardoulakis2018-09-12
| | | | PiperOrigin-RevId: 212730899
* Preserve unique ids when serializing/deserializing HLO protos.Gravatar Mark Heffernan2018-09-12
| | | | | | Re-assigning unique IDs broke serialization of HloSchedule, and keeping IDs stable improves the fidelity of the proto serialization. This change requires that instructions in HLO module protos have valid, module-scope-unique ids so change the XLA builder to hand out module-scope-unique ids. Previously, instruction ids were only unique in the computation scope. PiperOrigin-RevId: 212692339
* [XLA] A queue interface to allow fusion in different orders.Gravatar Yuanzhong Xu2018-09-12
| | | | PiperOrigin-RevId: 212674212
* Convert layout_assignment_test to use HloVerifiedTestBase.Gravatar Dimitris Vardoulakis2018-09-10
| | | | PiperOrigin-RevId: 212353819
* [TF:XLA] Migrate unit tests to use the HLO verifier (only tests where the ↵Gravatar Dimitris Vardoulakis2018-09-10
| | | | | | conversion is mostly automated). PiperOrigin-RevId: 212303594
* Make scheduling and rematerialization HLO passes.Gravatar Mark Heffernan2018-09-08
| | | | | | | | Now that HloSchedule is a field on the HLO module, scheduling can be done as an HLO pass. Similarly, rematerialization which requires a schedule can also be a pass which just gets the schedule from the module. Also as a clean up, hoist calls to CopyInsertion out of rematerialization. PiperOrigin-RevId: 212119795
* [TF:XLA] Convert bfloat16_propagation_test and hlo_cse_test to use the HLO ↵Gravatar Dimitris Vardoulakis2018-09-06
| | | | | | verifier. PiperOrigin-RevId: 211854249
* 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
* Rollforward of cl/211656888 after fixing failing unit test.Gravatar Mark Heffernan2018-09-05
| | | | | | | | | | | *** Original change description *** Add HloSchedule class representing a sequential order of an HloModule. Currently we represent a sequential schedule of a module using a SequentialHloOrdering::HloModuleSequence which is a type alias of a bare map from HloComputation* to std::vector<HloInstruction*>. This CL replaces this with a proper class which results in better encap... *** PiperOrigin-RevId: 211726890
* [XLA] Make tensorflow/compiler use absl::{StrCat,string_view,InlinedVector} ↵Gravatar Benjamin Kramer2018-09-05
| | | | | | | | consistently StringPiece is an alias for absl::string_view, InlinedVector is aliased to absl::InlinedVector. StrCat is compatible, so swapping it out is safe. PiperOrigin-RevId: 211691840
* BEGIN_PUBLICGravatar Mark Heffernan2018-09-05
| | | | | | Automated rollback of commit 7fa693209fe238478739b3982f652a7e35be91f3 PiperOrigin-RevId: 211681957
* Add HloSchedule class representing a sequential order of an HloModule.Gravatar Mark Heffernan2018-09-05
| | | | | | | | Currently we represent a sequential schedule of a module using a SequentialHloOrdering::HloModuleSequence which is a type alias of a bare map from HloComputation* to std::vector<HloInstruction*>. This CL replaces this with a proper class which results in better encapsulation of code which deals with schedules and better enforcement of invariants. This CL also fixes a corner-case bug in dataflow analysis, where values of instructions which are live out of the computation erroneously did not interfere with the values of instructions scheduled after the root instruction. PiperOrigin-RevId: 211656888
* [XLA] Don't show trivial feature_group_count attributesGravatar David Majnemer2018-09-04
| | | | | | | | If the feature_group_count is 1, don't bother showing it as it is not very informative and a very common scenario. This is consistent with the HloCustomCall's feature_group_count attribute. PiperOrigin-RevId: 211560372
* Change headers to directly include absl::Span, and clean up the buildGravatar Tim Shen2018-08-30
| | | | | | dependencies as well. PiperOrigin-RevId: 211038094
* Convert a couple more test files to HloVerifiedTestBase, and add default ↵Gravatar Dimitris Vardoulakis2018-08-29
| | | | | | arguments to the constructor to remove some boilerplate. PiperOrigin-RevId: 210855509
* New XLA API to launch a program.Gravatar Yunxing Dai2018-08-29
| | | | | | | 1. Propose a new API with ability to do input/output. 2. Start to enable ABSL in TF's codebase. PiperOrigin-RevId: 210783617
* [TF:XLA] Verify HLOs in buffer_assignment_test and hlo_instruction_test.Gravatar Dimitris Vardoulakis2018-08-29
| | | | PiperOrigin-RevId: 210760569
* [XLA] Add support for algebraic simplifications involving kIotaGravatar David Majnemer2018-08-28
| | | | PiperOrigin-RevId: 210634966
* [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
* [TF:XLA] Run the points-to analysis for a module group.Gravatar Dimitris Vardoulakis2018-08-27
| | | | PiperOrigin-RevId: 210483654
* Use a mixin to reduce llvm::IRBuilder<> related boilerplate.Gravatar Sanjoy Das2018-08-27
| | | | PiperOrigin-RevId: 210472260
* [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
* Run AddSpecialCaseCopies in HloRematerialization.Gravatar Mark Heffernan2018-08-24
| | | | | | RemoveUnnecessaryCopies which runs in rematerialization to take advantage of scheduling can sometimes remove copies which are needed to non-interference reasons. This requires running AddSpecialCaseCopies to add them back in. Furthermore, the schedule needs to be updated to account for the changes to the module, so add an UpdateSchedule function which can patch up a schedule in light a limited set of transformations to the module (addition and deletion of instructions). PiperOrigin-RevId: 210186375
* [XLA] Stop including str_util.h.Gravatar Justin Lebar2018-08-23
| | | | PiperOrigin-RevId: 210049592
* [XLA] Centralize BF16Normalization Tuple handlingGravatar Michael Kuperstein2018-08-23
| | | | | | As more tuple-producing ops are added, this probably makes more sense. PiperOrigin-RevId: 210039265
* [XLA] Switch from tensorflow::str_util::Join to absl::StrJoin.Gravatar Justin Lebar2018-08-23
| | | | PiperOrigin-RevId: 210018843
* [TF:XLA] Make the two functions for computing HLO buffer interference ↵Gravatar A. Unique TensorFlower2018-08-23
| | | | | | | | | | | | | | consistent. Consider only real uses of fusion parameters when computing buffer interference using HloDataflowAnalysis. This is a step in unifying our HLO dataflow framework to a single source of truth and improves HloOrdering::LiveRangeStrictlyBefore to match the behavior of BufferLiveness::live_range_strictly_before (which uses TuplePointsToAnalysis) PiperOrigin-RevId: 209966644
* [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] 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
* Merged commit includes the following changes:Gravatar Yifei Feng2018-08-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 209663919 by yifeif<yifeif@google.com>: Internal change. -- 209663914 by amitpatankar<amitpatankar@google.com>: Fix the topk_op_test for numpy>1.15. -- 209660476 by jdduke<jdduke@google.com>: Fix model lifetime for TensorFlow Lite C# bindings Ensure the model's existence for the duration of the interpreter, as per API requirements. -- 209655960 by scottzhu<scottzhu@google.com>: Unify RNN Cell interface between TF and Keras. -- 209655731 by A. Unique TensorFlower<gardener@tensorflow.org>: Added tests for PredictionOps and PartitionExamplesOps -- 209655291 by nolivia<nolivia@google.com>: adding rate class so that we can save global_step/sec using tf.contrib.summary. The function takes the rate in relation to any tensors provided that the numerator and denominator are broadcastable and have dtypes that can be cast to float64 -- 209654655 by kramerb<kramerb@google.com>: [XLA] Switch from tensorflow::gtl::InlinedVector to absl::InlinedVector This one comes with extra goodies like a move constructor. -- 209653851 by A. Unique TensorFlower<gardener@tensorflow.org>: Internal build specification change -- PiperOrigin-RevId: 209663919
* [XLA] Propagate invalid shape errors through reduce folding and turn it onGravatar Benjamin Kramer2018-08-21
| | | | | | | | HloEvaluator should be stable enough for reduce folding, but it shouldn't crash when it encounters an instruction without a layout. Verify the layout on every instruction that gets evaluated and return an error on failure. PiperOrigin-RevId: 209641401
* In HostCompute op, use SendToHost/RecvFromHost instead of Send/Recv.Gravatar Tong Shen2018-08-21
| | | | PiperOrigin-RevId: 209617148
* [XLA] Use absl::make_unique instead of xla::MakeUnique.Gravatar Justin Lebar2018-08-20
| | | | | | Same for WrapUnique. PiperOrigin-RevId: 209531124