From: Stephen Hemminger <stephen@networkplumber.org>
To: John Alexander <john.alexander@datapath.co.uk>
Cc: dmitry.kozliuk@gmail.com, navasile@linux.microsoft.com,
dmitrym@microsoft.com, pallavi.kadam@intel.com,
richard.smith@datapath.co.uk, dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH v2] eal/windows: Switched to an external pthreads library
Date: Wed, 14 Jun 2023 12:27:47 -0700 [thread overview]
Message-ID: <20230614122747.0e06ae5e@hermes.local> (raw)
In-Reply-To: <20200924114101.174-1-john.alexander@datapath.co.uk>
On Thu, 24 Sep 2020 12:41:01 +0100
John Alexander <john.alexander@datapath.co.uk> wrote:
> The Windows EAL build now pulls in the pthreads4w project as an external
> subproject. The pthreads4w subproject does not currently provide a
> meson build so the project has been patched with one.
>
> Removed the placeholder librte_eal\windows\include\pthread.h and sched.h
> header files as these are superseded by the pthreads4w implementation.
>
> rte_eal_init() in the Windows EAL has been modified to use
> pthread_create() and pthread_setaffinity_np() to setup the secondary
> lcores. eal_thread_create() has been removed as it is no longer
> required.
>
> rte_eal_init() in the Windows EAL now calls SetPriorityClass() to set
> the process class to real-time in a singular location.
>
> eal_thread_loop() in the Windows EAL now calls SetThreadPriority() to
> set the thread priority to real-time when the thread commences execution.
> This function now uses pthreads functions to test and compare pthread_t
> handles.
>
> Added the source file librte_eal\windows\windows_eal_impl.c. This source
> file serves as a location for the implementation of auxiliary
> functionality provided by the Windows EAL that would otherwise be provided
> by the UNIX runtime.
>
> Added the pthreads4w shared library as a dependency to EAL library builds
> for Windows builds only. The meson install step will install the
> pthreads4w.dll that is built by the meson external subproject build step.
> The shared library has been selected for both static and shared library
> builds to avoid constructior initialisation issues observed when using
> pthreads4w and static linkage within the DPDK project.
>
> Added the subprojects folder to the .gitignore file such that authored
> content is not ignored and downloaded content is ignored (as that's where
> meson stores the subprojects when they are cloned).
>
> Incremented the minimum meson version number to 0.55.0. This is required
> to use the subproject folder patch feature.
>
> Updated MAINTAINERS to reflect new additions.
>
> Signed-off-by: John Alexander <john.alexander@datapath.co.uk>
> ---
> .gitignore | 6 +
> MAINTAINERS | 3 +
> lib/librte_eal/windows/eal.c | 21 ++-
> lib/librte_eal/windows/eal_thread.c | 27 +---
> lib/librte_eal/windows/eal_windows.h | 10 --
> lib/librte_eal/windows/include/pthread.h | 146 ------------------
> lib/librte_eal/windows/include/rte_os.h | 15 +-
> lib/librte_eal/windows/include/sched.h | 92 -----------
> lib/librte_eal/windows/meson.build | 1 +
> lib/librte_eal/windows/windows_eal_impl.c | 53 +++++++
> lib/meson.build | 14 +-
> meson.build | 7 +-
> .../packagefiles/pthreads4w-meson/VERSION | 1 +
> .../packagefiles/pthreads4w-meson/meson.build | 49 ++++++
> subprojects/pthreads4w-code.wrap | 8 +
> 15 files changed, 178 insertions(+), 275 deletions(-)
> delete mode 100644 lib/librte_eal/windows/include/pthread.h
> delete mode 100644 lib/librte_eal/windows/include/sched.h
> create mode 100644 lib/librte_eal/windows/windows_eal_impl.c
> create mode 100644 subprojects/packagefiles/pthreads4w-meson/VERSION
> create mode 100644 subprojects/packagefiles/pthreads4w-meson/meson.build
> create mode 100644 subprojects/pthreads4w-code.wrap
This patch is really old by now.
The current windows port uses native windows threads in current code.
Supporting an external package is not necessary.
prev parent reply other threads:[~2023-06-14 19:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-24 11:41 John Alexander
2023-06-14 19:27 ` Stephen Hemminger [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=20230614122747.0e06ae5e@hermes.local \
--to=stephen@networkplumber.org \
--cc=dev@dpdk.org \
--cc=dmitry.kozliuk@gmail.com \
--cc=dmitrym@microsoft.com \
--cc=john.alexander@datapath.co.uk \
--cc=navasile@linux.microsoft.com \
--cc=pallavi.kadam@intel.com \
--cc=richard.smith@datapath.co.uk \
/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).