Skip to content

Conversation

andrurogerz
Copy link
Collaborator

Purpose

When a Z packet it sent to set a breakpoint or watchpoint, check the access mask for the containing memory region and fail if it doesn't make sense for the requested breakpoint/watchpoint type.

Overview

  • For hardware and software breakpoints, fail if the containing memory region is not executable
  • For read watchpoints, fail if the containing memory region is not readable
  • For write watchpoints, fail if the containing memory region is not writeable
  • For access watchpoints, fail if the containing memory region is not either readable or writable.
  • Enable the TestBadAddressBreakpoints.BadAddressBreakpointTestCase.test_bad_address_breakpoints lldb test case that was failing because of the missing checks

Validation

GitHub build & test job

@andrurogerz andrurogerz merged commit 2e7f67a into compnerd:main Oct 30, 2024
30 checks passed
@andrurogerz andrurogerz deleted the invalid-breakpoint branch October 30, 2024 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants