Add mean GC throughput as per CPU time to perfdump

Add mean GC throughput as per CPU time to the GC performance dump as
is already done in case of individual collectors.

Test: art/test/testrunner/testrunner.py --host --runtime-option=-XX:DumpGCPerformanceOnShutdown
Bug: 130362501
Change-Id: I0af44ba73a54de3e7490b09f3c0eddd26df519a5
diff --git a/runtime/gc/heap.cc b/runtime/gc/heap.cc
index c3660b4..9126d90 100644
--- a/runtime/gc/heap.cc
+++ b/runtime/gc/heap.cc
@@ -1080,10 +1080,13 @@
     collector->DumpPerformanceInfo(os);
   }
   if (total_duration != 0) {
-    const double total_seconds = static_cast<double>(total_duration / 1000) / 1000000.0;
+    const double total_seconds = total_duration / 1.0e9;
+    const double total_cpu_seconds = GetTotalGcCpuTime() / 1.0e9;
     os << "Total time spent in GC: " << PrettyDuration(total_duration) << "\n";
     os << "Mean GC size throughput: "
-       << PrettySize(GetBytesFreedEver() / total_seconds) << "/s\n";
+       << PrettySize(GetBytesFreedEver() / total_seconds) << "/s"
+       << " per cpu-time: "
+       << PrettySize(GetBytesFreedEver() / total_cpu_seconds) << "/s\n";
     os << "Mean GC object throughput: "
        << (GetObjectsFreedEver() / total_seconds) << " objects/s\n";
   }