From nobody Thu May 16 22:48:05 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+110117+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+110117+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1698334211; cv=none; d=zohomail.com; s=zohoarc; b=UoDWFVeXJbENEN3X93FICnG6qMsoLk8omulOLSt58njBxcn1S9KrFObd+18KKHE1PK30T/FVvyxgoKplPH4HzOJRea5iFU+X2wdFjfxCWDK+4Fw2kNH3sk8IRZfzQ63kj2lZaJhTUry23HAspzyGAiblHs3tUw0V4L6T5kF/VfI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1698334211; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Reply-To:References:Sender:Subject:Subject:To:To:Message-Id; bh=aPoMEPPI9lFbHfMhMsguEeLY9tmDR8ASb2l1HzO7tTQ=; b=iY0jreOD932dudCyH+S4suXu6C7GkrpdrL9KheSly8EDJbrh0nLqosHDPQ2nyMsFZ4k5PPirtTP64dzp8359Xcmtf2lk6XyBINmw8MOmCt2UaoMwWEh/1bwqeVBTklW5oxhQYqNBkHvKacLh9B5uG58gf9TrEeqXiZgkYhHENTA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+110117+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1698334211308244.6115359749324; Thu, 26 Oct 2023 08:30:11 -0700 (PDT) Return-Path: DKIM-Signature: a=rsa-sha256; bh=//QzmYSgCZvxGYH92znFR5cmFevJ3kWD3FMHXPEi3z8=; c=relaxed/simple; d=groups.io; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding; s=20140610; t=1698334211; v=1; b=CnSPnOaEs3mOKzESZqH/JW/aEyIwcf0sxYQ1vsgVgqSKjcNXgNB36BGIvtDfclvBXDBalJxu oIKoyrCA/6r6C/WX5fixB2DXg2HZHWfbtvKNqSx5vENwIj6AFawRiDhrV2mKEeco1R2RXtKHQji cB9qVUA/dI9Ha1QzEgkY6paU= X-Received: by 127.0.0.2 with SMTP id P9FDYY1788612x9zLNXkL3do; Thu, 26 Oct 2023 08:30:11 -0700 X-Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.9]) by mx.groups.io with SMTP id smtpd.web10.203466.1698334210120130173 for ; Thu, 26 Oct 2023 08:30:10 -0700 X-IronPort-AV: E=McAfee;i="6600,9927,10875"; a="6197982" X-IronPort-AV: E=Sophos;i="6.03,253,1694761200"; d="scan'208";a="6197982" X-Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orvoesa101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Oct 2023 08:30:10 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10875"; a="875991311" X-IronPort-AV: E=Sophos;i="6.03,253,1694761200"; d="scan'208";a="875991311" X-Received: from njayapra-mobl.gar.corp.intel.com ([10.213.103.39]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Oct 2023 08:30:07 -0700 From: "Jayaprakash, N" To: devel@edk2.groups.io Cc: Jayaprakash N , Rebecca Cran , Michael D Kinney , Kloper Dimitry Subject: [edk2-devel] [edk2-libc Patch 1/1] ek2-libc: fix missing nanf definition in StdLib Date: Thu, 26 Oct 2023 20:59:59 +0530 Message-Id: <20231026152959.877-2-n.jayaprakash@intel.com> In-Reply-To: <20231026152959.877-1-n.jayaprakash@intel.com> References: <20231026152959.877-1-n.jayaprakash@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,n.jayaprakash@intel.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: a8ZHIdg9WPDhfceZulCMGa6Cx1787277AA= Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1698334213512100004 Content-Type: text/plain; charset="utf-8" REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D4576 File StdLib/Include/math.h:406 defines NAN constant as __nanf.__val. The problem is that __nanf is never defined. Fix is simple: define __nanf in similar way as __infinityf This fix has been provided through the below PR on edk2-libc repo https://github.com/tianocore/edk2-libc/pull/9. Cc: Rebecca Cran Cc: Michael D Kinney Cc: Jayaprakash N Signed-off-by: Kloper Dimitry --- StdLib/LibC/LibC.inf | 1 + StdLib/LibC/Main/nanf_ieee754.c | 15 +++++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 StdLib/LibC/Main/nanf_ieee754.c diff --git a/StdLib/LibC/LibC.inf b/StdLib/LibC/LibC.inf index ad6a117..93e32e8 100644 --- a/StdLib/LibC/LibC.inf +++ b/StdLib/LibC/LibC.inf @@ -34,6 +34,7 @@ Main/isnand_ieee754.c Main/isnanf_ieee754.c Main/infinityf_ieee754.c + Main/nanf_ieee754.c Main/Main.c Main/HtoNtoH.c Main/ByteSwap.c diff --git a/StdLib/LibC/Main/nanf_ieee754.c b/StdLib/LibC/Main/nanf_ieee75= 4.c new file mode 100644 index 0000000..8e56d32 --- /dev/null +++ b/StdLib/LibC/Main/nanf_ieee754.c @@ -0,0 +1,15 @@ +/* + * IEEE-compatible nanf.c -- public domain. + */ +#include +#include + +#include +#include + +const union __float_u __nanf =3D +#if BYTE_ORDER =3D=3D BIG_ENDIAN + { { 0x7f, 0xc0, 0, 0 } }; +#else + { { 0, 0, 0xc0, 0x7f } }; +#endif --=20 2.40.0.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#110117): https://edk2.groups.io/g/devel/message/110117 Mute This Topic: https://groups.io/mt/102202277/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-