[Lldb-commits] [PATCH] D42443: [SymbolFilePDB] Add support for function symbols

2018-01-23 Thread Aaron Smith via Phabricator via lldb-commits
asmith created this revision. asmith added reviewers: zturner, lldb-commits. Herald added a subscriber: llvm-commits. This is combination of following changes, - Resolve function symbols in PDB symbol file. `lldb-test symbols` will display information about function symbols. - Implement

[Lldb-commits] [PATCH] D42434: [SymbolFilePDB] Fix null array access when parsing the type of a function without any arguments, i.e. 'int main()' and add support to test it

2018-01-23 Thread Aaron Smith via Phabricator via lldb-commits
asmith updated this revision to Diff 131129. asmith added a comment. Fix BCD typo https://reviews.llvm.org/D42434 Files: lit/SymbolFile/PDB/Inputs/SimpleTypesTest.cpp lit/SymbolFile/PDB/enums-layout.test lit/SymbolFile/PDB/typedefs.test source/Plugins/SymbolFile/PDB/PDBASTParser.cpp

[Lldb-commits] [PATCH] D42434: [SymbolFilePDB] Fix null array access when parsing the type of a function without any arguments, i.e. 'int main()' and add support to test it

2018-01-23 Thread Zachary Turner via Phabricator via lldb-commits
zturner accepted this revision. zturner added a comment. This revision is now accepted and ready to land. looks good. May as well fix the BCD typo while you're here though (either here or in a followup patch) Repository: rL LLVM https://reviews.llvm.org/D42434

[Lldb-commits] [PATCH] D42434: [SymbolFilePDB] Fix null array access when parsing the type of a function without any arguments, i.e. 'int main()' and add support to test it

2018-01-23 Thread David Majnemer via Phabricator via lldb-commits
majnemer added inline comments. Comment at: source/Plugins/SymbolFile/PDB/PDBASTParser.cpp:162-163 +return ConstString("HRESULT"); + case PDB_BuiltinType::BCD: +return ConstString("HRESULT"); + case PDB_BuiltinType::None: Copy paste bug? Repository:

[Lldb-commits] [PATCH] D42434: [SymbolFilePDB] Fix null array access when parsing the type of a function without any arguments, i.e. 'int main()' and add support to test it

2018-01-23 Thread Aaron Smith via Phabricator via lldb-commits
asmith added a comment. https://reviews.llvm.org/D41427 was reverted because the commit was missing some of the binary files for the tests. This is the same as https://reviews.llvm.org/D41427 without the binary files. I've dropped them since there are lit tests for the same functionality now.

[Lldb-commits] [PATCH] D42434: [SymbolFilePDB] Fix null array access when parsing the type of a function without any arguments, i.e. 'int main()' and add support to test it

2018-01-23 Thread Aaron Smith via Phabricator via lldb-commits
asmith created this revision. asmith added reviewers: zturner, lldb-commits. Herald added a subscriber: llvm-commits. - Fix a null array access bug. This happens when creating the lldb type for a function that has no argument. - Implement SymbolFilePDB::ParseTypes method. Using `lldb-test

[Lldb-commits] [PATCH] D42277: Use test-specific module caches to avoid stale header conflicts

2018-01-23 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added a comment. Okay got it. I'll investigate the PR separately. https://reviews.llvm.org/D42277 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [PATCH] D42277: Use test-specific module caches to avoid stale header conflicts

2018-01-23 Thread Vedant Kumar via Phabricator via lldb-commits
vsk added a comment. In https://reviews.llvm.org/D42277#985002, @aprantl wrote: > > Skip tests which fail when -fmodules is passed > > (https://bugs.llvm.org/show_bug.cgi?id=36048). > > Wait.. this patch is not supposed to change the set of tests that get > -fmodules passed to them. It should

Re: [Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Tatyana Krasnukha via lldb-commits
Like this idea of using breakpoint resolver very much. It's exactly how I see debugger's proper work in such cases. > -Original Message- > From: jing...@apple.com [mailto:jing...@apple.com] > Sent: Tuesday, 23 January, 2018 8:43 PM > To:

[Lldb-commits] [PATCH] D42281: WIP: compile the LLDB tests out-of-tree

2018-01-23 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added inline comments. Comment at: packages/Python/lldbsuite/test/dotest_args.py:166 +metavar='Test build directory', +help='The root build directory for the tests') clayborg wrote: > Maybe add a default right here?: > > ``` >

Re: [Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Jim Ingham via lldb-commits
It seems to me better to remove breakpoint sites under any memory that you are going to overwrite. The old breakpoints aren't guaranteed to make any sense and, for instance, on x86 could do harm (they could end up in the middle of an instruction in the new TEXT.) If you want to do this

Re: [Lldb-commits] [PATCH] D42195: [lldb] Generic base for testing gdb-remote behavior

2018-01-23 Thread Jim Ingham via lldb-commits
In the xcode build, yaml2obj is built as part of the llvm build stage and so gets put in the same bin directory clang builds into. It looks like this patch expects to find yaml2obj next to the lldb executable: def yaml2obj_executable(): """ Get the path to the yaml2obj executable,

[Lldb-commits] [lldb] r323219 - Move getBuildArtifact() from TestBase to Base and derive MiTestCaseBase from it

2018-01-23 Thread Adrian Prantl via lldb-commits
Author: adrian Date: Tue Jan 23 08:43:01 2018 New Revision: 323219 URL: http://llvm.org/viewvc/llvm-project?rev=323219=rev Log: Move getBuildArtifact() from TestBase to Base and derive MiTestCaseBase from it Thanks to Pavel Labath for pointing this out! Modified:

[Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Tatyana Krasnukha via Phabricator via lldb-commits
tatyana-krasnukha added a comment. Cannot promise that I'll do it (with all tests) quickly, but I'll do. One more question: what are the cases when intersection can happen, beside user forgot to disable it manually? (Will not it be annoying for user to get breakpoints in unpredictable

[Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. In https://reviews.llvm.org/D39967#985181, @labath wrote: > In https://reviews.llvm.org/D39967#985171, @clayborg wrote: > > > That would be an easy fix for the ObjectFile::Load(), we could see if there > > are any breakpoints in the range we are trying to write, get a

[Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. In https://reviews.llvm.org/D39967#985119, @tatyana-krasnukha wrote: > I completely agree with your point, but why isn't enough just to return an > error about breakpoints in the area user wants to write? The reason I don't like this is there is no way for a user to

[Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Tatyana Krasnukha via Phabricator via lldb-commits
tatyana-krasnukha added a comment. I completely agree with your point, but why isn't enough just to return an error about breakpoints in the area user wants to write? Or to disable breakpoints forcibly? https://reviews.llvm.org/D39967 ___

[Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. In https://reviews.llvm.org/D39967#984989, @tatyana-krasnukha wrote: > > Does this functionality really belong in the client? In case of memory > > reads, it's the server who patches out the breakpoint opcodes > > (NativeProcessProtocol::ReadMemoryWithoutTrap). I

[Lldb-commits] [PATCH] D42277: Use test-specific module caches to avoid stale header conflicts

2018-01-23 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added a comment. > Skip tests which fail when -fmodules is passed > (https://bugs.llvm.org/show_bug.cgi?id=36048). Wait.. this patch is not supposed to change the set of tests that get -fmodules passed to them. It should only add -fmodules-cache-path to tests that do pass -fmodules.

[Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Tatyana Krasnukha via Phabricator via lldb-commits
tatyana-krasnukha added a comment. > Does this functionality really belong in the client? In case of memory reads, > it's the server who patches out the breakpoint opcodes > (NativeProcessProtocol::ReadMemoryWithoutTrap). I think it would make sense > to do this in the same place. Will not

[Lldb-commits] [PATCH] D42409: Fix memory leaks in GoParser

2018-01-23 Thread Raphael Isemann via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL323197: Fix memory leaks in GoParser (authored by teemperor, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D42409?vs=131007=131052#toc

[Lldb-commits] [lldb] r323197 - Fix memory leaks in GoParser

2018-01-23 Thread Raphael Isemann via lldb-commits
Author: teemperor Date: Tue Jan 23 05:50:46 2018 New Revision: 323197 URL: http://llvm.org/viewvc/llvm-project?rev=323197=rev Log: Fix memory leaks in GoParser Summary: The GoParser is leaking memory in the tests due to not freeing allocated nodes when encountering some parsing errors. With

[Lldb-commits] [PATCH] D42195: [lldb] Generic base for testing gdb-remote behavior

2018-01-23 Thread Kamil Rytarowski via Phabricator via lldb-commits
krytarowski added a comment. In the standalone build, we put yaml2obj into `$PREFIX/bin/`, so into the default `PATH` of the toolchain. https://reviews.llvm.org/D42195 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [PATCH] D42409: Fix memory leaks in GoParser

2018-01-23 Thread Pavel Labath via Phabricator via lldb-commits
labath accepted this revision. labath added a comment. This revision is now accepted and ready to land. It looks like all of these parsing functions would benefit from returning unique_ptr, but that's probably not something we should bother doing now that we are contemplating removing this

[Lldb-commits] [PATCH] D42195: [lldb] Generic base for testing gdb-remote behavior

2018-01-23 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. Herald added a subscriber: hintonda. In https://reviews.llvm.org/D42195#984003, @owenpshaw wrote: > It looks like the yaml2obj target hasn't been defined yet when the check-lldb > target is defined, so if(TARGET yaml2obj) always returns false. Is there > another way to

Re: [Lldb-commits] [PATCH] D42195: [lldb] Generic base for testing gdb-remote behavior

2018-01-23 Thread Pavel Labath via lldb-commits
On 22 January 2018 at 22:06, Jim Ingham wrote: > > >> On Jan 22, 2018, at 3:10 AM, Pavel Labath via Phabricator >> wrote: >> >> labath added subscribers: krytarowski, jingham, davide. >> labath added a comment. >> >> In

[Lldb-commits] [PATCH] D39967: Refactoring of MemoryWrite function

2018-01-23 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. A couple of thoughts come to mind: - Does this functionality really belong in the client? In case of memory reads, it's the server who patches out the breakpoint opcodes (NativeProcessProtocol::ReadMemoryWithoutTrap). I think it would make sense to do this in the same

[Lldb-commits] [PATCH] D42348: Prevent unaligned memory read in parseMinidumpString

2018-01-23 Thread Raphael Isemann via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL323181: Prevent unaligned memory read in parseMinidumpString (authored by teemperor, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[Lldb-commits] [lldb] r323181 - Prevent unaligned memory read in parseMinidumpString

2018-01-23 Thread Raphael Isemann via lldb-commits
Author: teemperor Date: Tue Jan 23 00:04:27 2018 New Revision: 323181 URL: http://llvm.org/viewvc/llvm-project?rev=323181=rev Log: Prevent unaligned memory read in parseMinidumpString Summary: It's possible to hit an unaligned memory read when reading `source_length` as the `data` array is only

[Lldb-commits] [PATCH] D42409: Fix memory leaks in GoParser

2018-01-23 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added reviewers: labath, davide. The GoParser is leaking memory in the tests due to not freeing allocated nodes when encountering some parsing errors. With this patch all GoParser tests are passing with enabled memory sanitizers/ubsan.