From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qv1-xf2a.google.com (mail-qv1-xf2a.google.com [IPv6:2607:f8b0:4864:20::f2a]) by sourceware.org (Postfix) with ESMTPS id 5B20A3857835 for ; Thu, 11 Nov 2021 18:51:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 5B20A3857835 Received: by mail-qv1-xf2a.google.com with SMTP id b17so4647057qvl.9 for ; Thu, 11 Nov 2021 10:51:40 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=v2f3EQrrxjH6PMB1PY2UB0C66GqQSMAp9dXbcxov9ps=; b=YcAZa4rOAjGohXbCk8yee8l0MPbhc9oBaU9TkowBYedwtAkL/7cYdov/Wrccc9nuey hZpPqrJRD0BXGaY5KrODhOCtTwNNeNau6r9Lv2qx4A4IBFBcDJk4ItJkZcceA0k4Lx5V sBHsumqR7EBrv/Xs/XV/ItbQJJRqdmRUyaTw3mfSU8VyqYX2r5C0+RjqAkbuFu3U05hp vphxM9mit5LACGGAV43G6LvIIrY2i16/16NwmwydH0p/26kqSpCOjygxtPX6Dqh9/0mn v6cECoHJE3wqouDHu0vopi5W8yZZyYCDpZfXewFh9QJ+10iPsSOvkFSlM1rVecpEoESu uwRw== X-Gm-Message-State: AOAM533JZSrttFQSNiL+VcEjDneu8fhWKwfrGH4WS+RGlsmOWfLwanpd GBcIeCG6M1SKw0YKt0kGIs1Bo6zd4651CHuJaT4= X-Google-Smtp-Source: ABdhPJx5fy/fEMTsrpfrd/uJGq26H/TFHN1C7PDHiU0RS5Qe1JOaf55XHXIAcUp6AB8Q1cax1DC7X6cQ2opRZQsNKxc= X-Received: by 2002:a05:6214:2a45:: with SMTP id jf5mr8884903qvb.15.1636656699848; Thu, 11 Nov 2021 10:51:39 -0800 (PST) MIME-Version: 1.0 References: <20211110030726.2468302-1-skpgkp2@gmail.com> <20211110030726.2468302-6-skpgkp2@gmail.com> <20211111103931.GY1982710@arm.com> In-Reply-To: From: Sunil Pandey Date: Thu, 11 Nov 2021 10:51:04 -0800 Message-ID: Subject: Re: [PATCH 5/6] x86-64: Add pow/powf to libmvec microbenchmark To: Szabolcs Nagy Cc: Joseph Myers , andrey.kolesov@intel.com, GNU C Library X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, HK_RANDOM_ENVFROM, HK_RANDOM_FROM, HTML_MESSAGE, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Nov 2021 18:51:41 -0000 Purpose of the libmvec microbenchmark test is to evaluate work path performance reliably, not to cover as much input range as possible. On Thu, Nov 11, 2021 at 9:40 AM Sunil Pandey wrote: > > > On Thu, Nov 11, 2021 at 2:39 AM Szabolcs Nagy > wrote: > >> The 11/10/2021 19:31, Sunil Pandey via Libc-alpha wrote: >> > On Wed, Nov 10, 2021 at 12:27 PM Joseph Myers >> > wrote: >> > >> > > On Tue, 9 Nov 2021, Sunil K Pandey via Libc-alpha wrote: >> > > >> > > > +# Random inputs in [a=3D0.01,b=3D100.00], [c=3D0.01,d=3D10.00] >> > > >> > > I think there should be a reasonable proportion of negative exponent= s, >> > > unless you have evidence that negative exponents are rarely used in >> > > practice. (The *first* argument of pow being negative is of use >> (produces >> > > finite results) in much more limited cases, so may well be much >> rarer.) >> > > >> > >> > Negative exponents not used in the input file to avoid denormal >> > processing. Negative >> > exponent >> > may hit the underflow domain when pow(x, -y) produces denormals as >> results >> > or as intermediate >> > values. Both going to touch very slow special pow() path and invokes >> Intel >> > software assist for >> > denormals processing. All of this will distort the overall performance >> > result of the main path. >> > Also the base argument should be small so that it doesn=E2=80=99t prod= uce >> denormals. >> >> i'd expect typical negative exponents would not >> cause subormal computations. >> >> does powf(100, -10) have intermediate underflow >> with the x86 libmvec code? >> > > It may cause intermediate underflow for single precision function, becaus= e > result > get quite close to the underflow domain and intermediate values may be > even smaller. >