From patchwork Fri Feb 16 14:54:32 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Eremin-Solenikov X-Patchwork-Id: 128596 Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp646413ljc; Fri, 16 Feb 2018 06:54:43 -0800 (PST) X-Google-Smtp-Source: AH8x227ACwn60IbZhCXP7pjWo5Ohod45XdvRZOpyP0fmK8YU3GP2gxp5S3NkFmsT0leYYbtSDLoy X-Received: by 10.55.21.139 with SMTP id 11mr2916214qkv.127.1518792883641; Fri, 16 Feb 2018 06:54:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518792883; cv=none; d=google.com; s=arc-20160816; b=C1a/uIUvKO4cAYioDJhUBRvvucWzzMDsnR1+lRR49jYQO1fd7bOZfTGZhozYazd+HY w9DMArKTa/+JHj5+Dt1PKR1zavidzgL0LX/0JWT2FYY+9YKn1IgXvPLgPZKJnGjh7mJU WLtP/iJ+7BmwF3jJkVH0TTkDaPIKa/NUmI2GfidB85FeUG8eBhtGLUEucNvldGTeKdqq 5m0nWSGftBkTlvAil9CvEZmqRi5k0Li9R5aYlBCjOgR7j1u437VrfQe2zS5ucvfSohIx 8j4BTgAS9Hl8t4NSR5ME22doIqV5JpnOgvn0p22fke6/S9+DD853AokCltLWLNHMq+Ns ZBww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:content-language:mime-version:user-agent :date:message-id:from:to:delivered-to:arc-authentication-results; bh=Sey14rzJE1oebTw6EDBvYCVV95bogy7yHI+7Q6jQB3Y=; b=D69HcIWtPAwUQivuHotNI5Tg1IGJc+xisrZE3gR7RjpOjDPTrDqwG2RO5ttLH7TGTj tuf6J9ug7E40OKYCkjDuFDEoN3r0luMpYIx2Z1jhx9V/nHK9PVtqBYa29+HMEQIMC+68 s9AROunhg+LJBrfer7qkuo/nfXXEkQF8iTDaWQ3sz2Mdj2KN1rsZ7M8jQ+B8D72ePom7 c43EY5c12xzvPbcgub/4XVyEzF27AiZDDPZn7yvwnI5uwHHU9VgJh8dtLO3jdkv7zTaO tEOdaHdhJ5986zj9PsPVP3xcBocAA0KbRSiKma4o/Cp0Pb2ZBlFLvsedCm9/tFAzfO+e ii5Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.linaro.org (ec2-54-197-127-237.compute-1.amazonaws.com. [54.197.127.237]) by mx.google.com with ESMTP id f6si249000qkc.289.2018.02.16.06.54.43; Fri, 16 Feb 2018 06:54:43 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) client-ip=54.197.127.237; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 431396170D; Fri, 16 Feb 2018 14:54:43 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id D182F616E5; Fri, 16 Feb 2018 14:54:39 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 00EF861701; Fri, 16 Feb 2018 14:54:37 +0000 (UTC) Received: from mail-lf0-f53.google.com (mail-lf0-f53.google.com [209.85.215.53]) by lists.linaro.org (Postfix) with ESMTPS id 1ABD2609A8 for ; Fri, 16 Feb 2018 14:54:37 +0000 (UTC) Received: by mail-lf0-f53.google.com with SMTP id t79so4414060lfe.3 for ; Fri, 16 Feb 2018 06:54:37 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-language:content-transfer-encoding; bh=Sey14rzJE1oebTw6EDBvYCVV95bogy7yHI+7Q6jQB3Y=; b=Tmhs9Ofwulp82HmJYJKyvzBLdC98Uy2RPOKHMn1clpril4Fci6NIhj4el+0JK8rqqK Sdg400CKRqtphrEEb2kXlmModL4OV56fnH3gMyMtUULZ72jrwhXn+OhVQ4Js/kFi3z72 KIPWXj6LOHtPmPkymE4lNn3z+TE3g8J+Ba6LJzB5mRIyCtmqa5WNnHo04mBpdAk37TAc +0JZWpPIbdjx+UO+I8goswjfL8fGHRnynxuHdmJe4/LW5wi1KltoNnP/avWuFGhpy6uh tqxoI+sLAwjxcg10QQqpGMb5sLdR5536u6KqHkj+uD78GNLCxfTtg+EUCeEzNelwC2YN 5jBw== X-Gm-Message-State: APf1xPATkAQhi8+zkRn8tuz8MUgPZeflF3cn2btYifu7MQFNjKlKfEas qkDOIyw3rpPGD66A+EufFltm/vTQpIcj9A== X-Received: by 10.46.70.18 with SMTP id t18mr4585715lja.41.1518792874345; Fri, 16 Feb 2018 06:54:34 -0800 (PST) Received: from [10.0.0.11] ([188.162.65.178]) by smtp.gmail.com with ESMTPSA id n2sm803743lfg.39.2018.02.16.06.54.33 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Feb 2018 06:54:33 -0800 (PST) To: lng-odp-forward From: Dmitry Eremin-Solenikov Message-ID: Date: Fri, 16 Feb 2018 17:54:32 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Language: en-GB Subject: [lng-odp] Clang + AArch64 + non-ABI workaround X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Hello, I've been debugging the Clang/AArch64/non-ABI case during this week. It indeed is a compiler issue. Here is a workaround, which fixes the issue for at least clang 7 (did not try with earlier versions, probably it would also help). At this moment I do not think we should apply this fix, but rather declare this combination as not supported. Our code is perfectly valid from my POV. burst = ring_deq_multi(ring, mask, data, burst); -- With best wishes Dmitry diff --git a/platform/linux-generic/odp_pool.c b/platform/linux-generic/odp_pool.c index e5ba8982a29a..a97d096d1a53 100644 --- a/platform/linux-generic/odp_pool.c +++ b/platform/linux-generic/odp_pool.c @@ -727,12 +727,13 @@ int buffer_alloc_multi(pool_t *pool, odp_buffer_hdr_t *buf_hdr[], int max_num) buf_hdr[i] = buf_hdr_from_index(pool, cache->buf_index[j]); } - /* If needed, get more from the global pool */ - if (odp_unlikely(num_deq)) { /* Temporary copy needed since odp_buffer_t is uintptr_t * and not uint32_t. */ uint32_t data[burst]; + /* If needed, get more from the global pool */ + if (odp_unlikely(num_deq)) { + ring = &pool->ring->hdr; mask = pool->ring_mask;