[compiler-rt] [ASan] Disable test that sets call stack on Darwin (PR #170786)

Aiden Grossman via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 4 16:59:07 PST 2025


boomanaiden154 wrote:

I run into the same issue when calling `setrlimit` explicitly, so it would be hard to get around this with any sort of wrapper redesign. I'm honestly not sure how the default shell on MacOS is able to get around this.

```
aidengrossman-mac2:runtimes-bins aidengrossman$ cat /tmp/test.cpp
#include <stdio.h>
#include <errno.h>
#include <sys/resource.h>

int main(void)
{
    struct rlimit limits = {
        8372224,
        60792480
    };

    int r = setrlimit(RLIMIT_AS, &limits);
    if (r == -1) {
        perror("setrlimit");
        return 1;
    }
    return 0;
}
aidengrossman-mac2:runtimes-bins aidengrossman$ clang++ /tmp/test.cpp -o /tmp/test
aidengrossman-mac2:runtimes-bins aidengrossman$ /tmp/test
setrlimit: Invalid argument
aidengrossman-mac2:runtimes-bins aidengrossman$ python3
Python 3.9.6 (default, Apr 30 2025, 02:07:17)
[Clang 17.0.0 (clang-1700.0.13.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import resource
>>> print(resource.getrlimit(resource.RLIMIT_STACK))
(8372224, 67092480)
>>> exit()
```

https://github.com/llvm/llvm-project/pull/170786


More information about the llvm-commits mailing list