Chris Lattner
f0241b0652
simplify code
...
llvm-svn: 30661
2006-09-28 23:24:48 +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
Chris Lattner
2da81d7d76
Use LINK_COMPONENTS to specify *components* to link against instead of
...
using USED_LIBS to specify *libraries* to link against.
llvm-svn: 30090
2006-09-04 05:59:09 +00:00
Reid Spencer
249b932022
Provide indentation of the generated program.
...
llvm-svn: 29678
2006-08-14 22:35:15 +00:00
Chris Lattner
9f5a13c5c0
Tools require EH for their top-level try blocks.
...
llvm-svn: 29035
2006-07-07 00:46:19 +00:00
Chris Lattner
c57664f49c
Fix PR819, llvm2cpp should read .bc files, not .ll files.
...
llvm-svn: 29030
2006-07-06 23:48:57 +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
b28a9eedd3
Actually add instructions to the list of defined values so it gets
...
recognized as such! This prevents the CppWriter from treating every
operand as a forward reference and making a mess of the output.
llvm-svn: 28800
2006-06-15 16:09:59 +00:00
Reid Spencer
6919c1b53f
Suppress -pedantic warnings about print("%a")
...
llvm-svn: 28650
2006-06-02 00:39:08 +00:00
Reid Spencer
af36a41a09
Teach CppWriter how to emit an inline (partial) function.
...
llvm-svn: 28645
2006-06-01 23:43:47 +00:00
Reid Spencer
4be70bcdc9
Restore default arguments for llvm2cpp back to health by declaring an
...
emitted variable to actually have a type (picky, picky, picky!)
llvm-svn: 28625
2006-06-01 07:24:29 +00:00
Reid Spencer
b2d478a52b
Fix a bug where incorrect C++ was being emitted.
...
llvm-svn: 28615
2006-06-01 04:21:20 +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
Andrew Lenharth
1ba06d364e
fix utostr
...
llvm-svn: 28597
2006-05-31 20:18:56 +00:00
Reid Spencer
055e4e1fae
Major reorganization and extension of the code. The diff on this will be a
...
mess as functions were moved around into a better ordering. The code was
extended to provide various -gen-* options to better control what the
generated output should be. Currently it is possible to generate entire
modules (three different ways), functions, global variables, and types.
llvm-svn: 28589
2006-05-31 17:31:38 +00:00
Reid Spencer
d5b51c6db3
Don't generate module definitions when the -fragment option is given.
...
llvm-svn: 28583
2006-05-31 04:43:19 +00:00
Reid Spencer
2a2457158d
Fix more bugs. This version now passes all of the Feature test except for
...
a floating point conversion problem with NAN in intrinsics.ll. llvm2cpp
makes an attempt to provide the correct conversion, based on the
implementation in the CBackend writer, but it doesn't get NAN correct.
llvm-svn: 28568
2006-05-30 21:18:23 +00:00
Reid Spencer
d6d062ca7b
Fix many small bugs in llvm2cpp. This patch gets llvm2cpp working with
...
everything except PHI nodes and one odd recurse/opaque type situation.
PHI nodes forward reference INSTRUCTIONS (aaaaaaaahhhhhhh!) :)
llvm-svn: 28554
2006-05-30 10:21:41 +00:00
Reid Spencer
605d7b0bcf
First complete version of llvm2cpp that doesn't crash on any of the Feature
...
tests. The output in a few cases still doesn't compile, however.
llvm-svn: 28547
2006-05-30 03:43:49 +00:00
Reid Spencer
bf39add572
Next batch of implementation:
...
1. Get rid of old AsmWriter cruft that's not needed.
2. Implement several instructions. Enough to get by globalvars.ll and
alignment.ll in the Feature test suite.
3. Handle constants properly (don't repeat definitions).
4. Make the output compatible with llvm-dis for diff purposes.
llvm-svn: 28541
2006-05-29 18:08:06 +00:00
Reid Spencer
a51c941d8a
Fix file header comment.
...
llvm-svn: 28540
2006-05-29 18:06:28 +00:00
Reid Spencer
d526d5be09
Remove temporary testing rules.
...
llvm-svn: 28539
2006-05-29 18:05:59 +00:00
Reid Spencer
631bd45185
Fix two bugs in the CppWriter.cpp:
...
1. Return the module from the MakeModule function so it can be verified.
2. Make sure types get generated with their names
llvm-svn: 28536
2006-05-29 02:58:15 +00:00
Reid Spencer
2bd5cd1602
Fix the file's comment block.
...
llvm-svn: 28535
2006-05-29 02:35:29 +00:00
Reid Spencer
8bd3003e72
Initial Commit of llvm2cpp
...
This is a safekeeping commit. The program is not finished. It currently
handles modules, types, global variables and function declarations. Blocks
and instructions remain to be done.
llvm-svn: 28528
2006-05-29 00:57:22 +00:00