This is the mail archive of the
mailing list for the GCC project.
Re: [GSoC][match-and-simplify] sanitize option checking
- From: Richard Biener <richard dot guenther at gmail dot com>
- To: Prathamesh Kulkarni <bilbotheelffriend at gmail dot com>
- Cc: Diego Novillo <dnovillo at google dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Maxim Kuvyrkov <maxim dot kuvyrkov at linaro dot org>
- Date: Mon, 28 Jul 2014 12:09:09 +0200
- Subject: Re: [GSoC][match-and-simplify] sanitize option checking
- Authentication-results: sourceware.org; auth=none
- References: <CAJXstsB=f5g7g4R=MWZ2Xd=Fg=k7r--JGQuHssDnmxfdkUjMfQ at mail dot gmail dot com>
On Sun, Jul 27, 2014 at 10:45 PM, Prathamesh Kulkarni
> Added checks to see if either cmmand-line options is not repeated,
> and generates match-and-simplify code on both GENERIC and GIMPLE
> if both -generic and -gimple are specified.
I don't think we want to do this - in GCC earlier options are just overridden.
So passing multiple copies is fine.
Code-generation for both GIMPLE and GENERIC off one invocation of
genmatch doesn't work as you get the wrong macro predefined.
> * genmatch.c (cmd_options): New struct.
> (check_repeated_arg): New function.
> (parse_cmd_arg): Likewise.
> (main): Emit diagnostic if no command line options are given.
> Add call to parse_cmd_arg.