Commit Graph

57891 Commits

Author SHA1 Message Date
Chris Lattner e6c831deb2 Make diagnostic class explicit in the diag record instead of
implicit from its parenting.  Now that diag mapping is 
explicit, eliminate the fatal and extwarn classes.

llvm-svn: 69177
2009-04-15 16:56:26 +00:00
Chris Lattner 06a7f37265 don't infer diag class from parenting relations, make it an explicit field
in the record.

llvm-svn: 69176
2009-04-15 16:55:46 +00:00
Chris Lattner 1b595624a8 Tblgen now passes the default mapping explicitly, instead of having it
be tied to the diag class.  This requires an LLVM tree update.

llvm-svn: 69175
2009-04-15 16:44:12 +00:00
Chris Lattner 485626c5f5 add a bunch of files.
llvm-svn: 69174
2009-04-15 16:43:37 +00:00
Chris Lattner 4e7b579ecc include the default mapping in the clang diagnostic .inc files.
llvm-svn: 69173
2009-04-15 16:43:18 +00:00
Douglas Gregor 958dfc9bbd PCH support for string literals
llvm-svn: 69172
2009-04-15 16:35:07 +00:00
Daniel Dunbar a7b5e219bb Driver: Add --help-hidden
llvm-svn: 69171
2009-04-15 16:34:29 +00:00
Fariborz Jahanian f5e8ddd550 __objc_superrefs belongs to __DATA segment.
llvm-svn: 69170
2009-04-15 16:31:36 +00:00
Douglas Gregor 0253c83610 PCH support for UnaryOperator, SizeOfAlignOfExpr
llvm-svn: 69169
2009-04-15 15:58:59 +00:00
Anders Carlsson f747524819 Start attempting to generate code for C++ ctors.
llvm-svn: 69168
2009-04-15 15:55:24 +00:00
Steve Naroff 635168aa33 Fix <rdar://problem/6789707> "warning: 'extern' variable has an initializer" not correct for __private_extern__.
llvm-svn: 69167
2009-04-15 15:20:03 +00:00
Chris Lattner 5a8c8df08c rename variable in comment, not just in code :).
llvm-svn: 69166
2009-04-15 14:42:02 +00:00
Steve Naroff fab0262047 Fix <rdar://problem/6791490> [clang10 regression] [sema] invalid illegal jump diagnostic.
caused by: <rdar://problem/6252084> [sema] jumps into Obj-C exception blocks should be disallowed.

Sema::RecursiveCalcLabelScopes() and Sema::RecursiveCalcJumpScopes() need to pop the ScopeStack within the statement iteration loop (was outside the loop).

Eli, please review (thanks).

llvm-svn: 69165
2009-04-15 14:38:36 +00:00
Chris Lattner 9428a21067 this should be private
llvm-svn: 69158
2009-04-15 07:06:34 +00:00
Chris Lattner f5f049b548 add another sanity check for -Werror=xx
llvm-svn: 69157
2009-04-15 07:05:12 +00:00
Chris Lattner 5ea5dc8a3a add a missing &&
llvm-svn: 69156
2009-04-15 07:03:57 +00:00
Chris Lattner e9dba48684 fix a broken test, that passed for the wrong reason. Two wrongs make a right! :)
llvm-svn: 69155
2009-04-15 07:02:57 +00:00
Chris Lattner e007de3b9a Rejigger how -pedantic and -pedantic-errors work and their interaction
with other diagnostic mapping.  In the new scheme, -Wfoo or -Wno-foo or 
-Werror=foo all override the -pedantic options, and __extension__ 
robustly silences all extension diagnostics in their scope.

An added bonus of this change is that MAP_DEFAULT goes away, meaning that
per-diagnostic mapping information can now be stored in 2 bits, doubling
the density of the Diagnostic::DiagMapping array.  This also 
substantially simplifies Diagnostic::getDiagnosticLevel.

OTOH, this temporarily introduces some "macro intensive" code in 
Diagnostic.cpp.  This will be addressed in a later patch.

llvm-svn: 69154
2009-04-15 07:01:18 +00:00
Douglas Gregor d5846a1eb5 Implement support for designated initializers that refer to members of
anonymous structs or unions. Fixes PR3778.

llvm-svn: 69153
2009-04-15 06:41:24 +00:00
Chris Lattner 3dfaeeaefc minor cleanups
llvm-svn: 69152
2009-04-15 06:26:49 +00:00
Nick Lewycky 4a7bcf6410 Limit the number of times we're willing to chase pointers. Removes an O(n^2)
problem from instcombine.

llvm-svn: 69151
2009-04-15 06:23:41 +00:00
Anders Carlsson e4c40c8baf Add support for mangling C++ constructors. Review appreciated (I'm looking at you, Doug)
llvm-svn: 69150
2009-04-15 05:36:58 +00:00
Chris Lattner 28bb15f16d make default diagnostic mapping more explicit in .td file.
llvm-svn: 69149
2009-04-15 05:15:08 +00:00
Chris Lattner ce682d9ea5 remove some commented out -Wstrict-selector-match stuff.
llvm-svn: 69148
2009-04-15 04:57:48 +00:00
Douglas Gregor a532416d39 Switch designated-initializer checking from using designator iterators
to using designator indices. No functionality change.

llvm-svn: 69147
2009-04-15 04:56:10 +00:00
Douglas Gregor 534b6f27a0 Don't tip-to around BitstreamReader::JumpToBit jumping to the end of the stream. LLVM has been updated to allow this
llvm-svn: 69146
2009-04-15 04:54:29 +00:00
Douglas Gregor 0da0f22545 Allow jumping to the end of a bitstream while reading
llvm-svn: 69145
2009-04-15 04:53:47 +00:00
Chris Lattner 8a1dc20756 clean up error messages.
llvm-svn: 69142
2009-04-15 04:51:48 +00:00
Chris Lattner 00364c38d7 add Diagnostic.td to proj
llvm-svn: 69141
2009-04-15 04:51:29 +00:00
Bill Wendling 066b8023a4 Check for alignment.
llvm-svn: 69140
2009-04-15 04:51:05 +00:00
Chris Lattner 384a59cac1 Add support for -Werror=foo and -Wno-error=foo
llvm-svn: 69138
2009-04-15 04:37:12 +00:00
Anders Carlsson 375d6beb6c Add CGCXX.h with ctor/dtor type enumerations. No functionality change.
llvm-svn: 69137
2009-04-15 04:36:55 +00:00
Chris Lattner 4c73b67efb refactor a bunch of the warning parsing stuff to simplify it. This removes the
-Wfoo=ignore syntax.  GCC supports -Wno-foo, no need to invent our own stuff.

llvm-svn: 69136
2009-04-15 04:27:38 +00:00
Chris Lattner e94e13ca35 remove #include of system header, making this a) not apple specific, and
b) test dramatically faster.

llvm-svn: 69135
2009-04-15 04:26:10 +00:00
Anders Carlsson c483bd0724 Simplify CodeGenFunction::GenerateCode.
llvm-svn: 69134
2009-04-15 04:10:19 +00:00
Zhongxing Xu 55b6908f00 remove dead code.
llvm-svn: 69133
2009-04-15 03:36:15 +00:00
Daniel Dunbar b25452a98e Tweaks to Objective-C metadata (32 & 64-bit) to match llvm-gcc.
- Set alignment on property lists.
 - 32-bit:
   o Set section on property lists.
   o Fix section name for category class methods.
   o Fix symbol name for property lists.
   o Fix section name for class method.
   o Set alignment and section on class extension structure.
   o Set alignment on a number of things: instance variables, methods,
   method descriptions, the symbols structure.
 - 64-bit:
   o Fix section flags for protocol list.

I doubt most of these were problems in practice, but it is nice to
match llvm-gcc.

llvm-svn: 69132
2009-04-15 02:56:18 +00:00
Daniel Dunbar 2edd923c90 Driver: For clang, accept -fsigned-bitfields and reject
-funsigned-bitfields for now (clang defaults to -fsigned-bitfields).
 - <rdar://problem/6790309> ER: Support
   -fsigned-bitfields/-funsigned-bitfields

llvm-svn: 69131
2009-04-15 02:37:43 +00:00
Bill Wendling 64602b1ed6 More obsessive reformatting. Fixed some validation errors.
llvm-svn: 69130
2009-04-15 02:12:37 +00:00
Dan Gohman 3fea040c19 Don't use "protected:" in classes that aren't intended to be
subclassed.

llvm-svn: 69129
2009-04-15 01:47:03 +00:00
Dan Gohman 19e7a32457 Fix doxygen comment syntax.
llvm-svn: 69128
2009-04-15 01:44:07 +00:00
Dan Gohman 6f873b446a Fix X86MachineFunctionInfo's doxygen comment.
llvm-svn: 69127
2009-04-15 01:20:18 +00:00
Dan Gohman 210448c233 Move MachineRegisterInfo::setRegClass out of line.
llvm-svn: 69126
2009-04-15 01:19:35 +00:00
Dan Gohman 505065cdd0 Move MachineJumpTableInfo::ReplaceMBBInJumpTables out of line.
llvm-svn: 69125
2009-04-15 01:18:49 +00:00
Dan Gohman 89892b05c7 Give RemoveRegOperandFromRegInfo a comment and move the
code out of line.

llvm-svn: 69124
2009-04-15 01:17:37 +00:00
Dale Johannesen 7ffb7d5728 Enhance induction variable code to remove the
sext around sext(shorter IV + constant), using a
longer IV instead, when it can figure out the
add can't overflow.  This comes up a lot in
subscripting; mainly affects 64 bit.

llvm-svn: 69123
2009-04-15 01:10:12 +00:00
Evan Cheng ffb83a155e Avoid making the transformation enabled by my last patch if the new destinations have phi nodes.
llvm-svn: 69121
2009-04-15 00:43:54 +00:00
Douglas Gregor 67fdb085b9 PCH support for CStyleCastExpr and BinaryOperator expression kinds.
llvm-svn: 69119
2009-04-15 00:25:59 +00:00
Devang Patel 046bf624b9 While inlining, clone llvm.dbg.func.start intrinsic and adjust
llvm.dbg.region.end instrinsic. This nested llvm.dbg.func.start/llvm.dbg.region.end pair now enables DW_TAG_inlined_subroutine support in code generator.

llvm-svn: 69118
2009-04-15 00:17:06 +00:00
Chris Lattner 0813c0c34c silence a warning.
llvm-svn: 69117
2009-04-15 00:16:05 +00:00