Re: [dpdk-dev] [PATCH v4 2/4] ring: read tail using atomic load

2018-09-25 Thread Gavin Hu (Arm Technology China)
+ Justin He as Jerin requested. > -Original Message- > From: Jerin Jacob > Sent: Thursday, September 20, 2018 2:41 PM > To: Gavin Hu (Arm Technology China) > Cc: dev@dpdk.org; Honnappa Nagarahalli > ; Steve Capper > ; Ola Liljedahl ; nd > ; sta...@dpdk.org; jia...@hxt-semitech.com > Sub

Re: [dpdk-dev] [PATCH v4 2/4] ring: read tail using atomic load

2018-09-19 Thread Jerin Jacob
-Original Message- > Date: Mon, 17 Sep 2018 16:11:17 +0800 > From: Gavin Hu > To: dev@dpdk.org > CC: gavin...@arm.com, honnappa.nagaraha...@arm.com, steve.cap...@arm.com, > ola.liljed...@arm.com, jerin.ja...@caviumnetworks.com, n...@arm.com, > sta...@dpdk.org > Subject: [PATCH v4 2/4] ri

[dpdk-dev] [PATCH v4 2/4] ring: read tail using atomic load

2018-09-17 Thread Gavin Hu
In update_tail, read ht->tail using __atomic_load.Although the compiler currently seems to be doing the right thing even without _atomic_load, we don't want to give the compiler freedom to optimise what should be an atomic load, it should not be arbitarily moved around. Fixes: 39368ebfc6 ("ring: i