From 11b308e7363e937966b035b4891db32b4eece3bf Mon Sep 17 00:00:00 2001 From: Tor Aamodt Date: Fri, 1 Oct 2010 08:55:28 -0800 Subject: integrating recent changes from fermi-test into fermi (i'll use "fermi" for more disruptive changes to the pipeline model such as updating the MSHRs and getting rid of the warp tracker, ripping out DWF, etc...) [git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 7805] --- .../DG/3rdParty/ParMetis-3.1/METISLib/estmem.c | 157 --------------------- 1 file changed, 157 deletions(-) delete mode 100644 benchmarks/CUDA/DG/3rdParty/ParMetis-3.1/METISLib/estmem.c (limited to 'benchmarks/CUDA/DG/3rdParty/ParMetis-3.1/METISLib/estmem.c') diff --git a/benchmarks/CUDA/DG/3rdParty/ParMetis-3.1/METISLib/estmem.c b/benchmarks/CUDA/DG/3rdParty/ParMetis-3.1/METISLib/estmem.c deleted file mode 100644 index 82b9ac9..0000000 --- a/benchmarks/CUDA/DG/3rdParty/ParMetis-3.1/METISLib/estmem.c +++ /dev/null @@ -1,157 +0,0 @@ -/* - * Copyright 1997, Regents of the University of Minnesota - * - * estmem.c - * - * This file contains code for estimating the amount of memory required by - * the various routines in METIS - * - * Started 11/4/97 - * George - * - * $Id: estmem.c,v 1.1 2003/07/16 15:55:02 karypis Exp $ - * - */ - -#include - -/************************************************************************* -* This function computes how much memory will be required by the various -* routines in METIS -**************************************************************************/ -void METIS_EstimateMemory(int *nvtxs, idxtype *xadj, idxtype *adjncy, int *numflag, int *optype, int *nbytes) -{ - int i, j, k, nedges, nlevels; - float vfraction, efraction, vmult, emult; - int coresize, gdata, rdata; - - if (*numflag == 1) - Change2CNumbering(*nvtxs, xadj, adjncy); - - nedges = xadj[*nvtxs]; - - InitRandom(-1); - EstimateCFraction(*nvtxs, xadj, adjncy, &vfraction, &efraction); - - /* Estimate the amount of memory for coresize */ - if (*optype == 2) - coresize = nedges; - else - coresize = 0; - coresize += nedges + 11*(*nvtxs) + 4*1024 + 2*(NEG_GAINSPAN+PLUS_GAINSPAN+1)*(sizeof(ListNodeType *)/sizeof(idxtype)); - coresize += 2*(*nvtxs); /* add some more fore other vectors */ - - gdata = nedges; /* Assume that the user does not pass weights */ - - nlevels = (int)(log(100.0/(*nvtxs))/log(vfraction) + .5); - vmult = 0.5 + (1.0 - pow(vfraction, nlevels))/(1.0 - vfraction); - emult = 1.0 + (1.0 - pow(efraction, nlevels+1))/(1.0 - efraction); - - gdata += vmult*4*(*nvtxs) + emult*2*nedges; - if ((vmult-1.0)*4*(*nvtxs) + (emult-1.0)*2*nedges < 5*(*nvtxs)) - rdata = 0; - else - rdata = 5*(*nvtxs); - - *nbytes = sizeof(idxtype)*(coresize+gdata+rdata+(*nvtxs)); - - if (*numflag == 1) - Change2FNumbering2(*nvtxs, xadj, adjncy); -} - - -/************************************************************************* -* This function finds a matching using the HEM heuristic -**************************************************************************/ -void EstimateCFraction(int nvtxs, idxtype *xadj, idxtype *adjncy, float *vfraction, float *efraction) -{ - int i, ii, j, cnvtxs, cnedges, maxidx; - idxtype *match, *cmap, *perm; - - cmap = idxmalloc(nvtxs, "cmap"); - match = idxsmalloc(nvtxs, UNMATCHED, "match"); - perm = idxmalloc(nvtxs, "perm"); - RandomPermute(nvtxs, perm, 1); - - cnvtxs = 0; - for (ii=0; ii