If you are using SunStudio the debugger that the IDE uses is dbx, not gdb.
Dbx is unlikley to gracefully handle a breakpoint trap from
aninstruction which it didn't install itself.
If you're using such a trap as a panic or in an assert statement the
unixy thing to do is to call abort().
You can also replace these by calls to a global function
called (for example) "breakpoint()" which does nothing.
You need to make sure it doesn't get optimized away.
Then in the debugger, you just say "stop in breakpoint".
You get the same effect as an inlined breakpoint.
--chris