# Question about debugging by GDB on Hifive1

**URL:** <https://forums.sifive.com/t/question-about-debugging-by-gdb-on-hifive1/440>\
**Category:** HiFive1 Rev B\
**Created:** [March 31, 2017, 12:10pm UTC](https://forums.sifive.com/t/question-about-debugging-by-gdb-on-hifive1/440 "2017-03-31T12:10:06Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![mwachs5](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/mwachs5/32/13_2.png) [@mwachs5](https://forums.sifive.com/u/mwachs5)\
**Post date:** [March 31, 2017, 5:07pm UTC](https://forums.sifive.com/t/question-about-debugging-by-gdb-on-hifive1/440/3 "2017-03-31T17:07:37Z")

</div>

Yes, I don’t usually use the `run` command, because we’re connecting to hardware that is already running. We can look into what GDB actually does with the `run` command and see how it translates to OpenOCD.

@chriszhang you may also want to refer to this other thread :

> [@Problems w/ run\_debug, run\_openocd, run\_gdb make targets w/ E300 Arty](http://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332):
>
> I’m having issues getting openocd to do anything more than upload and run images on my Arty E300 board. The ‘make upload’ target executes successfully, but when I try ‘make run\_debug’ using the same program image, gdb starts but the image exists with 0x0000003 as the exist code after a ‘unhandled trap’ message. 'make run\_openocd appears to hang after loading the image. ‘make run\_gdb’ starts gdb running, but none of the gdb commands seem to work correctly (eg, ‘run’ at the gdb prompt generates …

---

_[View the full topic](https://forums.sifive.com/t/question-about-debugging-by-gdb-on-hifive1/440)._
