Does invalid html slow down a page load or the invalid html has no effect on page load time? Is there a way to test it accurately?
If anything, it will not be slower than a single animation in jQuery. Most of your javascript will take significantly more amount of time than invalid html (uSeconds of difference!!!) so in reality, i am sure you will not see an effect and the end time user will not see an effect.
If your software is mission critical and needs to be displayed as fast as possible then yes, anytime a browser cannot configure your html and has to guess, it requires extra operations, and possibily thousands of computer ops (1 ms). So in reality your probably fine, if not write better html by validating it