Home
last modified time | relevance | path

Searched refs:rl (Results 1 – 3 of 3) sorted by relevance

/bionic/libc/bionic/
Dsysconf.cpp44 rlimit rl; in __sysconf_rlimit() local
45 getrlimit(resource, &rl); in __sysconf_rlimit()
46 return rl.rlim_cur; in __sysconf_rlimit()
/bionic/tests/
Dunistd_test.cpp1117 rlimit rl; in TEST() local
1118 ASSERT_EQ(0, getrlimit(RLIMIT_STACK, &rl)); in TEST()
1119 uint64_t original_rlim_cur = rl.rlim_cur; in TEST()
1120 if (rl.rlim_cur == RLIM_INFINITY) { in TEST()
1121 rl.rlim_cur = 8 * 1024 * 1024; // Bionic reports unlimited stacks as 8MiB. in TEST()
1123 auto guard = android::base::make_scope_guard([&rl, original_rlim_cur]() { in TEST()
1124 rl.rlim_cur = original_rlim_cur; in TEST()
1125 ASSERT_EQ(0, setrlimit(RLIMIT_STACK, &rl)); in TEST()
1129 EXPECT_EQ(static_cast<long>(rl.rlim_cur / 4), sysconf(_SC_ARG_MAX)); in TEST()
1132 rl.rlim_cur = 1024; in TEST()
[all …]
Dpthread_test.cpp1761 rlimit rl; in TEST() local
1762 ASSERT_EQ(0, getrlimit(RLIMIT_STACK, &rl)); in TEST()
1763 uint64_t original_rlim_cur = rl.rlim_cur; in TEST()
1764 if (rl.rlim_cur == RLIM_INFINITY) { in TEST()
1765 rl.rlim_cur = 8 * 1024 * 1024; // Bionic reports unlimited stacks as 8MiB. in TEST()
1767 EXPECT_EQ(rl.rlim_cur, stack_size); in TEST()
1769 auto guard = android::base::make_scope_guard([&rl, original_rlim_cur]() { in TEST()
1770 rl.rlim_cur = original_rlim_cur; in TEST()
1771 ASSERT_EQ(0, setrlimit(RLIMIT_STACK, &rl)); in TEST()
1777 rl.rlim_cur = rl.rlim_max = 1024; // 1KiB. We know the stack must be at least a page already. in TEST()
[all …]