LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 07-17-2012, 04:33 AM   #1
rupeshkp728
Member
 
Registered: May 2012
Posts: 33

Rep: Reputation: Disabled
GDB Breakpoint Internals


When we put a breakpoint using gcc then what all things happen internally and how the gdb using break is able to pause the execution of process( instead of killing it ) and later on resume the process execution?
 
Old 07-17-2012, 04:59 AM   #2
firstfire
Member
 
Registered: Mar 2006
Location: Ekaterinburg, Russia
Distribution: Debian, Ubuntu
Posts: 709

Rep: Reputation: 428Reputation: 428Reputation: 428Reputation: 428Reputation: 428
Hi.

This document may be useful. See section 3.2.

Last edited by firstfire; 07-17-2012 at 05:00 AM.
 
1 members found this post helpful.
Old 07-17-2012, 05:27 AM   #3
rupeshkp728
Member
 
Registered: May 2012
Posts: 33

Original Poster
Rep: Reputation: Disabled
Thanks firstfire for the link.
It is indeed helpful and clears it all.
 
Old 07-17-2012, 02:55 PM   #4
resetreset
Senior Member
 
Registered: Mar 2008
Location: Cyberspace
Distribution: Dynebolic, Ubuntu 10.10
Posts: 1,340

Rep: Reputation: 62
Just out of curiosity, what were you doing that brought you to this question?
 
Old 07-18-2012, 05:41 AM   #5
rupeshkp728
Member
 
Registered: May 2012
Posts: 33

Original Poster
Rep: Reputation: Disabled
resetrest I was planning to write two process in which both of the process must be able to pause the other without killing it and share info between them.
 
Old 07-18-2012, 06:31 AM   #6
firstfire
Member
 
Registered: Mar 2006
Location: Ekaterinburg, Russia
Distribution: Debian, Ubuntu
Posts: 709

Rep: Reputation: 428Reputation: 428Reputation: 428Reputation: 428Reputation: 428
Hi.

If you just want to be able to pause execution of the process, no matter at which instruction it happen, then look at SIGSTOP and SIGCONT signals (see `man 7 signal').
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
GDB: Setting breakpoint on a class's member function in a file Aquarius_Girl Programming 5 09-07-2011 10:46 PM
Problem setting breakpoint on function with GDB Ganahim Programming 4 02-24-2011 08:03 AM
[SOLVED] How to cancel a breakpoint in gdb? PJYang2009 Linux - Software 3 06-02-2010 01:43 AM
[gdb]how to exec cmd when breakpoint was hit jackandking Linux - Software 1 12-08-2008 11:49 PM
gdb breakpoint doesnt work? Thinking Programming 3 09-29-2005 06:36 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:44 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration