Lines Matching refs:wp_index
236 uint32_t control_value = 0, wp_index = 0; in SetHardwareWatchpoint() local
281 wp_index = LLDB_INVALID_INDEX32; in SetHardwareWatchpoint()
284 wp_index = i; // Mark last free slot in SetHardwareWatchpoint()
290 if (wp_index == LLDB_INVALID_INDEX32) in SetHardwareWatchpoint()
294 m_hwp_regs[wp_index].real_addr = real_addr; in SetHardwareWatchpoint()
295 m_hwp_regs[wp_index].address = addr; in SetHardwareWatchpoint()
296 m_hwp_regs[wp_index].control = control_value; in SetHardwareWatchpoint()
302 m_hwp_regs[wp_index].address = 0; in SetHardwareWatchpoint()
303 m_hwp_regs[wp_index].control &= ~g_enable_bit; in SetHardwareWatchpoint()
311 return wp_index; in SetHardwareWatchpoint()
315 uint32_t wp_index) { in ClearHardwareWatchpoint() argument
317 LLDB_LOG(log, "wp_index: {0}", wp_index); in ClearHardwareWatchpoint()
328 if (wp_index >= m_max_hwp_supported) in ClearHardwareWatchpoint()
332 lldb::addr_t tempAddr = m_hwp_regs[wp_index].address; in ClearHardwareWatchpoint()
333 uint32_t tempControl = m_hwp_regs[wp_index].control; in ClearHardwareWatchpoint()
336 m_hwp_regs[wp_index].control &= ~g_enable_bit; in ClearHardwareWatchpoint()
337 m_hwp_regs[wp_index].address = 0; in ClearHardwareWatchpoint()
343 m_hwp_regs[wp_index].control = tempControl; in ClearHardwareWatchpoint()
344 m_hwp_regs[wp_index].address = tempAddr; in ClearHardwareWatchpoint()
387 NativeRegisterContextDBReg_arm64::GetWatchpointSize(uint32_t wp_index) { in GetWatchpointSize() argument
389 LLDB_LOG(log, "wp_index: {0}", wp_index); in GetWatchpointSize()
391 switch ((m_hwp_regs[wp_index].control >> 5) & 0xff) { in GetWatchpointSize()
405 bool NativeRegisterContextDBReg_arm64::WatchpointIsEnabled(uint32_t wp_index) { in WatchpointIsEnabled() argument
407 LLDB_LOG(log, "wp_index: {0}", wp_index); in WatchpointIsEnabled()
409 if ((m_hwp_regs[wp_index].control & g_enable_bit) != 0) in WatchpointIsEnabled()
416 uint32_t &wp_index, lldb::addr_t trap_addr) { in GetWatchpointHitIndex() argument
418 LLDB_LOG(log, "wp_index: {0}, trap_addr: {1:x}", wp_index, trap_addr); in GetWatchpointHitIndex()
431 for (wp_index = 0; wp_index < m_max_hwp_supported; ++wp_index) { in GetWatchpointHitIndex()
432 watch_size = GetWatchpointSize(wp_index); in GetWatchpointHitIndex()
433 watch_addr = m_hwp_regs[wp_index].address; in GetWatchpointHitIndex()
435 if (WatchpointIsEnabled(wp_index) && trap_addr >= watch_addr && in GetWatchpointHitIndex()
437 m_hwp_regs[wp_index].hit_addr = trap_addr; in GetWatchpointHitIndex()
442 wp_index = LLDB_INVALID_INDEX32; in GetWatchpointHitIndex()
447 NativeRegisterContextDBReg_arm64::GetWatchpointAddress(uint32_t wp_index) { in GetWatchpointAddress() argument
449 LLDB_LOG(log, "wp_index: {0}", wp_index); in GetWatchpointAddress()
451 if (wp_index >= m_max_hwp_supported) in GetWatchpointAddress()
454 if (WatchpointIsEnabled(wp_index)) in GetWatchpointAddress()
455 return m_hwp_regs[wp_index].real_addr; in GetWatchpointAddress()
460 NativeRegisterContextDBReg_arm64::GetWatchpointHitAddress(uint32_t wp_index) { in GetWatchpointHitAddress() argument
462 LLDB_LOG(log, "wp_index: {0}", wp_index); in GetWatchpointHitAddress()
464 if (wp_index >= m_max_hwp_supported) in GetWatchpointHitAddress()
467 if (WatchpointIsEnabled(wp_index)) in GetWatchpointHitAddress()
468 return m_hwp_regs[wp_index].hit_addr; in GetWatchpointHitAddress()