This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, MPX runtime 1/2] Integrate MPX runtime library
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Ilya Enkovich <enkovich dot gnu at gmail dot com>
- Cc: Andi Kleen <andi at firstfloor dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 12 Nov 2014 23:03:23 +0000
- Subject: Re: [PATCH, MPX runtime 1/2] Integrate MPX runtime library
- Authentication-results: sourceware.org; auth=none
- References: <20141111153449 dot GB52080 at msticlxl57 dot ims dot intel dot com> <alpine dot DEB dot 2 dot 10 dot 1411111754330 dot 26374 at digraph dot polyomino dot org dot uk> <87r3x9a7yt dot fsf at tassilo dot jf dot intel dot com> <alpine dot DEB dot 2 dot 10 dot 1411112016450 dot 12642 at digraph dot polyomino dot org dot uk> <20141112160432 dot GA5697 at msticlxl57 dot ims dot intel dot com> <alpine dot DEB dot 2 dot 10 dot 1411122125170 dot 31875 at digraph dot polyomino dot org dot uk> <CAMbmDYamHxfspd6MXEbc+ZP7Psef+YtpTCL6RDnkoiMS35CAsA at mail dot gmail dot com>
On Thu, 13 Nov 2014, Ilya Enkovich wrote:
> It's hard to decide which of runtime functionality should be
> considered as basic and how it should be used. We may say that the
> only basic thing is hardware enabling which is enable_mpx and stop
> here. But then you get minimal but quite useless library. Yes, it
> can enable MPX and thus make bounds violation to interrupt a program.
> But users cannot enable/disable MPX dinamycally then. Also they
> cannot configure it. Thus either control via environmental variables
> appears in this core library or we transform initialization function
> from constructor to interface function and use it from another
> extended MPX library which support environment variables, logging etc.
> But the core library will only be used by this extended MPX library
> and nothing else. So why not to leave it as a single library as it is?
You can leave it as a single library - it's just that imposes libgcc-like
constraints on what the library does and how it does things, so as to be
usable for arbitrary programs built with MPX (e.g. using
reserved-namespace names such as __write when available - direct syscalls
may also be a possibility in some cases).
--
Joseph S. Myers
joseph@codesourcery.com