cortex_m: implement hit_watchpoint function