Skip to content
  1. Feb 27, 2013
    • Greg Clayton's avatar
      Fixed a case where the result of std::string's c_str() method was being called... · 8571963a
      Greg Clayton authored
      Fixed a case where the result of std::string's c_str() method was being called on a local variable and returned as a const char * incorrectly. We used to cache the thread names for threads in the current host process, but we shoudn't be caching that as the names can change over time, so now a std::string is returned from Host::GetThreadName().
      
      llvm-svn: 176217
      8571963a
  2. Dec 07, 2012
    • Daniel Malea's avatar
      Fix a few more clang (3.2) warnings on Linux: · a85e6b6c
      Daniel Malea authored
      - remove unused members
      - add NO_PEDANTIC to selected Makefiles
      - fix return values (removed NULL as needed)
      - disable warning about four-char-constants
      - remove unneeded const from operator*() declaration
      - add missing lambda function return types
      - fix printf() with no format string
      - change sizeof to use a type name instead of variable name
      - fix Linux ProcessMonitor.cpp to be 32/64 bit friendly
      - disable warnings emitted by swig-generated C++ code
      
      Patch by Matt Kopec!
      
      llvm-svn: 169645
      a85e6b6c
  3. Dec 05, 2012
  4. Dec 04, 2012
    • Greg Clayton's avatar
      <rdar://problem/12798131> · 3bcdfc0e
      Greg Clayton authored
      Cleaned up the option parsing code to always pass around the short options as integers. Previously we cast this down to "char" and lost some information. I recently added an assert that would detect duplicate short character options which was firing during the test suite.
      
      This fix does the following:
      - make sure all short options are treated as "int"
      - make sure that short options can be non-printable values when a short option is not required or when an option group is mixed into many commands and a short option is not desired
      - fix the help printing to "do the right thing" in all cases. Previously if there were duplicate short character options, it would just not emit help for the duplicates
      - fix option parsing when there are duplicates to parse options correctly. Previously the option parsing, when done for an OptionGroup, would just start parsing options incorrectly by omitting table entries and it would end up setting the wrong option value
      
      llvm-svn: 169189
      3bcdfc0e
  5. Nov 29, 2012
  6. Oct 09, 2012
  7. Feb 21, 2012
  8. Dec 02, 2011
  9. Sep 20, 2011
  10. Apr 14, 2011
    • Greg Clayton's avatar
      Added auto completion for architecture names and for platforms. · ab65b34f
      Greg Clayton authored
      Modified the OptionGroupOptions to be able to specify only some of the options
      that should be appended by using the usage_mask in the group defintions and
      also provided a way to remap them to a new usage mask after the copy. This 
      allows options to be re-used and also targetted for specific option groups.
      
      Modfied the CommandArgumentType to have a new eArgTypePlatform enumeration.
      Taught the option parser to be able to automatically use the appropriate
      auto completion for a given options if nothing is explicitly specified
      in the option definition. So you don't have to specify it in the option
      definition tables.
      
      Renamed the default host platform name to "host", and the default platform
      hostname to be "localhost".
      
      Modified the "file" and "platform select" commands to make sure all options
      and args are good prior to creating a new platform. Also defer the computation
      of the architecture in the file command until all options are parsed and the
      platform has either not been specified or reset to a new value to avoid
      computing the arch more than once.
      
      Switch the PluginManager code over to using llvm::StringRef for string
      comparisons and got rid of all the AccessorXXX functions in lieu of the newer
      mutex + collection singleton accessors.
      
      llvm-svn: 129483
      ab65b34f
  11. Feb 23, 2011
    • Greg Clayton's avatar
      Abtracted all mach-o and ELF out of ArchSpec. This patch is a modified form · 64195a2c
      Greg Clayton authored
      of Stephen Wilson's idea (thanks for the input Stephen!). What I ended up
      doing was:
      - Got rid of ArchSpec::CPU (which was a generic CPU enumeration that mimics
        the contents of llvm::Triple::ArchType). We now rely upon the llvm::Triple 
        to give us the machine type from llvm::Triple::ArchType.
      - There is a new ArchSpec::Core definition which further qualifies the CPU
        core we are dealing with into a single enumeration. If you need support for
        a new Core and want to debug it in LLDB, it must be added to this list. In
        the future we can allow for dynamic core registration, but for now it is
        hard coded.
      - The ArchSpec can now be initialized with a llvm::Triple or with a C string
        that represents the triple (it can just be an arch still like "i386").
      - The ArchSpec can still initialize itself with a architecture type -- mach-o
        with cpu type and subtype, or ELF with e_machine + e_flags -- and this will
        then get translated into the internal llvm::Triple::ArchSpec + ArchSpec::Core.
        The mach-o cpu type and subtype can be accessed using the getter functions:
        
        uint32_t
        ArchSpec::GetMachOCPUType () const;
      
        uint32_t
        ArchSpec::GetMachOCPUSubType () const;
        
        But these functions are just converting out internal llvm::Triple::ArchSpec 
        + ArchSpec::Core back into mach-o. Same goes for ELF.
      
      All code has been updated to deal with the changes.
      
      This should abstract us until later when the llvm::TargetSpec stuff gets
      finalized and we can then adopt it.
      
      llvm-svn: 126278
      64195a2c
  12. Feb 04, 2011
  13. Jan 22, 2011
  14. Nov 19, 2010
    • Greg Clayton's avatar
      Cleaned up code that wasn't using the Initialize and Terminate paradigm by · 99d0faf2
      Greg Clayton authored
      changing it to use it. There was an extra parameter added to the static
      accessor global user settings controllers that wasn't needed. A bool was being
      used as a parameter to the accessor just so it could be used to clean up 
      the global user settings controller which is now fixed by splitting up the
      initialization into the "static void Class::Initialize()", access into the
      "static UserSettingsControllerSP & Class::GetSettingsController()", and
      cleanup into "static void Class::Terminate()".
      
      Also added initialize and terminate calls to the logging code to avoid issues
      when LLDB is shutting down. There were cases after the logging was switched
      over to use shared pointers where we could crash if the global destructor
      chain was being run and it causes the log to be destroyed and any any logging
      occurred.
      
      llvm-svn: 119757
      99d0faf2
  15. Oct 31, 2010
  16. Oct 29, 2010
  17. Oct 27, 2010
    • Greg Clayton's avatar
      Updated the lldb_private::Flags class to have better method names and made · 73b472d4
      Greg Clayton authored
      all of the calls inlined in the header file for better performance.
      
      Fixed the summary for C string types (array of chars (with any combo if
      modifiers), and pointers to chars) work in all cases.
      
      Fixed an issue where a forward declaration to a clang type could cause itself
      to resolve itself more than once if, during the resolving of the type itself
      it caused something to try and resolve itself again. We now remove the clang
      type from the forward declaration map in the DWARF parser when we start to 
      resolve it and avoid this additional call. This should stop any duplicate
      members from appearing and throwing all the alignment of structs, unions and
      classes.
      
      llvm-svn: 117437
      73b472d4
  18. Jun 23, 2010
    • Sean Callanan's avatar
      Fixed the log streams for logs that output to · 4be3990f
      Sean Callanan authored
      standard output, resolving a crasher.
      
      llvm-svn: 106682
      4be3990f
    • Greg Clayton's avatar
      Very large changes that were needed in order to allow multiple connections · 6611103c
      Greg Clayton authored
      to the debugger from GUI windows. Previously there was one global debugger
      instance that could be accessed that had its own command interpreter and
      current state (current target/process/thread/frame). When a GUI debugger
      was attached, if it opened more than one window that each had a console
      window, there were issues where the last one to setup the global debugger
      object won and got control of the debugger.
      
      To avoid this we now create instances of the lldb_private::Debugger that each 
      has its own state:
      - target list for targets the debugger instance owns
      - current process/thread/frame
      - its own command interpreter
      - its own input, output and error file handles to avoid conflicts
      - its own input reader stack
      
      So now clients should call:
      
          SBDebugger::Initialize(); // (static function)
      
          SBDebugger debugger (SBDebugger::Create());
          // Use which ever file handles you wish
          debugger.SetErrorFileHandle (stderr, false);
          debugger.SetOutputFileHandle (stdout, false);
          debugger.SetInputFileHandle (stdin, true);
      
          // main loop
          
          SBDebugger::Terminate(); // (static function)
          
      SBDebugger::Initialize() and SBDebugger::Terminate() are ref counted to
      ensure nothing gets destroyed too early when multiple clients might be
      attached.
      
      Cleaned up the command interpreter and the CommandObject and all subclasses
      to take more appropriate arguments.
      
      llvm-svn: 106615
      6611103c
  19. Jun 11, 2010
  20. Jun 08, 2010
Loading