Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
Pyston
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
Pyston
Commits
959f5a40
Commit
959f5a40
authored
May 07, 2015
by
Kevin Modzelewski
Committed by
Kevin Modzelewski
May 08, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
clean up stats a tad
parent
93b5d65d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
9 deletions
+1
-9
src/core/stats.cpp
src/core/stats.cpp
+1
-6
src/core/stats.h
src/core/stats.h
+0
-3
No files found.
src/core/stats.cpp
View file @
959f5a40
...
...
@@ -38,7 +38,6 @@ extern "C" const char* getStatTimerName() {
__thread
StatTimer
*
StatTimer
::
stack
;
StatTimer
::
StatTimer
(
int
statid
,
bool
push
)
{
uint64_t
at_time
=
getCPUTicks
();
_duration
=
0
;
_start_time
=
0
;
_statid
=
statid
;
...
...
@@ -56,7 +55,6 @@ StatTimer::StatTimer(int statid, bool push) {
}
StatTimer
::
StatTimer
(
int
statid
,
uint64_t
at_time
)
{
_duration
=
0
;
_start_time
=
0
;
_statid
=
statid
;
_prev
=
stack
;
...
...
@@ -88,13 +86,10 @@ StatTimer::~StatTimer() {
void
StatTimer
::
pause
(
uint64_t
at_time
)
{
assert
(
!
isPaused
());
assert
(
at_time
>
_start_time
);
auto
cur_duration
=
_duration
;
_duration
=
at_time
-
_start_time
;
assert
(
_duration
>
cur_duration
);
uint64_t
_duration
=
at_time
-
_start_time
;
Stats
::
log
(
_statid
,
_duration
);
_duration
=
0
;
_start_time
=
0
;
_last_pause_time
=
at_time
;
// fprintf (stderr, "paused %d at %lu\n", _statid, at_time);
...
...
src/core/stats.h
View file @
959f5a40
...
...
@@ -116,9 +116,6 @@ class StatTimer {
private:
static
__thread
StatTimer
*
stack
;
// the accumulated active duration of this timer
uint64_t
_duration
;
// the start time of the current active segment (0 == paused)
uint64_t
_start_time
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment