DPDK patches and discussions
 help / color / mirror / Atom feed
* 32 bit arch optimization suggestion
@ 2023-08-25  9:40 Morten Brørup
  2023-08-25  9:50 ` Bruce Richardson
  0 siblings, 1 reply; 2+ messages in thread
From: Morten Brørup @ 2023-08-25  9:40 UTC (permalink / raw)
  To: dev, Ruifeng Wang, bruce.richardson, konstantin.v.ananyev; +Cc: olivier.matz

I was wondering...

How widely is DPDK used with 32 bit architectures?

Both phys_addr_t and rte_iova_t are cast as uint64_t in rte_common.h. Should they be uint32_t on 32 bit arch?

If so, the rte_mbuf structure has 12 unused byte in the first cache line on 32 bit arch.

Now, moving the "next" (4 byte pointer) and "tx_offload" (8 byte flags) fields to the first cache line could improve performance significantly, because this modification would leave the second cache line unused in most cases.


Med venlig hilsen / Kind regards,
-Morten Brørup


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: 32 bit arch optimization suggestion
  2023-08-25  9:40 32 bit arch optimization suggestion Morten Brørup
@ 2023-08-25  9:50 ` Bruce Richardson
  0 siblings, 0 replies; 2+ messages in thread
From: Bruce Richardson @ 2023-08-25  9:50 UTC (permalink / raw)
  To: Morten Brørup; +Cc: dev, Ruifeng Wang, konstantin.v.ananyev, olivier.matz

On Fri, Aug 25, 2023 at 11:40:32AM +0200, Morten Brørup wrote:
> I was wondering...
> 
> How widely is DPDK used with 32 bit architectures?
> 
> Both phys_addr_t and rte_iova_t are cast as uint64_t in rte_common.h. Should they be uint32_t on 32 bit arch?
> 
I don't think they can be. Even if the address space of the process is 32
bits, the underlying physical address still has more bits. Even in the
"olden days" with 32-bit CPUs we had PAE mode where physical addresses were
36 bits and the page table entries expanded out to 64-bits to accomodate
this.

/Bruce

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-08-25  9:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-25  9:40 32 bit arch optimization suggestion Morten Brørup
2023-08-25  9:50 ` Bruce Richardson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).