This primary purpose of this patch is to take out
resource tracking out of ASM printing and make it
available as a service to others. ASMPrinting
should not ideally do such analysis and should
just print stuff. This is useful in
successive patches.
The tracker is being used by ASM printing as
of now but intention is to have this analysis
as a sperate MachineFunction pass and "clients"
can query whatever it wants from the tracker.
Further patches will convert this into an analysis pass
to be used in a general sense and ASMPrinter can "depend"
on it.
There's basically never a need for shared_ptr. unique_ptr is almost always better