Namespaces

Enumerations

enum JobExceptionChannelType
Name Value
kException 0
kDebugger 1

Defined at line 10 of file ../../src/developer/debug/debug_agent/job_exception_channel_type.h

enum MockJobExceptionInfo
Name Value
kProcessStarting 0
kProcessNameChanged 1
kException 2

Defined at line 14 of file ../../src/developer/debug/debug_agent/mock_job_handle.h

enum FakeEventType
Name Value
kDebugStarted 0
kStopped 1
kLast 2

Defined at line 16 of file ../../src/developer/debug/debug_agent/mock_component_manager.h

Records

Functions

  • std::string GetBacktraceMarkupForThread (const ProcessHandle & process, const ThreadHandle & thread)

    Defined at line 15 of file ../../src/developer/debug/debug_agent/backtrace_utils.cc

  • bool WriteAligned64Chunks (const void * buf, size_t len, fit::function<bool (uint64_t, uint64_t *)> read, fit::function<bool (uint64_t, uint64_t)> write, uint64_t dest_addr)

    Converts writing an array to a sequence of full-64-bit-word reads and writes (for ptrace memory

    functions). This is provided as a generic function so it can easily be unit testable on top of

    simpler platform APIs.

    Defined at line 22 of file ../../src/developer/debug/debug_agent/aligned_chunk.cc

  • uint64_t GetNowTimestamp ()

    Returns the current time as a timestamp for use in IPC messages.

    Defined at line 33 of file ../../src/developer/debug/debug_agent/time.h

  • debug::Status WalkElfModules (const ProcessHandle & process, uint64_t dl_debug_addr, std::function<bool (uint64_t, uint64_t)> cb)

    Iterates through all modules in the given process, calling the callback for each. The callback

    should return true to keep iterating, false to stop now.

    Defined at line 68 of file ../../src/developer/debug/debug_agent/elf_utils.cc

  • unwinder::Error UnwindStack (const ProcessHandle & process, const ModuleList & modules, const ThreadHandle & thread, const GeneralRegisters & regs, size_t max_depth, std::vector<debug_ipc::StackFrame> * stack)

    Returns the cumulative unwinder error value if the unwinding was fatally aborted - meaning that

    no unwinding strategies could unwind past the final frame in |stack| - the error message should

    include failure reasons for all attempted unwinders. Returns unwinder::Error::Success on

    successfully identified final stack frame.

    Defined at line 43 of file ../../src/developer/debug/debug_agent/unwind.cc

  • std::optional<debug::AddressRange> AlignRange (const debug::AddressRange & range)

    Depending on their size, watchpoints can only be inserted into aligned ranges. The alignment is

    as follows:

    Size Alignment

    1 1 byte

    2 2 byte

    4 4 byte

    8 8 byte

    A given range could be un-aligned (eg. observe two bytes unaligned). This will attempt to create

    a bigger range that will cover that range, so that the watchpoint can be installed and still

    track this range.

    If the range cannot be aligned (eg. unaligned 8 byte range), it will return a null option.

    Defined at line 60 of file ../../src/developer/debug/debug_agent/align.cc

  • fit::result<debug::Status, TestRealmAndOffers> GetTestRealmAndOffers (const std::string & realm_arg, fidl::SyncClient<fuchsia_sys2::LifecycleController> lifecycle_controller, fidl::SyncClient<fuchsia_sys2::RealmQuery> realm_query)

    Gets the test realm and related offers specified by |realm_arg|, which takes the form

    <realm

    moniker>:

    <test

    collection>.

    Defined at line 170 of file ../../src/developer/debug/debug_agent/test_realm.cc

  • std::vector<debug_ipc::Module> GetElfModulesForProcess (const ProcessHandle & process, uint64_t dl_debug_addr)

    Computes the modules for the given process.

    Defined at line 104 of file ../../src/developer/debug/debug_agent/elf_utils.cc

  • fit::result<debug::Status, TestRealmAndOffers> GetTestRealmAndOffers (const std::string & realm_arg)

    Gets the test realm and related offers specified by |realm_arg|, which takes the form

    <realm

    moniker>:

    <test

    collection>. This overload connects to |LifecycleController| and

    |RealmQuery| and calls the overload above.

    Defined at line 225 of file ../../src/developer/debug/debug_agent/test_realm.cc