disable vector PMD for i686
cover disable vector PMD for i686
Vector PMD does not support i686, it should not be compiled with i686 arch. Though there is no compile error and sometimes it does works, but it is not designed for i686 orignally.
We saw some test failed when vPMD is invovled on i686, so it is necessary to fix.
Qi Zhang (3):
net/i40e: disable vector PMD for i686
net/ixgbe: disable vector PMD for i686
net/fm10k: disable vector PMD for i686
drivers/net/fm10k/Makefile | 2 ++ drivers/net/i40e/Makefile | 2 +- drivers/net/ixgbe/Makefile | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-)
Signature · 1 line
2.9.3
PATCH 1/3 net/i40e: disable vector PMD for i686
Vector PMD does not support i686, it should not be compiled
--- drivers/net/i40e/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/i40e/Makefile +1 -1
@@ -101,7 +101,7 @@ ifeq ($(CONFIG_RTE_ARCH_ARM64),y) SRCS-$(CONFIG_RTE_LIBRTE_I40E_INC_VECTOR) += i40e_rxtx_vec_neon.c else ifeq ($(CONFIG_RTE_ARCH_PPC_64),y) SRCS-$(CONFIG_RTE_LIBRTE_I40E_INC_VECTOR) += i40e_rxtx_vec_altivec.c -else +else ifeq ($(CONFIG_RTE_ARCH_X86_64),y) SRCS-$(CONFIG_RTE_LIBRTE_I40E_INC_VECTOR) += i40e_rxtx_vec_sse.c endif SRCS-$(CONFIG_RTE_LIBRTE_I40E_PMD) += i40e_ethdev_vf.c
Signature · 1 line
2.9.3
PATCH 2/3 net/ixgbe: disable vector PMD for i686
In reply to Qi ZhangVector PMD does not support i686, so do not compile it.
--- drivers/net/ixgbe/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ixgbe/Makefile +1 -1
@@ -112,7 +112,7 @@ SRCS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += ixgbe_pf.c SRCS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += ixgbe_flow.c ifeq ($(CONFIG_RTE_ARCH_ARM64),y) SRCS-$(CONFIG_RTE_IXGBE_INC_VECTOR) += ixgbe_rxtx_vec_neon.c -else +else ifeq ($(CONFIG_RTE_ARCH_X86_64),y) SRCS-$(CONFIG_RTE_IXGBE_INC_VECTOR) += ixgbe_rxtx_vec_sse.c endif
Signature · 1 line
2.9.3
PATCH 3/3 net/fm10k: disable vector PMD for i686
In reply to Qi ZhangVector PMD does not support i686, it should not be compiled.
--- drivers/net/fm10k/Makefile | 2 ++ 1 file changed, 2 insertions(+)
drivers/net/fm10k/Makefile +2 -0
@@ -95,6 +95,8 @@ SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_common.c SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_mbx.c SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_vf.c SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_api.c +ifeq ($(CONFIG_RTE_ARCH_X86_64),y) SRCS-$(CONFIG_RTE_LIBRTE_FM10K_INC_VECTOR) += fm10k_rxtx_vec.c +endif include $(RTE_SDK)/mk/rte.lib.mk
Signature · 1 line
2.9.3
v2 cover disable vector PMD for i686
In reply to Qi ZhangVector PMD is not designed for i686 orginally, but it still can be active with i686 compile option.
Below are observed failure when vPMD is invovled on i686
(but may not limited to)
1) memory overwrite when assign 2 mbuf points to rx return points. _mm_storeu_si128((__m128i *)&rx_pkts[pos+2], mbp2)
2) rearm_data is not 16 bytes aligned that cause general-protection exception _mm_store_si128((__m128i *)&rx_pkts[0]->rearm_data, rearm0);
So the patch set will exclude Vector PMD from compile with i686 configure.
Qi Zhang (3):
net/i40e: disable vector PMD for i686
net/ixgbe: disable vector PMD for i686
net/fm10k: disable vector PMD for i686
drivers/net/fm10k/Makefile | 2 ++ drivers/net/i40e/Makefile | 2 +- drivers/net/ixgbe/Makefile | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-)
Signature · 1 line
2.9.3
PATCH v2 1/3 net/i40e: disable vector PMD for i686
Vector PMD does not support i686, it should not be compiled
--- drivers/net/i40e/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/i40e/Makefile +1 -1
@@ -101,7 +101,7 @@ ifeq ($(CONFIG_RTE_ARCH_ARM64),y) SRCS-$(CONFIG_RTE_LIBRTE_I40E_INC_VECTOR) += i40e_rxtx_vec_neon.c else ifeq ($(CONFIG_RTE_ARCH_PPC_64),y) SRCS-$(CONFIG_RTE_LIBRTE_I40E_INC_VECTOR) += i40e_rxtx_vec_altivec.c -else +else ifeq ($(CONFIG_RTE_ARCH_X86_64),y) SRCS-$(CONFIG_RTE_LIBRTE_I40E_INC_VECTOR) += i40e_rxtx_vec_sse.c endif SRCS-$(CONFIG_RTE_LIBRTE_I40E_PMD) += i40e_ethdev_vf.c
Signature · 1 line
2.9.3
PATCH v2 2/3 net/ixgbe: disable vector PMD for i686
In reply to Qi ZhangVector PMD does not support i686, so do not compile it.
--- drivers/net/ixgbe/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ixgbe/Makefile +1 -1
@@ -112,7 +112,7 @@ SRCS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += ixgbe_pf.c SRCS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += ixgbe_flow.c ifeq ($(CONFIG_RTE_ARCH_ARM64),y) SRCS-$(CONFIG_RTE_IXGBE_INC_VECTOR) += ixgbe_rxtx_vec_neon.c -else +else ifeq ($(CONFIG_RTE_ARCH_X86_64),y) SRCS-$(CONFIG_RTE_IXGBE_INC_VECTOR) += ixgbe_rxtx_vec_sse.c endif
Signature · 1 line
2.9.3
PATCH v2 3/3 net/fm10k: disable vector PMD for i686
In reply to Qi ZhangVector PMD does not support i686, it should not be compiled.
--- drivers/net/fm10k/Makefile | 2 ++ 1 file changed, 2 insertions(+)
drivers/net/fm10k/Makefile +2 -0
@@ -95,6 +95,8 @@ SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_common.c SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_mbx.c SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_vf.c SRCS-$(CONFIG_RTE_LIBRTE_FM10K_PMD) += fm10k_api.c +ifeq ($(CONFIG_RTE_ARCH_X86_64),y) SRCS-$(CONFIG_RTE_LIBRTE_FM10K_INC_VECTOR) += fm10k_rxtx_vec.c +endif include $(RTE_SDK)/mk/rte.lib.mk
Signature · 1 line
2.9.3
Quoted 7 lines · Qi Zhang
Vector PMD is not designed for i686 orginally, but it still can be active with i686 compile option.
Below are observed failure when vPMD is invovled on i686
(but may not limited to)1) memory overwrite when assign 2 mbuf points to rx return points.
_mm_storeu_si128((__m128i *)&rx_pkts[pos+2], mbp2)
Is this a serious issue that prevents us using the driver? I think it's been in the code for quite some time. Can it not be relatively easily fixed for 32-bit builds?
Quoted 4 lines
2)
rearm_datais not 16 bytes aligned that cause general-protection exception_mm_store_si128((__m128i *)&rx_pkts[0]->rearm_data, rearm0);
Good catch. I think this is also an easy fix. My preferred fix is to explicitly align the rearm data on a 16-byte boundary. It would add some padding to the middle of cacheline0 of the mbuf, but given that we explicitly move other data to cacheline1, we will have padding on 32-bit anyway, be it in the middle or the end of the mbuf cachelines.
Quoted 15 lines
So the patch set will exclude Vector PMD from compile with i686 configure.
Qi Zhang (3):
net/i40e: disable vector PMD for i686
net/ixgbe: disable vector PMD for i686
net/fm10k: disable vector PMD for i686drivers/net/fm10k/Makefile | 2 ++ drivers/net/i40e/Makefile | 2 +- drivers/net/ixgbe/Makefile | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-)Signature · 1 line
2.9.3
27/04/2017 11:25, Bruce Richardson:
Quoted 18 lines · Qi Zhang
Quoted 7 lines
Vector PMD is not designed for i686 orginally, but it still can be active with i686 compile option.
Below are observed failure when vPMD is invovled on i686
(but may not limited to)1) memory overwrite when assign 2 mbuf points to rx return points.
_mm_storeu_si128((__m128i *)&rx_pkts[pos+2], mbp2)Is this a serious issue that prevents us using the driver? I think it's been in the code for quite some time. Can it not be relatively easily fixed for 32-bit builds?
Quoted 4 lines
2)
rearm_datais not 16 bytes aligned that cause general-protection exception_mm_store_si128((__m128i *)&rx_pkts[0]->rearm_data, rearm0);
Quoted 7 lines
Good catch. I think this is also an easy fix. My preferred fix is to explicitly align the rearm data on a 16-byte boundary. It would add some padding to the middle of cacheline0 of the mbuf, but given that we explicitly move other data to cacheline1, we will have padding on 32-bit anyway, be it in the middle or the end of the mbuf cachelines.
Quoted 1 line
So the patch set will exclude Vector PMD from compile with i686 configure.
Please try to fix the drivers instead of turning them off.
Quoted 25 lines · Thomas Monjalon
27/04/2017 11:25, Bruce Richardson:
Quoted 24 lines · Qi Zhang
Quoted 7 lines
Vector PMD is not designed for i686 orginally, but it still can be active with i686 compile option.
Below are observed failure when vPMD is invovled on i686
(but may not limited to)1) memory overwrite when assign 2 mbuf points to rx return points.
_mm_storeu_si128((__m128i *)&rx_pkts[pos+2], mbp2)Is this a serious issue that prevents us using the driver? I think it's been in the code for quite some time. Can it not be relatively easily fixed for 32-bit builds?
Quoted 4 lines
2)
rearm_datais not 16 bytes aligned that cause general-protection exception_mm_store_si128((__m128i *)&rx_pkts[0]->rearm_data, rearm0);Good catch. I think this is also an easy fix. My preferred fix is to explicitly align the rearm data on a 16-byte boundary. It would add some padding to the middle of cacheline0 of the mbuf, but given that we explicitly move other data to cacheline1, we will have padding on 32-bit anyway, be it in the middle or the end of the mbuf cachelines.
Quoted 3 lines
Quoted 1 line
Quoted 1 line
So the patch set will exclude Vector PMD from compile with i686 configure.
Please try to fix the drivers instead of turning them off.
The patch for alignment of physical addresses should fix these issues, removing the need for these patches.
/Bruce
Quoted 26 lines · Bruce Richardson
Quoted 25 lines · Thomas Monjalon
27/04/2017 11:25, Bruce Richardson:
Quoted 24 lines · Qi Zhang
Quoted 7 lines
Vector PMD is not designed for i686 orginally, but it still can be active with i686 compile option.
Below are observed failure when vPMD is invovled on i686
(but may not limited to)1) memory overwrite when assign 2 mbuf points to rx return points.
_mm_storeu_si128((__m128i *)&rx_pkts[pos+2], mbp2)Is this a serious issue that prevents us using the driver? I think it's been in the code for quite some time. Can it not be relatively easily fixed for 32-bit builds?
Quoted 4 lines
2)
rearm_datais not 16 bytes aligned that cause general-protection exception_mm_store_si128((__m128i *)&rx_pkts[0]->rearm_data, rearm0);Good catch. I think this is also an easy fix. My preferred fix is to explicitly align the rearm data on a 16-byte boundary. It would add some padding to the middle of cacheline0 of the mbuf, but given that we explicitly move other data to cacheline1, we will have padding on 32-bit anyway, be it in the middle or the end of the mbuf cachelines.
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line
So the patch set will exclude Vector PMD from compile with i686 configure.
Please try to fix the drivers instead of turning them off.
The patch for alignment of physical addresses should fix these issues, removing the need for these patches.
Patches marked as rejected, Thanks for the fix Bruce!
Quoted 3 lines
/Bruce