So, a bit of background. I got my new laptop PC (Microsoft Surface Book 2) back in May, and I haven't had any problems with it for the first month. Minecraft ran smoothly, and I got around ~60-80 FPS average with Sildur's Vibrant Shaders on High. Things got a bit weird with Minecraft after a little, though. My game started stuttering a lot, and placing/breaking blocks made it freeze for a split second. My FPS went down to around ~40-60 FPS while moving and ~20-30 FPS while moving, both without shaders. The problems starting popping up in June, and it's been getting worse ever since.
I always play with OptiFine, and when I check the Lagometer rendering the terrain is never the issue. My laptop also has a decent CPU and GPU, so the problem can't be that my computer isn't powerful enough. I tried all sorts of different settings, and I still get the same results even with all the settings at minimum.
As you can see, rendering (green) isn't the issue, but I get these weird spikes of blue that represent "scheduled executables". This only happens when I'm moving or flying around, and when standing still these blue spikes never seem to appear.
Sometimes I even get a weird combination like shown above, when placing/breaking blocks.
The screenshots above were taken in Minecraft versions 1.12 and 1.13 (both with Optifine), and weirdly enough 1.14.2 seems to run better since I can still manage around ~40-60 fps with shaders on medium. Performance is still noticeably much worse than when I first got this computer, though.
To solve the above issues, I've spent countless hours online looking for solutions and trying out different settings, etc. I've tried booting in safe mode, which improved FPS *slightly* but not by much. I tried updating and completely reinstalling my drivers, which didn't change anything whatsoever. I tried playing with different versions both with and without optifine, but didn't really get any different results (with the exception of 1.14.2).
I think I should say here that I get FPS lag on both singleplayer and multiplayer, but I think singleplayer runs a bit worse. It should also be said that all these tests were done with only Minecraft open, and CPU/GPU usage didn't seem to be affecting anything too much, although the CPU usage fluctuated quite a bit.