A shorthand element requires a slash because its replacing . So you'd write that wherever appropriate for the sake of valid markup. But its not required to be one way or another.
Edited: this is not actually the problem. others here seem to agree that its a matter of regex performance