tlbmiss_cost.sh now knows how to cache TLB miss cost information. Do not
duplicate the work in cpupcstat.

Signed-off-by: Mel Gorman <m...@csn.ul.ie>
---
 cpupcstat |   15 ---------------
 1 files changed, 0 insertions(+), 15 deletions(-)

diff --git a/cpupcstat b/cpupcstat
index c4a1795..deca179 100755
--- a/cpupcstat
+++ b/cpupcstat
@@ -38,7 +38,6 @@ my $collector;
 my $miss_scale = 0;
 my $ins_scale = 0;
 my $cyc_scale = 0;
-my $tlbcost_cache = "$Bin/tlbmisscost";
 
 sub start_target()
 {
@@ -289,17 +288,6 @@ if ($misses > 0) {
        }
 
        if ($service && $cycles > 0) {
-               if ( !$config && -e $tlbcost_cache ) {
-                       $config = $tlbcost_cache;
-               }
-               if ($config) {
-                       open(DAT, $config) || die "Failed to open $config\n";
-                       my $data = <DAT>;
-                       close(DAT);
-                       ($data,$cost_in_cycles) = split(/\=/, $data);
-                       chomp($cost_in_cycles);
-               }
-
                if ($cost_in_cycles <= 0) {
                        my $cost_script = `which tlbmiss_cost.sh`;
                        if ($cost_script eq "") {
@@ -308,9 +296,6 @@ if ($misses > 0) {
                        my $data = `$cost_script --vmlinux $vmlinux`;
                        ($data,$cost_in_cycles) = split(/\=/, $data);
                        chomp($cost_in_cycles);
-                       open (DAT, ">$tlbcost_cache");
-                       print DAT "TLB_MISS_COST=$cost_in_cycles";
-                       close (DAT);
                }
                my $total_cost = $cost_in_cycles * $misses;
                print("$target spent ",
-- 
1.7.1


------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
Libhugetlbfs-devel mailing list
Libhugetlbfs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libhugetlbfs-devel

Reply via email to