[lldb-dev] [Bug 15784] New: expression interpreter fails after the inferior has crashed

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Apr 18 11:04:49 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=15784

            Bug ID: 15784
           Summary: expression interpreter fails after the inferior has
                    crashed
           Product: lldb
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: All Bugs
          Assignee: lldb-dev at cs.uiuc.edu
          Reporter: ashok.thirumurthi at intel.com
    Classification: Unclassified

When expression evaluation is performed after a crash, and the expression can
be handled by the expression interpreter, lldb fails with 

error: warning: expression result unused
error: Interpreting the expression locally failed: Result of expression is in
bad memory

To reproduce, build test/functionalities/inferior-crashing and run
  lldb a.out
  run
  p argc

Note that the automated test, test_inferior_expr shows the expected result and
can be run using:
  python dotest.py --executable <path-to-lldb>
functionalities/inferior-crashing

Note that the above test fails because ClangExpressionParser::ParseAST fails:

runCmd: p argc
error: use of undeclared identifier 'argc'
error: 1 errors parsing expression

The following stack frame shows the expected context for the call:
#1  0x00007ffff1474b93 in lldb_private::ClangUserExpression::Parse
(this=0x102d410, error_stream=..., exe_ctx=...,
execution_policy=lldb_private::eExecutionPolicyNever, 
keep_result_in_memory=true) at 
/home/athirumu/dev/lldb/tools/lldb/source/Expression/ClangUserExpression.cpp:453


To reproduce the above failure manually, use:
  lldb a.out
  run
  p argc
  p argc

Reproduced using Ubuntu 12.04 with clang using r179749.  Also reproduces using
gcc 4.6.3 and icc 13.1.0.  Cannot reproduce manually using gcc in place of
lldb.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20130418/317b04dd/attachment.html>


More information about the lldb-dev mailing list