Store the thread tree (id/refs) in memory using hashes instead of full strings