target/i386: Use cpu_breakpoint_test in breakpoint_handler
commit50b208b848d9497cf6d320b2d4a38a8f07354f5d
authorRichard Henderson <richard.henderson@linaro.org>
Sun, 20 Jun 2021 06:23:17 +0000 (19 23:23 -0700)
committerRichard Henderson <richard.henderson@linaro.org>
Sat, 10 Jul 2021 03:05:27 +0000 (9 20:05 -0700)
treebbaf2c2d6161ac3831450d2a1ccb296028492f03
parentd1c74ab3a1048a78b5fb8df06c1845e58111ee34
target/i386: Use cpu_breakpoint_test in breakpoint_handler

The loop is performing a simple boolean test for the existence
of a BP_CPU breakpoint at EIP.  Plus it gets the iteration wrong,
if we happen to have a BP_GDB breakpoint at the same address.

We have a function for this: cpu_breakpoint_test.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Message-Id: <20210620062317.1399034-1-richard.henderson@linaro.org>
target/i386/tcg/sysemu/bpt_helper.c