Skip to content

Commit b9dcb37

Browse files
committed
Last round of clang-format.
1 parent 53e3104 commit b9dcb37

File tree

2 files changed

+19
-22
lines changed

2 files changed

+19
-22
lines changed

lldb/include/lldb/Target/StackFrameList.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ class StackFrameList {
9494
bool show_frame_info, uint32_t num_frames_with_source,
9595
bool show_unique = false, bool show_hidden = false,
9696
const char *frame_marker = nullptr);
97-
97+
9898
/// Returns whether we have currently fetched all the frames of a stack.
9999
bool WereAllFramesFetched() const;
100100

@@ -118,13 +118,13 @@ class StackFrameList {
118118
/// fetch frames or not.
119119
bool GetFramesUpTo(uint32_t end_idx, InterruptionControl allow_interrupt);
120120

121-
// This should be called with either the reader or writer end of the list
121+
// This should be called with either the reader or writer end of the list
122122
// mutex held:
123-
bool GetAllFramesFetched() const {
124-
return m_concrete_frames_fetched == UINT32_MAX;
123+
bool GetAllFramesFetched() const {
124+
return m_concrete_frames_fetched == UINT32_MAX;
125125
}
126126

127-
// This should be called with the writer end of the list mutex held.
127+
// This should be called with the writer end of the list mutex held.
128128
void SetAllFramesFetched() { m_concrete_frames_fetched = UINT32_MAX; }
129129

130130
bool DecrementCurrentInlinedDepth();
@@ -197,7 +197,7 @@ class StackFrameList {
197197
GetFrameAtIndexNoLock(uint32_t idx,
198198
std::shared_lock<std::shared_mutex> &guard);
199199

200-
/// These two Fetch frames APIs and SynthesizeTailCallFrames are called in
200+
/// These two Fetch frames APIs and SynthesizeTailCallFrames are called in
201201
/// GetFramesUpTo, they are the ones that actually add frames. They must be
202202
/// called with the writer end of the list mutex held.
203203

lldb/source/Target/StackFrameList.cpp

Lines changed: 13 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -341,14 +341,14 @@ void StackFrameList::SynthesizeTailCallFrames(StackFrame &next_frame) {
341341
bool StackFrameList::GetFramesUpTo(uint32_t end_idx,
342342
InterruptionControl allow_interrupt) {
343343
// GetFramesUpTo is always called with the intent to add frames, so get the
344-
// writer lock:
344+
// writer lock:
345345
std::unique_lock<std::shared_mutex> guard(m_list_mutex);
346-
// Now that we have the lock, check to make sure someone didn't get there
346+
// Now that we have the lock, check to make sure someone didn't get there
347347
// ahead of us:
348-
if (m_frames.size() > end_idx || GetAllFramesFetched())
348+
if (m_frames.size() > end_idx || GetAllFramesFetched())
349349
return false;
350350

351-
// Do not fetch frames for an invalid thread.
351+
// Do not fetch frames for an invalid thread.
352352
bool was_interrupted = false;
353353
if (!m_thread.IsValid())
354354
return false;
@@ -371,7 +371,7 @@ bool StackFrameList::GetFramesUpTo(uint32_t end_idx,
371371
Dump(&s);
372372
s.EOL();
373373
#endif
374-
return was_interrupted;
374+
return was_interrupted;
375375
}
376376

377377
void StackFrameList::FetchOnlyConcreteFramesUpTo(uint32_t end_idx) {
@@ -394,9 +394,8 @@ void StackFrameList::FetchOnlyConcreteFramesUpTo(uint32_t end_idx) {
394394
m_frames.resize(num_frames);
395395
}
396396

397-
398397
bool StackFrameList::FetchFramesUpTo(uint32_t end_idx,
399-
InterruptionControl allow_interrupt) {
398+
InterruptionControl allow_interrupt) {
400399
Unwind &unwinder = m_thread.GetUnwinder();
401400
bool was_interrupted = false;
402401

@@ -461,18 +460,17 @@ bool StackFrameList::FetchFramesUpTo(uint32_t end_idx,
461460
break;
462461
}
463462

464-
const bool success = unwinder.GetFrameInfoAtIndex(
465-
idx, cfa, pc, behaves_like_zeroth_frame);
463+
const bool success =
464+
unwinder.GetFrameInfoAtIndex(idx, cfa, pc, behaves_like_zeroth_frame);
466465
if (!success) {
467466
// We've gotten to the end of the stack.
468467
SetAllFramesFetched();
469468
break;
470469
}
471470
const bool cfa_is_valid = true;
472471
unwind_frame_sp = std::make_shared<StackFrame>(
473-
m_thread.shared_from_this(), m_frames.size(), idx, cfa,
474-
cfa_is_valid, pc, StackFrame::Kind::Regular,
475-
behaves_like_zeroth_frame, nullptr);
472+
m_thread.shared_from_this(), m_frames.size(), idx, cfa, cfa_is_valid,
473+
pc, StackFrame::Kind::Regular, behaves_like_zeroth_frame, nullptr);
476474

477475
// Create synthetic tail call frames between the previous frame and the
478476
// newly-found frame. The new frame's index may change after this call,
@@ -637,10 +635,10 @@ StackFrameSP StackFrameList::GetFrameAtIndex(uint32_t idx) {
637635
return {};
638636
}
639637

640-
{ // Now we're accessing m_frames as a reader, so acquire the reader lock.
638+
{ // Now we're accessing m_frames as a reader, so acquire the reader lock.
641639
std::shared_lock<std::shared_mutex> guard(m_list_mutex);
642640
if (idx < m_frames.size()) {
643-
frame_sp = m_frames[idx];
641+
frame_sp = m_frames[idx];
644642
} else if (original_idx == 0) {
645643
// There should ALWAYS be a frame at index 0. If something went wrong
646644
// with the CurrentInlinedDepth such that there weren't as many frames as
@@ -798,8 +796,7 @@ StackFrameList::GetSelectedFrameIndex(SelectMostRelevant select_most_relevant) {
798796
return *m_selected_frame_idx;
799797
}
800798

801-
uint32_t
802-
StackFrameList::SetSelectedFrame(lldb_private::StackFrame *frame) {
799+
uint32_t StackFrameList::SetSelectedFrame(lldb_private::StackFrame *frame) {
803800
std::shared_lock<std::shared_mutex> guard(m_list_mutex);
804801

805802
const_iterator pos;

0 commit comments

Comments
 (0)