summaryrefslogtreecommitdiff
path: root/src/barrier.h
AgeCommit message (Collapse)Author
2019-07-10Use __typeof() instead of typeof()Hrvoje Zeba
typeof() is not available on all compilers. __typeof() is a safer bet. Signed-off-by: Hrvoje Zeba <zeba.hrvoje@gmail.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
2019-07-08Optimize i386 memory barriersBart Van Assche
Use identical memory barrier implementations on 32 and 64 bit Intel CPUs. In the past the Linux kernel supported 32 bit CPUs that violate the x86 ordering standard. Since io_uring is not supported by these older kernels, do not support these older CPUs in liburing. See also Linux kernel commit 5927145efd5d ("x86/cpu: Remove the CONFIG_X86_PPRO_FENCE=y quirk") # v4.16. Cc: Roman Penyaev <rpenyaev@suse.de> Suggested-by: Roman Penyaev <rpenyaev@suse.de> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
2019-07-08Change __x86_64 into __x86_64__Bart Van Assche
This patch improves consistency with the Linux kernel source code. Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
2019-07-02Fix the use of memory barriersBart Van Assche
Introduce the smp_load_acquire() and smp_store_release() macros. Fix synchronization in io_uring_cq_advance() and __io_uring_get_cqe(). Remove a superfluous local variable, if-test and write barrier from __io_uring_submit(). Remove a superfluous barrier from test/io_uring_enter.c. Cc: Stefan Hajnoczi <stefanha@redhat.com> Cc: Roman Penyaev <rpenyaev@suse.de> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
2019-01-16Update barriers for x86/x86-64Jens Axboe
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2019-01-13Add x86 32-bit supportJens Axboe
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2019-01-08Initial commitJens Axboe
Signed-off-by: Jens Axboe <axboe@kernel.dk>