[TS] Configure memory setup in linker to not insta-OOM