Skip to content

Commit da52a02

Browse files
committed
feedback
1 parent 160a68d commit da52a02

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

lldb/source/API/SBThread.cpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -841,8 +841,10 @@ SBError SBThread::StepOverUntil(lldb::SBFrame &sb_frame,
841841
// function, and then if there are no addresses remaining, give an
842842
// appropriate error message.
843843

844+
// Function block range information is valid even without parsing the entire
845+
// block.
846+
Block &fun_block = frame_sc.function->GetBlock(/*can_create=*/false);
844847
bool all_in_function = true;
845-
AddressRanges fun_ranges = frame_sc.function->GetAddressRanges();
846848

847849
std::vector<addr_t> step_over_until_addrs;
848850
const bool abort_other_plans = false;
@@ -859,9 +861,9 @@ SBError SBThread::StepOverUntil(lldb::SBFrame &sb_frame,
859861
addr_t step_addr =
860862
sc.line_entry.range.GetBaseAddress().GetLoadAddress(target);
861863
if (step_addr != LLDB_INVALID_ADDRESS) {
862-
if (llvm::any_of(fun_ranges, [&](const AddressRange &r) {
863-
return r.ContainsLoadAddress(step_addr, target);
864-
}))
864+
AddressRange unused_range;
865+
if (fun_block.GetRangeContainingLoadAddress(step_addr, *target,
866+
unused_range))
865867
step_over_until_addrs.push_back(step_addr);
866868
else
867869
all_in_function = false;

lldb/test/API/functionalities/thread/step_until/TestStepUntilAPI.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
from lldbsuite.test import lldbutil
55

66

7-
class StepUntilTestCase(TestBase):
7+
class TestStepUntilAPI(TestBase):
88
NO_DEBUG_INFO_TESTCASE = True
99

1010
def setUp(self):

0 commit comments

Comments
 (0)