gdbserver: Add assert in find_register_by_number
authorThiago Jung Bauermann <thiago.bauermann@linaro.org>
Tue, 16 Aug 2022 17:18:47 +0000 (17:18 +0000)
committerThiago Jung Bauermann <thiago.bauermann@linaro.org>
Wed, 1 Feb 2023 19:48:07 +0000 (19:48 +0000)
commitcbd02f9fa521a6cb21c04b15ee7671c8bb4be55b
tree2020002b59cf64272d5407c6cfcde95a9cf56b64
parentcded17bfca35566fa4d36e9ec06fa071bd7dab17
gdbserver: Add assert in find_register_by_number

It helped me during development, catching bugs closer to when they actually
happened.

Also remove the equivalent gdb_assert in regcache_raw_read_unsigned, since
it's checking the same condition a few frames above.

Suggested-By: Simon Marchi <simon.marchi@efficios.com>
Approved-By: Simon Marchi <simon.marchi@efficios.com>
gdbserver/regcache.cc