Regarding „<…> frustrating when analysing memory use, because there's no way to tag allocations to associate them with a particular program subroutine in pprof heap profiles <…>” — can't you try to use profiler labels?