Page MenuHomePhabricator

Don't set a software stepping breakpoint at 0 on arm.

Authored by labath on Oct 19 2016, 2:11 PM.



Added a test for the next_pc being zero before setting a software breakpoint
in arm32.
Reenabled the crash during step test for android/linux.

Event Timeline

jmajors updated this revision to Diff 75218.Oct 19 2016, 2:11 PM
jmajors retitled this revision from to Don't set a software stepping breakpoint at 0 on arm..
jmajors updated this object.
jmajors added a reviewer: labath.
jmajors added a subscriber: lldb-commits.

Not commenting on the substance of the change (though it seems sensible to me.) The inclusion of the .gitignore was probably accidental, but in any case, try not to gang unrelated changes together like this. Thanks!

labath requested changes to this revision.Oct 19 2016, 3:12 PM
labath edited edge metadata.

I envisioned a bit different solution to this problem. The issue does not happen only when the inferior jumps to a literal 0x0 address, but for any address that is not mapped into memory (so we cannot set a breakpoint there). The simplest way to figure out whether we are able to set a breakpoint is to actually try setting it, and check for the error. (plus, I don't think your code handles the thumb case)

And yes, the .gitignore changes should not be a part of this change. :)

This revision now requires changes to proceed.Oct 19 2016, 3:12 PM
labath commandeered this revision.Oct 27 2016, 11:37 AM
labath abandoned this revision.
labath edited reviewers, added: jmajors; removed: labath.