[Lldb-commits] [lldb] r358261 - PDBFPO: Improvements to the AST visitor

2019-04-12 Thread Pavel Labath via lldb-commits
Author: labath
Date: Fri Apr 12 00:19:00 2019
New Revision: 358261

URL: http://llvm.org/viewvc/llvm-project?rev=358261&view=rev
Log:
PDBFPO: Improvements to the AST visitor

Summary:
This patch attempts to solve two issues made this code hard to follow
for me.

The first issue was that a lot of what these visitors do is mutate the
AST. The visitor pattern is not particularly good for that because by
the time you have performed the dynamic type dispatch, it's too late to
go back to the parent node, and change its pointer. The previous code
dealt with that relatively elegantly, but it still meant that one had to
perform manual type checks, which is what the visitor pattern is
supposed to avoid.

The second issue was not being able to return values from the Visit
functions, which meant that one had to store function results in member
variables (a common problem with visitor patterns).

Here, I solve both problems by making the visitor use a type switch
instead of going through double dispatch on the visited object.  This
allows one to parameterize the visitor based on the return type and pass
function results as function results. The mutation is fascilitated by
having each Visit function take two arguments -- a reference to the
object itself (with the correct dynamic type), and a reference to the
parent's pointer to this object.

Although this wasn't my explicit goal here, the fact that we're not
using virtual dispatch anymore  allows us to make the AST nodes
trivially destructible, which is a good thing, since we were not
destroying them anyway.

Reviewers: aleksandr.urakov, amccarth

Subscribers: lldb-commits

Differential Revision: https://reviews.llvm.org/D60410

Modified:

lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp

Modified: 
lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp?rev=358261&r1=358260&r2=358261&view=diff
==
--- 
lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
 (original)
+++ 
lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
 Fri Apr 12 00:19:00 2019
@@ -25,12 +25,11 @@ using namespace lldb_private;
 
 namespace {
 
-class FPOProgramNode;
-class FPOProgramASTVisitor;
-
 class NodeAllocator {
 public:
   template  T *makeNode(Args &&... args) {
+static_assert(std::is_trivially_destructible::value,
+  "This object will not be destroyed!");
 void *new_node_mem = m_alloc.Allocate(sizeof(T), alignof(T));
 return new (new_node_mem) T(std::forward(args)...);
   }
@@ -53,9 +52,6 @@ protected:
   FPOProgramNode(Kind kind) : m_token_kind(kind) {}
 
 public:
-  virtual ~FPOProgramNode() = default;
-  virtual void Accept(FPOProgramASTVisitor &visitor) = 0;
-
   Kind GetKind() const { return m_token_kind; }
 
 private:
@@ -67,8 +63,6 @@ public:
   FPOProgramNodeSymbol(llvm::StringRef name)
   : FPOProgramNode(Symbol), m_name(name) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   llvm::StringRef GetName() const { return m_name; }
 
   static bool classof(const FPOProgramNode *node) {
@@ -84,8 +78,6 @@ public:
   FPOProgramNodeRegisterRef(uint32_t lldb_reg_num)
   : FPOProgramNode(Register), m_lldb_reg_num(lldb_reg_num) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   uint32_t GetLLDBRegNum() const { return m_lldb_reg_num; }
 
   static bool classof(const FPOProgramNode *node) {
@@ -101,8 +93,6 @@ public:
   FPOProgramNodeIntegerLiteral(uint32_t value)
   : FPOProgramNode(IntegerLiteral), m_value(value) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   uint32_t GetValue() const { return m_value; }
 
   static bool classof(const FPOProgramNode *node) {
@@ -126,8 +116,6 @@ public:
   : FPOProgramNode(BinaryOp), m_op_type(op_type), m_left(&left),
 m_right(&right) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   OpType GetOpType() const { return m_op_type; }
 
   const FPOProgramNode *Left() const { return m_left; }
@@ -155,8 +143,6 @@ public:
   FPOProgramNodeUnaryOp(OpType op_type, FPOProgramNode &operand)
   : FPOProgramNode(UnaryOp), m_op_type(op_type), m_operand(&operand) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   OpType GetOpType() const { return m_op_type; }
 
   const FPOProgramNode *Operand() const { return m_operand; }
@@ -171,84 +157,108 @@ private:
   FPOProgramNode *m_operand;
 };
 
+template 
 class FPOProgramASTVisitor {
-public:
-  virtual ~FPOProgramASTVisitor() = default;
+protected:
+  virtual ResultT Visit(FPOProgramNodeBinaryOp &binary,
+FPOProgramNode *&ref) = 0;
+  virtual ResultT Visit(FPOProgramNodeUnaryOp &unary, FPOProgramNode *&ref) = 
0;
+  virtual ResultT Visit(FPOProgramNodeRegi

[Lldb-commits] [PATCH] D60410: PDBFPO: Improvements to the AST visitor

2019-04-12 Thread Pavel Labath via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rLLDB358261: PDBFPO: Improvements to the AST visitor (authored 
by labath, committed by ).
Herald added a subscriber: abidh.
Herald added a project: LLDB.

Changed prior to commit:
  https://reviews.llvm.org/D60410?vs=194705&id=194808#toc

Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D60410/new/

https://reviews.llvm.org/D60410

Files:
  source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp

Index: source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
===
--- source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
+++ source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
@@ -25,12 +25,11 @@
 
 namespace {
 
-class FPOProgramNode;
-class FPOProgramASTVisitor;
-
 class NodeAllocator {
 public:
   template  T *makeNode(Args &&... args) {
+static_assert(std::is_trivially_destructible::value,
+  "This object will not be destroyed!");
 void *new_node_mem = m_alloc.Allocate(sizeof(T), alignof(T));
 return new (new_node_mem) T(std::forward(args)...);
   }
@@ -53,9 +52,6 @@
   FPOProgramNode(Kind kind) : m_token_kind(kind) {}
 
 public:
-  virtual ~FPOProgramNode() = default;
-  virtual void Accept(FPOProgramASTVisitor &visitor) = 0;
-
   Kind GetKind() const { return m_token_kind; }
 
 private:
@@ -67,8 +63,6 @@
   FPOProgramNodeSymbol(llvm::StringRef name)
   : FPOProgramNode(Symbol), m_name(name) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   llvm::StringRef GetName() const { return m_name; }
 
   static bool classof(const FPOProgramNode *node) {
@@ -84,8 +78,6 @@
   FPOProgramNodeRegisterRef(uint32_t lldb_reg_num)
   : FPOProgramNode(Register), m_lldb_reg_num(lldb_reg_num) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   uint32_t GetLLDBRegNum() const { return m_lldb_reg_num; }
 
   static bool classof(const FPOProgramNode *node) {
@@ -101,8 +93,6 @@
   FPOProgramNodeIntegerLiteral(uint32_t value)
   : FPOProgramNode(IntegerLiteral), m_value(value) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   uint32_t GetValue() const { return m_value; }
 
   static bool classof(const FPOProgramNode *node) {
@@ -126,8 +116,6 @@
   : FPOProgramNode(BinaryOp), m_op_type(op_type), m_left(&left),
 m_right(&right) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   OpType GetOpType() const { return m_op_type; }
 
   const FPOProgramNode *Left() const { return m_left; }
@@ -155,8 +143,6 @@
   FPOProgramNodeUnaryOp(OpType op_type, FPOProgramNode &operand)
   : FPOProgramNode(UnaryOp), m_op_type(op_type), m_operand(&operand) {}
 
-  void Accept(FPOProgramASTVisitor &visitor) override;
-
   OpType GetOpType() const { return m_op_type; }
 
   const FPOProgramNode *Operand() const { return m_operand; }
@@ -171,84 +157,108 @@
   FPOProgramNode *m_operand;
 };
 
+template 
 class FPOProgramASTVisitor {
-public:
-  virtual ~FPOProgramASTVisitor() = default;
+protected:
+  virtual ResultT Visit(FPOProgramNodeBinaryOp &binary,
+FPOProgramNode *&ref) = 0;
+  virtual ResultT Visit(FPOProgramNodeUnaryOp &unary, FPOProgramNode *&ref) = 0;
+  virtual ResultT Visit(FPOProgramNodeRegisterRef ®, FPOProgramNode *&) = 0;
+  virtual ResultT Visit(FPOProgramNodeIntegerLiteral &integer,
+FPOProgramNode *&) = 0;
+  virtual ResultT Visit(FPOProgramNodeSymbol &symbol, FPOProgramNode *&ref) = 0;
+
+  ResultT Dispatch(FPOProgramNode *&node) {
+switch (node->GetKind()) {
+case FPOProgramNode::Register:
+  return Visit(llvm::cast(*node), node);
+case FPOProgramNode::Symbol:
+  return Visit(llvm::cast(*node), node);
+
+case FPOProgramNode::IntegerLiteral:
+  return Visit(llvm::cast(*node), node);
+case FPOProgramNode::UnaryOp:
+  return Visit(llvm::cast(*node), node);
+case FPOProgramNode::BinaryOp:
+  return Visit(llvm::cast(*node), node);
+}
+llvm_unreachable("Fully covered switch!");
+  }
 
-  virtual void Visit(FPOProgramNodeSymbol &node) {}
-  virtual void Visit(FPOProgramNodeRegisterRef &node) {}
-  virtual void Visit(FPOProgramNodeIntegerLiteral &node) {}
-  virtual void Visit(FPOProgramNodeBinaryOp &node) {}
-  virtual void Visit(FPOProgramNodeUnaryOp &node) {}
 };
 
-void FPOProgramNodeSymbol::Accept(FPOProgramASTVisitor &visitor) {
-  visitor.Visit(*this);
-}
-
-void FPOProgramNodeRegisterRef::Accept(FPOProgramASTVisitor &visitor) {
-  visitor.Visit(*this);
-}
+class FPOProgramASTVisitorMergeDependent : public FPOProgramASTVisitor<> {
+public:
+  void Visit(FPOProgramNodeBinaryOp &binary, FPOProgramNode *&) override {
+Dispatch(binary.Left());
+Dispatch(binary.Right());
+  }
 
-void FPOProgramNodeIntegerLiteral::Accept(FPOProgramASTVisitor &visitor) {
-  visitor.Visit(*this

[Lldb-commits] [lldb] r358265 - [lldb-server] Update tests to use std::thread/mutex for all platforms

2019-04-12 Thread Aaron Smith via lldb-commits
Author: asmith
Date: Fri Apr 12 00:48:49 2019
New Revision: 358265

URL: http://llvm.org/viewvc/llvm-project?rev=358265&view=rev
Log:
[lldb-server] Update tests to use std::thread/mutex for all platforms

Summary:
Some cleanup suggested when bringing up lldb-server on Windows. 
Thanks to Hui Huang for the patch.

Reviewers: zturner, labath, jfb, Hui

Reviewed By: labath

Subscribers: clayborg, dexonsmith, lldb-commits

Tags: #lldb

Differential Revision: https://reviews.llvm.org/D60496

Modified:
lldb/trunk/packages/Python/lldbsuite/test/tools/lldb-server/main.cpp

Modified: lldb/trunk/packages/Python/lldbsuite/test/tools/lldb-server/main.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/tools/lldb-server/main.cpp?rev=358265&r1=358264&r2=358265&view=diff
==
--- lldb/trunk/packages/Python/lldbsuite/test/tools/lldb-server/main.cpp 
(original)
+++ lldb/trunk/packages/Python/lldbsuite/test/tools/lldb-server/main.cpp Fri 
Apr 12 00:48:49 2019
@@ -6,19 +6,25 @@
 //
 
//===--===//
 
+#include 
+#include 
 #include 
 #include 
 #include 
 #include 
 #include 
+#include 
+#if !defined(_WIN32)
 #include 
-#include 
 #include 
+#include 
+#endif
+#include 
 #include 
 #include 
 #include 
+#include 
 #include 
-#include 
 #include 
 
 #if defined(__APPLE__)
@@ -28,6 +34,8 @@ int pthread_threadid_np(pthread_t, __uin
 #include 
 #elif defined(__NetBSD__)
 #include 
+#elif defined(_WIN32)
+#include 
 #endif
 
 static const char *const RETVAL_PREFIX = "retval:";
@@ -50,10 +58,10 @@ static const char *const THREAD_COMMAND_
 static const char *const PRINT_PID_COMMAND = "print-pid";
 
 static bool g_print_thread_ids = false;
-static pthread_mutex_t g_print_mutex = PTHREAD_MUTEX_INITIALIZER;
+static std::mutex g_print_mutex;
 static bool g_threads_do_segfault = false;
 
-static pthread_mutex_t g_jump_buffer_mutex = PTHREAD_MUTEX_INITIALIZER;
+static std::mutex g_jump_buffer_mutex;
 static jmp_buf g_jump_buffer;
 static bool g_is_segfaulting = false;
 
@@ -63,7 +71,11 @@ static volatile char g_c1 = '0';
 static volatile char g_c2 = '1';
 
 static void print_pid() {
+#if defined(_WIN32)
+  fprintf(stderr, "PID: %d\n", ::GetCurrentProcessId());
+#else
   fprintf(stderr, "PID: %d\n", getpid());
+#endif
 }
 
 static void print_thread_id() {
@@ -81,12 +93,17 @@ static void print_thread_id() {
 #elif defined(__NetBSD__)
   // Technically lwpid_t is 32-bit signed integer
   printf("%" PRIx64, static_cast(_lwp_self()));
+#elif defined(_WIN32)
+  printf("%" PRIx64, static_cast(::GetCurrentThreadId()));
 #else
   printf("{no-tid-support}");
 #endif
 }
 
 static void signal_handler(int signo) {
+#if defined(_WIN32)
+  // No signal support on Windows.
+#else
   const char *signal_name = nullptr;
   switch (signo) {
   case SIGUSR1:
@@ -100,14 +117,15 @@ static void signal_handler(int signo) {
   }
 
   // Print notice that we received the signal on a given thread.
-  pthread_mutex_lock(&g_print_mutex);
-  if (signal_name)
-printf("received %s on thread id: ", signal_name);
-  else
-printf("received signo %d (%s) on thread id: ", signo, strsignal(signo));
-  print_thread_id();
-  printf("\n");
-  pthread_mutex_unlock(&g_print_mutex);
+  {
+std::lock_guard lock(g_print_mutex);
+if (signal_name)
+  printf("received %s on thread id: ", signal_name);
+else
+  printf("received signo %d (%s) on thread id: ", signo, strsignal(signo));
+print_thread_id();
+printf("\n");
+  }
 
   // Reset the signal handler if we're one of the expected signal handlers.
   switch (signo) {
@@ -136,6 +154,7 @@ static void signal_handler(int signo) {
 fprintf(stderr, "failed to set signal handler: errno=%d\n", errno);
 exit(1);
   }
+#endif
 }
 
 static void swap_chars() {
@@ -147,25 +166,18 @@ static void swap_chars() {
 }
 
 static void hello() {
-  pthread_mutex_lock(&g_print_mutex);
+  std::lock_guard lock(g_print_mutex);
   printf("hello, world\n");
-  pthread_mutex_unlock(&g_print_mutex);
 }
 
 static void *thread_func(void *arg) {
-  static pthread_mutex_t s_thread_index_mutex = PTHREAD_MUTEX_INITIALIZER;
-  static int s_thread_index = 1;
-
-  pthread_mutex_lock(&s_thread_index_mutex);
+  static std::atomic s_thread_index(1);
   const int this_thread_index = s_thread_index++;
-  pthread_mutex_unlock(&s_thread_index_mutex);
-
   if (g_print_thread_ids) {
-pthread_mutex_lock(&g_print_mutex);
+std::lock_guard lock(g_print_mutex);
 printf("thread %d id: ", this_thread_index);
 print_thread_id();
 printf("\n");
-pthread_mutex_unlock(&g_print_mutex);
   }
 
   if (g_threads_do_segfault) {
@@ -175,37 +187,36 @@ static void *thread_func(void *arg) {
 // trying to do is add predictability as to the timing of
 // signal generation by created threads.
 int sleep_seconds = 2 * (this_thread_index - 1);
-whi

[Lldb-commits] [lldb] r358266 - Make TestPrintStackTraces deterministic

2019-04-12 Thread Pavel Labath via lldb-commits
Author: labath
Date: Fri Apr 12 01:02:28 2019
New Revision: 358266

URL: http://llvm.org/viewvc/llvm-project?rev=358266&view=rev
Log:
Make TestPrintStackTraces deterministic

This test contained an incredibly complicated inferior, but in reality,
all it was testing was that we can backtrace up to main and see main's
arguments.

However, the way this was implemented (setting a breakpoint on a
separate thread) meant that each time the test would run, it would stop
in a different location on the main thread. Most of the time this
location would be deep in some libc function, which meant that the
success of this test depended on our ability to backtrace out of a
random function of the c library that the user happens to have
installed.

This makes the test unpredictable. Backtracing out of a libc function is
an important functionality, but this is not the way to test it. Often it
is not even our fault that we cannot backtrace out because the C library
contains a lot of assembly routines that may not have correct unwind
info associated with them.

For this reason the test has accumulated numerous @expectedFail/Flaky
decorators. In this patch, I replace the inferior with one that does not
depend on libc functions. Instead I create a couple of stack frames of
user code, and have the test verify that. I also simplify the test by
using lldbutil.run_to_source_breakpoint.

Modified:

lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/TestPrintStackTraces.py

lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/main.cpp

Modified: 
lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/TestPrintStackTraces.py
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/TestPrintStackTraces.py?rev=358266&r1=358265&r2=358266&view=diff
==
--- 
lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/TestPrintStackTraces.py
 (original)
+++ 
lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/TestPrintStackTraces.py
 Fri Apr 12 01:02:28 2019
@@ -18,47 +18,12 @@ class ThreadsStackTracesTestCase(TestBas
 
 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', '// Set break point at this line.')
-
-# We are unable to produce a backtrace of the main thread when the thread
-# is blocked in fgets
-@expectedFailureAll("llvm.org/pr23043", ["linux"], archs=["i386"])
-# The __thread_start function in libc doesn't contain any epilogue and 
prologue instructions
-# hence unwinding fail when we are stopped in __thread_start
-@expectedFailureAll(triple='mips*')
-@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24778")
-@expectedFlakeyAndroid("llvm.org/26492", archs=["arm"])
-@expectedFlakeyLinux("llvm.org/pr27687")
-@expectedFailureNetBSD
 @add_test_categories(['pyapi'])
 def test_stack_traces(self):
 """Test SBprocess and SBThread APIs with printing of the stack 
traces."""
 self.build()
-exe = self.getBuildArtifact("a.out")
-
-target = self.dbg.CreateTarget(exe)
-self.assertTrue(target, VALID_TARGET)
-
-breakpoint = target.BreakpointCreateByLocation("main.cpp", self.line)
-self.assertTrue(breakpoint, VALID_BREAKPOINT)
-
-# Now launch the process, and do not stop at entry point.
-process = target.LaunchSimple(
-["abc", "xyz"], None, self.get_process_working_directory())
-
-if not process:
-self.fail("SBTarget.LaunchProcess() failed")
-
-import lldbsuite.test.lldbutil as lldbutil
-if process.GetState() != lldb.eStateStopped:
-self.fail("Process should be in the 'stopped' state, "
-  "instead the actual state is: '%s'" %
-  lldbutil.state_type_to_str(process.GetState()))
-
+(_, process, _, _) = lldbutil.run_to_source_breakpoint(self,
+"// BREAK HERE", lldb.SBFileSpec("main.cpp"))
 stacktraces = lldbutil.print_stacktraces(process, string_buffer=True)
 self.expect(stacktraces, exe=False,
-substrs=['(int)argc=3'])
+substrs=['(int)x=4', '(int)y=6', '(int)x=3', 
'(int)argc=1'])

Modified: 
lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/main.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/main.cpp?rev=358266&r1=358265&r2=358266&view=diff
==
--- 
lldb/trunk/packages/Python/lldbsuite/test/python_api/lldbutil/process/main.cpp 
(original)
+++ 
lldb/trunk/packages/Python/lldbsuite/test/pyth

[Lldb-commits] [PATCH] D60599: Move postfix expression code out of the NativePDB plugin

2019-04-12 Thread Pavel Labath via Phabricator via lldb-commits
labath created this revision.
labath added reviewers: jasonmolenda, amccarth, clayborg, JDevlieghere, 
aleksandr.urakov.
Herald added a subscriber: aprantl.

The NativePDB plugin contains code to convert "programs" describing the
layout of function frames into dwarf (for easier interaction with the
rest of lldb). This functionality is useful for the Breakpad plugin too,
as it contains the same kind of expressions (because breakpad info is
generated from pdb files).

In this patch, I move the core classes of this code into a common place,
where it can be used from both files. Previously, these were the details
of the implementation, but here I am exposing them (instead of just a
single "string->string" conversion function), as breakpad will need to
use these in a slightly different way. The reason for that is that
breakpad files generated from dwarf expressions use a slightly different
syntax, although most of the core code can be reused with a bit of
thought.

This is also the reason why I am not moving the parsing or dwarf
generation bits, as they will need to be generalized a bit before
they're usable for both scenarios.

This patch should be NFC, modulo renaming the moved entities to more
neutral names.

The reason I am moving this to the "Symbol" library, is because both
customers will be "Symbol"Files, and also the unwinding code lives in
the Symbol library. From a purely dependency standpoint this code will
probably be standalone, and so it could be moved all the way to Utility,
but that seems too low for this kind of functionality.


https://reviews.llvm.org/D60599

Files:
  include/lldb/Symbol/PostfixExpression.h
  source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp

Index: source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
===
--- source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
+++ source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
@@ -11,6 +11,7 @@
 
 #include "lldb/Core/StreamBuffer.h"
 #include "lldb/Core/dwarf.h"
+#include "lldb/Symbol/PostfixExpression.h"
 #include "lldb/Utility/LLDBAssert.h"
 #include "lldb/Utility/Stream.h"
 #include "llvm/ADT/DenseMap.h"
@@ -18,10 +19,10 @@
 #include "llvm/ADT/StringExtras.h"
 #include "llvm/DebugInfo/CodeView/CodeView.h"
 #include "llvm/DebugInfo/CodeView/EnumTables.h"
-#include "llvm/Support/Casting.h"
 
 using namespace lldb;
 using namespace lldb_private;
+using namespace lldb_private::postfix;
 
 namespace {
 
@@ -38,188 +39,36 @@
   llvm::BumpPtrAllocator m_alloc;
 };
 
-class FPOProgramNode {
+class FPOProgramASTVisitorMergeDependent : public Visitor<> {
 public:
-  enum Kind {
-Symbol,
-Register,
-IntegerLiteral,
-BinaryOp,
-UnaryOp,
-  };
-
-protected:
-  FPOProgramNode(Kind kind) : m_token_kind(kind) {}
-
-public:
-  Kind GetKind() const { return m_token_kind; }
-
-private:
-  Kind m_token_kind;
-};
-
-class FPOProgramNodeSymbol: public FPOProgramNode {
-public:
-  FPOProgramNodeSymbol(llvm::StringRef name)
-  : FPOProgramNode(Symbol), m_name(name) {}
-
-  llvm::StringRef GetName() const { return m_name; }
-
-  static bool classof(const FPOProgramNode *node) {
-return node->GetKind() == Symbol;
-  }
-
-private:
-  llvm::StringRef m_name;
-};
-
-class FPOProgramNodeRegisterRef : public FPOProgramNode {
-public:
-  FPOProgramNodeRegisterRef(uint32_t lldb_reg_num)
-  : FPOProgramNode(Register), m_lldb_reg_num(lldb_reg_num) {}
-
-  uint32_t GetLLDBRegNum() const { return m_lldb_reg_num; }
-
-  static bool classof(const FPOProgramNode *node) {
-return node->GetKind() == Register;
-  }
-
-private:
-  uint32_t m_lldb_reg_num;
-};
-
-class FPOProgramNodeIntegerLiteral : public FPOProgramNode {
-public:
-  FPOProgramNodeIntegerLiteral(uint32_t value)
-  : FPOProgramNode(IntegerLiteral), m_value(value) {}
-
-  uint32_t GetValue() const { return m_value; }
-
-  static bool classof(const FPOProgramNode *node) {
-return node->GetKind() == IntegerLiteral;
-  }
-
-private:
-  uint32_t m_value;
-};
-
-class FPOProgramNodeBinaryOp : public FPOProgramNode {
-public:
-  enum OpType {
-Plus,
-Minus,
-Align,
-  };
-
-  FPOProgramNodeBinaryOp(OpType op_type, FPOProgramNode &left,
- FPOProgramNode &right)
-  : FPOProgramNode(BinaryOp), m_op_type(op_type), m_left(&left),
-m_right(&right) {}
-
-  OpType GetOpType() const { return m_op_type; }
-
-  const FPOProgramNode *Left() const { return m_left; }
-  FPOProgramNode *&Left() { return m_left; }
-
-  const FPOProgramNode *Right() const { return m_right; }
-  FPOProgramNode *&Right() { return m_right; }
-
-  static bool classof(const FPOProgramNode *node) {
-return node->GetKind() == BinaryOp;
-  }
-
-private:
-  OpType m_op_type;
-  FPOProgramNode *m_left;
-  FPOProgramNode *m_right;
-};
-
-class FPOProgramNodeUnaryOp : public FPOProgramNode {
-public:
-  enum OpType {
-Deref,
- 

[Lldb-commits] [PATCH] D60599: Move postfix expression code out of the NativePDB plugin

2019-04-12 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere added a comment.

Makes sense, LGTM


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D60599/new/

https://reviews.llvm.org/D60599



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


[Lldb-commits] [PATCH] D60608: Make TestVSCode_step pass reliably

2019-04-12 Thread Pavel Labath via Phabricator via lldb-commits
labath created this revision.
labath added reviewers: clayborg, jgorbe.
Herald added a subscriber: jfb.

The test was failing occasionally (1% of runs or so), because of
unpredictable timings between the two threads spawned by the test. If
the second thread hit the breakpoint right as we were stepping out of
the function on the first thread, we would still be stuck at the inner
frame when the process stopped.

This would cause errors like:

File 
"/home/worker/lldb-x86_64-debian/lldb-x86_64-debian/llvm/tools/lldb/packages/Python/lldbsuite/test/tools/lldb-vscode/step/TestVSCode_step.py",
 line 67, in test_step
  self.assertEqual(x1, x3, 'verify step out variable')
  AssertionError: 2 != 1 : verify step out variable

AFAICT, lldb-vscode is doing the right thing here, and the problem is
that the test is not taking this sequence of events into account. Since
the test is about testing stepping, it does not seem necessary to have
threads in the inferior at all, so I just rewrite the test to execute
the code we're supposed to step through directly on the main thread.


https://reviews.llvm.org/D60608

Files:
  packages/Python/lldbsuite/test/tools/lldb-vscode/step/main.cpp


Index: packages/Python/lldbsuite/test/tools/lldb-vscode/step/main.cpp
===
--- packages/Python/lldbsuite/test/tools/lldb-vscode/step/main.cpp
+++ packages/Python/lldbsuite/test/tools/lldb-vscode/step/main.cpp
@@ -1,5 +1,3 @@
-#include 
-
 int function(int x) {
   if ((x % 2) == 0)
 return function(x-1) + x; // breakpoint 1
@@ -8,9 +6,5 @@
 }
 
 int main(int argc, char const *argv[]) {
-  std::thread thread1(function, 2);
-  std::thread thread2(function, 4);
-  thread1.join();
-  thread2.join();
-  return 0;
+  return function(2);
 }


Index: packages/Python/lldbsuite/test/tools/lldb-vscode/step/main.cpp
===
--- packages/Python/lldbsuite/test/tools/lldb-vscode/step/main.cpp
+++ packages/Python/lldbsuite/test/tools/lldb-vscode/step/main.cpp
@@ -1,5 +1,3 @@
-#include 
-
 int function(int x) {
   if ((x % 2) == 0)
 return function(x-1) + x; // breakpoint 1
@@ -8,9 +6,5 @@
 }
 
 int main(int argc, char const *argv[]) {
-  std::thread thread1(function, 2);
-  std::thread thread2(function, 4);
-  thread1.join();
-  thread2.join();
-  return 0;
+  return function(2);
 }
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [PATCH] D60410: PDBFPO: Improvements to the AST visitor

2019-04-12 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor added a comment.

I believe this revision introduced a warning when compiling with Clang:

   98% [4004/4047] Building CXX object 
tooldir/PdbFPOProgramToDWARFExpression.cpp.o
  
/home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:161:7:
 warning: '(anonymous namespace)::FPOProgramASTVisitor' has virtual 
functions but non-virtual destructor [-Wnon-virtual-dtor]
  class FPOProgramASTVisitor {
^
  
/home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:190:51:
 note: in instantiation of template class '(anonymous 
namespace)::FPOProgramASTVisitor' requested here
  class FPOProgramASTVisitorMergeDependent : public FPOProgramASTVisitor<> {
^
  
/home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:190:7:
 warning: '(anonymous namespace)::FPOProgramASTVisitorMergeDependent' has 
virtual functions but non-virtual destructor [-Wnon-virtual-dtor]
  class FPOProgramASTVisitorMergeDependent : public FPOProgramASTVisitor<> {
^
  
/home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:161:7:
 warning: '(anonymous namespace)::FPOProgramASTVisitor' has virtual 
functions but non-virtual destructor [-Wnon-virtual-dtor]
  class FPOProgramASTVisitor {
^
  
/home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:232:14:
 note: in instantiation of template class '(anonymous 
namespace)::FPOProgramASTVisitor' requested here
  : public FPOProgramASTVisitor {
   ^
  
/home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:231:7:
 warning: '(anonymous namespace)::FPOProgramASTVisitorResolveRegisterRefs' has 
virtual functions but non-virtual destructor [-Wnon-virtual-dtor]
  class FPOProgramASTVisitorResolveRegisterRefs
^
  
/home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:310:7:
 warning: '(anonymous namespace)::FPOProgramASTVisitorDWARFCodegen' has virtual 
functions but non-virtual destructor [-Wnon-virtual-dtor]
  class FPOProgramASTVisitorDWARFCodegen : public FPOProgramASTVisitor<> {
^
  5 warnings generated.


Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D60410/new/

https://reviews.llvm.org/D60410



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


[Lldb-commits] [PATCH] D60410: PDBFPO: Improvements to the AST visitor

2019-04-12 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment.

In D60410#1464214 , @teemperor wrote:

> I believe this revision introduced a warning when compiling with Clang:
>
>98% [4004/4047] Building CXX object 
> tooldir/PdbFPOProgramToDWARFExpression.cpp.o
>   
> /home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:161:7:
>  warning: '(anonymous namespace)::FPOProgramASTVisitor' has virtual 
> functions but non-virtual destructor [-Wnon-virtual-dtor]
>   class FPOProgramASTVisitor {
> ^
>   
> /home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:190:51:
>  note: in instantiation of template class '(anonymous 
> namespace)::FPOProgramASTVisitor' requested here
>   class FPOProgramASTVisitorMergeDependent : public FPOProgramASTVisitor<> {
> ^
>   
> /home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:190:7:
>  warning: '(anonymous namespace)::FPOProgramASTVisitorMergeDependent' has 
> virtual functions but non-virtual destructor [-Wnon-virtual-dtor]
>   class FPOProgramASTVisitorMergeDependent : public FPOProgramASTVisitor<> {
> ^
>   
> /home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:161:7:
>  warning: '(anonymous namespace)::FPOProgramASTVisitor' has virtual 
> functions but non-virtual destructor [-Wnon-virtual-dtor]
>   class FPOProgramASTVisitor {
> ^
>   
> /home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:232:14:
>  note: in instantiation of template class '(anonymous 
> namespace)::FPOProgramASTVisitor' requested here
>   : public FPOProgramASTVisitor {
>^
>   
> /home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:231:7:
>  warning: '(anonymous namespace)::FPOProgramASTVisitorResolveRegisterRefs' 
> has virtual functions but non-virtual destructor [-Wnon-virtual-dtor]
>   class FPOProgramASTVisitorResolveRegisterRefs
> ^
>   
> /home/teemperor/llvm/side/llvm-project/lldb/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp:310:7:
>  warning: '(anonymous namespace)::FPOProgramASTVisitorDWARFCodegen' has 
> virtual functions but non-virtual destructor [-Wnon-virtual-dtor]
>   class FPOProgramASTVisitorDWARFCodegen : public FPOProgramASTVisitor<> {
> ^
>   5 warnings generated.
>


Thanks for the heads up. I'll fix that right away.


Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D60410/new/

https://reviews.llvm.org/D60410



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


[Lldb-commits] [lldb] r358284 - Fix compiler warning introduced by r358261

2019-04-12 Thread Pavel Labath via lldb-commits
Author: labath
Date: Fri Apr 12 06:48:01 2019
New Revision: 358284

URL: http://llvm.org/viewvc/llvm-project?rev=358284&view=rev
Log:
Fix compiler warning introduced by r358261

Add a virtual destructor to the class with virtual methods.

Modified:

lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp

Modified: 
lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp?rev=358284&r1=358283&r2=358284&view=diff
==
--- 
lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
 (original)
+++ 
lldb/trunk/source/Plugins/SymbolFile/NativePDB/PdbFPOProgramToDWARFExpression.cpp
 Fri Apr 12 06:48:01 2019
@@ -160,6 +160,8 @@ private:
 template 
 class FPOProgramASTVisitor {
 protected:
+  virtual ~FPOProgramASTVisitor() = default;
+
   virtual ResultT Visit(FPOProgramNodeBinaryOp &binary,
 FPOProgramNode *&ref) = 0;
   virtual ResultT Visit(FPOProgramNodeUnaryOp &unary, FPOProgramNode *&ref) = 
0;


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


[Lldb-commits] [PATCH] D59960: Fix for ambiguous lookup in expressions between local variable and namespace

2019-04-12 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment.

Just thought of 1 additional way to allow us to pull in fewer var declarations: 
get a list of all of the member variable names in the current class when 
stopped in a class method and only add ones that match local variables. If we 
are in a static member variable then skip of course. Comments? Thoughts?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59960/new/

https://reviews.llvm.org/D59960



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


[Lldb-commits] [PATCH] D59537: Instantiate 'std' templates explicitly in the expression evaluator

2019-04-12 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor updated this revision to Diff 194895.
teemperor added a comment.

- Added more documentation.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59537/new/

https://reviews.llvm.org/D59537

Files:
  lldb/include/lldb/Symbol/ClangASTContext.h
  lldb/include/lldb/Symbol/ClangASTImporter.h
  lldb/include/lldb/Symbol/StdModuleHandler.h
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/deque-basic/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/deque-basic/TestBasicDeque.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/deque-basic/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/deque-dbg-info-content/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/deque-dbg-info-content/TestDbgInfoContentDeque.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/deque-dbg-info-content/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/forward_list-basic/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/forward_list-basic/TestBasicForwardList.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/forward_list-basic/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/forward_list-dbg-info-content/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/forward_list-dbg-info-content/TestDbgInfoContentForwardList.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/forward_list-dbg-info-content/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/list-basic/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/list-basic/TestBasicList.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/list-basic/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/list-dbg-info-content/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/list-dbg-info-content/TestDbgInfoContentList.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/list-dbg-info-content/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/shared_ptr-dbg-info-content/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/shared_ptr-dbg-info-content/TestSharedPtrDbgInfoContent.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/shared_ptr-dbg-info-content/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/shared_ptr/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/shared_ptr/TestSharedPtr.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/shared_ptr/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/unique_ptr-dbg-info-content/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/unique_ptr-dbg-info-content/TestUniquePtrDbgInfoContent.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/unique_ptr-dbg-info-content/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/unique_ptr/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/unique_ptr/TestUniquePtr.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/unique_ptr/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-basic/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-basic/TestBasicVector.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-basic/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-bool/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-bool/TestBoolVector.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-bool/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-dbg-info-content/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-dbg-info-content/TestDbgInfoContentVector.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-dbg-info-content/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-of-vectors/Makefile
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-of-vectors/TestVectorOfVectors.py
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/vector-of-vectors/main.cpp
  
lldb/packages/Python/lldbsuite/test/expression_command/import-std-module/weak_ptr-dbg-in

Re: [Lldb-commits] [PATCH] D59960: Fix for ambiguous lookup in expressions between local variable and namespace

2019-04-12 Thread Jim Ingham via lldb-commits
This won't be complete, since we also get collisions between local variables 
and namespaces, and that wouldn't be detected by your heuristic.

I think the trick that Fred used in https://reviews.llvm.org/D46551 is actually 
pretty complete.  An expression is never going to need to look up a variable if 

strstr(expressionText, varname) == NULL

And OTOH if this is not NULL, there's a very good chance we will need to look 
it up.  So this is a pretty optimal filter.  We should clean this up (I think 
it caused some test failures with the new variable completion in expr, IIRC).  
If we need to do more after that is in place we can, but I bet this will end up 
with us for the most part only injecting local variables where they are needed.

Jim


> On Apr 12, 2019, at 7:21 AM, Greg Clayton via Phabricator 
>  wrote:
> 
> clayborg added a comment.
> 
> Just thought of 1 additional way to allow us to pull in fewer var 
> declarations: get a list of all of the member variable names in the current 
> class when stopped in a class method and only add ones that match local 
> variables. If we are in a static member variable then skip of course. 
> Comments? Thoughts?
> 
> 
> CHANGES SINCE LAST ACTION
>  https://reviews.llvm.org/D59960/new/
> 
> https://reviews.llvm.org/D59960
> 
> 
> 

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


[Lldb-commits] [PATCH] D59960: Fix for ambiguous lookup in expressions between local variable and namespace

2019-04-12 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment.

Jim Ingham said:

> This won't be complete, since we also get collisions between local variables 
> and namespaces, and that wouldn't be detected by your heuristic.
> 
> I think the trick that Fred used in https://reviews.llvm.org/D46551 is 
> actually pretty complete.  An expression is never going to need to look up a 
> variable if
> 
> strstr(expressionText, varname) == NULL
> 
> And OTOH if this is not NULL, there's a very good chance we will need to look 
> it up.  So this is a pretty optimal filter.  We should clean this up (I think 
> it caused some test failures with the new variable completion in expr, IIRC). 
>  If we need to do more after that is in place we can, but I bet this will end 
> up with us for the most part only injecting local variables where they are 
> needed.
> 
> Jim

I am fine if the strstr method is already in place, then my objection is gone.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59960/new/

https://reviews.llvm.org/D59960



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