File tree 6 files changed +12
-0
lines changed
6 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -697,6 +697,8 @@ pub const FD_SETSIZE: usize = 1024;
697
697
698
698
pub const ST_NOSUID : :: c_ulong = 2 ;
699
699
700
+ pub const HW_AVAILCPU : :: c_int = 25 ;
701
+
700
702
extern {
701
703
pub fn mincore ( addr : * const :: c_void , len : :: size_t ,
702
704
vec : * mut :: c_char ) -> :: c_int ;
Original file line number Diff line number Diff line change @@ -543,6 +543,8 @@ pub const FD_SETSIZE: usize = 1024;
543
543
544
544
pub const ST_NOSUID : :: c_ulong = 2 ;
545
545
546
+ pub const HW_AVAILCPU : :: c_int = 25 ;
547
+
546
548
extern {
547
549
pub fn mincore ( addr : * const :: c_void , len : :: size_t ,
548
550
vec : * mut c_char ) -> :: c_int ;
Original file line number Diff line number Diff line change @@ -98,6 +98,9 @@ pub const ST_RDONLY: ::c_ulong = 1;
98
98
99
99
pub const NI_MAXHOST : :: socklen_t = 1025 ;
100
100
101
+ pub const CTL_HW : :: c_int = 6 ;
102
+ pub const HW_NCPU : :: c_int = 3 ;
103
+
101
104
f ! {
102
105
pub fn FD_CLR ( fd: :: c_int, set: * mut fd_set) -> ( ) {
103
106
let fd = fd as usize ;
Original file line number Diff line number Diff line change @@ -205,6 +205,8 @@ pub const PTHREAD_COND_INITIALIZER: pthread_cond_t = 0 as *mut _;
205
205
pub const PTHREAD_RWLOCK_INITIALIZER : pthread_rwlock_t = 0 as * mut _ ;
206
206
pub const PTHREAD_MUTEX_RECURSIVE : :: c_int = 2 ;
207
207
208
+ pub const HW_AVAILCPU : :: c_int = 25 ;
209
+
208
210
extern {
209
211
pub fn mprotect ( addr : * const :: c_void , len : :: size_t , prot : :: c_int )
210
212
-> :: c_int ;
Original file line number Diff line number Diff line change @@ -208,6 +208,8 @@ pub const PTHREAD_COND_INITIALIZER: pthread_cond_t = 0 as *mut _;
208
208
pub const PTHREAD_RWLOCK_INITIALIZER : pthread_rwlock_t = 0 as * mut _ ;
209
209
pub const PTHREAD_MUTEX_RECURSIVE : :: c_int = 2 ;
210
210
211
+ pub const HW_AVAILCPU : :: c_int = 25 ;
212
+
211
213
extern {
212
214
pub fn mprotect ( addr : * const :: c_void , len : :: size_t , prot : :: c_int )
213
215
-> :: c_int ;
Original file line number Diff line number Diff line change @@ -163,6 +163,7 @@ pub const _SC_THREAD_PRIORITY_SCHEDULING: ::c_int = 82;
163
163
pub const _SC_THREAD_PRIO_INHERIT: :: c_int = 83 ;
164
164
pub const _SC_THREAD_PRIO_PROTECT: :: c_int = 84 ;
165
165
pub const _SC_THREAD_SAFE_FUNCTIONS: :: c_int = 85 ;
166
+ pub const _SC_NPROCESSORS_ONLN: :: c_int = 97 ;
166
167
167
168
pub const PTHREAD_STACK_MIN : :: size_t = 8192 ;
168
169
pub const PTHREAD_MUTEX_INITIALIZER : pthread_mutex_t = pthread_mutex_t {
You can’t perform that action at this time.
0 commit comments