Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Technical Support
 Performance issues when typing
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

fredbloggs
New Member

9 Posts

Posted - Feb 22 2018 :  07:54:17 AM  Show Profile  Reply with Quote
Hi,

I'm trialling Visual Assist 2248 for my team on a C++ code base.

We each use VS2017 remotely, over Citrix, but it's not a multi-user environment. I've found that typing in Visual Assist sometimes slows down to a crawl, and CPU spikes.
Maybe Citrix is a cause but no other application is affected.
Disabling Visual Assist fixes the issue.

I've tried disabling every VAx option I can think of, since I mainly use it for the navigation features, but this doesn't help.

Any ideas?


Edited by - fredbloggs on Feb 22 2018 07:56:20 AM

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Feb 22 2018 :  11:07:39 AM  Show Profile  Reply with Quote
Which IDE or IDE's are you using?

I don't really know anything about Citrix, so this might be a silly question. Are you basically doing a remote desktop connection to a server here? Are you seeing this CPU usage spike on the remote system, or on the local system?

Have you tried turning off VA enhanced syntax colouring:

VA Options -> Coloring and Attributes -> Enable Enhanced Syntax Coloring

My first thought is that VA's updates to the screen are the problem here, but perhaps it is somehow related to VA's parser instead, since this is happening when typing. To try and tell the difference, do you see any such problems when scrolling through code? Moving between different code files? Jumping to a symbol definition?

Can you look in Windows Task Manager on the effected system, just to confirm which process or processes are causing the CPU spike? I would expect "devenv.exe" (the IDE) to be one of the processes showing a spike, but are any other processes showing a spike?

zen is the art of being at one with the two'ness
Go to Top of Page

fredbloggs
New Member

9 Posts

Posted - Feb 22 2018 :  10:06:47 PM  Show Profile  Reply with Quote
IDE: VS2017 15.5.3

Yes, it's just like a remote desktop connection. It might be a different protocol though. The CPU spike is on the remote system, and it's devenv.exe.

Yes, syntax colouring is off.

Scrolling, changing files, and jumping to symbols doesn't seem too bad. It's typing that's bad. Eg if I type "The quick brown fox jumps over the lazy dog", the text appears far slower than I can type it.
It's not bad at startup, it seems to get worse over time (or maybe it's not related to time but something else).

Using process explorer, devenv.exe shows va_x.dll in a few frames in the callstack during the CPU spikes.

Is it possible to disable VAx parsing while typing? I mainly would like to use VAx for the navigation - so maybe it doesn't need it to parse in real time.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Feb 23 2018 :  05:48:21 AM  Show Profile  Reply with Quote
Are you able to test the performance of VA locally, without using Citrix? Also, are you able to test this when connecting to the remote machine via Microsoft Remote Desktop? I do a lot of work via Remote Desktop, and have never seen this problem there. So I am just trying to find out if working remotely is actually a factor or not.

While you are actually typing VA should not be parsing, we aim to wait for a pause in your typing before parsing the changes you have made. So I would not expect VA's parsing to have this effect, but it really looks like VA is a factor.

Do you have VA suggestions:

VA Options -> Suggestions -> Enable Suggestion Lists

turned On or Off? If On, does turning this Off make any difference?

What do you have:

VA Options -> Enhanced Listboxes -> Source of C/C++ content: Visual Assist OR Default Intellisense

set to?

Once this starts happening, can you try creating a new, empty code file, and try typing in this file? I am wondering if file size, or existing file content is somehow a factor.

zen is the art of being at one with the two'ness
Go to Top of Page

fredbloggs
New Member

9 Posts

Posted - Feb 28 2018 :  03:54:25 AM  Show Profile  Reply with Quote
Unfortunately I'm unable to test the performance on the same machine locally, as it's in a remote location. I'm also unable to use Remote Desktop due to company restrictions.

VA Suggestions are turned off.

VA Enhanced Listboxes: all options are disabled, but Source of C/C++ content is set to "Visual Assist".

So this was happening today in a 9000 line CPP file. I went to the header file (500 lines), and it was still happening.

I then created a new CPP file - and typing was fine. I then went to the stdafx.cpp for that project, and typing was fine.

The 500 line header file where it's happening has many #includes and a couple of #imports. So maybe it's related to that, and not remote access at all?
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Feb 28 2018 :  08:26:17 AM  Show Profile  Reply with Quote
I suspected testing directly was not going to be an option, but worth asking just in case. The fact that this is file specific is very interesting. A 500 line header file, under normal conditions, should never have an effect like this on performance.

Do you know if some of your header files use a lot of very complex template code, or complex macros?

Would you be able to go to one of the problem files, comment out all of the #include and #import lines, pause for a couple of seconds to let VA catch up with this change, and then see if this has any effect?

To make commenting out the lines quick and easy, just select them and press / to comment all of them out with // comments.

zen is the art of being at one with the two'ness
Go to Top of Page

fredbloggs
New Member

9 Posts

Posted - Mar 06 2018 :  04:31:27 AM  Show Profile  Reply with Quote
Commenting out all #include and #import lines (with a pause to allow VA to catch up) doesn't seem to help.
The header files don't use complex templates, other than what's introduced with #import and atlcom.h etc.

More info - The CPU seems to spike just by holding page up, then page down to scroll through the file. I reconfirmed that vax_x.dll was in the devenv callstack, and that disabling VA greatly reduces this spike.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Mar 06 2018 :  07:33:33 AM  Show Profile  Reply with Quote
If scrolling is having this effect the normal answer is that this is related to VA's syntax highlighting. Can you please double check that you have turned Off:

VA Options -> Coloring and Attributes -> Enable Enhanced Syntax Coloring

Do you have:

VA Options -> Display -> Display VA Navigation Bar:

turned On or Off? What about showing VA Outline? I am trying to think of parts of VA that are likely to be updated as you are scrolling through the file. Parsing should not be an issue at all, since scrolling on its own won't change the file, so no need to parse any changes.

zen is the art of being at one with the two'ness
Go to Top of Page

fredbloggs
New Member

9 Posts

Posted - Mar 13 2018 :  04:18:53 AM  Show Profile  Reply with Quote
Yes, "VA Options -> Coloring and Attributes -> Enable Enhanced Syntax Coloring" is turned off.

"VA Options -> Display -> Display VA Navigation Bar" is on, but disabling it didn't help - if anything it made it worse.

VA Outline is off.

I originally thought it was a boost header (regex.hpp), as moving it to stdafx seemed to help things, but that fix was not easily reproducible.

Is there any commonality in VA between scrolling and typing? As both seem to be affected. Also - it seems to be worse when VS is debugging.

Are you able to provide PDBs so I can give you VA function names that are in the callstacks during spikes?

Edited by - fredbloggs on Mar 13 2018 04:19:54 AM
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Mar 13 2018 :  09:16:38 AM  Show Profile  Reply with Quote
I am just wondering if this is solution or file specific. A large VA symbol database could be a factor here, since VA will have to look up symbol names both while scrolling (for the colouring) and while editing (for the listboxes). It's the only obvious common factor I can think of. Normally I would expect to see a hard drive access hit here, not a CPU hit, if this was a factor, but its still a working theory.

If you have the time, can you please try the following test. Make a new, default C++ solution, and then copy one of the large slow code files into the solution, and add it. Obviously this won't compile, and most of the symbols will be unknown, but it does separate out a single file.

Do you still see the CPU hit and slow performance with this test solution?

If so, can you please press the button:

VA Options -> Performance -> Rebuild symbol databases

and restart the IDE, loading just this small test solution. This will eliminate the current VA symbol database and its size as a factor. Does this make any difference?

If none of this helps, and you are still seeing the problems, then mini dump is starting to look like a good plan. First, can you install VA 2258.5, our current version:

http://www.wholetomato.com/downloads/default.asp

this always makes debugging a little bit easier.

Next can you please try turning on VA logging, then reproduce this problem across a couple of different files, and then close the IDE to stop the VA log files getting to large. This page explains turning on VA logging, and the locations of the log files:

https://support.wholetomato.com/default.asp?W305

The other thing to try is to download procdump: https://docs.microsoft.com/en-us/sysinternals/downloads/procdump

Extract this, load the IDE and load one of the slow files, and then run the command line:

procdump.exe -c 50 -u -s 2 devenv.exe vs_slow_citrix.dmp

When the IDE CPU usage hits 50% relative to a single core for 2 seconds this will save out a minidump in the current directory. Hopefully between these two we will get some clues as to what is going on here.

Please submit the files via the form:

http://www.wholetomato.com/support/contact.asp

including this thread ID or URL in the description, so we can match it up.

zen is the art of being at one with the two'ness
Go to Top of Page

tjcbs
Tomato Guru

100 Posts

Posted - Mar 24 2021 :  9:07:51 PM  Show Profile  Reply with Quote
I'm experiencing this exact problem as well. Except, I am running on a laptop. As described, it gets slower with time. Was there a resolution?
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Mar 25 2021 :  08:29:19 AM  Show Profile  Reply with Quote
Can you please run Windows Task Manager, in detailed mode, and see how much memory Visual Studio is using? Is it close to 3gig, which is the limit for a 32bit process?

Are you seeing this slow typing in all files, or is it a file specific problem?

Are you seeing high CPU usage when this is happening?

zen is the art of being at one with the two'ness
Go to Top of Page

Uniwares
Tomato Guru

Portugal
2120 Posts

Posted - Mar 26 2021 :  10:12:02 AM  Show Profile  Reply with Quote
on a side note: if its with VS 16.9.0/1 then its probably the live analysis of VS through the Roslyn language services. Its occupying 80% processor on my machine and never stops. Turning live analysis off solves it.
Go to Top of Page

pampersrocker
Junior Member

Germany
10 Posts

Posted - Apr 06 2021 :  12:22:39 PM  Show Profile  Reply with Quote
From my experience VS with VAssistX can get quite slow over time if a lot of files (>30) are open at the same time. Using the "Close All But This" feature usually immediatly restored performance when typing or doing any VAssistX related action.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Apr 06 2021 :  12:56:52 PM  Show Profile  Reply with Quote
I have a vague memory of this, but from memory it was happening with hundreds of files open. I often have 20 or more files open myself, and don't notice a performance problem, but there are suddenly quite a few people seeing performance problems at the moment, we just don't yet know why.

zen is the art of being at one with the two'ness
Go to Top of Page

pampersrocker
Junior Member

Germany
10 Posts

Posted - Apr 06 2021 :  1:03:14 PM  Show Profile  Reply with Quote
Yeah on second thought it will be probably at least the double. I use the Custom Document Well with vertical tabs and when this occurs, the complete bar is full and need to scroll. With vertical tabs on my screen this usually happens after an intense UE4 debugging session or research VAX find referemces, leaving many files open.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
17242 Posts

Posted - Apr 07 2021 :  07:49:41 AM  Show Profile  Reply with Quote
If the only trigger here is the number of open files, and possibly their size, and the number of open files is large, then this isn't to major a concern. Still, I am not sure why VA slows down this much, unless you really have a LOT of files open at once.

zen is the art of being at one with the two'ness
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2019 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000