public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Oliver Smith-Denny" <osde@linux.microsoft.com>
To: devel@edk2.groups.io, ardb@kernel.org
Cc: Leif Lindholm <quic_llindhol@quicinc.com>,
	Sami Mujawar <sami.mujawar@arm.com>,
	Michael Kinney <michael.d.kinney@intel.com>,
	Liming Gao <gaoliming@byosoft.com.cn>,
	Zhiguang Liu <zhiguang.liu@intel.com>
Subject: Re: [edk2-devel] [RFC] Move CompilerIntrinsicsLib and ArmSoftFloatLib to MdePkg
Date: Mon, 5 Aug 2024 09:18:47 -0700	[thread overview]
Message-ID: <848549c2-2ef4-4692-bf90-bbca25c3ffba@linux.microsoft.com> (raw)
In-Reply-To: <CAMj1kXHUatMsCcu+mATfPGgs01tK0wpsJri8rOAs1f8CXyd2mQ@mail.gmail.com>

On 8/2/2024 1:46 AM, Ard Biesheuvel wrote:
> On Fri, 2 Aug 2024 at 00:39, Oliver Smith-Denny
> <osde@linux.microsoft.com> wrote:
>>
>> CompilerIntrinsicsLib and ArmSoftFloatLib add ARM/AARCH64 compiler
>> intrinsics and floating point functions required by OpenSSL,
>> respectively. CompilerIntrinsicsLib is used almost in every DSC that
>> builds ARM/AARCH64 and ArmSoftFloatLib is used by every DSC that builds
>> logic from OpenSSL.
> 
> What's even worse: OpenSSL doesn't really use floating point at all -
> the only reason we need this is because there is some global double_t
> somewhere that records entropy or somesuch, but IIRC that code is not
> actually used.
> 
> So perhaps we could add a hack in OpensslLib to work around this in
> one way or another for ARM only, and get rid of SoftFloatLib
> altogether.

I took a quick look at this. Unfortunately, I don't think this is
trivial. There are some uses of doubles within OpenSSL and it
doesn't look like we can just not build part of it, because
the first error I hit is that crypto/params.c uses fp operations:
https://github.com/openssl/openssl/blob/de90e54bbe82e5be4fb9608b6f5c308bb837d355/crypto/params.c#L762
and this provides a lot of definitions for other OpenSSL code. A
quick search turns up a number of other instances, so for now I will
go with moving the submodule, unless you want to take a look at
OpenSSL.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#120237): https://edk2.groups.io/g/devel/message/120237
Mute This Topic: https://groups.io/mt/107675828/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



  parent reply	other threads:[~2024-08-05 16:18 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-01 22:39 [edk2-devel] [RFC] Move CompilerIntrinsicsLib and ArmSoftFloatLib to MdePkg Oliver Smith-Denny
2024-08-01 22:49 ` Michael D Kinney
2024-08-01 22:51   ` Oliver Smith-Denny
2024-08-02  8:46 ` Ard Biesheuvel
2024-08-02 15:41   ` Michael D Kinney
2024-08-05 16:18   ` Oliver Smith-Denny [this message]
2024-08-05 10:13 ` Leif Lindholm
2024-08-05 16:20   ` Oliver Smith-Denny

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-list 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=848549c2-2ef4-4692-bf90-bbca25c3ffba@linux.microsoft.com \
    --to=devel@edk2.groups.io \
    /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