diff options
author | Chris Lattner <sabre@nondot.org> | 2005-01-29 05:21:16 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2005-01-29 05:21:16 +0000 |
commit | 6cfbd626806875214291d44ea4f9064cc1479623 (patch) | |
tree | 616b26288cb31439946673e6291cc78f80408569 /include/llvm/Support/Timer.h | |
parent | 03aef68dc1768e78ca536cffbb8bd52332968042 (diff) | |
download | llvm-6cfbd626806875214291d44ea4f9064cc1479623.tar.gz llvm-6cfbd626806875214291d44ea4f9064cc1479623.tar.bz2 llvm-6cfbd626806875214291d44ea4f9064cc1479623.tar.xz |
Memory used is a delta between memuse at the start of the time and the
memuse at the end, thus it is signed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19904 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support/Timer.h')
-rw-r--r-- | include/llvm/Support/Timer.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/llvm/Support/Timer.h b/include/llvm/Support/Timer.h index 86194d16b6..3af688c863 100644 --- a/include/llvm/Support/Timer.h +++ b/include/llvm/Support/Timer.h @@ -36,7 +36,7 @@ class Timer { double Elapsed; // Wall clock time elapsed in seconds double UserTime; // User time elapsed double SystemTime; // System time elapsed - size_t MemUsed; // Memory allocated (in bytes) + ssize_t MemUsed; // Memory allocated (in bytes) size_t PeakMem; // Peak memory used size_t PeakMemBase; // Temporary for peak calculation... std::string Name; // The name of this time variable @@ -50,7 +50,7 @@ public: double getProcessTime() const { return UserTime+SystemTime; } double getWallTime() const { return Elapsed; } - size_t getMemUsed() const { return MemUsed; } + ssize_t getMemUsed() const { return MemUsed; } size_t getPeakMem() const { return PeakMem; } std::string getName() const { return Name; } |