tunemygc 1.0.56 → 1.0.57
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ext/tunemygc/getRSS.c +11 -1
- data/lib/tunemygc/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e95fa4caa87878bd91875eee79cbd9722fddfb61
|
4
|
+
data.tar.gz: e0eeab54f46aac72d03d9b1ac9fc9bca0d246820
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d4e24deeba0010babd67486b1662f7d6d2d78322e86360d49699d7a11479e21464da581b376d3dda4dcf62c4bc068ac34fa05365fffabaa085d04c8bab04d91f
|
7
|
+
data.tar.gz: eeb79132bea640599c00ac60c7084614fadc4c35242175a4507fb5bd7f9b6a67cae811fde9a8efac089084cfe877e91462c1c041a16423dc613786ede540dd91
|
data/ext/tunemygc/getRSS.c
CHANGED
@@ -15,6 +15,8 @@
|
|
15
15
|
|
16
16
|
#if defined(__APPLE__) && defined(__MACH__)
|
17
17
|
#include <mach/mach.h>
|
18
|
+
#include <mach/task.h>
|
19
|
+
#include <mach/task_info.h>
|
18
20
|
|
19
21
|
#elif (defined(_AIX) || defined(__TOS__AIX__)) || (defined(__sun__) || defined(__sun) || defined(sun) && (defined(__SVR4) || defined(__svr4__)))
|
20
22
|
#include <fcntl.h>
|
@@ -94,13 +96,21 @@ size_t getCurrentRSS( )
|
|
94
96
|
|
95
97
|
#elif defined(__APPLE__) && defined(__MACH__)
|
96
98
|
/* OSX ------------------------------------------------------ */
|
99
|
+
#ifdef MACH_TASK_BASIC_INFO
|
97
100
|
struct mach_task_basic_info info;
|
98
101
|
mach_msg_type_number_t infoCount = MACH_TASK_BASIC_INFO_COUNT;
|
99
102
|
if ( task_info( mach_task_self( ), MACH_TASK_BASIC_INFO,
|
100
103
|
(task_info_t)&info, &infoCount ) != KERN_SUCCESS )
|
101
104
|
return (size_t)0L; /* Can't access? */
|
102
105
|
return (size_t)info.resident_size;
|
103
|
-
|
106
|
+
#else
|
107
|
+
struct task_basic_info info;
|
108
|
+
mach_msg_type_number_t infoCount = TASK_BASIC_INFO_COUNT
|
109
|
+
if (task_info( mach_task_self(), TASK_BASIC_INFO,
|
110
|
+
(task_info_t)&info, &infoCount) != KERN_SUCCESS)
|
111
|
+
return (size_t)0L;
|
112
|
+
return (size_t)info.resident_size;
|
113
|
+
#endif
|
104
114
|
#elif defined(__linux__) || defined(__linux) || defined(linux) || defined(__gnu_linux__)
|
105
115
|
/* Linux ---------------------------------------------------- */
|
106
116
|
long rss = 0L;
|
data/lib/tunemygc/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tunemygc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.57
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bear Metal
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-04-
|
11
|
+
date: 2015-04-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|