Author Topic: Why is slickedit always using the CPU even when I haven't touched it for hours?  (Read 3460 times)

greggman

  • Senior Community Member
  • Posts: 280
  • Hero Points: 14
Not sure about other platforms but checking the Activity Monitor on OSX it shows SlickEdit as constantly using the CPU. Of course it's only 2-3% but the question is why is it greater than 0% when I'm not using slickedit and having touched it for hours?


chrisant

  • Senior Community Member
  • Posts: 1410
  • Hero Points: 131
On Win7 x86, I've noticed that vs.exe will spike the CPU briefly on launch and then go to ~0%.  But as time goes on the CPU usage slowly climbs.  Maybe it has to do with commands I've invoked, I don't know.  But after a while it consumes as much as 25% of one CPU while completely idle.

I captured two profiles in v17.0.1 while the problem was occurring (attached).  One profile with symbol coloring on, and one profile with symbol coloring off (to see if symbol coloring made a difference, but it didn't seem to).

In case it's hard to tell the overall duration from a .tsv file, each profile covered a period of around 10 seconds, give or take a little.
« Last Edit: August 15, 2012, 02:45:24 AM by chrisant »

Dan

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2897
  • Hero Points: 153
Did you have any error markers up that might have been drawing on the document overview bar (side of the scroll bar)?  This should not use a constant amount of CPU, but it is a newer feature, so it came to mind.

chrisant

  • Senior Community Member
  • Posts: 1410
  • Hero Points: 131
I don't think so, but I couldn't swear to it.  I'll check that tonight -- while I can't repro on demand, it seems to happen within the first hour or two of an editing session, so I'd characterize it as a "slow but 100%" repro.

chrisant

  • Senior Community Member
  • Posts: 1410
  • Hero Points: 131
Some files have bookmarks that got confused, and show up in the bookmark list window as being on line 0.  The bookmark isn't rendered anywhere in the file, but it shows up at the top of the overview bar.  But the CPU is at 0% when idle after launch, so I think that probably isn't related to the slow-growth CPU consumption on idle.

Here's part of the .vpwhist file:
Code: [Select]
FILEHIST: 9
sdutil.h
quickdiff.h
resolver.cpp
diffwnd.h
color.cpp
color.h
quickdiff.cpp
filelistwnd.cpp
diffwnd.cpp
BOOKMARK2: 2
DiffFrameController::OnMessage():885011019-1C:\chrisant\sdvdiff\diffwnd.cpp
diffwnd.cpp:15111529270#include "nomore.h"C:\chrisant\sdvdiff\diffwnd.cpp
BOOKMARK3: 2
DiffFrameController::OnMessage():885011019-1C:\chrisant\sdvdiff\diffwnd.cpp05
/ *
* DiffWnd - diff viewer window .
* /
<**EMPTY_BOOKMARK_LINE**>
/ / vim : set noet sw = 4 ts = 8 cino = { 0s cino = ^ 1s :
diffwnd.cpp:15111529270#include "nomore.h"C:\chrisant\sdvdiff\diffwnd.cpp55
#include " quickdiff . h "
#include " diffwnd . h "
#include " logwnd . h "
#include " tooltip . h "
#include " gotoline . h "
#include " font . h "
#include " color . h "
#include " sdutil . h "
#include " regexp . h "
#include " upgrade . h "
TBCLASS: 0 0

It seems like something is going wrong with bookmark save/restore.  Also, I don't know where all those extra spaces came from in the text in the bookmark section, they aren't present in the actual file.

I'll keep editing for a while and see if the idle CPU happens.