Skip to content

Commit 8998979

Browse files
nathanlynchLinus Torvalds
authored andcommitted
fix bloat-o-meter for ppc64
bloat-o-meter assumes that a '.' anywhere in a symbol's name means that it is static and prepends 'static.' to the first part of the symbol name, discarding the portion of the name that follows the '.'. However, the names of function entry points begin with '.' in the ppc64 ABI. This causes all function text size changes to be accounted to a single 'static.' entry in the output when comparing ppc64 kernels. Change getsizes() to ignore the first character of the symbol name when searching for '.'. Signed-off-by: Nathan Lynch <ntl@pobox.com> Cc: Matt Mackall <mpm@selenic.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent bb8e8bc commit 8998979

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/bloat-o-meter

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ def getsizes(file):
1818
for l in os.popen("nm --size-sort " + file).readlines():
1919
size, type, name = l[:-1].split()
2020
if type in "tTdDbB":
21-
if "." in name: name = "static." + name.split(".")[0]
21+
# function names begin with '.' on 64-bit powerpc
22+
if "." in name[1:]: name = "static." + name.split(".")[0]
2223
sym[name] = sym.get(name, 0) + int(size, 16)
2324
return sym
2425

0 commit comments

Comments
 (0)