diff options
author | 2018-04-28 22:19:22 -0700 | |
---|---|---|
committer | 2018-04-28 22:21:47 -0700 | |
commit | d02745e20c02ba7506a920cc4c8b00415f82ee79 (patch) | |
tree | 1caeccbacfa521d13cf790537bfb24c2e7f7f081 /tensorflow/compiler/xla/service/hlo_cost_analysis_test.cc | |
parent | 3a9c513c3f4303e5194474d804367c1f4831e3ee (diff) |
[TF:XLA]
- Require a module config when creating an HloModule.
- All tests using HloTestBase create a module using CreateNewModule.
PiperOrigin-RevId: 194684585
Diffstat (limited to 'tensorflow/compiler/xla/service/hlo_cost_analysis_test.cc')
-rw-r--r-- | tensorflow/compiler/xla/service/hlo_cost_analysis_test.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tensorflow/compiler/xla/service/hlo_cost_analysis_test.cc b/tensorflow/compiler/xla/service/hlo_cost_analysis_test.cc index 3d055b327e..81cc7c4bdc 100644 --- a/tensorflow/compiler/xla/service/hlo_cost_analysis_test.cc +++ b/tensorflow/compiler/xla/service/hlo_cost_analysis_test.cc @@ -370,8 +370,8 @@ TEST_F(FusionCostAnalysis, LoopFusion) { HloInstruction::CreateBinary(r2f32, HloOpcode::kSubtract, mul, clamp)); auto tuple = HloInstruction::CreateTuple({sub, sub, mul, c1}); - HloModule module(TestName()); - auto* computation = module.AddEntryComputation(builder.Build()); + auto module = CreateNewModule(); + auto* computation = module->AddEntryComputation(builder.Build()); auto* fusion = computation->CreateFusionInstruction( {sub, mul, exp, clamp, add}, HloInstruction::FusionKind::kLoop); @@ -412,8 +412,8 @@ TEST_F(FusionCostAnalysis, NoLayout) { auto add = builder.AddInstruction(HloInstruction::CreateBinary( shape_with_layout, HloOpcode::kAdd, c1, broadcast)); - HloModule module(TestName()); - auto* computation = module.AddEntryComputation(builder.Build()); + auto module = CreateNewModule(); + auto* computation = module->AddEntryComputation(builder.Build()); auto* fusion = computation->CreateFusionInstruction( {add, broadcast}, HloInstruction::FusionKind::kLoop); |