This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC PATCH, i386]: Deprecate -mmitigate-rop
- From: Uros Bizjak <ubizjak at gmail dot com>
- To: Jeff Law <law at redhat dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Jakub Jelinek <jakub at redhat dot com>
- Date: Wed, 15 Aug 2018 23:08:01 +0200
- Subject: Re: [RFC PATCH, i386]: Deprecate -mmitigate-rop
- References: <CAFULd4ZL-wa3wBaH4cNmvW=nxMYDgXtybinE4sg5EmsAgtasMA@mail.gmail.com> <584edd40-30c0-e564-5ac0-b4d53bb398fc@redhat.com>
On Wed, Aug 15, 2018 at 5:56 AM, Jeff Law <law@redhat.com> wrote:
> On 08/10/2018 05:42 AM, Uros Bizjak wrote:
>> This option is fairly ineffective, and in the light of CET, nobody
>> seems interested to improve it. Deprecate the option, so it won't lure
>> developers to the land of false security.
>>
>> 2018-08-10 Uros Bizjak <ubizjak@gmail.com>
>>
>> * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
>> * doc/invoke.texi (mmitigate-rop): Remove.
>> * config/i386/i386.c: Do not include "regrename.h".
>> (ix86_rop_should_change_byte_p, reg_encoded_number)
>> (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
>> Remove.
>> (ix86_reorg): Remove call to ix86_mitigate_rop.
>> * config/i386/i386.md (attr "modrm_class"): Remove.
>> (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor,
>> x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
>> (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
>>
>> testsuite/Changelog:
>>
>> 2018-08-10 Uros Bizjak <ubizjak@gmail.com>
>>
>> * gcc.target/i386/rop1.c: Remove.
>> * gcc.target/i386/pr83554 (dg-options): Remove -mmitigate-rop.
>>
>> Bootstrapped and regression tested on x86_64-linux-gnu {,-m32}.
>>
>> Any opinion against the deprecation?
> As I noted privately, Red Hat is no longer investing in this space due
> to the introduction of CET.
>
> I'll ack deprecation.
Thanks, I have committed the patch to mainline.
Uros.