Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/125785/?format=api
http://patches.dpdk.org/api/patches/125785/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/1680638847-26430-3-git-send-email-roretzla@linux.microsoft.com/", "project": { "id": 1, "url": "http://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<1680638847-26430-3-git-send-email-roretzla@linux.microsoft.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1680638847-26430-3-git-send-email-roretzla@linux.microsoft.com", "date": "2023-04-04T20:07:20", "name": "[v2,2/9] eal: use rtm and xtest intrinsics when compiling with msvc", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "792d8fe49990056829662ecb3d6ccd6f8fb0ec60", "submitter": { "id": 2077, "url": "http://patches.dpdk.org/api/people/2077/?format=api", "name": "Tyler Retzlaff", "email": "roretzla@linux.microsoft.com" }, "delegate": { "id": 1, "url": "http://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/1680638847-26430-3-git-send-email-roretzla@linux.microsoft.com/mbox/", "series": [ { "id": 27622, "url": "http://patches.dpdk.org/api/series/27622/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=27622", "date": "2023-04-04T20:07:18", "name": "msvc integration changes", "version": 2, "mbox": "http://patches.dpdk.org/series/27622/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/125785/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/125785/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@inbox.dpdk.org", "Delivered-To": "patchwork@inbox.dpdk.org", "Received": [ "from mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 7FAB9428BC;\n\tTue, 4 Apr 2023 22:07:37 +0200 (CEST)", "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 090A341141;\n\tTue, 4 Apr 2023 22:07:32 +0200 (CEST)", "from linux.microsoft.com (linux.microsoft.com [13.77.154.182])\n by mails.dpdk.org (Postfix) with ESMTP id C64D140EE3\n for <dev@dpdk.org>; Tue, 4 Apr 2023 22:07:29 +0200 (CEST)", "by linux.microsoft.com (Postfix, from userid 1086)\n id 0E01B210DEA0; Tue, 4 Apr 2023 13:07:28 -0700 (PDT)" ], "DKIM-Filter": "OpenDKIM Filter v2.11.0 linux.microsoft.com 0E01B210DEA0", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com;\n s=default; t=1680638849;\n bh=aVNgvOGAqJXcMymeeUabNQLNbDPaZZ1fFdt0Ib9Ah9I=;\n h=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n b=AEgRMKMclF23hchMIM+uy3Je8RW6FQIESWswlt98zV1fKDK4ccIlPDNpe7ySGt+yV\n ee123EyH5BsEkGFHmFvl0ItylgRirB5EQh+B8se5JMJ0A19n3MXKOYG8Bt7kh/faHF\n faIdX9gJVohtgD8sxf4wmhVkv/8+BBRINUPIyAhM=", "From": "Tyler Retzlaff <roretzla@linux.microsoft.com>", "To": "dev@dpdk.org", "Cc": "bruce.richardson@intel.com, david.marchand@redhat.com,\n thomas@monjalon.net,\n mb@smartsharesystems.com, konstantin.ananyev@huawei.com,\n Tyler Retzlaff <roretzla@linux.microsoft.com>", "Subject": "[PATCH v2 2/9] eal: use rtm and xtest intrinsics when compiling with\n msvc", "Date": "Tue, 4 Apr 2023 13:07:20 -0700", "Message-Id": "<1680638847-26430-3-git-send-email-roretzla@linux.microsoft.com>", "X-Mailer": "git-send-email 1.8.3.1", "In-Reply-To": "<1680638847-26430-1-git-send-email-roretzla@linux.microsoft.com>", "References": "<1680558751-17931-1-git-send-email-roretzla@linux.microsoft.com>\n <1680638847-26430-1-git-send-email-roretzla@linux.microsoft.com>", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.29", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org" }, "content": "Inline assembly is not supported for msvc x64 instead use _xbegin,\n_xend, _xabort and _xtest intrinsics.\n\nSigned-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>\n---\n lib/eal/x86/include/rte_rtm.h | 19 +++++++++++++++++++\n 1 file changed, 19 insertions(+)", "diff": "diff --git a/lib/eal/x86/include/rte_rtm.h b/lib/eal/x86/include/rte_rtm.h\nindex 36bf498..26672cb 100644\n--- a/lib/eal/x86/include/rte_rtm.h\n+++ b/lib/eal/x86/include/rte_rtm.h\n@@ -5,6 +5,9 @@\n #ifndef _RTE_RTM_H_\n #define _RTE_RTM_H_ 1\n \n+#ifdef RTE_TOOLCHAIN_MSVC\n+#include <immintrin.h>\n+#endif\n \n /* Official RTM intrinsics interface matching gcc/icc, but works\n on older gcc compatible compilers and binutils. */\n@@ -28,31 +31,47 @@\n static __rte_always_inline\n unsigned int rte_xbegin(void)\n {\n+#ifndef RTE_TOOLCHAIN_MSVC\n \tunsigned int ret = RTE_XBEGIN_STARTED;\n \n \tasm volatile(\".byte 0xc7,0xf8 ; .long 0\" : \"+a\" (ret) :: \"memory\");\n \treturn ret;\n+#else\n+\treturn _xbegin();\n+#endif\n }\n \n static __rte_always_inline\n void rte_xend(void)\n {\n+#ifndef RTE_TOOLCHAIN_MSVC\n \t asm volatile(\".byte 0x0f,0x01,0xd5\" ::: \"memory\");\n+#else\n+\t_xend();\n+#endif\n }\n \n /* not an inline function to workaround a clang bug with -O0 */\n+#ifndef RTE_TOOLCHAIN_MSVC\n #define rte_xabort(status) do { \\\n \tasm volatile(\".byte 0xc6,0xf8,%P0\" :: \"i\" (status) : \"memory\"); \\\n } while (0)\n+#else\n+#define rte_xabort(status) _xabort(status)\n+#endif\n \n static __rte_always_inline\n int rte_xtest(void)\n {\n+#ifndef RTE_TOOLCHAIN_MSVC\n \tunsigned char out;\n \n \tasm volatile(\".byte 0x0f,0x01,0xd6 ; setnz %0\" :\n \t\t\"=r\" (out) :: \"memory\");\n \treturn out;\n+#else\n+\treturn _xtest();\n+#endif\n }\n \n #ifdef __cplusplus\n", "prefixes": [ "v2", "2/9" ] }{ "id": 125785, "url": "