how do i use a debugger ,

GFA, ASM, STOS, ...

Moderators: simonsunnyboy, Mug UK, Zorro 2, Moderator Team

User avatar
charles
10 GOTO 10
10 GOTO 10
Posts: 2394
Joined: Tue Aug 17, 2004 12:11 am
Location: ont. Canada
Contact:

how do i use a debugger ,

Postby charles » Sun Sep 09, 2018 4:44 am

im at the point where I feel I should ask ,,

what is a debugger ?

and how do u use one?

hit a wall on my project and use the down time to research other areas of interest..
The radioactive half-life : )
Atari is a lifestyle,not a hobby.
HOLD ON ! ! ! Im printing unreadable characters ...!

joska
Hardware Guru
Hardware Guru
Posts: 4144
Joined: Tue Oct 30, 2007 2:55 pm
Location: Florø, Norway
Contact:

Re: how do i use a debugger ,

Postby joska » Mon Sep 10, 2018 7:23 pm

charles wrote:what is a debugger ?


A debugger is a program that let you inspect the status of the program you want to debug. You can step through the code line by line, and watch the variables and data changing. You can define breakpoints in your code, i.e. points in your code where execution is halted and control is handed over to the debugger so you can inspect the state of variables and data, and either abort the program, continue running it or stepping through it line by line from the breakpoint.

Most debuggers for TOS works at the assembler level, you don't see your actual source code but the assembler code generated by the compiler. But there are source-level debuggers too, the best I have used on TOS is the PureC debugger. It lets you inspect the code both at the source level and at the assembler level, even at the same time. It's been a long time since I used any Pascal compiler but IIRC Pure Pascal has a similar debugger.

Source level debuggers are infinitely more useful than low level debuggers when using high-level languages, and the Pure debugger is the main reason why I mostly use PureC when programming on my Ataris.
Jo Even

VanillaMiNT - Firebee - Falcon060 - Milan060 - Falcon040 - MIST - Mega ST - STM - STE - Amiga 600 - Sharp MZ700 - MSX - Amstrad CPC - C64

User avatar
charles
10 GOTO 10
10 GOTO 10
Posts: 2394
Joined: Tue Aug 17, 2004 12:11 am
Location: ont. Canada
Contact:

Re: how do i use a debugger ,

Postby charles » Mon Sep 10, 2018 10:14 pm

good explaination .. I knew it behaved very much in the manner described.
im still a novice coder so code is just code to me , however learning and making good understanding of these items should be beneficial..(sooner or later)
currentily I have one line of problematic code I need to inspect further....
afraid my knowledge isn't vast enough to find the trouble...

does an interrupt affect the stack in anyway ?
The radioactive half-life : )
Atari is a lifestyle,not a hobby.
HOLD ON ! ! ! Im printing unreadable characters ...!


Social Media

     

Return to “Coding”

Who is online

Users browsing this forum: No registered users and 2 guests