- Feb 04, 2012
-
-
Sean Callanan authored
LLVM/Clang. This brings in several fixes, including: - Improvements in the Just-In-Time compiler's allocation of memory: the JIT now allocates memory in chunks of sections, improving its ability to generate relocations. I have revamped the RecordingMemoryManager to reflect these changes, as well as to get the memory allocation and data copying out fo the ClangExpressionParser code. Jim Grosbach wrote the updates to the JIT on the LLVM side. - A new ExternalASTSource interface to allow LLDB to report accurate structure layout information to Clang. Previously we could only report the sizes of fields, not their offsets. This meant that if data structures included field alignment directives, we could not communicate the necessary alignment to Clang and accesses to the data would fail. Now we can (and I have update the relevant test case). Thanks to Doug Gregor for implementing the Clang side of this fix. - The way Objective-C interfaces are completed by Clang has been made consistent with RecordDecls; with help from Doug Gregor and Greg Clayton I have ensured that this still works. - I have eliminated all local LLVM and Clang patches, committing the ones that are still relevant to LLVM and Clang as needed. I have tested the changes extensively locally, but please let me know if they cause any trouble for you. llvm-svn: 149775
-
Greg Clayton authored
Changed the lldb.SBModule.section[<str>] property to return a single section. Added a lldb.SBSection.addr property which returns an lldb.SBAddress object. llvm-svn: 149755
-
Greg Clayton authored
instead of the __repr__. __repr__ is a function that should return an expression that can be used to recreate an python object and we were using it to just return a human readable string. Fixed a crasher when using the new implementation of SBValue::Cast(SBType). Thread hardened lldb::SBValue and lldb::SBWatchpoint and did other general improvements to the API. Fixed a crasher in lldb::SBValue::GetChildMemberWithName() where we didn't correctly handle not having a target. llvm-svn: 149743
-
Johnny Chen authored
llvm-svn: 149741
-
- Feb 03, 2012
-
-
Johnny Chen authored
llvm-svn: 149710
-
Johnny Chen authored
llvm-svn: 149707
-
Enrico Granata authored
Fixing issues where synthetic children providers for STL containers std::list and std::map where not doing their job properly llvm-svn: 149700
-
Greg Clayton authored
lldb.SBValueList now exposes the len() method and also allows item access: lldb.SBValueList[<int>] - where <int> is an integer index into the list, returns a single lldb.SBValue which might be empty if the index is out of range lldb.SBValueList[<str>] - where <str> is the name to look for, returns a list() of lldb.SBValue objects with any matching values (the list might be empty if nothing matches) lldb.SBValueList[<re>] - where <re> is a compiles regular expression, returns a list of lldb.SBValue objects for containing any matches or a empty list if nothing matches lldb.SBFrame now exposes: lldb.SBFrame.variables => SBValueList of all variables that are in scope lldb.SBFrame.vars => see lldb.SBFrame.variables lldb.SBFrame.locals => SBValueList of all variables that are locals in the current frame lldb.SBFrame.arguments => SBValueList of all variables that are arguments in the current frame lldb.SBFrame.args => see lldb.SBFrame.arguments lldb.SBFrame.statics => SBValueList of all static variables lldb.SBFrame.registers => SBValueList of all registers for the current frame lldb.SBFrame.regs => see lldb.SBFrame.registers Combine any of the above properties with the new lldb.SBValueList functionality and now you can do: y = lldb.frame.vars['rect.origin.y'] or vars = lldb.frame.vars for i in range len(vars): print vars[i] Also expose "lldb.SBFrame.var(<str>)" where <str> can be en expression path for any variable or child within the variable. This makes it easier to get a value from the current frame like "rect.origin.y". The resulting value is also not a constant result as expressions will return, but a live value that will continue to track the current value for the variable expression path. lldb.SBValue now exposes: lldb.SBValue.unsigned => unsigned integer for the value lldb.SBValue.signed => a signed integer for the value llvm-svn: 149684
-
Greg Clayton authored
llvm-svn: 149673
-
Greg Clayton authored
lldb.SBModule.section and lldb.SBModule.sections property access. llvm-svn: 149665
-
Enrico Granata authored
Adding support for an "equivalents map". This can be useful when compilers emit multiple, different names for the same actual type. In such scenarios, one of the type names can actually be found during a type lookup, while the others are just aliases. This can cause issues when trying to work with these aliased names and being unable to resolve them to an actual type (e.g. getting an SBType for the aliased name). Currently, no code is using this feature, since we can hopefully rely on the new template support in SBType to get the same stuff done, but the support is there just in case it turns out to be useful for some future need. llvm-svn: 149661
-
Greg Clayton authored
uint32_t SBType::GetNumberOfTemplateArguments (); lldb::SBType SBType::GetTemplateArgumentType (uint32_t idx); lldb::TemplateArgumentKind SBType::GetTemplateArgumentKind (uint32_t idx); Some lldb::TemplateArgumentKind values don't have a corresponding SBType that will be returned from SBType::GetTemplateArgumentType(). This will help our data formatters do their job by being able to find out the type of template params and do smart things with those. llvm-svn: 149658
-
Johnny Chen authored
llvm-svn: 149656
-
Enrico Granata authored
When used in conjunction with --inline-children, this option will cause the names of the values to be omitted from the output. This can be beneficial in cases such as vFloat, where it will compact the representation from ([0]=1,[1]=2,[2]=3,[3]=4) to (1, 2, 3, 4). Added a test case to check that the new option works correctly. Also took some time to revisit SummaryFormat and related classes and tweak them for added readability and maintainability. Finally, added a new class name to which the std::string summary should be applied. llvm-svn: 149644
-
- Feb 02, 2012
-
-
Johnny Chen authored
bool lldb_private::StateIsStoppedState (StateType state, bool must_exist) instead. llvm-svn: 149637
-
Johnny Chen authored
should use Target::ReadMemory() call to read from the file section offset address. Also remove the @expectedFailure decorator.. 'target variable' command fails if the target program has been run rdar://problem/9763907 llvm-svn: 149629
-
Greg Clayton authored
This affected bash users. llvm-svn: 149623
-
Greg Clayton authored
otherwise we will have a launched process stopped at the entry point and it will get reparented when debugserver goes away and we won't be able to kill the process later. llvm-svn: 149622
-
Greg Clayton authored
llvm-svn: 149609
-
Enrico Granata authored
ensure that changes to the typemaps are properly detected and cause SWIG to rebuild LLDBWrapPython.cpp llvm-svn: 149606
-
Greg Clayton authored
a type when we have a forward declaration. We always have found a type by basename, but now we also compare the decl context of the die we are trying to complete with the matches we find from the accelerator tables to ensure we get the right one. llvm-svn: 149593
-
Greg Clayton authored
negative hex values. Also added a very rudimentary version of the == and != operators to the lldb.value helper class. llvm-svn: 149564
-
- Feb 01, 2012
-
-
Johnny Chen authored
llvm-svn: 149529
-
Johnny Chen authored
llvm-svn: 149523
-
Johnny Chen authored
llvm-svn: 149519
-
Greg Clayton authored
You can now access a frame in a thread using: lldb.SBThread.frame[int] -> lldb.SBFrame object for a frame in a thread Where "int" is an integer index. You can also access a list object with all of the frames using: lldb.SBThread.frames => list() of lldb.SBFrame objects All SB objects that give out SBAddress objects have properties named "addr" lldb.SBInstructionList now has the following convenience accessors for len() and instruction access using an index: insts = lldb.frame.function.instructions for idx in range(len(insts)): print insts[idx] Instruction lists can also lookup an isntruction using a lldb.SBAddress as the key: pc_inst = lldb.frame.function.instructions[lldb.frame.addr] lldb.SBProcess now exposes: lldb.SBProcess.is_alive => BOOL Check if a process is exists and is alive lldb.SBProcess.is_running => BOOL check if a process is running (or stepping): lldb.SBProcess.is_running => BOOL check if a process is currently stopped or crashed: lldb.SBProcess.thread[int] => lldb.SBThreads for a given "int" zero based index lldb.SBProcess.threads => list() containing all lldb.SBThread objects in a process SBInstruction now exposes: lldb.SBInstruction.mnemonic => python string for instruction mnemonic lldb.SBInstruction.operands => python string for instruction operands lldb.SBInstruction.command => python string for instruction comment SBModule now exposes: lldb.SBModule.uuid => uuid.UUID(), an UUID object from the "uuid" python module lldb.SBModule.symbol[int] => lldb.Symbol, lookup symbol by zero based index lldb.SBModule.symbol[str] => list() of lldb.Symbol objects that match "str" lldb.SBModule.symbol[re] => list() of lldb.Symbol objecxts that match the regex lldb.SBModule.symbols => list() of all symbols in a module SBAddress objects can now access the current load address with the "lldb.SBAddress.load_addr" property. The current "lldb.target" will be used to try and resolve the load address. Load addresses can also be set using this accessor: addr = lldb.SBAddress() addd.load_addr = 0x123023 Then you can check the section and offset to see if the address got resolved. SBTarget now exposes: lldb.SBTarget.module[int] => lldb.SBModule from zero based module index lldb.SBTarget.module[str] => lldb.SBModule by basename or fullpath or uuid string lldb.SBTarget.module[uuid.UUID()] => lldb.SBModule whose UUID matches lldb.SBTarget.module[re] => list() of lldb.SBModule objects that match the regex lldb.SBTarget.modules => list() of all lldb.SBModule objects in the target SBSymbol now exposes: lldb.SBSymbol.name => python string for demangled symbol name lldb.SBSymbol.mangled => python string for mangled symbol name or None if there is none lldb.SBSymbol.type => lldb.eSymbolType enum value lldb.SBSymbol.addr => SBAddress object that represents the start address for this symbol (if there is one) lldb.SBSymbol.end_addr => SBAddress for the end address of the symbol (if there is one) lldb.SBSymbol.prologue_size => pythin int containing The size of the prologue in bytes lldb.SBSymbol.instructions => SBInstructionList containing all instructions for this symbol SBFunction now also has these new properties in addition to what is already has: lldb.SBFunction.addr => SBAddress object that represents the start address for this function lldb.SBFunction.end_addr => SBAddress for the end address of the function lldb.SBFunction.instructions => SBInstructionList containing all instructions for this function SBFrame now exposes the SBAddress for the frame: lldb.SBFrame.addr => SBAddress which is the section offset address for the current frame PC These are all in addition to what was already added. Documentation and website updates coming soon. llvm-svn: 149489
-
Greg Clayton authored
Added a new convenience property on lldb.SBThread names "frames" which always returns a complete list of all lldb.SBFrame objects: (lldb) script >>> frames = lldb.thread.frames >>> for frame in frames: ... print frame Also changed all of the "__repr__" methods to strip any trailing newline characters so we don't end up with entra newlines. llvm-svn: 149466
-
Johnny Chen authored
o Symbols.cpp: Emit a warning message when dSYM does not match the binary. o warnings/uuid: Added regression test case. o lldbtest.py: Modified to allow test case writer to demand that the build command does not begin with a clean first; required to make TestUUIDMismatchWanring.py work. rdar://problem/10515708 llvm-svn: 149465
-
Greg Clayton authored
lldb.value() It it designed to be given a lldb.SBValue object and it allows natural use of a variable value: pt = lldb.value(lldb.frame.FindVariable("pt")) print pt print pt.x print pt.y pt = lldb.frame.FindVariable("rectangle_array") print rectangle_array[12] print rectangle_array[5].origin.x Note that array access works just fine and works on arrays or pointers: pt = lldb.frame.FindVariable("point_ptr") print point_ptr[5].y Also note that pointer child accesses are done using a "." instead of "->": print point_ptr.x llvm-svn: 149464
-
Enrico Granata authored
llvm-svn: 149461
-
Greg Clayton authored
We previously weren't catching that SBValue::Cast(...) would crash if we had an invalid (empty) SBValue object. Cleaned up the SBType API a bit. llvm-svn: 149447
-
Jim Ingham authored
Threads now store their "temporary" resume state, so we know whether they were suspended in the most recent step, and if they weren't allowed to run, don't ask questions about their state unless explicitly requested to do so. llvm-svn: 149443
-
- Jan 31, 2012
-
-
Enrico Granata authored
llvm-svn: 149421
-
Enrico Granata authored
llvm-svn: 149420
-
Enrico Granata authored
llvm-svn: 149419
-
Enrico Granata authored
Splitting test case for Python synthetic children: part 1 test is only testing the synthetic children feature itself. More test cases will be commited for individual STL containers llvm-svn: 149393
-
Enrico Granata authored
llvm-svn: 149390
-
Enrico Granata authored
This commit provides a new default summary for Objective-C boolean variables, which shows YES or NO instead of the character value. A new category named objc is added to contain this summary provider. Any future Objective-C related formatters would probably fit here llvm-svn: 149388
-
Greg Clayton authored
instances to not pthread_cancel the read threads and wreak havoc on the mutex in our ConnectionFileDescriptor class. Also cleaned up some shutdown delays. llvm-svn: 149355
-
rdar://problem/10776614Greg Clayton authored
Fixed an issue where we can crash if you call cast when the SBValue doesn't contain a valid value. llvm-svn: 149345
-