diff options
author | Elliott Hughes <enh@google.com> | 2018-10-23 11:23:00 -0700 |
---|---|---|
committer | Elliott Hughes <enh@google.com> | 2018-10-23 11:23:00 -0700 |
commit | 2d0b28bc0da1ade2de2b72093dbdb740028fce7c (patch) | |
tree | 75a1b66144e65f7141e3cf9ddaaae0049b07ca11 /libc/include/stdlib.h | |
parent | 7562f1ab87e4b51042d185345248f1a54885489a (diff) |
Add getloadavg(3).
Lets us build ninja with bionic.
Bug: N/A
Test: ran tests
Change-Id: I97eef1247d794b58a2b9aee4851551632e5a4e48
Diffstat (limited to 'libc/include/stdlib.h')
-rw-r--r-- | libc/include/stdlib.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/libc/include/stdlib.h b/libc/include/stdlib.h index 6888e8c20..96a77a790 100644 --- a/libc/include/stdlib.h +++ b/libc/include/stdlib.h @@ -147,6 +147,15 @@ typedef struct { lldiv_t lldiv(long long __numerator, long long __denominator) __attribute_const__; +/** + * [getloadavg(3)](http://man7.org/linux/man-pages/man3/getloadavg.3.html) queries the + * number of runnable processes averaged over time. The Linux kernel supports averages + * over the last 1, 5, and 15 minutes. + * + * Returns the number of samples written to `__averages` (at most 3), and returns -1 on failure. + */ +int getloadavg(double __averages[], int __n) __INTRODUCED_IN_FUTURE; + /* BSD compatibility. */ const char* getprogname(void) __INTRODUCED_IN(21); void setprogname(const char* __name) __INTRODUCED_IN(21); |