mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 07:17:55 +03:00
scuba: round bytes to the nearest useful value
Summary: This will reduce the amount of space they take in scuba. Reviewed By: xavierd Differential Revision: D21483472 fbshipit-source-id: 9de49dedef480932f8583dd17fe6625d222a3285
This commit is contained in:
parent
95f0b94031
commit
20c3f8b34d
@ -27,6 +27,8 @@ configitem = registrar.configitem(configtable)
|
||||
configitem("sampling", "filepath", default="")
|
||||
configitem("sampling", "debug", default=False)
|
||||
|
||||
onehundredmb = 100 * 1024 * 1024
|
||||
|
||||
|
||||
def getrelativecwd(repo):
|
||||
"""Returns the current directory relative to the working copy root, or
|
||||
@ -64,7 +66,8 @@ def telemetry(reporef):
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
maxrss = util.getmaxrss()
|
||||
# Round to the nearest 100MB megabyte to reduce our storage size
|
||||
maxrss = int(util.getmaxrss() / onehundredmb) * onehundredmb
|
||||
|
||||
# Log maxrss from within the hg process. The wrapper logs its own
|
||||
# value (which is incorrect if chg is used) so the column is
|
||||
|
Loading…
Reference in New Issue
Block a user