- Aug 13, 2009
-
-
Owen Anderson authored
llvm-svn: 78948
-
- Jul 14, 2009
-
-
Torok Edwin authored
This adds location info for all llvm_unreachable calls (which is a macro now) in !NDEBUG builds. In NDEBUG builds location info and the message is off (it only prints "UREACHABLE executed"). llvm-svn: 75640
-
- Jul 11, 2009
-
-
Torok Edwin authored
Make llvm_unreachable take an optional string, thus moving the cerr<< out of line. LLVM_UNREACHABLE is now a simple wrapper that makes the message go away for NDEBUG builds. llvm-svn: 75379
-
- Jul 07, 2009
-
-
Owen Anderson authored
llvm-svn: 74931
-
- Jun 23, 2009
-
-
Owen Anderson authored
llvm-svn: 73928
-
- May 11, 2009
-
-
Jay Foad authored
just a Type. llvm-svn: 71426
-
- May 09, 2009
-
-
Duncan Sands authored
will make it more obvious what it represents, and stop it being confused with the StoreSize. llvm-svn: 71349
-
- Apr 01, 2009
-
-
Dan Gohman authored
less ambiguous and less C-specific. llvm-svn: 68219
-
- Feb 17, 2009
-
-
Dan Gohman authored
llvm-svn: 64694
-
- Jan 12, 2009
-
-
Duncan Sands authored
suggested by Chris. llvm-svn: 62099
-
- Dec 09, 2008
-
-
Duncan Sands authored
llvm-svn: 60755
-
- Dec 08, 2008
-
-
Chris Lattner authored
llvm-svn: 60694
-
Chris Lattner authored
remove some more 64-bit divs and rems from the StructLayout ctor. llvm-svn: 60692
-
- Sep 04, 2008
-
-
Dan Gohman authored
llvm-svn: 55779
-
- Jun 04, 2008
-
-
Duncan Sands authored
are the same as in unpacked structs, only field positions differ. This only matters for structs containing x86 long double or an apint; it may cause backwards compatibility problems if someone has bitcode containing a packed struct with a field of one of those types. The issue is that only 10 bytes are needed to hold an x86 long double: the store size is 10 bytes, but the ABI size is 12 or 16 bytes (linux/ darwin) which comes from rounding the store size up by the alignment. Because it seemed silly not to pack an x86 long double into 10 bytes in a packed struct, this is what was done. I now think this was a mistake. Reserving the ABI size for an x86 long double field even in a packed struct makes things more uniform: the ABI size is now always used when reserving space for a type. This means that developers are less likely to make mistakes. It also makes life easier for the CBE which otherwise could not represent all LLVM packed structs (PR2402). Front-end people might need to adjust the way they create LLVM structs - see following change to llvm-gcc. llvm-svn: 51928
-
- May 13, 2008
-
-
Dan Gohman authored
several things that were neither in an anonymous namespace nor static but not intended to be global. llvm-svn: 51017
-
- Apr 14, 2008
-
-
Dan Gohman authored
llvm-svn: 49681
-
- Mar 19, 2008
-
-
Devang Patel authored
llvm-svn: 48554
-
- Jan 29, 2008
-
-
Duncan Sands authored
to get the alignment of global variables, rather than using hand-made versions. llvm-svn: 46495
-
- Jan 10, 2008
-
-
rdar://5676945Chris Lattner authored
than hardware supported type will be scalarized, so we can infer their alignment from that info. We now codegen pr1845 into: _boolVectorSelect: lbz r2, 0(r3) stb r2, -16(r1) blr llvm-svn: 45796
-
- Dec 29, 2007
-
-
Chris Lattner authored
llvm-svn: 45418
-
- Dec 21, 2007
-
-
Duncan Sands authored
of this patch is the last line). llvm-svn: 45289
-
- Dec 13, 2007
-
-
Duncan Sands authored
put it in a new header System/Host.h instead. Instead of getting the endianness from configure, calculate it directly. llvm-svn: 44959
-
- Dec 11, 2007
-
-
Chris Lattner authored
don't have to #include config.h in it. #including config.h breaks other projects that have their own autoconf stuff and try to #include the llvm headers. One obscure example is llvm-gcc. llvm-svn: 44825
-
- Nov 09, 2007
-
-
Anton Korobeynikov authored
llvm-svn: 43954
-
- Nov 01, 2007
-
-
Duncan Sands authored
The meaning of getTypeSize was not clear - clarifying it is important now that we have x86 long double and arbitrary precision integers. The issue with long double is that it requires 80 bits, and this is not a multiple of its alignment. This gives a primitive type for which getTypeSize differed from getABITypeSize. For arbitrary precision integers it is even worse: there is the minimum number of bits needed to hold the type (eg: 36 for an i36), the maximum number of bits that will be overwriten when storing the type (40 bits for i36) and the ABI size (i.e. the storage size rounded up to a multiple of the alignment; 64 bits for i36). This patch removes getTypeSize (not really - it is still there but deprecated to allow for a gradual transition). Instead there is: (1) getTypeSizeInBits - a number of bits that suffices to hold all values of the type. For a primitive type, this is the minimum number of bits. For an i36 this is 36 bits. For x86 long double it is 80. This corresponds to gcc's TYPE_PRECISION. (2) getTypeStoreSizeInBits - the maximum number of bits that is written when storing the type (or read when reading it). For an i36 this is 40 bits, for an x86 long double it is 80 bits. This is the size alias analysis is interested in (getTypeStoreSize returns the number of bytes). There doesn't seem to be anything corresponding to this in gcc. (3) getABITypeSizeInBits - this is getTypeStoreSizeInBits rounded up to a multiple of the alignment. For an i36 this is 64, for an x86 long double this is 96 or 128 depending on the OS. This is the spacing between consecutive elements when you form an array out of this type (getABITypeSize returns the number of bytes). This is TYPE_SIZE in gcc. Since successive elements in a SequentialType (arrays, pointers and vectors) need to be aligned, the spacing between them will be given by getABITypeSize. This means that the size of an array is the length times the getABITypeSize. It also means that GEP computations need to use getABITypeSize when computing offsets. Furthermore, if an alloca allocates several elements at once then these too need to be aligned, so the size of the alloca has to be the number of elements multiplied by getABITypeSize. Logically speaking this doesn't have to be the case when allocating just one element, but it is simpler to also use getABITypeSize in this case. So alloca's and mallocs should use getABITypeSize. Finally, since gcc's only notion of size is that given by getABITypeSize, if you want to output assembler etc the same as gcc then getABITypeSize is the size you want. Since a store will overwrite no more than getTypeStoreSize bytes, and a read will read no more than that many bytes, this is the notion of size appropriate for alias analysis calculations. In this patch I have corrected all type size uses except some of those in ScalarReplAggregates, lib/Codegen, lib/Target (the hard cases). I will get around to auditing these too at some point, but I could do with some help. Finally, I made one change which I think wise but others might consider pointless and suboptimal: in an unpacked struct the amount of space allocated for a field is now given by the ABI size rather than getTypeStoreSize. I did this because every other place that reserves memory for a type (eg: alloca) now uses getABITypeSize, and I didn't want to make an exception for unpacked structs, i.e. I did it to make things more uniform. This only effects structs containing long doubles and arbitrary precision integers. If someone wants to pack these types more tightly they can always use a packed struct. llvm-svn: 43620
-
- Oct 29, 2007
-
-
Chris Lattner authored
zero-length fields better. llvm-svn: 43427
-
- Oct 08, 2007
-
-
Dan Gohman authored
llvm-svn: 42751
-
- Oct 01, 2007
-
-
Dale Johannesen authored
llvm-svn: 42488
-
- Sep 21, 2007
-
-
Rafael Espindola authored
Implement calls to functions with byval arguments on X86 llvm-svn: 42192
-
- Sep 17, 2007
-
-
Chris Lattner authored
Add a new DenseMapInfo::isEqual method to allow clients to redefine the equality predicate used when probing the hash table. llvm-svn: 42042
-
- Sep 07, 2007
-
-
Rafael Espindola authored
The x86-64 ABI states that objects passed on the stack have 8 byte alignment. Implement that. llvm-svn: 41768
-
- Aug 05, 2007
-
-
Reid Spencer authored
llvm-svn: 40854
-
- Aug 03, 2007
-
-
Dale Johannesen authored
(I've tried to get the info right for all targets, but I'm not expert on all of them - check yours.) llvm-svn: 40792
-
- May 03, 2007
-
-
Devang Patel authored
llvm-svn: 36662
-
- May 02, 2007
-
-
Devang Patel authored
Due to darwin gcc bug, one version of darwin linker coalesces static const int, which defauts PassID based pass identification. llvm-svn: 36652
-
Lauro Ramos Venancio authored
llvm-svn: 36648
-
- May 01, 2007
-
-
Devang Patel authored
llvm-svn: 36632
-
- Apr 22, 2007
-
-
Christopher Lamb authored
llvm-svn: 36352
-
- Apr 09, 2007
-
-
Jeff Cohen authored
Fixes unexpected failures on FreeBSD/amd64 of: CFrontend/2005-09-24-BitFieldCrash.c: CFrontend/2007-02-04-EmptyStruct.c: CFrontend/2007-03-26-ZeroWidthBitfield.c: CodeGen/Generic/2005-10-18-ZeroSizeStackObject.ll: llvm-svn: 35828
-