Display memory sizes as TB when >=10TB

(cherry picked from commit e78f040ffde1f067e13b8dc9fa0d3952246c40ee)