Skip to content

Commit 907bc2b

Browse files
committed
gperf.cpp
1 parent a44056f commit 907bc2b

1 file changed

Lines changed: 17 additions & 0 deletions

File tree

section4/gperf.cpp

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
// Copyright (c) 2020 by Chrono
2+
//
3+
// g++ gperf.cpp -std=c++11 -lprofiler -ltcmalloc -o a.out;./a.out
4+
// g++ gperf.cpp -std=c++14 -lprofiler -ltcmalloc -o a.out;./a.out
5+
6+
#include <iostream>
7+
8+
#include <gperftools/profiler.h>
9+
#include <gperftools/heap-profiler.h>
10+
11+
using namespace std;
12+
13+
14+
int main()
15+
{
16+
cout << "gperf demo" << endl;
17+
}

0 commit comments

Comments
 (0)