1. 20 Apr, 2016 3 commits
    • Vicent Marti's avatar
      cc: Add a set of ELF-related APIs based on libelf · b8f0f092
      Vicent Marti authored
      The following APIs have been implemented inside `libbcc`, which
      programatically replicate the previous usage of `binutils` tools like
      `objdump` and `elfdump`.
      
      - bcc_elf_foreach_usdt: finds all USDT probes inside a given binary
      - bcc_elf_loadadddr: find the load address for a shared object
      - bcc_elf_foreach_sym: lists all symbols in an ELF binary or SO
      - bcc_elf_shared_obj: returns whether a given path is an ELF shared
        object, a binary, or neither
      b8f0f092
    • Vicent Marti's avatar
      cmake: Add dependency to LibELF · 0612db5f
      Vicent Marti authored
      Add a new a `FindLibElf.cmake` package, and use it to link the main
      `libbcc` library against the system's LibELF. This library will be used
      to re-implement functionality that was previously dependent on
      `binutils`.
      0612db5f
    • Vicent Marti's avatar
      cmake: Properly use library detection modules · ff9ff5d6
      Vicent Marti authored
      Instead of importing the `Find*.cmake` modules directly, place them in
      the root `cmake/` folder and define it as a CMake Module path. This lets
      us use the `find_package` builtin to require any given packages.
      ff9ff5d6
  2. 19 Apr, 2016 7 commits
  3. 18 Apr, 2016 2 commits
  4. 17 Apr, 2016 3 commits
  5. 16 Apr, 2016 1 commit
    • Aaron Puchert's avatar
      Don't require "OS ABI" specification in libraries · 3926f264
      Aaron Puchert authored
      The most important system libraries are listed like this by ldconfig:
      
      	libc.so.6 (libc6,x86-64, OS ABI: Linux 3.0.0) => /lib64/libc.so.6
      
      But most user-level libraries don't have the "OS ABI" and will not be
      found by the regular expression.
      
      	libz.so (libc6,x86-64) => /usr/lib64/libz.so
      
      This makes the regular expression more permissive, so that it finds
      those libraries as well.
      3926f264
  6. 15 Apr, 2016 1 commit
    • Vicent Marti's avatar
      lua: Properly support high-range 64 addresses · fbf7193c
      Vicent Marti authored
      Lua's native Number type is a 64-bit double with 52-bit precision, which
      was causing rounding errors when storing and working with high-range
      memory addresses (namely, addresses from the kernel, which are all in
      the `0xffffffff........` range).
      
      To work around this, we've made sure to never call `tonumber` on any
      variables that represent memory addresses, and instead continue
      operating on them with their native types: LuaJIT can work with the
      underlying `uint64_t` type for these values and transparently perform
      all kinds of numeric operations.
      
      The only limitation of working with native 64-bit types in LuaJIT is
      that they cannot be printed with the language's default `string.format`
      API. To give better UX to probe writers, these APIs have been
      monkeypatched so the `%p` format specifier will now properly handle
      64-bit addresses and print them in an appropriate format.
      fbf7193c
  7. 14 Apr, 2016 1 commit
  8. 11 Apr, 2016 2 commits
  9. 10 Apr, 2016 5 commits
  10. 09 Apr, 2016 2 commits
  11. 06 Apr, 2016 6 commits
  12. 05 Apr, 2016 4 commits
  13. 04 Apr, 2016 3 commits