diff options
author | Stan Shebs <stanshebs@google.com> | 2018-09-25 08:04:10 -0700 |
---|---|---|
committer | Fangrui Song <i@maskray.me> | 2021-08-27 17:23:13 -0700 |
commit | 6ea6782b69a19dfd32bceaa3b83bf81d90763373 (patch) | |
tree | 9be5c20ea221f54349d0b33f07854561660ec150 /sysdeps | |
parent | b35774068a3f606c1fb76476d3e695dc2dacb86e (diff) | |
download | glibc-6ea6782b69a19dfd32bceaa3b83bf81d90763373.zip glibc-6ea6782b69a19dfd32bceaa3b83bf81d90763373.tar.gz glibc-6ea6782b69a19dfd32bceaa3b83bf81d90763373.tar.bz2 |
Work around clang crash by skipping apparently-unneeded asm
Diffstat (limited to 'sysdeps')
-rw-r--r-- | sysdeps/powerpc/powerpc64/backtrace.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sysdeps/powerpc/powerpc64/backtrace.c b/sysdeps/powerpc/powerpc64/backtrace.c index c0c4b48..b438560 100644 --- a/sysdeps/powerpc/powerpc64/backtrace.c +++ b/sysdeps/powerpc/powerpc64/backtrace.c @@ -70,8 +70,12 @@ __backtrace (void **array, int size) struct layout *current; int count; + /* The following asm causes a clang crash, and does not seem to be + needed anyway; clang always saves link register. */ +#if !defined __clang__ /* Force gcc to spill LR. */ asm volatile ("" : "=l"(current)); +#endif /* Get the address on top-of-stack. */ asm volatile ("ld %0,0(1)" : "=r"(current)); |