X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=scripts%2Fbloat-o-meter;h=6129020c41a94570ff49f5e42b5963a23105ba8e;hb=698d601224824bc1a5bf17f3d86be902e2aabff0;hp=75f21d843c1d5f814176bf6d33a37313146ad529;hpb=94bc2be31a01a3055ec94176e595dfe208e92d3b;p=karo-tx-linux.git diff --git a/scripts/bloat-o-meter b/scripts/bloat-o-meter old mode 100644 new mode 100755 index 75f21d843c1d..6129020c41a9 --- a/scripts/bloat-o-meter +++ b/scripts/bloat-o-meter @@ -17,8 +17,12 @@ def getsizes(file): sym = {} for l in os.popen("nm --size-sort " + file).readlines(): size, type, name = l[:-1].split() - if type in "tTdDbB": - sym[name] = int(size, 16) + if type in "tTdDbBrR": + # strip generated symbols + if name[:6] == "__mod_": continue + # function names begin with '.' on 64-bit powerpc + if "." in name[1:]: name = "static." + name.split(".")[0] + sym[name] = sym.get(name, 0) + int(size, 16) return sym old = getsizes(sys.argv[1])