track resources used via shared atomic object

[#79618102]

Signed-off-by: Matthew Sykes <matthew.sykes@gmail.com>