Skip to content
Permalink
Browse files

8235671: enhance print_rlimit_info in os_posix

Reviewed-by: clanger, mdoerr
  • Loading branch information
Matthias Baesken
Matthias Baesken committed Dec 10, 2019
1 parent 83cb704 commit 9a31ab88621c970a762b068f74f512a637ec91c5
Showing with 9 additions and 0 deletions.
  1. +9 −0 src/hotspot/os/posix/os_posix.cpp
@@ -419,6 +419,10 @@ void os::Posix::print_rlimit_info(outputStream* st) {
#if defined(AIX)
st->print(", NPROC ");
st->print("%d", sysconf(_SC_CHILD_MAX));
st->print(", THREADS ");
getrlimit(RLIMIT_THREADS, &rlim);
if (rlim.rlim_cur == RLIM_INFINITY) st->print("infinity");
else st->print(UINT64_FORMAT, uint64_t(rlim.rlim_cur));
#elif !defined(SOLARIS)
st->print(", NPROC ");
getrlimit(RLIMIT_NPROC, &rlim);
@@ -436,6 +440,11 @@ void os::Posix::print_rlimit_info(outputStream* st) {
if (rlim.rlim_cur == RLIM_INFINITY) st->print("infinity");
else st->print(UINT64_FORMAT "k", uint64_t(rlim.rlim_cur) / 1024);

st->print(", CPU ");
getrlimit(RLIMIT_CPU, &rlim);
if (rlim.rlim_cur == RLIM_INFINITY) st->print("infinity");
else st->print(UINT64_FORMAT, uint64_t(rlim.rlim_cur));

st->print(", DATA ");
getrlimit(RLIMIT_DATA, &rlim);
if (rlim.rlim_cur == RLIM_INFINITY) st->print("infinity");

0 comments on commit 9a31ab8

Please sign in to comment.
You can’t perform that action at this time.