1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 20:12:56 +02:00
Commit Graph

361 Commits

Author SHA1 Message Date
Jeff Cohen
98c99a3a02 Unbreak VC++ build.
llvm-svn: 34917
2007-03-05 00:00:42 +00:00
Chris Lattner
69aafa4be8 fix 80 col violations, mark arrays static
llvm-svn: 34915
2007-03-04 23:33:03 +00:00
Anton Korobeynikov
af46a0e4a2 Fix uninitialized use of variable. Remove tabs and fix identation.
llvm-svn: 34850
2007-03-02 22:19:41 +00:00
Owen Anderson
6d3b179de3 Fix a typo.
llvm-svn: 34836
2007-03-02 05:03:07 +00:00
Owen Anderson
070c37407c Use GCC intrinsics when available, and use smarter fallbacks when not.
llvm-svn: 34812
2007-03-01 21:16:30 +00:00
Reid Spencer
3f3487918c Remove the "isSigned" parameters from ConstantRange. It turns out they
are not needed as the results are the same with or without it.

Patch by Nicholas Lewycky.

llvm-svn: 34782
2007-03-01 07:54:15 +00:00
Owen Anderson
cbbf9aa6b0 Use the GCC built-in for PopulationCount when it's available, and use a faster
algorithm when it's not.  This should be particularly noticeable in the
64-bit case.

llvm-svn: 34776
2007-03-01 05:41:28 +00:00
Reid Spencer
f119927a6f Move ConstantRange class to lib/Support from lib/Analysis and make its
interface not depend on Type or ICmpInst.

llvm-svn: 34761
2007-02-28 22:02:48 +00:00
Reid Spencer
965067a054 For PR1205:
Remove ConstantInt from ConstantRange interface and adjust its users to
compensate.

llvm-svn: 34758
2007-02-28 19:57:34 +00:00
Reid Spencer
e2b4631435 For PR1205:
First round of ConstantRange changes. This makes all CR constructors use
only APInt and not use ConstantInt. Clients are adjusted accordingly.

llvm-svn: 34756
2007-02-28 18:57:32 +00:00
Reid Spencer
2b933467ad For PR1205:
Convert ConstantRange class to use APInt internally as its value type for
the constant range, instead of ConstantInt.

llvm-svn: 34745
2007-02-28 17:36:23 +00:00
Chris Lattner
08e1470365 add a way to register an arbitrary cleanup function.
llvm-svn: 34442
2007-02-20 06:08:37 +00:00
Andrew Lenharth
3c51b17d7b I love non-deturminism. Returning objects with references to stack objects is a bad idea (TM).
llvm-svn: 34210
2007-02-13 00:37:50 +00:00
Nick Lewycky
b994bafc0f Fix comments to match names of functions.
llvm-svn: 34173
2007-02-11 00:58:49 +00:00
Chris Lattner
e5eb7d79d3 add helper method.
llvm-svn: 34155
2007-02-10 19:54:24 +00:00
Chris Lattner
ae8f9f7df4 StableBasicBlockNumbering is conceptually just a wrapper around UniqueVector,
so we should actually use a UniqueVector to implement it.

llvm-svn: 33935
2007-02-05 23:19:24 +00:00
Bill Wendling
bc1c8e70ac Use unsigned char& instead of std::vector<>::reference.
llvm-svn: 33896
2007-02-05 02:37:07 +00:00
Bill Wendling
d2623ac830 Added some accessor methods.
llvm-svn: 33814
2007-02-03 02:38:15 +00:00
Reid Spencer
591bfa1e0b Changes to support making the shift instructions be true BinaryOperators.
This feature is needed in order to support shifts of more than 255 bits
on large integer types.  This changes the syntax for llvm assembly to
make shl, ashr and lshr instructions look like a binary operator:
   shl i32 %X, 1
instead of
   shl i32 %X, i8 1
Additionally, this should help a few passes perform additional optimizations.

llvm-svn: 33776
2007-02-02 02:16:23 +00:00
Jim Laskey
52a12383a4 Support for non-landing pad exception handling.
llvm-svn: 33755
2007-02-01 16:31:34 +00:00
Reid Spencer
2d41dbae16 Fix a homonymo in a comment.
llvm-svn: 33754
2007-02-01 12:09:51 +00:00
Devang Patel
46a1a617f5 Add PrintVersionMessage() that tools can use to print version number
without exiting program.

llvm-svn: 33737
2007-02-01 01:43:37 +00:00
Anton Korobeynikov
2079992c16 Moved disassembler to libSystem
llvm-svn: 33461
2007-01-23 10:26:08 +00:00
Reid Spencer
e33c18f4d2 For PR970:
Clean up handling of isFloatingPoint() and dealing with PackedType.
Patch by Gordon Henriksen!

llvm-svn: 33415
2007-01-21 00:29:26 +00:00
Anton Korobeynikov
944088f221 Adding disassembler interface and external hook to udis86 library.
llvm-svn: 33358
2007-01-19 17:25:17 +00:00
Bill Wendling
af4f1b8791 Have the OutputBuffer take the is64Bit and isLittleEndian booleans.
llvm-svn: 33316
2007-01-18 01:23:11 +00:00
Bill Wendling
19aee9b178 Refactored output buffer methods from MachO and ELF writers.
llvm-svn: 33310
2007-01-17 22:17:24 +00:00
Zhou Sheng
23d24526b2 For PR1043:
Merge ConstantIntegral and ConstantBool into ConstantInt.
Remove ConstantIntegral and ConstantBool from LLVM.

llvm-svn: 33073
2007-01-11 12:24:14 +00:00
Bill Wendling
05f7a367a2 The previous implementation of LLVM Streams wasn't removing symbols. This
one should.

llvm-svn: 32845
2007-01-03 22:37:27 +00:00
Reid Spencer
4428c3483b For PR950:
This patch removes the SetCC instructions and replaces them with the ICmp
and FCmp instructions. The SetCondInst instruction has been removed and
been replaced with ICmpInst and FCmpInst.

llvm-svn: 32751
2006-12-23 06:05:41 +00:00
Chris Lattner
6a34f2718f Doxgenate comments.
Add GreatestCommonDivisor64

llvm-svn: 32661
2006-12-19 01:11:32 +00:00
Bill Wendling
7f6a73eb5c Added an automatic cast to "std::ostream*" etc. from OStream. We then can
rework the hacks that had us passing OStream in. We pass in std::ostream*
instead, check for null, and then dispatch to the correct print() method.

llvm-svn: 32636
2006-12-17 05:15:13 +00:00
Bill Wendling
fe0af72bc4 Don't use <sstream> in Streams.h but <iosfwd> instead.
llvm-svn: 32340
2006-12-07 23:41:45 +00:00
Bill Wendling
a3246c4272 Changed llvm_ostream et all to OStream. llvm_cerr, llvm_cout, llvm_null, are
now cerr, cout, and NullStream resp.

llvm-svn: 32298
2006-12-07 01:30:32 +00:00
Jim Laskey
25d00cc31d Ignoring the upper 32 bits of a 64 bit constant is not a good thing.
llvm-svn: 32294
2006-12-06 22:47:14 +00:00
Chris Lattner
30bf130327 add a helper to call llvm_shutdown()
llvm-svn: 32249
2006-12-06 01:01:14 +00:00
Chris Lattner
1b0e89e022 Start moving pass registration over to using the ManagedStatic mechanism.
This fixes issues where passes get unregistered before llvm_shutdown is
called, and is generally cleaner and simpler.  Analysis groups up next.

llvm-svn: 32108
2006-12-01 23:27:45 +00:00
Chris Lattner
e91ec14530 remove 'target constructor' support.
llvm-svn: 32100
2006-12-01 22:00:50 +00:00
Reid Spencer
52d8c5bd3b Get the delegation right for InstVisitor.
llvm-svn: 32025
2006-11-29 21:37:00 +00:00
Bill Wendling
4effa38086 Replacing std::iostreams with llvm iostreams. Some of these changes involve
adding a temporary wrapper around the ostream to make it friendly to
functions expecting an LLVM stream. This should be fixed in the future.

llvm-svn: 31990
2006-11-29 00:19:40 +00:00
Bill Wendling
4157840bd6 Added a temporary hack to get the llvm-streams to work for future checkins.
llvm-svn: 31978
2006-11-28 22:21:29 +00:00
Bill Wendling
250560d106 Protect against null streams.
llvm-svn: 31937
2006-11-27 10:45:49 +00:00
Reid Spencer
992d9788b3 For PR950:
The long awaited CAST patch. This introduces 12 new instructions into LLVM
to replace the cast instruction. Corresponding changes throughout LLVM are
provided. This passes llvm-test, llvm/test, and SPEC CPUINT2000 with the
exception of 175.vpr which fails only on a slight floating point output
difference.

llvm-svn: 31931
2006-11-27 01:05:10 +00:00
Bill Wendling
78be822ec4 Add method that will take a function pointer so that it can handle things
like "llvm_cerr << std::flush";

llvm-svn: 31926
2006-11-26 10:51:51 +00:00
Reid Spencer
6e34ef887b For PR950:
First in a series of patches to convert SetCondInst into ICmpInst and
FCmpInst using only two opcodes and having the instructions contain their
predicate value. Nothing uses these classes yet. More patches to follow.

llvm-svn: 31867
2006-11-20 01:22:35 +00:00
Bill Wendling
48bd5207a4 Used llvm_ostream instead of std::ostream objects. This will reduce use
of the icky <iostream> class.

llvm-svn: 31818
2006-11-17 09:52:49 +00:00
Bill Wendling
dbbb5112c5 Added wrappers for the std::cerr/std::cout objects. The wrappers will
soon replace all uses of those objects.

llvm-svn: 31817
2006-11-17 09:51:22 +00:00
Bill Wendling
efe40f4316 #ifndef NDEBUG the "if (Stream) ..." stuff.
llvm-svn: 31803
2006-11-17 01:43:48 +00:00
Bill Wendling
d2627f76dd Adjusted the // comments so that doxygen picks them up.
llvm-svn: 31801
2006-11-17 01:13:12 +00:00
Bill Wendling
748f1ae70b Added "DOUT" macro. This is used as a replacement for the std::cerr
stream. It centralizes the use of std::cerr so that static c'tor/d'tors
aren't scattered around all over the place. The way to use it is like this:

       DOUT << "This is a status line: " << Var << "\n";

If "-debug" is specified, it will print. Otherwise, it'll not print. If
NDEBUG is defined, the DOUT does nothing.

llvm-svn: 31798
2006-11-17 00:49:12 +00:00