public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* why gdb try to read address 0x0 when I set $pc,how to suppress this behavior?
@ 2023-07-19  7:59 庄秋彬
  2023-07-19 12:44 ` 庄秋彬
  2023-07-26 16:09 ` Tom Tromey
  0 siblings, 2 replies; 5+ messages in thread
From: 庄秋彬 @ 2023-07-19  7:59 UTC (permalink / raw)
  To: gdb

[-- Attachment #1: Type: text/plain, Size: 1509 bytes --]

Hi,

I use gdb with openocd to debug a riscv board, and found that when set $pc=xxx(a non-zero value) in gdb, gdb would first read the address 0x0, which caused an error on this riscv device.
Is there any documentation or suggestions for reading the source code to solve this problem? 
Thanks


This message and any attachment are confidential and may be privileged or otherwise protected from disclosure. If you are not an intended recipient of this message, please delete it and any attachment from your system and notify the sender immediately by reply e-mail. Unintended recipients should not use, copy, disclose or take any action based on this message or any information contained in this message. Emails cannot be guaranteed to be secure or error free as they can be intercepted, amended, lost or destroyed, and you should take full responsibility for security checking. 
 
本邮件及其任何附件具有保密性质,并可能受其他保护或不允许被披露给第三方。如阁下误收到本邮件,敬请立即以回复电子邮件的方式通知发件人,并将本邮件及其任何附件从阁下系统中予以删除。如阁下并非本邮件写明之收件人,敬请切勿使用、复制、披露本邮件或其任何内容,亦请切勿依本邮件或其任何内容而采取任何行动。电子邮件无法保证是一种安全和不会出现任何差错的通信方式,可能会被拦截、修改、丢失或损坏,收件人需自行负责做好安全检查。

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-07-27 17:36 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-19  7:59 why gdb try to read address 0x0 when I set $pc,how to suppress this behavior? 庄秋彬
2023-07-19 12:44 ` 庄秋彬
2023-07-26 16:09 ` Tom Tromey
2023-07-27 15:51   ` 庄秋彬
2023-07-27 17:36     ` Torbjorn SVENSSON

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).