summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm2cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* For PR1064:Reid Spencer2007-01-121-27/+24
| | | | | | | | | | | | | | | | | | | | | | | Implement the arbitrary bit-width integer feature. The feature allows integers of any bitwidth (up to 64) to be defined instead of just 1, 8, 16, 32, and 64 bit integers. This change does several things: 1. Introduces a new Derived Type, IntegerType, to represent the number of bits in an integer. The Type classes SubclassData field is used to store the number of bits. This allows 2^23 bits in an integer type. 2. Removes the five integer Type::TypeID values for the 1, 8, 16, 32 and 64-bit integers. These are replaced with just IntegerType which is not a primitive any more. 3. Adjust the rest of LLVM to account for this change. Note that while this incremental change lays the foundation for arbitrary bit-width integers, LLVM has not yet been converted to actually deal with them in any significant way. Most optimization passes, for example, will still only deal with the byte-width integer types. Future increments will rectify this situation. llvm-svn: 33113
* Implement review feedback for the ConstantBool->ConstantInt merge. ChrisReid Spencer2007-01-121-1/+1
| | | | | | | | recommended that getBoolValue be replaced with getZExtValue and that get(bool) be replaced by get(const Type*, uint64_t). This implements those changes. llvm-svn: 33110
* Rename BoolTy as Int1Ty. Patch by Sheng Zhou.Reid Spencer2007-01-111-3/+3
| | | | llvm-svn: 33076
* For PR1043:Zhou Sheng2007-01-111-6/+7
| | | | | | | Merge ConstantIntegral and ConstantBool into ConstantInt. Remove ConstantIntegral and ConstantBool from LLVM. llvm-svn: 33073
* For PR411:Reid Spencer2007-01-061-8/+9
| | | | | | | | | Take an incremental step towards type plane elimination. This change separates types from values in the symbol tables by finally making use of the TypeSymbolTable class. This yields more natural interfaces for dealing with types and unclutters the SymbolTable class. llvm-svn: 32956
* For PR950:Reid Spencer2006-12-311-22/+14
| | | | | | Convert signed integer types to signless. llvm-svn: 32790
* For PR950:Reid Spencer2006-12-231-40/+97
| | | | | | | | 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
* Remove a call to Type::isSigned().Reid Spencer2006-12-181-3/+1
| | | | llvm-svn: 32651
* Generate the correct cast opcode for constant expressions.Reid Spencer2006-12-121-2/+17
| | | | llvm-svn: 32461
* make all llvm tools call llvm_shutdown when they exit, static'ify some stuff.Chris Lattner2006-12-062-2/+5
| | | | | | With this change, I can now move -stats to print when llvm_shutdown is called. llvm-svn: 32250
* For PR950:Reid Spencer2006-11-271-4/+30
| | | | | | | | | | 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
* For PR950:Reid Spencer2006-11-081-3/+6
| | | | | | | | 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
* Make llvm2cpp -pedantic clean.Reid Spencer2006-11-031-1/+1
| | | | llvm-svn: 31389
* For PR786:Reid Spencer2006-11-021-2/+1
| | | | | | | | | | 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
* For PR950:Reid Spencer2006-11-021-3/+9
| | | | | | Replace the REM instruction with UREM, SREM and FREM. llvm-svn: 31369
* For PR950:Reid Spencer2006-10-261-3/+9
| | | | | | | | 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
* For PR950:Reid Spencer2006-10-201-6/+5
| | | | | | | | 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
* simplify codeChris Lattner2006-09-281-2/+1
| | | | llvm-svn: 30661
* Adding dllimport, dllexport and external weak linkage types.Anton Korobeynikov2006-09-141-0/+6
| | | | | | | | | 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
* Use LINK_COMPONENTS to specify *components* to link against instead ofChris Lattner2006-09-041-2/+1
| | | | | | using USED_LIBS to specify *libraries* to link against. llvm-svn: 30090
* Provide indentation of the generated program.Reid Spencer2006-08-141-181/+267
| | | | llvm-svn: 29678
* Tools require EH for their top-level try blocks.Chris Lattner2006-07-071-0/+1
| | | | llvm-svn: 29035
* Fix PR819, llvm2cpp should read .bc files, not .ll files.Chris Lattner2006-07-062-82/+55
| | | | llvm-svn: 29030
* Change the verifier to never throw an exception. Instead verifyModule ↵Chris Lattner2006-07-061-8/+10
| | | | | | canoptionally return the string error, which is an easier api for clients touse anyway. llvm-svn: 29017
* Actually add instructions to the list of defined values so it getsReid Spencer2006-06-151-0/+1
| | | | | | | 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
* Suppress -pedantic warnings about print("%a")Reid Spencer2006-06-021-0/+3
| | | | llvm-svn: 28650
* Teach CppWriter how to emit an inline (partial) function.Reid Spencer2006-06-011-50/+132
| | | | llvm-svn: 28645
* Restore default arguments for llvm2cpp back to health by declaring anReid Spencer2006-06-011-1/+1
| | | | | | emitted variable to actually have a type (picky, picky, picky!) llvm-svn: 28625
* Fix a bug where incorrect C++ was being emitted.Reid Spencer2006-06-011-1/+0
| | | | llvm-svn: 28615
* Use archive libraries instead of object files for VMCore, BCReader,Reid Spencer2006-06-011-2/+2
| | | | | | | BCWriter, and bzip2 libraries. Adjust the various makefiles to accommodate these changes. This was done to speed up link times. llvm-svn: 28610
* fix utostrAndrew Lenharth2006-05-311-1/+1
| | | | llvm-svn: 28597
* Major reorganization and extension of the code. The diff on this will be aReid Spencer2006-05-311-487/+698
| | | | | | | | | 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
* Don't generate module definitions when the -fragment option is given.Reid Spencer2006-05-311-51/+59
| | | | llvm-svn: 28583
* Fix more bugs. This version now passes all of the Feature test except forReid Spencer2006-05-301-135/+244
| | | | | | | | 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
* Fix many small bugs in llvm2cpp. This patch gets llvm2cpp working withReid Spencer2006-05-301-73/+161
| | | | | | | everything except PHI nodes and one odd recurse/opaque type situation. PHI nodes forward reference INSTRUCTIONS (aaaaaaaahhhhhhh!) :) llvm-svn: 28554
* First complete version of llvm2cpp that doesn't crash on any of the FeatureReid Spencer2006-05-301-274/+308
| | | | | | tests. The output in a few cases still doesn't compile, however. llvm-svn: 28547
* Next batch of implementation:Reid Spencer2006-05-291-1148/+265
| | | | | | | | | | 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
* Fix file header comment.Reid Spencer2006-05-291-2/+2
| | | | llvm-svn: 28540
* Remove temporary testing rules.Reid Spencer2006-05-291-14/+0
| | | | llvm-svn: 28539
* Fix two bugs in the CppWriter.cpp:Reid Spencer2006-05-292-4/+17
| | | | | | | 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
* Fix the file's comment block.Reid Spencer2006-05-291-6/+7
| | | | llvm-svn: 28535
* Initial Commit of llvm2cppReid Spencer2006-05-294-0/+2174
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
OpenPOWER on IntegriCloud