[Lldb-commits] [lldb] r266944 - Expressions can run without a process.

2016-04-20 Thread Jim Ingham via lldb-commits
Author: jingham
Date: Wed Apr 20 20:46:11 2016
New Revision: 266944

URL: http://llvm.org/viewvc/llvm-project?rev=266944=rev
Log:
Expressions can run without a process.

Code was added in ClangExpressionParser::ClangExpressionParser that was calling 
through
the process w/o checking that it was good.  Also, we were pretending that we 
could do something
reasonable if we had no target, but that's actually not true, so I check for a 
target at the
beginning of the constructor and don't make a compiler in that case.



Modified:
lldb/trunk/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp

Modified: 
lldb/trunk/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp?rev=266944=266943=266944=diff
==
--- lldb/trunk/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp 
(original)
+++ lldb/trunk/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp 
Wed Apr 20 20:46:11 2016
@@ -262,40 +262,57 @@ ClangExpressionParser::ClangExpressionPa
 {
 Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_EXPRESSIONS));
 
+// We can't compile expressions without a target.  So if the exe_scope is 
null or doesn't have a target,
+// then we just need to get out of here.  I'll lldb_assert and not make 
any of the compiler objects since
+// I can't return errors directly from the constructor.  Further calls 
will check if the compiler was made and
+// bag out if it wasn't.
+
+if (!exe_scope)
+{
+lldb_assert(exe_scope, "Can't make an expression parser with a null 
scope.", __FUNCTION__, __FILE__, __LINE__);
+return;
+}
+
+lldb::TargetSP target_sp;
+target_sp = exe_scope->CalculateTarget();
+if (!target_sp)
+{
+lldb_assert(exe_scope, "Can't make an expression parser with a null 
target.", __FUNCTION__, __FILE__, __LINE__);
+return;
+}
+
 // 1. Create a new compiler instance.
 m_compiler.reset(new CompilerInstance());
 lldb::LanguageType frame_lang = expr.Language(); // defaults to 
lldb::eLanguageTypeUnknown
 bool overridden_target_opts = false;
 lldb_private::LanguageRuntime *lang_rt = nullptr;
-lldb::TargetSP target_sp;
-if (exe_scope)
-target_sp = exe_scope->CalculateTarget();
-
+
 ArchSpec target_arch;
-if (target_sp)
-target_arch = target_sp->GetArchitecture();
+target_arch = target_sp->GetArchitecture();
 
 const auto target_machine = target_arch.GetMachine();
 
 // If the expression is being evaluated in the context of an existing
 // stack frame, we introspect to see if the language runtime is available.
-auto frame = exe_scope->CalculateStackFrame();
-
+
+lldb::StackFrameSP frame_sp = exe_scope->CalculateStackFrame();
+lldb::ProcessSP process_sp = exe_scope->CalculateProcess();
+
 // Make sure the user hasn't provided a preferred execution language
 // with `expression --language X -- ...`
-if (frame && frame_lang == lldb::eLanguageTypeUnknown)
-frame_lang = frame->GetLanguage();
+if (frame_sp && frame_lang == lldb::eLanguageTypeUnknown)
+frame_lang = frame_sp->GetLanguage();
 
-if (frame_lang != lldb::eLanguageTypeUnknown)
+if (process_sp && frame_lang != lldb::eLanguageTypeUnknown)
 {
-lang_rt = 
exe_scope->CalculateProcess()->GetLanguageRuntime(frame_lang);
+lang_rt = process_sp->GetLanguageRuntime(frame_lang);
 if (log)
 log->Printf("Frame has language of type %s", 
Language::GetNameForLanguageType(frame_lang));
 }
 
 // 2. Configure the compiler with a set of default options that are 
appropriate
 // for most situations.
-if (target_sp && target_arch.IsValid())
+if (target_arch.IsValid())
 {
 std::string triple = target_arch.GetTriple().str();
 m_compiler->getTargetOpts().Triple = triple;
@@ -432,10 +449,6 @@ ClangExpressionParser::ClangExpressionPa
 // information.
 m_compiler->getLangOpts().SpellChecking = false;
 
-lldb::ProcessSP process_sp;
-if (exe_scope)
-process_sp = exe_scope->CalculateProcess();
-
 if (process_sp && m_compiler->getLangOpts().ObjC1)
 {
 if (process_sp->GetObjCLanguageRuntime())


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266941 - Corrected wording of REPL not available messaging (contained a repeated word and lacked clarity.)

2016-04-20 Thread Kate Stone via lldb-commits
Author: kate
Date: Wed Apr 20 19:56:08 2016
New Revision: 266941

URL: http://llvm.org/viewvc/llvm-project?rev=266941=rev
Log:
Corrected wording of REPL not available messaging (contained a repeated word 
and lacked clarity.)


Modified:
lldb/trunk/source/Core/Debugger.cpp
lldb/trunk/source/Target/Target.cpp

Modified: lldb/trunk/source/Core/Debugger.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Core/Debugger.cpp?rev=266941=266940=266941=diff
==
--- lldb/trunk/source/Core/Debugger.cpp (original)
+++ lldb/trunk/source/Core/Debugger.cpp Wed Apr 20 19:56:08 2016
@@ -1812,7 +1812,7 @@ Debugger::RunREPL (LanguageType language
 }
 else if (repl_languages.empty())
 {
-err.SetErrorStringWithFormat("LLDB isn't configured with support 
support for any REPLs.");
+err.SetErrorStringWithFormat("LLDB isn't configured with REPL 
support for any languages.");
 return err;
 }
 else

Modified: lldb/trunk/source/Target/Target.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/Target.cpp?rev=266941=266940=266941=diff
==
--- lldb/trunk/source/Target/Target.cpp (original)
+++ lldb/trunk/source/Target/Target.cpp Wed Apr 20 19:56:08 2016
@@ -222,7 +222,7 @@ Target::GetREPL (Error , lldb::Langu
 }
 else if (repl_languages.size() == 0)
 {
-err.SetErrorStringWithFormat("LLDB isn't configured with support 
support for any REPLs.");
+err.SetErrorStringWithFormat("LLDB isn't configured with REPL 
support for any languages.");
 return REPLSP();
 }
 else


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266940 - Added command prefix to new help messages to ensure that they're correctly words in REPL mode.

2016-04-20 Thread Kate Stone via lldb-commits
Author: kate
Date: Wed Apr 20 19:55:20 2016
New Revision: 266940

URL: http://llvm.org/viewvc/llvm-project?rev=266940=rev
Log:
Added command prefix to new help messages to ensure that they're correctly 
words in REPL mode.


Modified:
lldb/trunk/source/Commands/CommandObjectHelp.cpp

Modified: lldb/trunk/source/Commands/CommandObjectHelp.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectHelp.cpp?rev=266940=266939=266940=diff
==
--- lldb/trunk/source/Commands/CommandObjectHelp.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectHelp.cpp Wed Apr 20 19:55:20 2016
@@ -35,22 +35,16 @@ CommandObjectHelp::GenerateAdditionalHel
 if (s && command && *command)
 {
 s->Printf("'%s' is not a known command.\n", command);
-if (prefix && *prefix)
-{
-s->Printf("Try '%shelp' to see a current list of commands.\n", 
prefix);
-}
-else
-{
-s->PutCString("Try 'help' to see a current list of commands.\n");
-}
-
+s->Printf("Try '%shelp' to see a current list of commands.\n", prefix 
? prefix : "");
 if (include_apropos)
 {
-s->Printf("Try 'apropos %s' for a list of related commands.\n", 
subcommand ? subcommand : command);
+ s->Printf("Try '%sapropos %s' for a list of related commands.\n",
+prefix ? prefix : "", subcommand ? subcommand : command);
 }
 if (include_type_lookup)
 {
-s->Printf("Try 'type lookup %s' for information on types, methods, 
functions, modules, etc.", subcommand ? subcommand : command);
+s->Printf("Try '%stype lookup %s' for information on types, 
methods, functions, modules, etc.",
+ prefix ? prefix : "", subcommand ? subcommand : command);
 }
 }
 }


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266924 - Removed extraneous print() in decorator for enabling module debugging

2016-04-20 Thread Kate Stone via lldb-commits
Author: kate
Date: Wed Apr 20 16:59:43 2016
New Revision: 266924

URL: http://llvm.org/viewvc/llvm-project?rev=266924=rev
Log:
Removed extraneous print() in decorator for enabling module debugging


Modified:
lldb/trunk/packages/Python/lldbsuite/test/decorators.py

Modified: lldb/trunk/packages/Python/lldbsuite/test/decorators.py
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/decorators.py?rev=266924=266923=266924=diff
==
--- lldb/trunk/packages/Python/lldbsuite/test/decorators.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/decorators.py Wed Apr 20 16:59:43 
2016
@@ -509,7 +509,6 @@ def skipUnlessClangModules():
 """Decorate the item to skip test unless Clang -gmodules flag is 
supported."""
 def is_compiler_clang_with_gmodules(self):
 compiler_path = self.getCompiler()
-print(compiler_path)
 compiler = os.path.basename(compiler_path)
 if compiler != "clang":
 return "Test requires clang as compiler"


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266922 - When making an array or stuct/union/class elements, make sure the type is complete. If the type isn't complete, complete the type so that clang won't assert and kill yo

2016-04-20 Thread Greg Clayton via lldb-commits
Author: gclayton
Date: Wed Apr 20 16:47:56 2016
New Revision: 266922

URL: http://llvm.org/viewvc/llvm-project?rev=266922=rev
Log:
When making an array or stuct/union/class elements, make sure the type is 
complete. If the type isn't complete, complete the type so that clang won't 
assert and kill your program. Since the DWARF assists in doing layout, it won't 
show the array or struct/unions/class elements correctly, but it will stop you 
from crashing if you have a struct/union/class that contains one of these 
arrays.




Modified:
lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp

Modified: lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp?rev=266922=266921=266922=diff
==
--- lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp 
(original)
+++ lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp Wed Apr 
20 16:47:56 2016
@@ -1656,7 +1656,8 @@ DWARFASTParserClang::ParseTypeFromDWARF
 
 DEBUG_PRINTF ("0x%8.8" PRIx64 ": %s (\"%s\")\n", 
die.GetID(), DW_TAG_value_to_name(tag), type_name_cstr);
 
-Type *element_type = 
dwarf->ResolveTypeUID(DIERef(type_die_form));
+DIERef type_die_ref(type_die_form);
+Type *element_type = 
dwarf->ResolveTypeUID(type_die_ref);
 
 if (element_type)
 {
@@ -1665,6 +1666,32 @@ DWARFASTParserClang::ParseTypeFromDWARF
 if (byte_stride == 0 && bit_stride == 0)
 byte_stride = element_type->GetByteSize();
 CompilerType array_element_type = 
element_type->GetForwardCompilerType ();
+
+if 
(ClangASTContext::IsCXXClassType(array_element_type) && 
array_element_type.GetCompleteType() == false)
+{
+ModuleSP module_sp = die.GetModule();
+if (module_sp)
+{
+if (die.GetCU()->GetProducer() == 
DWARFCompileUnit::eProducerClang)
+module_sp->ReportError ("DWARF 
DW_TAG_array_type DIE at 0x%8.8x has a class/union/struct element type DIE 
0x%8.8x that is a forward declaration, not a complete definition.\nTry 
compiling the source file with -fno-limit-debug-info or disable -gmodule",
+
die.GetOffset(),
+
type_die_ref.die_offset);
+else
+module_sp->ReportError ("DWARF 
DW_TAG_array_type DIE at 0x%8.8x has a class/union/struct element type DIE 
0x%8.8x that is a forward declaration, not a complete definition.\nPlease file 
a bug against the compiler and include the preprocessed output for %s",
+
die.GetOffset(),
+
type_die_ref.die_offset,
+
die.GetLLDBCompileUnit() ? die.GetLLDBCompileUnit()->GetPath().c_str() : "the 
source file");
+}
+
+// We have no choice other than to pretend 
that the element class type
+// is complete. If we don't do this, clang 
will crash when trying
+// to layout the class. Since we provide 
layout assistance, all
+// ivars in this class and other classes will 
be fine, this is
+// the best we can do short of crashing.
+
ClangASTContext::StartTagDeclarationDefinition(array_element_type);
+
ClangASTContext::CompleteTagDeclarationDefinition(array_element_type);
+}
+
 uint64_t array_element_bit_stride = byte_stride * 
8 + bit_stride;
 if (element_orders.size() > 0)
 {


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19273: Update Go OS Plugin for newer runtimes

2016-04-20 Thread Ryan Brown via lldb-commits
ribrdb removed rL LLVM as the repository for this revision.
ribrdb updated this revision to Diff 54427.

http://reviews.llvm.org/D19273

Files:
  source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp

Index: source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
===
--- source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
+++ source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
@@ -249,8 +249,19 @@
 TargetSP target_sp = m_process->CalculateTarget();
 if (!target_sp)
 return false;
-m_allg_sp = FindGlobal(target_sp, "runtime.allg");
-m_allglen_sp = FindGlobal(target_sp, "runtime.allglen");
+// Go 1.6 stores goroutines in a slice called runtime.allgs
+ValueObjectSP allgs_sp = FindGlobal(target_sp, "runtime.allgs");
+if (allgs_sp)
+{
+m_allg_sp = allgs_sp->GetChildMemberWithName(ConstString("array"), 
true);
+m_allglen_sp = allgs_sp->GetChildMemberWithName(ConstString("len"), 
true);
+}
+else
+{
+// Go 1.4 stores goroutines in the variable runtime.allg.
+m_allg_sp = FindGlobal(target_sp, "runtime.allg");
+m_allglen_sp = FindGlobal(target_sp, "runtime.allglen");
+}

 if (m_allg_sp && !m_allglen_sp)
 {


Index: source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
===
--- source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
+++ source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
@@ -249,8 +249,19 @@
 TargetSP target_sp = m_process->CalculateTarget();
 if (!target_sp)
 return false;
-m_allg_sp = FindGlobal(target_sp, "runtime.allg");
-m_allglen_sp = FindGlobal(target_sp, "runtime.allglen");
+// Go 1.6 stores goroutines in a slice called runtime.allgs
+ValueObjectSP allgs_sp = FindGlobal(target_sp, "runtime.allgs");
+if (allgs_sp)
+{
+m_allg_sp = allgs_sp->GetChildMemberWithName(ConstString("array"), true);
+m_allglen_sp = allgs_sp->GetChildMemberWithName(ConstString("len"), true);
+}
+else
+{
+// Go 1.4 stores goroutines in the variable runtime.allg.
+m_allg_sp = FindGlobal(target_sp, "runtime.allg");
+m_allglen_sp = FindGlobal(target_sp, "runtime.allglen");
+}

 if (m_allg_sp && !m_allglen_sp)
 {
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19273: Update Go OS Plugin for newer runtimes

2016-04-20 Thread Ryan Brown via lldb-commits
ribrdb marked an inline comment as done.
ribrdb added a comment.

I'm not sure how else we could identify the runtime version. I'm hoping to 
eventually add a producer string that has the version, but this would just be a 
git commit for development compilers.


Repository:
  rL LLVM

http://reviews.llvm.org/D19273



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266917 - update Jenkins Xcode buildbot target for r266885

2016-04-20 Thread Todd Fiala via lldb-commits
Author: tfiala
Date: Wed Apr 20 15:54:59 2016
New Revision: 266917

URL: http://llvm.org/viewvc/llvm-project?rev=266917=rev
Log:
update Jenkins Xcode buildbot target for r266885

Modified:
lldb/trunk/lldb.xcodeproj/project.pbxproj

Modified: lldb/trunk/lldb.xcodeproj/project.pbxproj
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/lldb.xcodeproj/project.pbxproj?rev=266917=266916=266917=diff
==
--- lldb/trunk/lldb.xcodeproj/project.pbxproj (original)
+++ lldb/trunk/lldb.xcodeproj/project.pbxproj Wed Apr 20 15:54:59 2016
@@ -6016,7 +6016,7 @@
 /* Begin PBXLegacyTarget section */
2387551E1C24974600CCE8C3 /* lldb-python-test-suite */ = {
isa = PBXLegacyTarget;
-   buildArgumentsString = "-u $(SRCROOT)/test/dotest.py 
--apple-sdk $(PLATFORM_NAME) 
--executable=$(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)/lldb -C 
$(LLDB_PYTHON_TESTSUITE_CC) --results-formatter 
lldbsuite.test.xunit_formatter.XunitFormatter --results-file 
$(BUILD_DIR)/test-results.xml --rerun-all-issues --env TERM=vt100 
-O--xpass=ignore";
+   buildArgumentsString = "-u $(SRCROOT)/test/dotest.py 
--apple-sdk $(PLATFORM_NAME) 
--executable=$(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)/lldb -C 
$(LLDB_PYTHON_TESTSUITE_CC) --results-formatter 
lldbsuite.test_event.formatter.xunit.XunitFormatter --results-file 
$(BUILD_DIR)/test-results.xml --rerun-all-issues --env TERM=vt100 
-O--xpass=ignore";
buildConfigurationList = 238755241C24974600CCE8C3 /* 
Build configuration list for PBXLegacyTarget "lldb-python-test-suite" */;
buildPhases = (
);


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266911 - Fix a bug where LLDB would crash if 'apropos ' was used after spawning an inferior process

2016-04-20 Thread Enrico Granata via lldb-commits
Author: enrico
Date: Wed Apr 20 15:48:05 2016
New Revision: 266911

URL: http://llvm.org/viewvc/llvm-project?rev=266911=rev
Log:
Fix a bug where LLDB would crash if 'apropos ' was used after 
spawning an inferior process

Added:

lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/

lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/Makefile

lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/TestAproposWithProcess.py

lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/main.cpp
Modified:
lldb/trunk/include/lldb/Interpreter/CommandObject.h
lldb/trunk/include/lldb/Interpreter/CommandObjectMultiword.h
lldb/trunk/include/lldb/lldb-forward.h
lldb/trunk/source/Commands/CommandObjectMultiword.cpp
lldb/trunk/source/Interpreter/CommandInterpreter.cpp

Modified: lldb/trunk/include/lldb/Interpreter/CommandObject.h
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Interpreter/CommandObject.h?rev=266911=266910=266911=diff
==
--- lldb/trunk/include/lldb/Interpreter/CommandObject.h (original)
+++ lldb/trunk/include/lldb/Interpreter/CommandObject.h Wed Apr 20 15:48:05 2016
@@ -172,6 +172,9 @@ public:
 virtual bool
 IsMultiwordObject () { return false; }
 
+virtual CommandObjectMultiword*
+GetAsMultiwordCommand () { return nullptr; }
+
 virtual bool
 IsAlias () { return false; }
 

Modified: lldb/trunk/include/lldb/Interpreter/CommandObjectMultiword.h
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Interpreter/CommandObjectMultiword.h?rev=266911=266910=266911=diff
==
--- lldb/trunk/include/lldb/Interpreter/CommandObjectMultiword.h (original)
+++ lldb/trunk/include/lldb/Interpreter/CommandObjectMultiword.h Wed Apr 20 
15:48:05 2016
@@ -41,6 +41,12 @@ public:
 {
 return true;
 }
+
+CommandObjectMultiword*
+GetAsMultiwordCommand () override
+{
+return this;
+}
 
 bool
 LoadSubCommand(const char *cmd_name,
@@ -131,6 +137,9 @@ public:
 bool
 IsMultiwordObject() override;
 
+CommandObjectMultiword*
+GetAsMultiwordCommand () override;
+
 void
 GenerateHelpText (Stream ) override;
 

Modified: lldb/trunk/include/lldb/lldb-forward.h
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/lldb-forward.h?rev=266911=266910=266911=diff
==
--- lldb/trunk/include/lldb/lldb-forward.h (original)
+++ lldb/trunk/include/lldb/lldb-forward.h Wed Apr 20 15:48:05 2016
@@ -59,6 +59,7 @@ class   ClangPersistentVariables;
 class   CommandInterpreter;
 class   CommandInterpreterRunOptions;
 class   CommandObject;
+class   CommandObjectMultiword;
 class   CommandReturnObject;
 class   Communication;
 class   CompactUnwindInfo;

Added: 
lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/Makefile
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/Makefile?rev=266911=auto
==
--- 
lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/Makefile
 (added)
+++ 
lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/Makefile
 Wed Apr 20 15:48:05 2016
@@ -0,0 +1,5 @@
+LEVEL = ../../make
+
+CXX_SOURCES := main.cpp
+
+include $(LEVEL)/Makefile.rules

Added: 
lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/TestAproposWithProcess.py
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/TestAproposWithProcess.py?rev=266911=auto
==
--- 
lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/TestAproposWithProcess.py
 (added)
+++ 
lldb/trunk/packages/Python/lldbsuite/test/functionalities/apropos_with_process/TestAproposWithProcess.py
 Wed Apr 20 15:48:05 2016
@@ -0,0 +1,44 @@
+"""
+Test that apropos env doesn't crash trying to touch the process plugin commmand
+"""
+
+from __future__ import print_function
+
+
+
+import os, time
+import re
+import lldb
+from lldbsuite.test.lldbtest import *
+import lldbsuite.test.lldbutil as lldbutil
+
+class AproposWithProcessTestCase(TestBase):
+
+mydir = TestBase.compute_mydir(__file__)
+
+def setUp(self):
+# Call super's setUp().
+TestBase.setUp(self)
+# Find the line number to break inside main().
+self.line = line_number('main.cpp', '// break here')
+
+def test_apropos_with_process(self):
+"""Test that apropos env doesn't crash trying 

Re: [Lldb-commits] [PATCH] D18848: Add PDBASTParser and parse type information from PDB

2016-04-20 Thread Jonas Hahnfeld via lldb-commits
Hahnfeld added a subscriber: Hahnfeld.
Hahnfeld added a comment.

I think this one is breaking `make check-all` for me because it cannot find and 
copy `test-pdb-types.exe`. Maybe this has to be checked in? `test-dwarf.exe` 
and `test-pdb.exe` are in SVN as well...


http://reviews.llvm.org/D18848



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19305: Use Process Plugin register indices when communicating with remote

2016-04-20 Thread Francis Ricci via lldb-commits
fjricci added a comment.

I can add a comment to the ReadRegister decl.

Alternatively, if you think it would be preferable, I could change the 
parameter name from reg_num to something more descriptive, like remote_reg_num 
or plugin_reg_num.

Or I could change ReadRegister to take a RegisterInfo instead of a register 
number, and that way it could select the appropriate ProcessPlugin regnum on 
its own, right when it generates the packet. This method actually might be most 
consistent with the rest of the changes in the patch.


http://reviews.llvm.org/D19305



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19305: Use Process Plugin register indices when communicating with remote

2016-04-20 Thread Greg Clayton via lldb-commits
clayborg accepted this revision.
clayborg added a comment.
This revision is now accepted and ready to land.

Looks good. As to Jason's comment about a register number class: I wanted 
RegisterContext classes to be able to statically initialize an array or 
RegisterInfo structs without having to call C++ constructors. That is the main 
reason the register numbers are just an array.


http://reviews.llvm.org/D19305



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266886 - Add missing file needed for PDB unittests.

2016-04-20 Thread Zachary Turner via lldb-commits
Author: zturner
Date: Wed Apr 20 11:41:02 2016
New Revision: 266886

URL: http://llvm.org/viewvc/llvm-project?rev=266886=rev
Log:
Add missing file needed for PDB unittests.

Added:
lldb/trunk/unittests/SymbolFile/PDB/Inputs/test-pdb-types.exe

Added: lldb/trunk/unittests/SymbolFile/PDB/Inputs/test-pdb-types.exe
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/unittests/SymbolFile/PDB/Inputs/test-pdb-types.exe?rev=266886=auto
==
Binary files lldb/trunk/unittests/SymbolFile/PDB/Inputs/test-pdb-types.exe 
(added) and lldb/trunk/unittests/SymbolFile/PDB/Inputs/test-pdb-types.exe Wed 
Apr 20 11:41:02 2016 differ


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19288: test infra: move test event-related handling into its own package

2016-04-20 Thread Todd Fiala via lldb-commits
tfiala closed this revision.
tfiala added a comment.

Closed with commit r266885.

@zturner, we can post-commit adjust if you see any improvements.  I want to get 
moving on writing the package-level tests for it.


http://reviews.llvm.org/D19288



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19288: test infra: move test event-related handling into its own package

2016-04-20 Thread Todd Fiala via lldb-commits
tfiala added a comment.





Comment at: packages/Python/lldbsuite/test_event/formatter/curses.py:1
@@ +1,2 @@
+#!/usr/bin/env python
+

labath wrote:
> Is this actually supposed to be executable?
No, there is no need for it to be executable.  That can come out.

Good catch.  I'll clean that up before submission.


http://reviews.llvm.org/D19288



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D18848: Add PDBASTParser and parse type information from PDB

2016-04-20 Thread Zachary Turner via lldb-commits
Hmm, ok i will check it out later. I'm not sure why it's even trying to
copy an exe, should be only doing the pdb. Exe isn't even checked in
On Wed, Apr 20, 2016 at 8:08 AM Pavel Labath  wrote:

> labath added a subscriber: labath.
> labath added a comment.
>
> In http://reviews.llvm.org/D18848#406509, @zturner wrote:
>
> > I was under the impression the make build was officially
> unsupported/dead?
>
>
> You can still cmake to generate makefiles (and it does that by default).
>
> In any case, this problem should not be related to make, unit tests fail
> even when using ninja:
>
>   Error copying file
> "llvm/tools/lldb/unittests/SymbolFile/PDB/Inputs/test-pdb-types.exe" to
> "build/dbg/tools/lldb/unittests/SymbolFile/PDB/Inputs".
>
>
> http://reviews.llvm.org/D18848
>
>
>
>
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D18848: Add PDBASTParser and parse type information from PDB

2016-04-20 Thread Zachary Turner via lldb-commits
zturner added a comment.

Hmm, ok i will check it out later. I'm not sure why it's even trying to
copy an exe, should be only doing the pdb. Exe isn't even checked in


http://reviews.llvm.org/D18848



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D18848: Add PDBASTParser and parse type information from PDB

2016-04-20 Thread Pavel Labath via lldb-commits
labath added a subscriber: labath.
labath added a comment.

In http://reviews.llvm.org/D18848#406509, @zturner wrote:

> I was under the impression the make build was officially unsupported/dead?


You can still cmake to generate makefiles (and it does that by default).

In any case, this problem should not be related to make, unit tests fail even 
when using ninja:

  Error copying file 
"llvm/tools/lldb/unittests/SymbolFile/PDB/Inputs/test-pdb-types.exe" to 
"build/dbg/tools/lldb/unittests/SymbolFile/PDB/Inputs".


http://reviews.llvm.org/D18848



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D18848: Add PDBASTParser and parse type information from PDB

2016-04-20 Thread Zachary Turner via lldb-commits
zturner added a comment.

I was under the impression the make build was officially unsupported/dead?


http://reviews.llvm.org/D18848



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D18848: Add PDBASTParser and parse type information from PDB

2016-04-20 Thread Zachary Turner via lldb-commits
I was under the impression the make build was officially unsupported/dead?
On Wed, Apr 20, 2016 at 4:26 AM Jonas Hahnfeld 
wrote:

> Hahnfeld added a subscriber: Hahnfeld.
> Hahnfeld added a comment.
>
> I think this one is breaking `make check-all` for me because it cannot
> find and copy `test-pdb-types.exe`. Maybe this has to be checked in?
> `test-dwarf.exe` and `test-pdb.exe` are in SVN as well...
>
>
> http://reviews.llvm.org/D18848
>
>
>
>
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19252: Handle invalid values of PLT entry size generated by ld + gcc on arm linux targets.

2016-04-20 Thread Tamas Berghammer via lldb-commits
tberghammer accepted this revision.
tberghammer added a comment.

I don't really have an opinion about CheckPLTSize() function Greg proposes but 
I definitely want to see some comment explaining why we say that a plt entry 
less then 4 byte is invalid.


http://reviews.llvm.org/D19252



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D18975: Fix unwind failures when PC points beyond the end of a function

2016-04-20 Thread Tamas Berghammer via lldb-commits
tberghammer accepted this revision.
tberghammer added a comment.

I think having an explicit value for resolve_tail_call_address with a comment 
is valuable (not sure how much details we need in the comment) so when the next 
person looking into related unwinding issue he/she will know that changing 
resolve_tail_call_address to true is a bad idea (even if it fixes the problem 
they are debugging) and will break some usecase


http://reviews.llvm.org/D18975



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19273: Update Go OS Plugin for newer runtimes

2016-04-20 Thread Tamas Berghammer via lldb-commits
tberghammer added a subscriber: tberghammer.
tberghammer added a comment.

Is it possible to query the version of the go runtime we are currently 
debugging and decide which symbol we look for instead of using this fallback 
mechanism? I think it would make the code easier to understand and also easier 
to add support for new runtime versions


Repository:
  rL LLVM

http://reviews.llvm.org/D19273



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19288: test infra: move test event-related handling into its own package

2016-04-20 Thread Pavel Labath via lldb-commits
labath accepted this revision.
labath added a comment.
This revision is now accepted and ready to land.

Makes sense.



Comment at: packages/Python/lldbsuite/test_event/formatter/curses.py:1
@@ +1,2 @@
+#!/usr/bin/env python
+

Is this actually supposed to be executable?


http://reviews.llvm.org/D19288



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] r266867 - Fix xfail for test_tilde_home_directory on windows

2016-04-20 Thread Tamas Berghammer via lldb-commits
Author: tberghammer
Date: Wed Apr 20 04:54:47 2016
New Revision: 266867

URL: http://llvm.org/viewvc/llvm-project?rev=266867=rev
Log:
Fix xfail for test_tilde_home_directory on windows

Modified:
lldb/trunk/packages/Python/lldbsuite/test/functionalities/llvm/TestLLVM.py

Modified: 
lldb/trunk/packages/Python/lldbsuite/test/functionalities/llvm/TestLLVM.py
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/llvm/TestLLVM.py?rev=266867=266866=266867=diff
==
--- lldb/trunk/packages/Python/lldbsuite/test/functionalities/llvm/TestLLVM.py 
(original)
+++ lldb/trunk/packages/Python/lldbsuite/test/functionalities/llvm/TestLLVM.py 
Wed Apr 20 04:54:47 2016
@@ -16,7 +16,7 @@ class TestHomeDirectory(TestBase):
 
 mydir = TestBase.compute_mydir(__file__)
 
-@expectedFailureAll(oslist=["windows"])
+@expectedFailureAll(hostoslist=["windows"], bugnumber="llvm.org/pr22274: 
need a pexpect replacement for windows")
 @no_debug_info_test
 def test_tilde_home_directory(self):
 """Test that we can resolve "~/" in paths correctly. 


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19273: Update Go OS Plugin for newer runtimes

2016-04-20 Thread Pavel Labath via lldb-commits
labath added a comment.

btw, this does not seem to follow lldb code style (braces on a new line), 
please reformat that.


Repository:
  rL LLVM

http://reviews.llvm.org/D19273



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


Re: [Lldb-commits] [PATCH] D19273: Update Go OS Plugin for newer runtimes

2016-04-20 Thread Pavel Labath via lldb-commits
labath added a subscriber: labath.
labath accepted this revision.
labath added a reviewer: labath.
This revision is now accepted and ready to land.


Comment at: source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp:253
@@ +252,3 @@
+ValueObjectSP allgs_sp = FindGlobal(target_sp,  "runtime.allgs");
+if (allgs_sp) {
+m_allg_sp = allgs_sp->GetChildMemberWithName(ConstString("array"), 
true);

To me, as someone who might accidentally wander into this part of codebase, a 
comment explaining that the symbols to look for differ between runtime versions 
would definitely be helpful.


Repository:
  rL LLVM

http://reviews.llvm.org/D19273



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits