diff options
| author | Rainer Orth <ro@gcc.gnu.org> | 2024-09-24 09:36:40 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-09-24 09:36:40 +0200 |
| commit | 4a264c559922a8754a0e28fbf316ba667ec19798 (patch) | |
| tree | 331ed2dc9af6f6f576f5b259dfefbfc722a74af3 /llvm/lib/Object/ModuleSymbolTable.cpp | |
| parent | 3907d186d627f8957627b2861cf6f879d07c93c2 (diff) | |
| download | llvm-4a264c559922a8754a0e28fbf316ba667ec19798.zip llvm-4a264c559922a8754a0e28fbf316ba667ec19798.tar.gz llvm-4a264c559922a8754a0e28fbf316ba667ec19798.tar.bz2 | |
[sanitizer_common] Fix GetArgsAndEnv on Linux/sparc64 (#109109)
When ASan testing is enabled on SPARC as per PR #107405, the
```
AddressSanitizer-sparc-linux :: TestCases/Posix/print_cmdline.cpp
```
test `FAIL`s. Either `ASAN_OPTIONS=print_cmdline=true` yielded binary
garbage in the `Command:` output or just an empty string.
It turns out one needs to apply an offset to `__libc_stack_end` to get
at the actual `argc`/`argv`, as described in `glibc`'s
`sysdeps/sparc/sparc{32,64}/dl-machine.h` (`DL_STACK_END`).
This patch does this, fixing the test.
Tested on `sparc64-unknown-linux-gnu`.
Diffstat (limited to 'llvm/lib/Object/ModuleSymbolTable.cpp')
0 files changed, 0 insertions, 0 deletions
