aboutsummaryrefslogtreecommitdiffstats
path: root/lib/observer/src/observer_lib.erl
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2012-01-10 08:47:43 +0100
committerDan Gudmundsson <[email protected]>2012-02-21 15:06:42 +0100
commitde67c104757f25794d93dc1c7d61d6d11e30e77a (patch)
tree8f0b3313c67a663e48d65f2008fb481f51b53954 /lib/observer/src/observer_lib.erl
parent338aa477321c0cd0cfe159aead7b6d616a81335b (diff)
downloadotp-de67c104757f25794d93dc1c7d61d6d11e30e77a.tar.gz
otp-de67c104757f25794d93dc1c7d61d6d11e30e77a.tar.bz2
otp-de67c104757f25794d93dc1c7d61d6d11e30e77a.zip
[observer] Add performance monitor
Diffstat (limited to 'lib/observer/src/observer_lib.erl')
-rw-r--r--lib/observer/src/observer_lib.erl2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/observer/src/observer_lib.erl b/lib/observer/src/observer_lib.erl
index 5260861497..3b924d46cf 100644
--- a/lib/observer/src/observer_lib.erl
+++ b/lib/observer/src/observer_lib.erl
@@ -154,7 +154,9 @@ to_str(Value) when is_atom(Value) ->
to_str({bytes, B}) ->
KB = B div 1024,
MB = KB div 1024,
+ GB = MB div 1024,
if
+ GB > 10 -> integer_to_list(GB) ++ " gB";
MB > 10 -> integer_to_list(MB) ++ " mB";
KB > 0 -> integer_to_list(KB) ++ " kB";
true -> integer_to_list(B) ++ " B "