Commit Graph

51428 Commits

Author SHA1 Message Date
Misha Brukman f845ef79f3 CSS cleanup:
* Lowercased all HTML element names
* Standardized spacing around { and }
* removed class "doc_table_nw": grep finds no uses

llvm-svn: 61004
2008-12-14 07:20:36 +00:00
Zhongxing Xu b0cc30ddb4 I think we should getRValueType here. The lvaluetype of an array region is 'pointer to array'.
llvm-svn: 61003
2008-12-14 03:14:52 +00:00
Ted Kremenek d2f9cd1cbd Updated checker build.
llvm-svn: 61002
2008-12-14 01:25:59 +00:00
Bill Wendling e5af6f1990 Temporarily revert r60997. It was causing this failure:
Running /Users/void/llvm/llvm.src/test/CodeGen/Generic/dg.exp ...
FAIL: /Users/void/llvm/llvm.src/test/CodeGen/Generic/asm-large-immediate.ll
Failed with exit(1) at line 1
while running:  llvm-as < /Users/void/llvm/llvm.src/test/CodeGen/Generic/asm-large-immediate.ll |  llc | /usr/bin/grep 68719476738
Assertion failed: ((TypesNeedLegalizing || getTypeAction(VT) == Legal) && "Illegal type introduced after type legalization?"), function HandleOp, file /Users/void/llvm/llvm.src/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp, line 493.
0   llc               0x0085392e char const* std::find<char const*, char>(char const*, char const*, char const&) + 98
1   llc               0x00853e63 llvm::sys::PrintStackTraceOnErrorSignal() + 593
2   libSystem.B.dylib 0x96cac09b _sigtramp + 43
3   libSystem.B.dylib 0xffffffff _sigtramp + 1765097359
4   libSystem.B.dylib 0x96d24ec2 raise + 26
5   libSystem.B.dylib 0x96d3447f abort + 73
6   libSystem.B.dylib 0x96d26063 __assert_rtn + 101
7   llc               0x004f9018 llvm::cast_retty<llvm::SubprogramDesc, llvm::DebugInfoDesc*>::ret_type llvm::cast<llvm::Sub
...

llvm-svn: 61001
2008-12-13 23:53:00 +00:00
Anders Carlsson 6b958f9634 Store the size of the EH stack inside each BreakContinue struct so we know when a break/continue won't cross a try block.
llvm-svn: 60998
2008-12-13 22:52:24 +00:00
Duncan Sands 24092271cc LegalizeDAG is not supposed to introduce illegal
types into the DAG if they were not already there.
Check this with an assertion.

llvm-svn: 60997
2008-12-13 22:33:38 +00:00
Fariborz Jahanian b1378f9b0f Patch for ObjCIvarRefExpr containing the field
matching the storage layout for this ivar

llvm-svn: 60996
2008-12-13 22:20:28 +00:00
Ted Kremenek b5670fd555 MemRegion:
- Overhauled the notion of "types" for TypedRegions.  We now distinguish between the "lvalue" of a region (via getLValueRegion()) and the "rvalue" of a region (va getRValueRegion()).  Since a region represents a chunk of memory it has both, but we were conflating these concepts in some cases, leading to some insidious bugs.
- Removed AnonPointeeType, partially because it is unused and because it doesn't have a clear notion of lvalue vs rvalue type.  We can add it back once there is a need for it and we can resolve its role with these concepts.

StoreManager:
- Overhauled StoreManager::CastRegion.  It expects an *lvalue* type for a region.  This is actually what motivated the overhaul to the MemRegion type mechanism.  It also no longer returns an SVal; we can just return a MemRegion*.
- BasicStoreManager::CastRegion now overlays an "AnonTypedRegion" for pointer-pointer casts.  This matches with the MemRegion changes.
- Similar changes to RegionStore, except I've added a bunch of FIXMEs where it wasn't 100% clear where we should use TypedRegion::getRValueRegion() or TypedRegion::getLValueRegion().

AuditCFNumberCreate check:
- Now blasts through AnonTypedRegions that may layer the original memory region, thus checking if the actually memory block is of the appropriate type.  This change was needed to work with the changes to StoreManager::CastRegion.

GRExprEngine::VisitCast:
- Conform to the new interface of StoreManager::CastRegion.

Tests:
- None of the analysis tests fail now for using the "basic store".
- Disabled the tests 'array-struct.c' and 'rdar-6442306-1.m' pending further testing and bug fixing.

llvm-svn: 60995
2008-12-13 21:49:13 +00:00
Chris Lattner 9b9a145694 RLE isn't smart enough to eliminate this safely yet.
llvm-svn: 60994
2008-12-13 21:04:20 +00:00
Fariborz Jahanian 0222553d1c Add storage layout to ObjC classes.
llvm-svn: 60993
2008-12-13 20:28:25 +00:00
Chris Lattner 77c76ae3de eliminate the isCXXNamedOperator function and some string compares and
use identifierinfo instead.  Patch by Chris Goller!

llvm-svn: 60992
2008-12-13 20:12:40 +00:00
Ted Kremenek 1c89be0216 Temporarily XFAIL these tests.
llvm-svn: 60991
2008-12-13 19:27:01 +00:00
Ted Kremenek f065b15f7d A series of cleanups/fixes motivated by <rdar://problem/6442306>:
GRExprEngine (VisitCast):
- When using StoreManager::CastRegion, always use the state and value it returns to generate the next node.  Failure to do so means that region values returned that don't require the state to be modified will get ignored.

MemRegion:
- Tighten the interface for ElementRegion.  Now ElementRegion can only be created with a super region that is a 'TypedRegion' instead of any MemRegion.  Code in BasicStoreManager/RegionStoreManager already assumed this, but it would result in a dynamic assertion check (and crash) rather than just having the compiler forbid the construction of such regions.
- Added ElementRegion::getArrayRegion() to return the 'typed version' of an ElementRegion's super region.
- Removed bogus assertion in ElementRegion::getType() that assumed that the super region was an AnonTypedRegion.  All that matters is that it is a TypedRegion, which is now true all the time by design.

BasicStore:
- Modified getLValueElement() to check if the 'array' region is a TypedRegion before creating an ElementRegion.  This conforms to the updated interface for ElementRegion.

RegionStore:
- In ArrayToPointer() gracefully handle things we don't reason about, and only create an ElementRegion if the array region is indeed a TypedRegion.

llvm-svn: 60990
2008-12-13 19:24:37 +00:00
Chris Lattner e69336c22d disable Anders' recent VLA patch, this fixes PR3209.
llvm-svn: 60989
2008-12-13 18:58:59 +00:00
Chris Lattner d923519cc5 rename some tests to be more uniform in naming convention.
llvm-svn: 60988
2008-12-13 18:47:40 +00:00
Chris Lattner 9e24267120 gvn should never crash on this.
llvm-svn: 60987
2008-12-13 18:39:44 +00:00
Chris Lattner 695bc778f8 These messages should always be emitted when NDEBUG is unset, not when
NDEBUG is unset and -debug is passed.

llvm-svn: 60986
2008-12-13 18:37:58 +00:00
Mikhail Glushenkov e04b5bfd19 Add a comment to the auto-generated docs.
llvm-svn: 60985
2008-12-13 17:51:47 +00:00
Mikhail Glushenkov 6027992ea9 Merge llvm-rst.css and llvm.css.
llvm-svn: 60984
2008-12-13 17:50:58 +00:00
Sebastian Redl c675baba92 Some utilities for using the smart pointers in Actions, especially Sema. Convert a few functions.
llvm-svn: 60983
2008-12-13 16:23:55 +00:00
Sebastian Redl cb6e2c6156 Convert remaining expression parsers to smart pointers. Now on to the Action connection.
llvm-svn: 60982
2008-12-13 15:32:12 +00:00
Sebastian Redl 19ed30be38 stdlib.h is the wrong header for printf, and introduces test-breaking definitions of inlines on Linux
llvm-svn: 60981
2008-12-13 15:31:28 +00:00
Cedric Venet c41deefec7 Add /Za to all MSVC build of a clang libraries.
This allow to use the new move emulation for smart pointer by disabling language extension.

llvm-svn: 60979
2008-12-13 11:00:04 +00:00
Cedric Venet 13b3e7f217 Add explicit this-> for some member function in templated base class.
These call are probably dependent but VS with /Za don't seems to think so. We need to help him.

llvm-svn: 60978
2008-12-13 10:55:13 +00:00
Bill Wendling 293b9181e5 Temporarily revert r60973. It's inexplicably causing a failure when self-hosting LLVM:
llvm[2]: Linking Release executable opt (without symbols)
...
Undefined symbols:
  "llvm::APFloat::IEEEsingle", referenced from:
      __ZN4llvm7APFloat10IEEEsingleE$non_lazy_ptr in libLLVMCore.a(Constants.o)
      __ZN4llvm7APFloat10IEEEsingleE$non_lazy_ptr in libLLVMCore.a(AsmWriter.o)
      __ZN4llvm7APFloat10IEEEsingleE$non_lazy_ptr in libLLVMCore.a(ConstantFold.o)
  "llvm::APFloat::IEEEdouble", referenced from:
      __ZN4llvm7APFloat10IEEEdoubleE$non_lazy_ptr in libLLVMCore.a(Constants.o)
      __ZN4llvm7APFloat10IEEEdoubleE$non_lazy_ptr in libLLVMCore.a(AsmWriter.o)
      __ZN4llvm7APFloat10IEEEdoubleE$non_lazy_ptr in libLLVMCore.a(ConstantFold.o)
ld: symbol(s) not found

This is in release mode. To replicate, compile llvm and llvm-gcc in optimized
mode. Then build llvm, in optimized mode, with the newly created compiler.

llvm-svn: 60977
2008-12-13 09:28:44 +00:00
Torok Edwin 040688f1b2 Fix getFieldAs() to use the parameter instead of 6.
Add missing DIType constructor, needed by DIVariable::getType().

llvm-svn: 60976
2008-12-13 08:25:29 +00:00
Mon P Wang 472cd640fa Remove assertion to allow promotion of a truncating store operand
llvm-svn: 60975
2008-12-13 08:16:43 +00:00
Mon P Wang f95bd2078d Added basic support for expanding VSETCC
llvm-svn: 60974
2008-12-13 08:15:14 +00:00
Chris Lattner 1e29f7c97d make RLE preserve the name of the load that it replaces. This is just
a pretification of the IR.

llvm-svn: 60973
2008-12-13 07:22:47 +00:00
Duncan Sands b6f09933c0 On big-endian machines it is wrong to do a full
width register load followed by a truncating
store for the copy, since the load will not place
the value in the lower bits.  Probably partial
loads/stores can never happen here, but fix it
anyway.

llvm-svn: 60972
2008-12-13 07:18:38 +00:00
Misha Brukman 234b44add2 Fix spelling.
llvm-svn: 60971
2008-12-13 05:21:37 +00:00
Mikhail Glushenkov afebaf96f9 Some more documentation tweaks.
llvm-svn: 60970
2008-12-13 03:11:37 +00:00
Mikhail Glushenkov c0363fcba6 More cosmetic tweaks for llvmc docs.
llvm-svn: 60969
2008-12-13 02:28:58 +00:00
Devang Patel 146324f99c Re-enable test.
llvm-svn: 60968
2008-12-12 22:42:35 +00:00
Ted Kremenek 877556f4b9 PTH: Added minor 'sibling jumping' optimization for iterating over the side table used for fast preprocessor block skipping. This has a minor performance improvement when preprocessing Cocoa.h, but can have some wins in pathologic cases.
llvm-svn: 60966
2008-12-12 22:05:38 +00:00
Devang Patel 42828e8168 Do not print empty DW_AT_comp_dir.
llvm-svn: 60965
2008-12-12 21:57:54 +00:00
Duncan Sands 8f352fe100 When expanding unaligned loads and stores do not make
use of illegal integer types: instead, use a stack slot
and copying via integer registers.  The existing code
is still used if the bitconvert is to a legal integer
type.

This fires on the PPC testcases 2007-09-08-unaligned.ll
and vec_misaligned.ll.  It looks like equivalent code
is generated with these changes, just permuted, but
it's hard to tell.

With these changes, nothing in LegalizeDAG produces
illegal integer types anymore.  This is a prerequisite
for removing the LegalizeDAG type legalization code.

While there I noticed that the existing code doesn't
handle trunc store of f64 to f32: it turns this into
an i64 store, which represents a 4 byte stack smash.
I added a FIXME about this.  Hopefully someone more
motivated than I am will take care of it.

llvm-svn: 60964
2008-12-12 21:47:02 +00:00
Bill Wendling c4499feb1a - Use patterns instead of creating completely new instruction matching patterns,
which are identical to the original patterns.

- Change the multiply with overflow so that we distinguish between signed and
  unsigned multiplication. Currently, unsigned multiplication with overflow
  isn't working!

llvm-svn: 60963
2008-12-12 21:15:41 +00:00
Steve Naroff 3b0da664bd Fix <rdar://problem/6435837> clang ObjC rewriter: use Block_release instead of Block_destroy.
llvm-svn: 60962
2008-12-12 21:05:34 +00:00
Chris Lattner 6bf1db148c fix a buggy fall through that caused a crash-on-invalid. rdar://6248081
llvm-svn: 60961
2008-12-12 19:20:14 +00:00
Daniel Dunbar a4daf203fe Add test case for using mmintrin (and making sure that inlining is
working with and without debug info).

llvm-svn: 60960
2008-12-12 19:12:02 +00:00
Devang Patel 5784ead8c7 XFAIL these tests for now.
llvm-svn: 60959
2008-12-12 19:08:08 +00:00
Evan Cheng 3270a1dec3 Fix add/sub expansion: don't create ADD / SUB with two results (seems like everyone is doing this these days :-). Patch by Daniel M Gessel!
llvm-svn: 60958
2008-12-12 18:49:09 +00:00
Daniel Dunbar 7b127324ce Force i[0-9]86 to i386 when using LLVM_HOSTTRIPLE.
Only use major part of OS version when on darwin and modifying OS part
of target triple.

llvm-svn: 60957
2008-12-12 18:34:35 +00:00
Ted Kremenek 56572ab9e9 Added PTH optimization to not process entire blocks of tokens that appear in skipped preprocessor blocks. This improves PTH speed by 6%. The code for this optimization itself is not very optimized, and will get cleaned up.
llvm-svn: 60956
2008-12-12 18:34:08 +00:00
Ted Kremenek ee87e0bd31 Enhance PTH preprocessor-condition-block side table to track #elseinformation as well.
llvm-svn: 60955
2008-12-12 18:31:09 +00:00
Chris Lattner 04397358ec Implement the final (hopefully) wrinkle to i-c-e + builtin_constant_p
processing: it allows arbitrary foldable constants as the operand of ?: when
builtin_constant_p is the condition.

llvm-svn: 60954
2008-12-12 18:00:51 +00:00
Nick Lewycky 729bf137a8 Revert my re-instated reverted commit, fixes the bootstrap build on x86-64 linux.
llvm-svn: 60951
2008-12-12 17:09:07 +00:00
Douglas Gregor 4287b37389 Enable out-of-line definitions of C++ constructors and destructors
llvm-svn: 60947
2008-12-12 08:25:50 +00:00
Duncan Sands e4bcb8e2dd When using a 4 byte jump table on a 64 bit machine,
do an extending load of the 4 bytes rather than a
potentially illegal (type) i32 load followed by a
sign extend.

llvm-svn: 60945
2008-12-12 08:13:38 +00:00