pindor@gpu.utcs.utoronto.ca (Andrzej Pindor) (05/02/91)
I am trying to debug a C program on a Sun 3/60 using dbxtool. I keep getting these strange messages: Reading symbolic information... Read 1177 symbols program terminated by signal BUS (hardware error) (dbxtool) (dbxtool) cont signal SEGV (no mapping at the fault address) in init_draw at line 489 in file "tile1.c" (dbxtool) Can anyone please suggest either what causes the problem or how to look for the cause? If this is an inappropriate group for my query, please direct me to a more suitable one. Thanks in advance -- Andrzej Pindor University of Toronto Computing Services pindor@gpu.utcs.utoronto.ca
weimer@garden.ssd.kodak.com (Gary Weimer (253-7796)) (05/03/91)
In article <1991May2.133654.9953@gpu.utcs.utoronto.ca>, pindor@gpu.utcs.utoronto.ca (Andrzej Pindor) writes: |> |> I am trying to debug a C program on a Sun 3/60 using dbxtool. I keep getting |> these strange messages: |> |> Reading symbolic information... |> Read 1177 symbols |> program terminated by signal BUS (hardware error) |> (dbxtool) |> |> (dbxtool) cont |> signal SEGV (no mapping at the fault address) in init_draw at line 489 in file "tile1.c" |> (dbxtool) |> |> Can anyone please suggest either what causes the problem or how to look for |> the cause? try looking at line 489 in the file tile1.c (inside the function init_draw). Most likely this uses a pointer which points to an invalid address (hence the Segmentation Violation--SEGV). To find out how you got to that function, you can try using the where command in dbxtool. Unless the bug in your code has corrupted the stack space, this will give a list of the functions called in reverse order (Try it. If it's code that you have looked at, you should be able to understand the output.). You can also print the values of variables that appear on line 489 of tile1.c. If any of the values are unexpected, you need to start tracing your code (by hand, using printf's, or using some of the many features available in dbxtool). weimer@ssd.kodak.com ( Gary Weimer )