3251c5ae51
The compatibility code for the atomic operations in ZFS code is a bit messy. In some cases the native definitions are directly made available, in some cases there are emulated operations in opensolaris_atomic.c and in yet other cases there are atomic operations implemented in assembly that were obtained from OpenSolaris / illumos. This commit adds atomic_swap_64 for use with i386 userland. The code is copied from illumos. I am not sure why FreeBSD does not provide that operation natively. Maybe because we try (or pretend) to support processors that did not have the necessary instructions. While here I also added atomic_load_64 for the same reasons. This is original code based on iilumos atomic_swap_64 and FreeBSD atomic_load_acq_64_i586. Pointyhat to: avg MFC after: 1 week |
||
---|---|---|
.. | ||
boot/zfs | ||
compat/opensolaris | ||
contrib/opensolaris | ||
dev |