Autocomplete extremly slow after reboot

I was writing code on my pc and enabled autocomplete and it worked perfecty with 500+ lines of code. Unfortunatly after a reboot of the pc the autocomplete takes ~30 sec to make a suggestion to a thing it suggested instantly before. I'm on arduino IDE 2.3.6.

Is there a way to restore my autocomplete to it's former glory from 30 min ago?

edit: after an another reboot and waiting ~5min it suddenly came back to normal, but i don't know what will happen in the future.

I will take a SWAG and say it is a Windoze computer with anti virus testing all of the files upon boot. I saw that many years ago in the win 95 era. I have been Linux ever since.

1 Like

Normal operation. If you watch carefully somewhere on the screen, maybe bottom left, you will see messages regarding some files. The IDE is a sophisticated, complex beast, and there is a lot going on under the covers in order to give you all the cool features.
I generally just leave mine open with my default sketch loaded.

On Windows, the Task Manager provides stats for what processes are using the CPU.

It should show you if antivirus, Windows Update or something else is taking up a lot of CPU time.

Like @gilshultz my main platform is Linux nowdays.

Is there a way to speed this process up? My project i now 700+ lines long and autocomplete just gave up. Arduino IDE uses ~50% of my processor power and my processor is at 70% utilization

700+ lines, are you using assembler? Most Arduino sketches are much smaller. I just tried a 200-line sketch, and it took maybe 3 seconds. One trick to speed it up is turn off verbose during compile. You must have some sort of add on software like a 3rd party anti-virus (not needed for many years, it's free and builtin) or some other add-on.

It is not the compilation time that @szymonk1029 is concerned about, rather it is the time taken to build the index to functions and variables used by IDE autocomplete. Turning off verbose reporting will not influence that

Noted

No, just normal c (im not copmpetent enough to use assembler lol). Yes my project has over 700 lines and it's still growing. It mostly worked fine while it had 500 lines, but the more lines, the worse the autocoplete got. Now after a reboot I don't get any suggestions even after waiting for an hour. My pc isn't very powerfull (i5 9500f, 32gb ram) but the processor is only 70% utilized, 50% by adruino.

I have had a similar problem in the past even with smaller sketches and never found a solution. There seems to be no way to manually trigger the rebuilding of the index and it sometimes appears to be hit and miss as to whether it runs and when

every once it a while is says "indexing" and "building sketch"in the bottom left corner, but max for 2 sec and there's no improvement. it takes ~7 ces to get a suggestion and about the same wher i press ctrl + space

edit: is it possible that arduino IDE has too little ram assigned? it doesn't seem to go above 1 gb