How to put a breakpoint in a code

How to put a breakpoint in a code

Portrait de Rasoul K.

I want to put a breakpoint in a code.

I presume with a breakpoint, code will execute until it reaches the breakpoint and then need my approval to succeed. Am I correct?

Trying to put a brekpoit, it asks for a function.

I don't understand what is the function in this stage?

7 posts / 0 nouveau(x)
Dernière contribution
Reportez-vous à notre Notice d'optimisation pour plus d'informations sur les choix et l'optimisation des performances dans les produits logiciels Intel.
Portrait de IanH

How (what menu items, keypresses, etc) are you inserting the breakpoint?

An easy way to insert a breakpoint in a file that is part of a project is to select the line of interest, and then select Debug > Toggle breakpoint (F9 is the short cut key for most keyboard configurations). You should see a red circle appear in the margin on that line. Repeat to turn the breakpoint off.

Portrait de Rasoul K.

My understanding of breakpoint is that the program will execute until that point and stops and will wait for further instruction from me. Is it correct?
If it correct, then how can I resume the execution?

Portrait de Anthony Richards

Under the Debug menu option you will find various function keys Fn (some times in combination with the shift key) to use to step through the code after you have triggered a break point..
For example shift+F8 will step through or 'over' the line of code that is pointed to..
I think F8 wil enter a function or subroutine if a call is on the line of code in question, F5 will just continue execution to the next break point or until an error is detected or until program code requires an action from the user, or until the program exits normally.

Portrait de Rasoul K.

Quote:

Anthony Richards wrote:

Under the Debug menu option you will find various function keys Fn (some times in combination with the shift key) to use to step through the code after you have triggered a break point..
For example shift+F8 will step through or 'over' the line of code that is pointed to..
I think F8 wil enter a function or subroutine if a call is on the line of code in question, F5 will just continue execution to the next break point or until an error is detected or until program code requires an action from the user, or until the program exits normally.

Dear Richard
Thanks for your comments. That is what I was looking for.

Portrait de Steve Lionel (Intel)

To put a breakpoint on a line of code, click in the leftmost column on that line - a red circle will appear. But I note from your other threads that you mistakenly used an F# project for your Fortran code, and this will prevent any of your code from being used.

Steve
Portrait de Rasoul K.

Quote:

Steve Lionel (Intel) wrote:

To put a breakpoint on a line of code, click in the leftmost column on that line - a red circle will appear. But I note from your other threads that you mistakenly used an F# project for your Fortran code, and this will prevent any of your code from being used.

Dear Steve
Thanks for your comment. I resolved the F# problem with aid of IanH. extension for F# is different from FORTRAN. So IAnH noticed this and informed me. Now My project type is FORTRAN and there is no problem in this regard.

Connectez-vous pour laisser un commentaire.