[all-commits] [llvm/llvm-project] c48390: Simplify Target::RunStopHooks()

Julian Lettner via All-commits all-commits at lists.llvm.org
Mon Mar 3 11:21:59 PST 2025


  Branch: refs/heads/users/yln/lldb-simplify-Target_RunStopHooks
  Home:   https://github.com/llvm/llvm-project
  Commit: c4839032505b7f9df0e41978295d78e096835d87
      https://github.com/llvm/llvm-project/commit/c4839032505b7f9df0e41978295d78e096835d87
  Author: Julian Lettner <jlettner at apple.com>
  Date:   2025-03-03 (Mon, 03 Mar 2025)

  Changed paths:
    M lldb/include/lldb/Target/Target.h
    M lldb/source/Target/Target.cpp

  Log Message:
  -----------
  Simplify Target::RunStopHooks()

Introduce `StopHookResult::NoPreference` and
simplify control flow in `Target::RunStopHooks()`.

The algorithm is (in order):
1. "Auto continue" set on any hook -> continue
2. "Stop demanded" by any hook -> stop
3. "Continue" requested by any hook -> continue
4. Default is to stop

The new `NoPreference` let's us keep the default
distinguishing case 3. and 4.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list