From f4eb9ae9436d72d1406286528331a52c1b3afa1d Mon Sep 17 00:00:00 2001 From: David Brazdil Date: Fri, 17 Apr 2015 18:19:30 +0100 Subject: ART: Fix a failing gtest Stricter assumptions about the state of linear scan caused a reg alloc gtest to fail. Change-Id: I0c568bf996ce6adefe4f000524b38acd3967421e --- compiler/optimizing/register_allocator_test.cc | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/compiler/optimizing/register_allocator_test.cc b/compiler/optimizing/register_allocator_test.cc index c307d98555..182cd0e833 100644 --- a/compiler/optimizing/register_allocator_test.cc +++ b/compiler/optimizing/register_allocator_test.cc @@ -433,18 +433,15 @@ TEST(RegisterAllocatorTest, FreeUntil) { // Add three temps holding the same register, and starting at different positions. // Put the one that should be picked in the middle of the inactive list to ensure // we do not depend on an order. - LiveInterval* interval = LiveInterval::MakeInterval(&allocator, Primitive::kPrimInt); - interval->SetRegister(0); + LiveInterval* interval = LiveInterval::MakeFixedInterval(&allocator, 0, Primitive::kPrimInt); interval->AddRange(40, 50); register_allocator.inactive_.Add(interval); - interval = LiveInterval::MakeInterval(&allocator, Primitive::kPrimInt); - interval->SetRegister(0); + interval = LiveInterval::MakeFixedInterval(&allocator, 0, Primitive::kPrimInt); interval->AddRange(20, 30); register_allocator.inactive_.Add(interval); - interval = LiveInterval::MakeInterval(&allocator, Primitive::kPrimInt); - interval->SetRegister(0); + interval = LiveInterval::MakeFixedInterval(&allocator, 0, Primitive::kPrimInt); interval->AddRange(60, 70); register_allocator.inactive_.Add(interval); -- cgit v1.2.3-59-g8ed1b