The following is more informational than anything as far as I'm concerned. But there may be implications that I'm unaware of. (I sometimes experiment with toolchain use to see what the current status is for such use.)
In attempting to buildworld buildkernel via powerpc64-unknown-freebsd13.0-gcc9 (via amd64->powerpc64 cross build): --- vfs_vnops.o --- In file included from /usr/src/sys/sys/systm.h:44, from /usr/src/sys/kern/vfs_vnops.c:51: /usr/src/sys/kern/vfs_vnops.c: In function 'atomic_cmpset_masked': ./machine/atomic.h:623:2: error: 'tmp' is used uninitialized in this function [-Werror=uninitialized] 623 | __asm __volatile ( | ^~~~~ This was for: #else static __inline int atomic_cmpset_masked(uint32_t *p, uint32_t cmpval, uint32_t newval, uint32_t mask) { int ret; uint32_t tmp; __asm __volatile ( "1:\tlwarx %2, 0, %3\n\t" /* load old value */ "and %0, %2, %7\n\t" "cmplw %4, %0\n\t" /* compare */ "bne- 2f\n\t" /* exit if not equal */ "andc %2, %2, %7\n\t" "or %2, %2, %5\n\t" "stwcx. %2, 0, %3\n\t" /* attempt to store */ "bne- 1b\n\t" /* spin if failed */ "li %0, 1\n\t" /* success - retval = 1 */ "b 3f\n\t" /* we've succeeded */ "2:\n\t" "stwcx. %2, 0, %3\n\t" /* clear reservation (74xx) */ "li %0, 0\n\t" /* failure - retval = 0 */ "3:\n\t" : "=&r" (ret), "=m" (*p), "+&r" (tmp) : "r" (p), "r" (cmpval), "r" (newval), "m" (*p), "r" (mask) : "cr0", "memory"); return (ret); } (Looks like the lwarx initializes tmp to me.) This was an attempt to cross-build head -r363000 ( via -r363000 ). === Mark Millard marklmi at yahoo.com ( dsl-only.net went away in early 2018-Mar) _______________________________________________ freebsd-toolchain@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-toolchain To unsubscribe, send any mail to "freebsd-toolchain-unsubscr...@freebsd.org"