1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 03:53:04 +02:00
Commit Graph

599 Commits

Author SHA1 Message Date
Bill Wendling
4d1444725b Removed more <iostream> includes
llvm-svn: 32321
2006-12-07 20:28:15 +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
Chris Lattner
a531ce882e Detemplatize the Statistic class. The only type it is instantiated with
is 'unsigned'.

llvm-svn: 32279
2006-12-06 17:46:33 +00:00
Reid Spencer
3e2d6cd0d1 Fix a CmpInst writing bug by removing merge cruft that I *know* I've removed
before. Also, make sure we write the predicate value for Cmp instructions
using instruction format 0.

llvm-svn: 32253
2006-12-06 04:27:07 +00:00
Reid Spencer
ccdc1ac3a7 For PR950: Implement read/write of ICmp and FCmp constant expressions
llvm-svn: 32172
2006-12-04 05:23:49 +00:00
Reid Spencer
41583e85cb Support ICmp/FCmp constant expression reading and writing.
llvm-svn: 32160
2006-12-03 17:17:02 +00:00
Reid Spencer
7a449dd20b Implement reading and writing of the ICmp and FCmp instructions.
llvm-svn: 32149
2006-12-03 06:28:54 +00:00
Reid Spencer
5f687b7190 Remove backwards compatibility goop. This is now handled by llvm-upgrade.
llvm-svn: 32146
2006-12-03 05:47:10 +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
c942df4921 Use ostream instead of iostream
llvm-svn: 31986
2006-11-28 22:49:32 +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
Reid Spencer
c7a1e60e44 Have ConstantExprs upgrade opcodes the same way as instructions.
llvm-svn: 31841
2006-11-18 04:37:19 +00:00
Reid Spencer
f65a8539ec Discard code that supported old bytecode formats. This makes the Bytecode
Reader code much easier to read and maintain. Backwards compatibility from
version 5 format has been retained. Older formats will produce an error.

llvm-svn: 31723
2006-11-14 04:47:22 +00:00
Reid Spencer
72bcd0530b For PR998:
Fix an infinite loop in the Linker and a few other assorted link problems.

Patch contributed by Scott Michel. Thanks, Scott!

llvm-svn: 31680
2006-11-11 11:54:25 +00:00
Reid Spencer
972e7d7995 Bump the bytecode version number to 7. Implement upgrade of version 6 and
version 6 bytecode.

llvm-svn: 31573
2006-11-08 21:27:54 +00:00
Reid Spencer
da1f5b882a For PR950:
This patch converts the old SHR instruction into two instructions,
AShr (Arithmetic) and LShr (Logical). The Shr instructions now are not
dependent on the sign of their operands.

llvm-svn: 31542
2006-11-08 06:47:33 +00:00
Reid Spencer
52135336f2 Remove some dead code.
llvm-svn: 31401
2006-11-03 01:44:51 +00:00
Reid Spencer
4bafa71dc1 For PR786:
Turn on -Wunused and -Wno-unused-parameter. Clean up most of the resulting
fall out by removing unused variables. Remaining warnings have to do with
unused functions (I didn't want to delete code without review) and unused
variables in generated code. Maintainers should clean up the remaining
issues when they see them. All changes pass DejaGnu tests and Olden.

llvm-svn: 31380
2006-11-02 20:25:50 +00:00
Reid Spencer
1abf69e923 For PR950:
Replace the REM instruction with UREM, SREM and FREM.

llvm-svn: 31369
2006-11-02 01:53:59 +00:00
Reid Spencer
6833ffe8b8 For PR950:
Make necessary changes to support DIV -> [SUF]Div. This changes llvm to
have three division instructions: signed, unsigned, floating point. The
bytecode and assembler are bacwards compatible, however.

llvm-svn: 31195
2006-10-26 06:15:43 +00:00
Reid Spencer
d414793dbc For PR950:
This patch implements the first increment for the Signless Types feature.
All changes pertain to removing the ConstantSInt and ConstantUInt classes
in favor of just using ConstantInt.

llvm-svn: 31063
2006-10-20 07:07:24 +00:00
Chris Lattner
08684eac36 Fix massive resource leaks in the bytecode reader. Reading a bytecode file
with ParseBytecodeFile used to leak both a ModuleProvider (and related
bytecode parser stuff attached to it) AND a file descriptor, which was
never closed.  This prevented gccld/llvm-ld/llvm-link from linking together
apps with more that ~252 .bc files on darwin.

llvm-svn: 30912
2006-10-12 18:32:30 +00:00
Anton Korobeynikov
b2b7c2f8b9 Small fixes for supporting dll* linkage types
llvm-svn: 30441
2006-09-17 13:06:18 +00:00
Anton Korobeynikov
6e19f80688 Adding dllimport, dllexport and external weak linkage types.
DLL* linkages got full (I hope) codegeneration support in C & both x86
assembler backends.
External weak linkage added for future use, we don't provide any
codegeneration, etc. support for it.

llvm-svn: 30374
2006-09-14 18:23:27 +00:00
Anton Korobeynikov
1c7d8613c4 - Fixed broken Win32 build
- Removed warning about clobbered parameter in Bytecode/Reader

llvm-svn: 30026
2006-09-01 20:35:17 +00:00
Reid Spencer
e2b7b29a82 For PR797:
Final commit for this bug. This removes the last EH holdouts in LLVM
and turns off exception support by using the -fno-exceptions option. This
leads to the following reduction in library and executable sizes:
                DEBUG BUILD                RELEASE BUILD
         before     after   delta     before   after    delta
lib    162,328K  157,616K   4,712    17,864K  16,416K  1,448K
bin    571,444K  557,156K  14,288    63,296K   56,996K 6,300K

Debug   Improvement: 19,000K (2.59%)
Release Improvement:  7,748K (9.55%)

llvm-svn: 29882
2006-08-25 19:54:53 +00:00
Reid Spencer
741140980f For PR797:
Remove exception throwing/handling from lib/Bytecode, and adjust its users
to compensate for changes in the interface.

llvm-svn: 29875
2006-08-25 17:43:11 +00:00
Reid Spencer
d813eae003 For PR797:
Remove exception handling from the bytecode archiver and adjust the llvm-ar
tool to accommodate the new interfaces.

llvm-svn: 29866
2006-08-24 23:45:08 +00:00
Reid Spencer
bc4c8e8ac0 For PR797:
Eliminate exception throwing from Path::renamePathOnDisk and adjust its
users correspondingly.

llvm-svn: 29843
2006-08-23 07:30:48 +00:00
Reid Spencer
baf54399e7 For PR797:
Remove exceptions from the Path::create*OnDisk methods. Update their users
to handle error messages via arguments and result codes.

llvm-svn: 29840
2006-08-23 00:39:35 +00:00
Reid Spencer
c9c2bf5af1 Inverse the error check logic for the MappedFile::map() call. It returns
a null pointer when there is an error.

llvm-svn: 29827
2006-08-22 17:58:50 +00:00
Reid Spencer
2ee33a6305 For PR797:
Adjust the use of MappedFile to its new non-throwing interface. We just
propagate the exceptions if an error occurs. This will get cleaned up
later, incrementally.

llvm-svn: 29820
2006-08-22 16:10:12 +00:00
Reid Spencer
d00c37651a For PR797:
Make the Bytecode Reader use setjmp/longjump instead of exceptions to handle
errors. The alternative was even uglier than setjmp/longjump as it would
impact the interface and workings of nearly every function in the reader.

llvm-svn: 29819
2006-08-22 16:09:19 +00:00
Reid Spencer
88b3207059 For PR797:
Adjust to new interface for MappedFile. Note that the new "throw"
statements will be removed later.

llvm-svn: 29818
2006-08-22 16:07:44 +00:00
Chris Lattner
d7873a0757 Modify Path::eraseFromDisk to not throw an exception.
llvm-svn: 29400
2006-07-28 22:29:50 +00:00
Chris Lattner
93ab0e8787 formatting cleanups
llvm-svn: 29396
2006-07-28 22:07:54 +00:00
Chris Lattner
f4c7ceebaf Change Path::getStatusInfo to return a boolean and error string on an error
instead of throwing an exception.  This reduces the amount of code that is
exposed to exceptions (e.g. FileUtilities), though it is clearly only one step
along the way.

llvm-svn: 29395
2006-07-28 22:03:44 +00:00
Chris Lattner
5f87e5d0cf Exceptions are thrown by and through this library.
llvm-svn: 29393
2006-07-28 22:00:24 +00:00
Reid Spencer
cb66ae964e Finish removal of EH usage from the Archive library. The REQUIRES_EH flag
in lib/Bytecode/Archive/Makefile is now removed. One small step closer to
a smaller LLVM.

llvm-svn: 29067
2006-07-07 20:56:50 +00:00
Reid Spencer
9f4deeabf4 Remove EH use from the Archive library and adjust its users accordingly.
llvm-svn: 29066
2006-07-07 19:09:14 +00:00
Chris Lattner
f898cccc07 These libs use EH info
llvm-svn: 29043
2006-07-07 16:44:31 +00:00
Chris Lattner
d20dc02699 Fix a bug in my previous patch which broke building llvm/runtime when using llvm-gcc3.
llvm-svn: 29041
2006-07-07 06:06:06 +00:00
Chris Lattner
792190e73d Change the ModuleProvider interface to not throw exceptions.
llvm-svn: 29024
2006-07-06 21:35:01 +00:00
Chris Lattner
c55abf6f70 Change the verifier to never throw an exception. Instead verifyModule canoptionally return the string error, which is an easier api for clients touse anyway.
llvm-svn: 29017
2006-07-06 18:02:27 +00:00
Reid Spencer
3c338b3803 For PR787:
Provide new llvm::sys::Program facilities for converting the stdout and
stdin to binary mode. There is no standard way to do this and the available
mechanisms are platform specific. Adjust the bytecode reader and writer to
use these methods when their input is stdin or output is stdout. THis avoids
the problem with \n writing CRLF to a bytecode file on windows.

Patch Contributed by Michael Smith.

llvm-svn: 28722
2006-06-07 23:18:34 +00:00
Chris Lattner
038432eeb3 Fix a bug where the types for inlineasm nodes were not properly entered into
the compaction table for a function.  This broke compilation of hexxagon
on darwin/x86 with recent changes.

llvm-svn: 28717
2006-06-07 22:20:03 +00:00
Reid Spencer
94a443bb29 Use archive libraries instead of object files for VMCore, BCReader,
BCWriter, and bzip2 libraries. Adjust the various makefiles to accommodate
these changes. This was done to speed up link times.

llvm-svn: 28610
2006-06-01 01:30:27 +00:00
Chris Lattner
e3222507ee Fix a bug in the bc reader/writer: we were not correctly encoding varargs
nonccc calls (we were dropping the CC and tail flag).  This broke several
FORTRAN programs.

Testcase here: Regression/Assembler/2006-05-26-VarargsCallEncode.ll

llvm-svn: 28501
2006-05-26 18:42:34 +00:00
Chris Lattner
91a82b1152 Fix misencoding of calling conventions
llvm-svn: 28411
2006-05-19 21:57:37 +00:00
Reid Spencer
ea509eb3ac When reading the symbol table, make sure to delete the ArchiveMember
created by reading the symbol table.

llvm-svn: 28251
2006-05-12 17:56:20 +00:00