PWM signals are on 20ms bursts so anything you do adjust within it just waits for it to be sent to the motor anyway.
Looping endlessly fast can hog the CPU in a loop prevents other tasks from running. In competition code, even if you don’t call another task, you are the user control task and the main task is out there looking for the on/off actions from the judges table. I am unsure if you loop too much if background things like interrupts for sensors or timers will act funky.
jpearman can opine better on this topic if he is reading the thread. He was author of this one linked below. You can see the pulse lengths sent to the motor for various values.