[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread walter erquinigo via Phabricator via lldb-commits
wallace added a comment. Don't forget to update the description of this diff and of the commit before pushing (you need to do both). Include the avg instruction size for a trace of at least 10k instructions as well :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[Lldb-commits] [PATCH] D122867: [trace][intel pt] Handle better tsc in the decoder

2022-03-31 Thread walter erquinigo via Phabricator via lldb-commits
wallace created this revision. wallace added reviewers: jj10306, zrthxn. Herald added a project: All. wallace requested review of this revision. Herald added a project: LLDB. Herald added a subscriber: lldb-commits. A problem that I introduced in the decoder is that I was considering TSC

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread walter erquinigo via Phabricator via lldb-commits
wallace accepted this revision. wallace added a comment. This revision is now accepted and ready to land. lgtm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122603/new/ https://reviews.llvm.org/D122603

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn added inline comments. Comment at: lldb/source/Plugins/Trace/intel-pt/DecodedThread.h:145 + private: +friend class DecodedThread; + wallace wrote: > jj10306 wrote: > > nit: No need to friend the enclosing class since C++11 - > >

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn updated this revision to Diff 419619. zrthxn marked 3 inline comments as done. zrthxn added a comment. Dont use auto for simple types Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122603/new/ https://reviews.llvm.org/D122603 Files:

[Lldb-commits] [PATCH] D122859: [trace] Show ideas for the main interfaces for new HTR

2022-03-31 Thread walter erquinigo via Phabricator via lldb-commits
wallace created this revision. wallace added reviewers: davidca, clayborg, jj10306. Herald added a project: All. wallace requested review of this revision. Herald added a project: LLDB. Herald added a subscriber: lldb-commits. This diff tries to show the low level structures and the high level

[Lldb-commits] [PATCH] D122523: [lldb] Fix building standalone LLDB on Windows.

2022-03-31 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere accepted this revision as: JDevlieghere. JDevlieghere added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122523/new/ https://reviews.llvm.org/D122523

[Lldb-commits] [PATCH] D122856: [lldb] Refactor DataBuffer so we can map files as read-only

2022-03-31 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere created this revision. JDevlieghere added reviewers: labath, jasonmolenda, clayborg. Herald added subscribers: pmatos, asb, atanasyan, jrtc27, kbarton, sbc100, nemanjai, sdardis, emaste. Herald added a project: All. JDevlieghere requested review of this revision. Herald added

[Lldb-commits] [PATCH] D122848: Reduce extraneous temp strings in debugserver, free objects when they're not longer needed

2022-03-31 Thread Jason Molenda via Phabricator via lldb-commits
jasonmolenda added a comment. I was chatting with Jonas about this a bit. The part of this patch which fixes all of the `SendPacket(outbuf.c_str())` calls, to avoid a temporary copy of the std::string, is clearly necessary and correct. The changes to clear the ostringstreams eagerly after

[Lldb-commits] [lldb] 71ec09b - Revert "[LLDB][NativePDB] Minor fix on inline line table."

2022-03-31 Thread Zequan Wu via lldb-commits
Author: Zequan Wu Date: 2022-03-31T16:07:49-07:00 New Revision: 71ec09b33ef4f378aaad2431c4b2d1140c7f285a URL: https://github.com/llvm/llvm-project/commit/71ec09b33ef4f378aaad2431c4b2d1140c7f285a DIFF: https://github.com/llvm/llvm-project/commit/71ec09b33ef4f378aaad2431c4b2d1140c7f285a.diff

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread walter erquinigo via Phabricator via lldb-commits
wallace added inline comments. Comment at: lldb/source/Plugins/Trace/intel-pt/DecodedThread.h:145 + private: +friend class DecodedThread; + jj10306 wrote: > nit: No need to friend the enclosing class since C++11 - >

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Jakob Johnson via Phabricator via lldb-commits
jj10306 added inline comments. Comment at: lldb/source/Plugins/Trace/intel-pt/DecodedThread.h:145 + private: +friend class DecodedThread; + nit: No need to friend the enclosing class since C++11 - https://en.cppreference.com/w/cpp/language/nested_types

[Lldb-commits] [PATCH] D122848: Reduce extraneous temp strings in debugserver, free objects when they're not longer needed

2022-03-31 Thread Jason Molenda via Phabricator via lldb-commits
jasonmolenda added a comment. In D122848#3420581 , @JDevlieghere wrote: > If debugserver linked against libSupport we could have saved the additional > copy altogether by using `llvm::raw_string_ostream`: > > std::string str; >

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread walter erquinigo via Phabricator via lldb-commits
wallace added a comment. one last nit and good to go Comment at: lldb/source/Plugins/Trace/intel-pt/TraceCursorIntelPT.cpp:82 + + auto dist = FindDistanceAndSetPos(); + m_tsc_range = m_decoded_thread_sp->CalculateTscRange(m_pos); don't use auto for simple

[Lldb-commits] [lldb] 4b2af36 - [LLDB][NativePDB] Minor fix on inline line table.

2022-03-31 Thread Zequan Wu via lldb-commits
Author: Zequan Wu Date: 2022-03-31T14:57:26-07:00 New Revision: 4b2af365b6fadde9e578ca08e6de332388b2f9c2 URL: https://github.com/llvm/llvm-project/commit/4b2af365b6fadde9e578ca08e6de332388b2f9c2 DIFF: https://github.com/llvm/llvm-project/commit/4b2af365b6fadde9e578ca08e6de332388b2f9c2.diff

[Lldb-commits] [PATCH] D122848: Reduce extraneous temp strings in debugserver, free objects when they're not longer needed

2022-03-31 Thread Jason Molenda via Phabricator via lldb-commits
jasonmolenda added inline comments. Comment at: lldb/tools/debugserver/source/RNBRemote.cpp:588 + stream.str(std::string()); + stream.clear(); return SendPacket(payload); JDevlieghere wrote: > `clear` doesn't do what you think it does, it modifies the state

[Lldb-commits] [PATCH] D122848: Reduce extraneous temp strings in debugserver, free objects when they're not longer needed

2022-03-31 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere added a comment. If debugserver linked against libSupport we could have saved the additional copy altogether by using `llvm::raw_string_ostream`: std::string str; llvm::raw_string_ostream stream(str); stream.str() // Flushes and returns a reference to the stack allocated str

[Lldb-commits] [PATCH] D122680: Add a setting to force overwriting commands in "command script add"

2022-03-31 Thread Jim Ingham via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1f7b58f2a504: Add a setting to not require --overwrite to overwrite commands. (authored by jingham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[Lldb-commits] [lldb] 1f7b58f - Add a setting to not require --overwrite to overwrite commands.

2022-03-31 Thread Jim Ingham via lldb-commits
Author: Jim Ingham Date: 2022-03-31T14:15:14-07:00 New Revision: 1f7b58f2a50461493f083b2ed807b25e036286f6 URL: https://github.com/llvm/llvm-project/commit/1f7b58f2a50461493f083b2ed807b25e036286f6 DIFF: https://github.com/llvm/llvm-project/commit/1f7b58f2a50461493f083b2ed807b25e036286f6.diff

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn added inline comments. Comment at: lldb/source/Plugins/Trace/intel-pt/TraceCursorIntelPT.cpp:67-82 switch (origin) { case TraceCursor::SeekType::Set: m_pos = fitPosToBounds(offset); +m_current_tsc = m_decoded_thread_sp->CalculateTscRange(m_pos); return

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn updated this revision to Diff 419560. zrthxn marked 12 inline comments as done. zrthxn added a comment. Incorporate feedback and update tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122603/new/ https://reviews.llvm.org/D122603 Files:

[Lldb-commits] [PATCH] D122848: Reduce extraneous temp strings in debugserver, free objects when they're not longer needed

2022-03-31 Thread Jason Molenda via Phabricator via lldb-commits
jasonmolenda created this revision. jasonmolenda added reviewers: jingham, JDevlieghere. jasonmolenda added a project: LLDB. Herald added a project: All. jasonmolenda requested review of this revision. Herald added a subscriber: lldb-commits. Looking at debugserver's memory use a bit, I noticed

[Lldb-commits] [PATCH] D121844: Applying clang-tidy modernize-use-equals-default over LLDB

2022-03-31 Thread Shafik Yaghmour via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG24f9a2f53db7: [LLDB] Applying clang-tidy modernize-use-equals-default over LLDB (authored by shafik). Herald added a project: LLDB. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[Lldb-commits] [lldb] 24f9a2f - [LLDB] Applying clang-tidy modernize-use-equals-default over LLDB

2022-03-31 Thread Shafik Yaghmour via lldb-commits
Author: Shafik Yaghmour Date: 2022-03-31T13:21:49-07:00 New Revision: 24f9a2f53db78df59761f46ceed3bb5e7aa0d331 URL: https://github.com/llvm/llvm-project/commit/24f9a2f53db78df59761f46ceed3bb5e7aa0d331 DIFF:

[Lldb-commits] [PATCH] D121844: Applying clang-tidy modernize-use-equals-default over LLDB

2022-03-31 Thread Shafik Yaghmour via Phabricator via lldb-commits
shafik updated this revision to Diff 419550. shafik marked 2 inline comments as done. shafik added a comment. - Rebased - Applied clang-format - Address Pavel's comment CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121844/new/ https://reviews.llvm.org/D121844 Files:

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread walter erquinigo via Phabricator via lldb-commits
wallace requested changes to this revision. wallace added a comment. This revision now requires changes to proceed. almost there! Mostly cosmetic changes needed Comment at: lldb/source/Plugins/Trace/intel-pt/DecodedThread.cpp:94-98 + m_instructions.emplace_back(insn); + if

[Lldb-commits] [PATCH] D121967: [LLDB][NativePDB] Create inline function decls

2022-03-31 Thread Zequan Wu via Phabricator via lldb-commits
zequanwu added inline comments. Comment at: lldb/test/Shell/SymbolFile/NativePDB/inline_sites_live.cpp:7 +// RUN: %p/Inputs/inline_sites_live.lldbinit 2>&1 | FileCheck %s + +inline int bar(int bar_param) { labath wrote: > ``` > void __attribute__((optnone))

[Lldb-commits] [PATCH] D121967: [LLDB][NativePDB] Create inline function decls

2022-03-31 Thread Zequan Wu via Phabricator via lldb-commits
zequanwu updated this revision to Diff 419521. zequanwu marked 2 inline comments as done. zequanwu added a comment. Update live debugging test to build with no optimization. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121967/new/

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn updated this revision to Diff 419519. zrthxn added a comment. Updated tests according to new memory usage calculation Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122603/new/ https://reviews.llvm.org/D122603 Files:

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn updated this revision to Diff 419517. zrthxn marked an inline comment as done. zrthxn added a comment. Fixed issue with TSC becoming invalid midway through trace Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122603/new/

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn updated this revision to Diff 419348. zrthxn added a comment. Change tsc check anyway Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122603/new/ https://reviews.llvm.org/D122603 Files: lldb/source/Plugins/Trace/intel-pt/DecodedThread.cpp

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn added inline comments. Comment at: lldb/source/Plugins/Trace/intel-pt/TraceCursorIntelPT.cpp:45-52 +if (!m_current_tsc) + m_current_tsc = m_decoded_thread_sp->CalculateTscRange(m_pos); +else if (!m_current_tsc->InRange(m_pos)) { + if (m_pos >

[Lldb-commits] [PATCH] D122603: [intelpt] Refactor timestamps out of IntelPTInstruction

2022-03-31 Thread Alisamar Husain via Phabricator via lldb-commits
zrthxn updated this revision to Diff 419347. zrthxn marked 23 inline comments as done. zrthxn added a comment. Included requested changes, removed extra members Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122603/new/

[Lldb-commits] [PATCH] D121967: [LLDB][NativePDB] Create inline function decls

2022-03-31 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. In D121967#3403886 , @zequanwu wrote: >> Can you say (in english) what are the properties that you are trying to >> check there? Maybe we can find a better way to do that... > > I'm trying to check for local variables values in