Bug 532077 - Fast =breakpoint-modified events from GDB cause hit count values to become incorrect
Summary: Fast =breakpoint-modified events from GDB cause hit count values to become in...
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug-dsf-gdb (show other bugs)
Version: 9.3.0   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 9.6.0   Edit
Assignee: Jonah Graham CLA
QA Contact: Jonah Graham CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-06 12:49 EST by Jonah Graham CLA
Modified: 2018-11-18 08:27 EST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jonah Graham CLA 2018-03-06 12:49:47 EST
Raised in Bug 530377 Comment 3:

DSF is sending -break-after commands to GDB even though state is not actually changing. For example:


#include <stdio.h>
#include <stdlib.h>

int main(void) {
	for (int i = 0; i < 40000; i++)
		puts("!!!Hello World!!!"); /* prints !!!Hello World!!! */
	return EXIT_SUCCESS;
}

Added breakpoint on puts call with ignore count 10000 and resumed. Execution completed in no time, when I checked the value of 'i', it was around 18000 and even after all breakpoint-modified messages have been appeared in gdb traces console, following keeps on appearing in gdb console.

592,412 48-break-after 1 7877
592,422 48^done
592,422 (gdb) 
596,832 49-break-after 1 6219
596,847 49^done
596,847 (gdb) 
....
....
Comment 1 Jonah Graham CLA 2018-05-30 19:19:15 EDT
We discussed this at a CDT call recently. The plan on this going forward is to simply not update the Platform breakpoint with the current hit count. This looks to probably resolve the issue, but it won't make it into 9.5.
Comment 2 Eclipse Genie CLA 2018-11-18 06:55:39 EST
New Gerrit change created: https://git.eclipse.org/r/132637
Comment 4 Jonah Graham CLA 2018-11-18 08:27:09 EST
CDT now ignores changes to ignore count from GDB. Updated N&N: https://wiki.eclipse.org/CDT/User/NewIn96#Debug