For the love of all that is Holy, load your datapacks through Fabric/Cotton.
I had a few datapack mods installed inside the Datapack folder in my saved game folder. I didn't realize just how much of a performance
impact that had until I have 10 or more installed. Then using a vein miner a few times cause my game to "lose connection" in a single player game.
I was sitting at a constant 50-70ms tick.
Once I discovered that I could move them into the datapacks folder in the main C:\Users\%Username%\AppData\Roaming\.minecraft folder...
I'm sitting at a constant 9ms ticks...
I'll do more testing and research, but I had no idea how much faster it was to use the API.
The only downside is that ALL new and old saved games will use the datapacks.
PS. DO NOT UNZIP the datapack and make them folders. Keep them .Zip files. this too can have a big impact on performance.