- Dec 16, 2010
-
-
Jason Molenda authored
(from Sean's commit a minute ago) llvm-svn: 121954
-
Sean Callanan authored
can avoid running the code in the target if the expression's result is known and the expression has no side effects. Right now this feature is quite conservative in its guess about side effects, and it only computes integer results, but the machinery to make it more sophisticated is there. llvm-svn: 121952
-
- Dec 14, 2010
-
-
Greg Clayton authored
values or persistent expression variables. Now if an expression consists of a value that is a child of a variable, or of a persistent variable only, we will create a value object for it and make a ValueObjectConstResult from it to freeze the value (for program variables only, not persistent variables) and avoid running JITed code. For everything else we still parse up and JIT code and run it in the inferior. There was also a lot of clean up in the expression code. I made the ClangExpressionVariables be stored in collections of shared pointers instead of in collections of objects. This will help stop a lot of copy constructors on these large objects and also cleans up the code considerably. The persistent clang expression variables were moved over to the Target to ensure they persist across process executions. Added the ability for lldb_private::Target objects to evaluate expressions. We want to evaluate expressions at the target level in case we aren't running yet, or we have just completed running. We still want to be able to access the persistent expression variables between runs, and also evaluate constant expressions. Added extra logging to the dynamic loader plug-in for MacOSX. ModuleList objects can now dump their contents with the UUID, arch and full paths being logged with appropriate prefix values. Thread hardened the Communication class a bit by making the connection auto_ptr member into a shared pointer member and then making a local copy of the shared pointer in each method that uses it to make sure another thread can't nuke the connection object while it is being used by another thread. Added a new file to the lldb/test/load_unload test that causes the test a.out file to link to the libd.dylib file all the time. This will allow us to test using the DYLD_LIBRARY_PATH environment variable after moving libd.dylib somewhere else. llvm-svn: 121745
-
Sean Callanan authored
the code to pass the _cmd pointer has been improved, and _cmd is now set to the value of _cmd for the current context, as opposed to being simply NULL. llvm-svn: 121739
-
- Dec 13, 2010
-
-
Sean Callanan authored
access to the members of the Objective-C self object. The approach we take is to generate the method as a @category on top of the self object, and to pass the "self" pointer to it. (_cmd is currently NULL.) Most changes are in ClangExpressionDeclMap, but the change that adds support to the ABIs to pass _cmd touches a fair amount of code. llvm-svn: 121722
-
- Dec 07, 2010
-
-
Sean Callanan authored
between clients of the LLDB API and the expression parser. llvm-svn: 121193
-
Sean Callanan authored
LLDB expression execution. We also now print the argument structure after execution, to allow us to verify that the expression did indeed execute correctly. llvm-svn: 121126
-
Jim Ingham authored
llvm-svn: 121099
-
Sean Callanan authored
when calling built-ins. llvm-svn: 121070
-
- Dec 06, 2010
-
-
Sean Callanan authored
wrongly as the target of a pointer rather than the SEL pointer itself. This caused incorrect behavior when dealing with Objective-C selector variables. llvm-svn: 121048
-
Sean Callanan authored
(for example, string literals) were being flagged erroneously as undefined external variables. llvm-svn: 120972
-
- Dec 03, 2010
-
-
Sean Callanan authored
llvm-svn: 120834
-
Sean Callanan authored
llvm-svn: 120788
-
Sean Callanan authored
so that it is not referring to potentially stale state during IR execution. This was done by introducing modular state (like ClangExpressionVariable) where groups of state variables have well-defined lifetimes: - m_parser_vars are specific to parsing, and only exist between calls to WillParse() and DidParse(). - m_struct_vars survive for the entire execution of the ClangExpressionDeclMap because they provide the template for a materialized set of expression variables. - m_material_vars are specific to a single instance of materialization, and only exist between calls to Materialize() and Dematerialize(). I also removed unnecessary references to long- lived state that really didn't need to be referred to at all, and also introduced several assert()s that helped me diagnose a few bugs (fixed too). llvm-svn: 120778
-
Greg Clayton authored
TagDecl subclasses and Objective C interfaces to complete themselves through the ExternalASTSource class. llvm-svn: 120749
-
- Dec 02, 2010
-
-
Sean Callanan authored
pointers are used. Previously, they caused a crash in the JIT because we didn't resolve them correctly. llvm-svn: 120728
-
- Dec 01, 2010
-
-
Sean Callanan authored
in C++ methods. There were two fixes involved: - For an object whose contents are not known, the expression should be treated as a non-member, and "this" should have no meaning. - For a const object, the method should be declared const as well. llvm-svn: 120606
-
Sean Callanan authored
persistent variables even after the parser has finished running. llvm-svn: 120521
-
Sean Callanan authored
llvm-svn: 120520
-
- Nov 30, 2010
-
-
Sean Callanan authored
copied by the copy constructor for ClangExpressionVariable. This meant that a NULL m_register_info wouldn't be copied, and instead the field was uninitialized, potentially confusing the materializer. llvm-svn: 120472
-
Jim Ingham authored
Moved the code in ClangUserExpression that set up & ran the thread plan with timeouts, and restarting with all threads into a utility function in Process. This required a bunch of renaming. Added a ThreadPlanCallUserExpression that differs from ThreadPlanCallFunction in that it holds onto a shared pointer to its ClangUserExpression so that can't go away before the thread plan is done using it. Fixed the stop message when you hit a breakpoint while running a user expression so it is more obvious what has happened. llvm-svn: 120386
-
Sean Callanan authored
using special $-variables from expressions. (lldb) expr $rip These variables are available for reading and writing. llvm-svn: 120367
-
- Nov 29, 2010
-
-
Jason Molenda authored
llvm-svn: 120322
-
- Nov 20, 2010
-
-
Sean Callanan authored
of failures in the AST importer. Also ensured that a variable will not be blindly added if GetVariableValue() returns an error. llvm-svn: 119889
-
Sean Callanan authored
llvm-svn: 119888
-
Jason Molenda authored
RegisterContext* - normally this is retrieved from the ExecutionContext's StackFrame but when we need to evaluate an expression while creating the stack frame list this can be a little tricky. Add DW_OP_deref_size, needed for the _sigtramp FDE expression. Add support for processing DWARF expressions in RegisterContextLLDB. Update callers to DWARFExpression::Evaluate. llvm-svn: 119885
-
- Nov 19, 2010
-
-
Sean Callanan authored
perform recursive type lookups, because these are not required for full type fidelity. We also make the SelectorTable last for the full lifetime of the Clang compiler; this was the source of many bugs. llvm-svn: 119835
-
Sean Callanan authored
that the result of an expression should be coerced to a specific type. Also made breakpoint conditions pass in the bool type for this type. The expression parser ignores this indication for now. llvm-svn: 119779
-
Greg Clayton authored
conventions. llvm-svn: 119771
-
- Nov 18, 2010
-
-
Sean Callanan authored
externally-defined variables to match up with the code in ClangASTSource that produces them. llvm-svn: 119750
-
Sean Callanan authored
llvm-svn: 119677
-
Jim Ingham authored
The thread plan destructors may call Thread virtual methods. That means they have to get cleaned up in the derived class's destructor. Make sure that happens. llvm-svn: 119675
-
Sean Callanan authored
They are replaced with calls to the CoreFoundation function CFStringCreateWithBytes() by a portion of the IRForTarget pass. llvm-svn: 119582
-
Sean Callanan authored
llvm-svn: 119581
-
- Nov 17, 2010
-
-
Jim Ingham authored
with the Interrupted bit set. Process::HandlePrivateEvent ignores Interrupted events. DoHalt is changed to ensure that the stop even is processed, and an event with the Interrupted event is posted. Finally ClangFunction is rationalized to use this facility so the that Halt is handled more deterministically. llvm-svn: 119453
-
- Nov 16, 2010
-
-
Greg Clayton authored
It currently isn't working, but it should be close. I will work on this more when I figure out what I am not doing correctly. llvm-svn: 119324
-
- Nov 15, 2010
-
-
Greg Clayton authored
expression logging. Added some properties to the "objc" test. The expression parser can currently display properties that are backed by the default functions "expr myStr.string" will work. But it won't currently work when the property is backed by a different function such as "expr myStr.date". llvm-svn: 119103
-
Greg Clayton authored
Added recursive name lookup logging with depth which is commented out and is currently only enabled when we blow the stack. llvm-svn: 119101
-
- Nov 14, 2010
-
-
Greg Clayton authored
can too. So now the lldb_private::Variable class has support for this. Variables now have support for having a basename ("i"), and a mangled name ("_ZN12_GLOBAL__N_11iE"), and a demangled name ("(anonymous namespace)::i"). Nowwhen searching for a variable by name, users might enter the fully qualified name, or just the basename. So new test functions were added to the Variable and Mangled classes as: bool NameMatches (const ConstString &name); bool NameMatches (const RegularExpression ®ex); I also modified "ClangExpressionDeclMap::FindVariableInScope" to also search for global variables that are not in the current file scope by first starting with the current module, then moving on to all modules. Fixed an issue in the DWARF parser that could cause a varaible to get parsed more than once. Now, once we have parsed a VariableSP for a DIE, we cache the result even if a variable wasn't made so we don't do any re-parsing. Some DW_TAG_variable DIEs don't have locations, or are missing vital info that stops a debugger from being able to display anything for it, we parse a NULL variable shared pointer for these DIEs so we don't keep trying to reparse it. llvm-svn: 119085
-
- Nov 13, 2010
-
-
Greg Clayton authored
expression. This currently takes waaaayyyyy too much time to evaluate. We will need to look at the expression parser and find ways to optimize the info we provide and get this to evaluate quicker. I believe the performance issue is currently related to us always providing a complete C++ class type when asked about a C++ class which can cause a lot of information to be pulled since all classes will be fully created (methods, base classes, members, all their types). We will need to give the classes back the parser and mark them as having external sources and get parser (Sema) to query us when it needs more info. This should bring things up to an acceptable level. llvm-svn: 118979
-