Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix test watchpoint_error when run with a 32-bit build of rr. #3808

Closed

Conversation

bernhardu
Copy link
Contributor

Looks like a 32-bit rr can provide even less hardware breakpionts.

Another option to "fix" would be just skipping it with skip_if_rr_32_bit?

What do you think?

Example output of a failed test:

(rr) break main
break main
Breakpoint 1 at 0x5656328b: file /home/bernhard/data/entwicklung/2023/rr/2022-09-11/rr/src/test/x86/watchpoint_error.c, line 8.
(rr) continue
continue
Continuing.

Breakpoint 1, main ()
    at /home/bernhard/data/entwicklung/2023/rr/2022-09-11/rr/src/test/x86/watchpoint_error.c:8
8         atomic_puts("EXIT-SUCCESS");
watch -l *(long long*)(&buffer[0])
(rr) watch -l *(long long*)(&buffer[0])
Hardware watchpoint 2: -location *(long long*)(&buffer[0])
watch -l *(long long*)(&buffer[8])
(rr) watch -l *(long long*)(&buffer[8])
Hardware watchpoint 3: -location *(long long*)(&buffer[8])
(rr) watch -l *(long long*)(&buffer[16])
watch -l *(long long*)(&buffer[16])
Hardware watchpoint 4: -location *(long long*)(&buffer[16])
watch -l *(long long*)(&buffer[24])
(rr) watch -l *(long long*)(&buffer[24])
Hardware watchpoint 5: -location *(long long*)(&buffer[24])
watch -l *(long long*)(&buffer[32])
(rr) watch -l *(long long*)(&buffer[32])
Hardware watchpoint 6: -location *(long long*)(&buffer[32])
stepi
(rr) stepi
Warning:
Could not insert hardware watchpoint 4.
Could not insert hardware watchpoint 5.
Could not insert hardware watchpoint 6.
Could not insert hardware breakpoints:
You may have requested too many hardware breakpoints/watchpoints.

delete 6
delete 5
watch -l *(long long*)(&buffer[24])
break atomic_puts
Command aborted.
(rr) delete 6
delete 5
(rr) delete 5
watch -l *(long long*)(&buffer[24])
(rr) watch -l *(long long*)(&buffer[24])
Hardware watchpoint 7: -location *(long long*)(&buffer[24])
(rr) break atomic_puts
Breakpoint 8 at 0x56563213: file /home/bernhard/data/entwicklung/2023/rr/2022-09-11/rr/src/test/x86/../util.h, line 178.
(rr) continue
continue
Continuing.
Warning:
Could not insert hardware watchpoint 4.
Could not insert hardware watchpoint 7.
Could not insert hardware breakpoints:
You may have requested too many hardware breakpoints/watchpoints.

Command aborted.
(rr)

@rocallahan rocallahan closed this in 1668def Sep 4, 2024
@bernhardu bernhardu deleted the fix-test-watchpoint-32bit branch September 27, 2024 09:48
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.

1 participant