Finally I've started to work on this. Just want to share an idea of performace improvement. Now, we're fetching all messages in all threads for current page. I think we should do this only when "Autoexpand/Expand All" is enabled. Otherwise we should fetch headers for roots only and fetch children headers on demand. Also the last operation could be improved with SEARCH=INTHREAD use.