This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 221074 - java debugger slow when running with pre-set breakpoints (some times)
Summary: java debugger slow when running with pre-set breakpoints (some times)
Status: RESOLVED INCOMPLETE
Alias: None
Product: debugger
Classification: Unclassified
Component: Java (show other bugs)
Version: 7.2.1
Hardware: PC Windows XP
: P2 normal (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-30 10:21 UTC by notnulpointer
Modified: 2012-11-12 21:44 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description notnulpointer 2012-10-30 10:21:32 UTC
i know there's lot of issues around complaining about java debugger being slow but this looks different. I was trying to start an application which usually takes 50 seconds to startup. When i  did try to run the debugger it would take 6-7 minutes. I tried any suggestion i found on the internet no solution. Then i asked someone if he had the same bug and he said "remove all breakpoints and start again". I removed all breakpoints before starting the debugger and the debugger did start the app in around 50 seconds as usual. (I had 6 breakpoints). I didn't gather any information because i didn't know what/how would help. Hope it helps.
Comment 1 Jan Lahoda 2012-10-30 15:04:59 UTC
FWIW, breakpoints with conditions may slow down program execution, esp. when applied to a place where the condition needs to be evaluated often - I always considered that to be an understandable property of the conditional breakpoints.
Comment 2 notnulpointer 2012-10-30 15:54:22 UTC
(In reply to comment #1)
> FWIW, breakpoints with conditions may slow down program execution, esp. when
> applied to a place where the condition needs to be evaluated often - I always
> considered that to be an understandable property of the conditional
> breakpoints.

hm.. the breakpoints were not enabled (not sure if it makes a difference or not), and if i am right they were not in places used a lot. I may be wrong. Unfortunately i was frustrated and deleted all of them so i cant reproduce at the moment, i will come back if it ever happens again. But i believe even the breakpoints were in places evaluated often it shouldn't have such a massive effect. 

Thank you
Comment 3 Jiri Kovalsky 2012-10-31 14:08:57 UTC
Product Version: NetBeans IDE Dev (Build 201210310001)
Java: 1.7.0_06; Java HotSpot(TM) Client VM 23.2-b09
Runtime: Java(TM) SE Runtime Environment 1.7.0_06-b24
System: Linux version 3.0.0-12-generic running on i386; UTF-8; cs_CZ (nb)
User directory: /home/cesilko/.netbeans/dev
Cache directory: /home/cesilko/.cache/netbeans/dev

I tried to reproduce it on NetBeans itself and here is my finding:

execution of debugger.jpda.ui/StartDebuggerTestSuite: 20 seconds
debugging of debugger.jpda.ui/StartDebuggerTestSuite: 25 seconds
debugging of debugger.jpda.ui/StartDebuggerTestSuite with 7 conditional breakpoints: 23 seconds

Times were measured by stop watch from invocation of Run/Debug File till NetBeans main window showed up on my screen. Hence I didn't reproduce this slowdown.
Comment 4 Martin Entlicher 2012-11-12 14:33:33 UTC
Resolving as incomplete until we get more specific information about the problem.
Conditional breakpoints can slow the execution down, since the application is always suspended for a while, the condition is evaluated and when it's not satisfied, execution is resumed again. This can take some time, especially when in a loop. Non-conditional breakpoint should have negligible impact, but for instance field breakpoint can also slow the execution down even when not hit (which is completely out of control for NetBeans, field breakpoints are managed by the debugger backend).

We need a reproducible test case to be able to seriously evaluate the problem.
Comment 5 notnulpointer 2012-11-12 21:44:17 UTC
ok it may be my fault then, it was very slow so i thought it was a bug. It only happened once to me and i can't reproduced either, but i know it happened again on some friends.