diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2024-12-16 18:56:55 +0800 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2024-12-22 12:56:49 +0800 |
commit | e5a52298680d3af2cf384fbedbd8be22a165574f (patch) | |
tree | c8c3beae8eb8e34ffbcba420c57f863d0a96da45 /stdio-common/printf-parsewc.c | |
parent | d9d30f6cb582fbd3932aa4731061c6335ffc5a70 (diff) | |
download | glibc-e5a52298680d3af2cf384fbedbd8be22a165574f.zip glibc-e5a52298680d3af2cf384fbedbd8be22a165574f.tar.gz glibc-e5a52298680d3af2cf384fbedbd8be22a165574f.tar.bz2 |
tst-atomic.c: Mark as UNSUPPORTED when compiled with Clang
Since Clang can't remove the dead statement and issues an error:
tst-atomic.c:463:7: error: unsupported inline asm: input with type 'int64_t' (aka 'long') matching output with type 'typeof (*&mem)' (aka 'int')
463 | if (catomic_exchange_and_add (&mem, 11) != 2
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../sysdeps/x86/atomic-machine.h:213:3: note: expanded from macro 'catomic_exchange_and_add'
213 | __arch_exchange_and_add_body (__arch_exchange_and_add_cprefix, __arch_c, \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
214 | mem, value)
| ~~~~~~~~~~~
../sysdeps/x86/atomic-machine.h:199:12: note: expanded from macro '__arch_exchange_and_add_body'
198 | : "=r" (__result), "=m" (*mem) \
| ~~~~~~~~
199 | : "0" ((int64_t) cast_to_integer (__addval)), \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tst-atomic.c:487:7: error: unsupported inline asm: input with type 'int64_t' (aka 'long') matching output with type 'typeof (*(&mem))' (aka 'int')
487 | if (catomic_increment_val (&mem) != 3)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
../include/atomic.h:313:38: note: expanded from macro 'catomic_increment_val'
313 | # define catomic_increment_val(mem) (catomic_exchange_and_add ((mem), 1) + 1)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../sysdeps/x86/atomic-machine.h:213:3: note: expanded from macro 'catomic_exchange_and_add'
213 | __arch_exchange_and_add_body (__arch_exchange_and_add_cprefix, __arch_c, \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
214 | mem, value)
| ~~~~~~~~~~~
../sysdeps/x86/atomic-machine.h:199:12: note: expanded from macro '__arch_exchange_and_add_body'
198 | : "=r" (__result), "=m" (*mem) \
| ~~~~~~~~
199 | : "0" ((int64_t) cast_to_integer (__addval)), \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tst-atomic.c:501:7: error: unsupported inline asm: input with type 'int64_t' (aka 'long') matching output with type 'typeof (*(&mem))' (aka 'int')
501 | if (catomic_decrement_val (&mem) != 15)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
../include/atomic.h:340:38: note: expanded from macro 'catomic_decrement_val'
340 | # define catomic_decrement_val(mem) (catomic_exchange_and_add ((mem), -1) - 1)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../sysdeps/x86/atomic-machine.h:213:3: note: expanded from macro 'catomic_exchange_and_add'
213 | __arch_exchange_and_add_body (__arch_exchange_and_add_cprefix, __arch_c, \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
214 | mem, value)
| ~~~~~~~~~~~
../sysdeps/x86/atomic-machine.h:199:12: note: expanded from macro '__arch_exchange_and_add_body'
198 | : "=r" (__result), "=m" (*mem) \
| ~~~~~~~~
199 | : "0" ((int64_t) cast_to_integer (__addval)), \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
mark tst-atomic.c as UNSUPPORTED when compiled with Clang.
Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
Reviewed-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'stdio-common/printf-parsewc.c')
0 files changed, 0 insertions, 0 deletions