From: "Wiles, Keith" <keith.wiles@intel.com>
To: "hom.sepanta@gmail.com" <hom.sepanta@gmail.com>
Cc: "users@dpdk.org" <users@dpdk.org>
Subject: Re: [dpdk-users] Using memzone for sharing memory
Date: Tue, 8 May 2018 13:07:44 +0000 [thread overview]
Message-ID: <7C6873AE-1D3C-4A2F-B69E-EBF52AC76DCC@intel.com> (raw)
In-Reply-To: <CAG8BTKnq6dYOhH45eNGXLk-a5vaAiFaFxJwSto04DwKXedZMzw@mail.gmail.com>
> On May 6, 2018, at 7:04 AM, hom.sepanta@gmail.com wrote:
>
> Hi everyone. I was wondering if the virtual address of memzones remains the
> same across different processes. The memzone docs mention the same physical
> address is returned but there is no mention of the virtual address. A
> little bit of testing makes it look like that the virtual address is also
> the same, but I can't be sure about that.
Normally the virtual address of memory shared between to processes could be different it just depends on the kernel and other factors.
>
> The interesting thing about this for me is that if the same virtual address
> is always returned, I could store and share complex data structures with
> internal pointers in a memzone.
I have seen this to be true, but you can not count on the fact for all cases.
>
> Does this sound possible? If using memzones is not the correct approach for
> this, could you suggest another course of action?
You have to use offsets in the shared memory or some other method to determine the correct virtual address in each process.
>
> Cheers,
> Mostafa
Regards,
Keith
prev parent reply other threads:[~2018-05-08 13:07 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-06 12:04 hom.sepanta
2018-05-08 13:07 ` Wiles, Keith [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7C6873AE-1D3C-4A2F-B69E-EBF52AC76DCC@intel.com \
--to=keith.wiles@intel.com \
--cc=hom.sepanta@gmail.com \
--cc=users@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).