On Apr 1, 2012, at 4:47 PM, David Blaikie wrote: > On Sun, Apr 1, 2012 at 4:03 PM, Bob Wilson <[email protected]> wrote: >> Author: bwilson >> Date: Sun Apr 1 18:03:29 2012 >> New Revision: 153854 >> >> URL: http://llvm.org/viewvc/llvm-project?rev=153854&view=rev >> Log: >> Ignore unused --serialize-diagnostics option when using llvm-gcc. >> >> llvm-gcc doesn't handle --serialize-diagnostics so when compiling i386 >> kernel/kext code with -Werror, you get an error about that option being >> unused. Claim the argument to prevent this from breaking builds. >> <rdar://problem/11161933> >> >> Modified: >> cfe/trunk/lib/Driver/Tools.cpp >> >> Modified: cfe/trunk/lib/Driver/Tools.cpp >> URL: >> http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=153854&r1=153853&r2=153854&view=diff >> ============================================================================== >> --- cfe/trunk/lib/Driver/Tools.cpp (original) >> +++ cfe/trunk/lib/Driver/Tools.cpp Sun Apr 1 18:03:29 2012 >> @@ -3619,6 +3619,9 @@ >> >> assert(Inputs.size() == 1 && "Unexpected number of inputs!"); >> >> + // Silence warning about unused --serialize-diagnostics >> + Args.ClaimAllArgs(options::OPT__serialize_diags); > > Should this be in the big table at Tools.cpp:3208?
I'm hardly an expert on the driver, but no, I don't think so. That big table is a list of cc1 options that are not supported by llvm-gcc and need to be filtered out of the cc1 command line. This is for a driver option that is never passed to cc1 regardless. It doesn't need to be filtered out -- it just needs to be claimed to avoid unwanted warnings. _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
