The performances of this script felt back. Investigating, it's due to the extended attribute filtering improvement
when there are ext attributes, the script does a:
SELECT borrowernumber AS bn, b.code, attribute AS val, category AS avcategory, lib AS avdescription
FROM borrower_attributes b
JOIN borrower_attribute_types bt ON (b.code = bt.code)
LEFT JOIN authorised_values a ON (a.category = bt.authorised_value_category AND a.authorised_value = b.attribute)
that returns a LOT of datas when you have 10 000 patrons and 5 attributes.
That results in the page needing something like 10 seconds to be loaded.
There are some other caveats. I've commented a few lines that remove the extended attr option. The best solution would be to fix it better, but I can't find how to do that now.
(note : i also have commented some lines that are unused)