This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH][RFA/RFC] Stack clash mitigation patch 01/08
- From: Jeff Law <law at redhat dot com>
- To: Jakub Jelinek <jakub at redhat dot com>, Segher Boessenkool <segher at kernel dot crashing dot org>
- Cc: "gcc-patches at gcc dot gnu dot org >> gcc-patches" <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 14 Jul 2017 01:46:18 -0600
- Subject: Re: [PATCH][RFA/RFC] Stack clash mitigation patch 01/08
- Authentication-results: sourceware.org; auth=none
- Authentication-results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com
- Authentication-results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=law at redhat dot com
- Dkim-filter: OpenDKIM Filter v2.11.0 mx1.redhat.com DBAEA3B71F
- Dmarc-filter: OpenDMARC Filter v1.3.2 mx1.redhat.com DBAEA3B71F
- References: <93ce7fc1-e41e-282f-a574-234a83d57d7d@redhat.com> <20170713003157.GW13471@gate.crashing.org> <470c6af6-0c13-34fb-8ccb-7c31d24181f2@redhat.com> <20170713213201.GI13471@gate.crashing.org> <20170714074026.GX2123@tucnak>
On 07/14/2017 01:40 AM, Jakub Jelinek wrote:
> On Thu, Jul 13, 2017 at 04:32:02PM -0500, Segher Boessenkool wrote:
>> I don't think it should be inside -fstack-check at all. Sure, the
>> mechanisms implementing it overlap a bit (more on some targets, less
>> on others), but how will a user ask for clash protection _and_ for
>> stack checking?
>
> Are we willing to implement that? What would we do in that case?
I'd change every existing target that has a backend stack probing
implementatoin to use a moving-sp style. ie, allocate page, probe page,
allocate page, probe page. We'd then want to use the -fstack-check
routines rather than the new routines.
But in the end I don't think using the options together makes all that
much sense. We really should look at -fstack-check as Ada specific,
even though its implementation is in the target files and middle end.
Jeff