perf(util/extend): size and perf improvements