Commit Graph

947 Commits

Author SHA1 Message Date
Chris Lattner
40515dba1b Fold iType into Value::VTy
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14435 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-27 18:38:48 +00:00
Chris Lattner
62372c2ee7 User ctor is now inline
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14431 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-27 18:01:38 +00:00
Chris Lattner
3d4bd5aa8d Instancevar was renamed
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14428 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-26 20:33:39 +00:00
Chris Lattner
fae098a56b Don't call getValueType directly. the LLVM optimizer will turn it into the same code anyway :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14426 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-26 19:40:40 +00:00
Misha Brukman
5b636315a9 * Capitalize `Java'
* Sprinkle hypens liberally
* Fix some grammar in comments


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14374 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-24 21:47:35 +00:00
Misha Brukman
c837dd93cd Linker.h moved to include/llvm/Support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14349 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-23 17:24:31 +00:00
Misha Brukman
0313e0b44d Use a reference instead of a pointer for the ostream. The pointer was only
there to assist in the development of llvm-tv, and it no longer has a need to
modify the AsmWriter output stream.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14304 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-21 21:53:56 +00:00
Chris Lattner
c2dfb8bb90 Make ConstantBool act like a 1 bit ConstantInt, in order to simplify client
code.  Patch contributed by Vladimir Prus.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14280 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-21 12:12:12 +00:00
Chris Lattner
697692a009 IntrinsicLowering.cpp now lives in lib/CodeGen/
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14269 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-20 07:59:27 +00:00
Chris Lattner
3048373748 Move the IntrinsicLowering header into the CodeGen directory, as per PR346
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14266 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-20 07:49:54 +00:00
Chris Lattner
fab8596459 compute dominator tree children in a deterministic order that does not depend
on the address of BasicBlock objects in memory.  This eliminates stuff like this:

 Inorder Dominator Tree:
   [1]  %entry
     [2]  %loopentry
-      [3]  %loopexit
       [3]  %no_exit
-        [4]  %endif
         [4]  %then
+        [4]  %endif
+      [3]  %loopexit
       [3]  %return


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14253 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-19 20:13:48 +00:00
Chris Lattner
f6437a3023 Print out immediate dominators in program order, not in random order based on the address
of BasicBlock objects


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14252 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-19 20:04:47 +00:00
Chris Lattner
a8abee2136 Fix printing of Argument objects, problem found by Patrick Meredith
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14215 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-18 04:07:20 +00:00
Chris Lattner
f70c22b019 Rename Type::PrimitiveID to TypeId and ::getPrimitiveID() to ::getTypeID()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14201 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-17 18:19:28 +00:00
Chris Lattner
c2616625a3 Minor cleanup
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14199 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-17 17:56:54 +00:00
Chris Lattner
4ee623de0b isnan is dead
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14191 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-15 21:52:58 +00:00
Chris Lattner
be78ac4422 Remove isnan support, correct isunordered support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14187 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-15 21:42:23 +00:00
Chris Lattner
d1cd328560 Do not dereference end iterators. It's really bad for the asmwriter's health.
This possibly fixes PR370


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14181 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-15 21:07:32 +00:00
Alkis Evlogimenos
ac700ca926 Make assertions more consistent with the rest of the intrinsic
function verification and make it a requirement that both arguments to
llvm.isunordered are of the same type.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14165 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-13 00:55:26 +00:00
Alkis Evlogimenos
9685372062 Add the isunordered intrinsic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14159 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-12 19:19:14 +00:00
Chris Lattner
02348caffc Fix lowering to work correctly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14134 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-11 02:54:02 +00:00
Chris Lattner
137cc4fc8c I misled Alkis: LLVM should have isnan, not isunordered.
isunordered(X, Y) === isnan(X) | isnan(Y)

Remove isunordered, add isnan.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14132 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-11 02:29:43 +00:00
Alkis Evlogimenos
f616f22e81 Add the isunordered intrinsic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14127 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-11 01:08:18 +00:00
Chris Lattner
1797ce1e24 Share some code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14106 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-10 01:57:38 +00:00
Chris Lattner
e9e326e2eb Tolerate more errors
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14104 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-09 22:22:10 +00:00
Chris Lattner
69566459cc Make the asmwriter much more tolerant of errors (which are common when working
on new front-ends and stuff).  Also get rid of some tabs that snuck in.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14100 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-09 19:41:19 +00:00
Reid Spencer
fc621e2878 Made it possible for the printInfoComment method to invoke getSlot in
such a way that if the Value being printed is standalone that we don't
assert and abort but just print ":??" for the slot number instead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14097 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-09 15:26:53 +00:00
Chris Lattner
2a5020150c Workaround or a VS miscompilation bug
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14078 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-08 23:21:39 +00:00
Chris Lattner
82d55902c6 Fix a link error using VS8.0
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14071 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-08 17:53:24 +00:00
Chris Lattner
40416e4e85 Fix PR361.
Dominance properties don't hold in unreachable code


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14053 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-07 23:07:33 +00:00
Chris Lattner
c70a5092bf Fix GCC warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14045 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-05 17:44:48 +00:00
Chris Lattner
9bf2a926cb Fix GCC warnings
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14044 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-05 17:43:52 +00:00
Chris Lattner
f0a3e6c21c Remove an unused variable.
Work around for bogus errors: no those static functions don't need to
be executed to be initialized!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14040 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-05 01:05:19 +00:00
Chris Lattner
8e72749fc0 Add missing #include
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14037 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-05 00:24:59 +00:00
Chris Lattner
ed965e901c Work around VS bug
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14036 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-05 00:22:04 +00:00
Chris Lattner
f878218c97 As much as I dislike doing this, it's the only fix for VC8.0 that I can come
up with, even though it's perfectly conformant code.  :(


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14034 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-05 00:11:27 +00:00
Chris Lattner
e1cacce400 Remove unused var
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14033 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-05 00:03:27 +00:00
Chris Lattner
54e3e8fd37 Squelch a warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14032 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-04 23:53:20 +00:00
Chris Lattner
20924bc3dd Delete some unreachable code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14031 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-04 23:52:36 +00:00
Misha Brukman
40c732cc52 * No more CachedWriter::setStream()
* ostream is back to being a reference instead of a pointer
* Output single characters as chars, not as length-1 strings


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14030 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-04 21:11:51 +00:00
Chris Lattner
d9a98de5c8 Ugh, apparently there is no common ground here.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14026 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-04 20:48:51 +00:00
Chris Lattner
071f2f13b6 Squish a warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14020 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-04 20:14:29 +00:00
Chris Lattner
7c277b3a64 * Verify function prototypes, not just functions with bodies.
* Verify that functions do not take aggregates as arguments.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13984 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-03 06:38:43 +00:00
John Criswell
4ff620a867 Modified calcTypeName() so that it does not allocate a std::string for
every recursive call.
This makes it more robust for deeply nested, unnamed types.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13915 91177308-0d34-0410-b5e6-96231b3b80d8
2004-06-01 14:54:08 +00:00
Reid Spencer
3ee239bd40 Fix a bug that Chris asserts emphatically is a bug. The changed clause
would always return false because the Type of a type value is always
Type::TypeTY and can never be a floating point type.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13902 91177308-0d34-0410-b5e6-96231b3b80d8
2004-05-30 01:19:48 +00:00
Reid Spencer
3c82aa3623 Moved this file to lib/Bytecode/Writer because its used there only.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13900 91177308-0d34-0410-b5e6-96231b3b80d8
2004-05-30 00:09:32 +00:00
Chris Lattner
c3fcaea8ac Don't use size() when you mean empty()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13876 91177308-0d34-0410-b5e6-96231b3b80d8
2004-05-28 05:40:19 +00:00
Reid Spencer
73b7495a96 Clean up a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13860 91177308-0d34-0410-b5e6-96231b3b80d8
2004-05-27 22:04:46 +00:00
Reid Spencer
5dff158858 Fix for bug 348.
The SymbolTable changes caused this one too.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13859 91177308-0d34-0410-b5e6-96231b3b80d8
2004-05-27 21:58:13 +00:00
Alkis Evlogimenos
75dbe8eafa Add constructors that take a BasicBlock to append to, to the rest of
the llvm::Instruction hierarchy.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13800 91177308-0d34-0410-b5e6-96231b3b80d8
2004-05-27 00:15:23 +00:00