Never really used the profiler before, I asked chatGPT how I could find out what makes saving files in emacs slow and it gave clear instructions. To clear the undo cache it was useless though. Suggested some non existing functions