| Author |
Topic  |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Nov 03 2025 : 11:03:33 AM
|
I have a C/C++ project where I'm including libsodium in a particular source file (let's call it main.cpp).
In main.cpp, I #include libsodium with a single line:
#include "..\libsodium\include\sodium.h"
Which is this sodium.h include file:
#ifndef sodium_H
#define sodium_H
#include "sodium/version.h"
#include "sodium/core.h"
#include "sodium/crypto_aead_aes256gcm.h"
#include "sodium/crypto_aead_aegis128l.h"
#include "sodium/crypto_aead_aegis256.h"
#include "sodium/crypto_aead_chacha20poly1305.h"
#include "sodium/crypto_aead_xchacha20poly1305.h"
#include "sodium/crypto_auth.h"
#include "sodium/crypto_auth_hmacsha256.h"
#include "sodium/crypto_auth_hmacsha512.h"
#include "sodium/crypto_auth_hmacsha512256.h"
#include "sodium/crypto_box.h"
#include "sodium/crypto_box_curve25519xsalsa20poly1305.h"
#include "sodium/crypto_core_hsalsa20.h"
#include "sodium/crypto_core_hchacha20.h"
#include "sodium/crypto_core_salsa20.h"
#include "sodium/crypto_core_salsa2012.h"
#include "sodium/crypto_core_salsa208.h"
#include "sodium/crypto_generichash.h"
#include "sodium/crypto_generichash_blake2b.h"
#include "sodium/crypto_hash.h"
#include "sodium/crypto_hash_sha256.h"
#include "sodium/crypto_hash_sha512.h"
#include "sodium/crypto_kdf.h"
#include "sodium/crypto_kdf_hkdf_sha256.h"
#include "sodium/crypto_kdf_hkdf_sha512.h"
#include "sodium/crypto_kdf_blake2b.h"
#include "sodium/crypto_kx.h"
#include "sodium/crypto_onetimeauth.h"
#include "sodium/crypto_onetimeauth_poly1305.h"
#include "sodium/crypto_pwhash.h"
#include "sodium/crypto_pwhash_argon2i.h"
#include "sodium/crypto_scalarmult.h"
#include "sodium/crypto_scalarmult_curve25519.h"
#include "sodium/crypto_secretbox.h"
#include "sodium/crypto_secretbox_xsalsa20poly1305.h"
#include "sodium/crypto_secretstream_xchacha20poly1305.h"
#include "sodium/crypto_shorthash.h"
#include "sodium/crypto_shorthash_siphash24.h"
#include "sodium/crypto_sign.h"
#include "sodium/crypto_sign_ed25519.h"
#include "sodium/crypto_stream.h"
#include "sodium/crypto_stream_chacha20.h"
#include "sodium/crypto_stream_salsa20.h"
#include "sodium/crypto_stream_xsalsa20.h"
#include "sodium/crypto_verify_16.h"
#include "sodium/crypto_verify_32.h"
#include "sodium/crypto_verify_64.h"
#include "sodium/randombytes.h"
#include "sodium/randombytes_internal_random.h"
#include "sodium/randombytes_sysrandom.h"
#include "sodium/runtime.h"
#include "sodium/utils.h"
#ifndef SODIUM_LIBRARY_MINIMAL
# include "sodium/crypto_box_curve25519xchacha20poly1305.h"
# include "sodium/crypto_core_ed25519.h"
# include "sodium/crypto_core_ristretto255.h"
# include "sodium/crypto_scalarmult_ed25519.h"
# include "sodium/crypto_scalarmult_ristretto255.h"
# include "sodium/crypto_secretbox_xchacha20poly1305.h"
# include "sodium/crypto_pwhash_scryptsalsa208sha256.h"
# include "sodium/crypto_stream_salsa2012.h"
# include "sodium/crypto_stream_salsa208.h"
# include "sodium/crypto_stream_xchacha20.h"
#endif
#endif
The problem is, each time I go to that main.cpp file with VAX enabled, it pauses for about 15 seconds and then continues. The UI is frozen, and if I start trying to click on things I get the not responding mouse pointer, and eventually the frosted window indicating it's not responding, and finally if I keep clicking, the attached image.
If I disable VAX then I'm able to go back and forth just fine. I'm reasonably sure it has to do with checking all those files to see if they've changed since the last time that file was opened.
Is there a way to add that folder to the do-not-rescan list, or some such?
-- Rick C. Hodgin

|
Edited by - foxmuldr on Nov 03 2025 11:04:42 AM |
|
|
feline
Whole Tomato Software
    
United Kingdom
19293 Posts |
Posted - Nov 03 2025 : 11:28:18 AM
|
Is this an open source library I can test on here? Or something that only you have access to?
My first thought would be to add the library to the stable include directory list, by adding it to:
Project properties -> VC++ Directories -> Include Directories
directories included here are automatically added to VA's stable include directory list, assuming you are using:
VA Options -> C/C++ Directories -> Platform = Project defined
and not a custom directory list.
VA doesn't re-scan stable include directories.
The problem with this answer is that VA is designed not to re-scan files it has already scanned once, unless they have changed. So, assuming these files are not changing on the hard drive, getting a new last modified date / time, once VA has scanned then the once, we should not need to re-scan them again. So I am not actually sure if this will have any effect or not.
|
zen is the art of being at one with the two'ness |
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Nov 03 2025 : 11:49:49 AM
|
quote: Originally posted by feline The problem with this answer is that VA is designed not to re-scan files it has already scanned once, unless they have changed. So, assuming these files are not changing on the hard drive, getting a new last modified date / time, once VA has scanned then the once, we should not need to re-scan them again. So I am not actually sure if this will have any effect or not.
Then I'm not sure what it is. It only happens with VAX enabled.
Is there a diagnostic / logging mode I can enable which would log which internal algorithms in VAX are being called and which ones are consuming the most time? It's literally unusable with VAX right now, so I've had to disable it to complete this current task.
-- Rick C. Hodgin
|
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Nov 03 2025 : 12:59:51 PM
|
I created a second cpp file with those entries, and it's not lagging. I'm going to add bits in one by one until it starts lagging to figure out what's causing it.
-- Rick C. Hodgin
|
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Nov 03 2025 : 1:50:29 PM
|
I've added everything in the original source file to the second one and no pauses. So, I'm truly at a loss. I'm going to try cutting all, re-pasting all, etc., to see if I can get it to go away.
-- Rick C. Hodgin
|
Edited by - foxmuldr on Nov 03 2025 2:11:49 PM |
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Nov 03 2025 : 5:38:59 PM
|
I ultimately asked Claude about it, and that AI suggested I exit Visual Studio, delete my .vs folder, restart, and that fixed it. So apparently it was something inside of VS working with VAX, because disabling VAX would prevent it from happening on that file.
Thank you, feline.
-- Rick C. Hodgin
|
 |
|
|
feline
Whole Tomato Software
    
United Kingdom
19293 Posts |
Posted - Nov 04 2025 : 08:08:29 AM
|
| At a guess, based on your experiences, some form of clash between the VA and IDE intellisense parsers, perhaps involving some form of corruption in the IDE intellisense database. Definitely a rare problem these days, but not unheard of. |
zen is the art of being at one with the two'ness |
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Nov 04 2025 : 1:00:32 PM
|
Hasn't reproduced. Thank you again.
-- Rick C. Hodgin
|
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Dec 09 2025 : 12:24:43 PM
|
I do still see this periodically. It seems to come when it's popping up the auto-completion. There are times when it will literally hang for 15 or more seconds. It eventually comes back, but during that time it is stuck. It will sometimes do this dribble effect too, so it's hangs for 15 seconds, works until I hit another key, then it will hang for like 5 to 10 seconds, then I hit another key and it will hang for 3 seconds, and then after that it just works.
Does anyone else see that? |
 |
|
|
feline
Whole Tomato Software
    
United Kingdom
19293 Posts |
Posted - Dec 10 2025 : 07:18:25 AM
|
I would suggest disabling IDE intellisense, to see if this has any effect on this:
IDE tools menu -> Options -> Text Editor -> C/C++ -> Advanced -> IntelliSense -> Disable IntelliSense = True
it is rare, but I have seen problems where if the IDE intellisense sees an edit on a widely used header file, this can cause a lot of re-parsing, and thus a lot of system load and IDE slow down. Knowing if disabling IDE intellisense has an effect would tell us something.
Also look for CPU or system load from the devenv.exe process, to see if the hangs seem to be associated with CPU or IO spikes. |
zen is the art of being at one with the two'ness |
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Dec 12 2025 : 08:21:11 AM
|
quote: Originally posted by feline
IDE tools menu -> Options -> Text Editor -> C/C++ -> Advanced -> IntelliSense -> Disable IntelliSense = True
it is rare, but I have seen problems where if the IDE intellisense sees an edit on a widely used header file, this can cause a lot of re-parsing, and thus a lot of system load and IDE slow down. Knowing if disabling IDE intellisense has an effect would tell us something
Will try that. Thank you. |
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Dec 18 2025 : 08:52:25 AM
|
| Did not make a difference. Still freezing periodically, randomly, but once it freezes once it's like it's in this debilitated state where every navigation is slower than normal, jerky, has pauses. I have to exit, delete my .vs folder, and come back in to get it to work right again. According to Claude it's a known issue with VS2022 and appears unrelated to VAX. |
 |
|
|
feline
Whole Tomato Software
    
United Kingdom
19293 Posts |
Posted - Dec 18 2025 : 10:01:42 AM
|
I would be curious to know if Claude can defend / explain that claim.
From memory and experience, the only real time I would expect this sort of behaviour is someone, VA or the IDE, ending up with a corrupt symbol database. This should be a VERY rare problem, and disabling IDE intellisense should eliminate the IDE intellisense symbol database as a factor. Plus I would also expect it to be solution specific, if the trigger is something inside the code tripping up our parser that badly.
Or, equally rarely, a problem with VA, or another extension. There is a known problem with a couple of extensions by Devart that interact badly with VA, and you can get random problems showing up, but the problems normally end up with a crash.
Deleting the .vs folder is an interesting clue, and sounds like a bug that has just been reported in VS2026, that we are currently working on. Can you please email me about this at:
[email protected]
and I can try sending you an internal build that has a possible fix for the VS2026 bug, in case it helps you. |
zen is the art of being at one with the two'ness |
 |
|
|
foxmuldr
Tomato Guru
    
USA
443 Posts |
Posted - Dec 23 2025 : 09:25:18 AM
|
I've switched to Visual Studio 2026 against my better judgement :-) So far no freezes at all. I lost my blue color though and it's harder to read, but it is faster and it appears to work. |
 |
|
| |
Topic  |
|