jQuery 1.4.1: .empty() and .html() efficiency issues

jQuery 1.4.1: .empty() and .html() efficiency issues

I ran into an issue with .empty() (and eventually .html("")) while attempting to build a filterable table. The root of the problem stemmed from the fact that this is a fairly robust table with numerous child objects per row. When running .empty() on the tbody, I found that the .remove() and .removeData() functions were being called 8500+ times during the course of 1 .empty() call. This ends up accounting for roughly 87% of the processing in my situation and jumps the processing time from 180ms to 1390ms

I understand that every element needs to be removed in order to properly remove events, but in this situation there are maybe 160 items that have events bound to them, the other 8340 elements are just taking up processing time.

There may be a better way for me to accomplish what I'm trying to, but if this was the only option I had it would cause some major issues.