[cfe-dev] notes without warnings and a question to -cc1

Olaf Krzikalla Olaf.Krzikalla at tu-dresden.de
Fri Mar 25 09:25:55 PDT 2011


Hi @clang,

sometimes I'd like to issue some notes just at the start of compilation. 
However while there is "Diagnostic::setLastDiagnosticIgnored", there is 
no similiar function for other diagnostic levels. Thus for the moment I 
have to issue warnings instead of notes. Granted, it is a cosmetical 
issue only, but IMHO it can be easily fixed by introducing a 
"Diagnostic::setLastDiagnosticNote" or similar. I don't see any harm in 
introducing such a function.

The second question is related to the available options in normal and 
-cc1 mode. Actually I call

CompilerInvocation::CreateFromArgs(...);

to get a compiler invocation.
But CreateFromArgs uses the cc1 option table hard-coded and thus I can't 
pass options like "-msse2" to the compiler. This in turn forbids the 
handling of files which includes <xmmintrin.h> and similiar headers.
Is there a reason for using the cc1 option table there and is it 
possible to change it so that it is optionally possible to use the 
driver option table instead?


Thanks in advance and best regards
Olaf Krzikalla



More information about the cfe-dev mailing list