Minor bugfixes, added RT4, save/restore threshold on exhaustion, reduced start heap size

Change-Id: If128e08db9ef5821d1019c805bfc203ee4744917