Commit Graph

1222 Commits

Author SHA1 Message Date
Chris Lattner 395aef6bbe Hopefully fix the objdir != srcdir issue
llvm-svn: 9761
2003-11-07 00:34:33 +00:00
Chris Lattner 72a4db8b92 Fix warnings building on sparc
llvm-svn: 9758
2003-11-06 21:30:05 +00:00
Misha Brukman b4ad4c3d4c * Make the comment header 80 columns long
* Alphabetize #includes

llvm-svn: 9751
2003-11-06 18:06:13 +00:00
Misha Brukman e5b358c829 We know exactly what the value of $< is, so instead of using `basename $<` to
get just the filename and not the full path, just use the filename directly.

llvm-svn: 9730
2003-11-05 06:43:36 +00:00
Alkis Evlogimenos 9118a426d3 Change all machine basic block modifier functions in MRegisterInfo to
return the number of instructions added to/removed from the basic block
passed as their first argument.

Note: This is only needed because we use a std::vector instead of an
ilist to keep MachineBasicBlock instructions. Inserting an instruction
to a MachineBasicBlock invalidates all iterators to the basic
block. The return value can be used to update an index to the machine
basic block instruction vector and circumvent the iterator elimination
problem but this is really not needed if we move to a better
representation.

llvm-svn: 9704
2003-11-04 22:57:09 +00:00
Chris Lattner 47dfa641c3 Fix problems in previous changes. This fixes several regressions last night.
llvm-svn: 9694
2003-11-04 16:04:32 +00:00
Chris Lattner b71c3f7430 Significantly simplify constant emission by unifying the stuff which used to build up
strings with the stuff that used to print to an ostream directly.  We now NEVER build
up big strings, only to print them once they are formed.

llvm-svn: 9686
2003-11-03 20:19:49 +00:00
Chris Lattner 469e404370 Incorporate printSingleConstantValue into its single caller
llvm-svn: 9684
2003-11-03 19:44:05 +00:00
Chris Lattner 72e516f0d1 * Reformat some code
* Emit bools as 1/0 instead of true/false, fixing compilation of eon and
  PR 83 & Jello/2003-11-03-GlobalBool.llx

llvm-svn: 9683
2003-11-03 19:33:45 +00:00
Brian Gaeke adc07972bc Tweak sed commands so that they filter out more # stuff and also
work on Mac OS X. Also turn ${...} into $(...); we do not speak BSD
Make.

llvm-svn: 9589
2003-10-29 20:07:35 +00:00
Chris Lattner 37f4a4c184 Delete unused EmitByteSwap method
Implement mul/div/rem constant expressions

llvm-svn: 9424
2003-10-23 17:21:43 +00:00
Misha Brukman 3f45389172 Make code layout more consistent.
llvm-svn: 9418
2003-10-23 16:48:30 +00:00
Misha Brukman 998cabe4ff * Order includes according to style guide
* Convert tabs to spaces
* Make code fit within 80 columns

llvm-svn: 9416
2003-10-23 16:22:08 +00:00
Misha Brukman dbe73c5d6d Add comments to describe what these functions actually do.
llvm-svn: 9370
2003-10-22 05:50:40 +00:00
Misha Brukman 8c0608cf0d * Use <cmath> instead of <math.h>
* Order #includes according to LLVM coding standards

llvm-svn: 9369
2003-10-22 05:09:56 +00:00
Misha Brukman cc0d34223d Removed completely duplicated function comment (an identical one appears later).
llvm-svn: 9368
2003-10-22 04:55:09 +00:00
Misha Brukman 980d74c752 No, really, order the #includes correctly.
llvm-svn: 9367
2003-10-22 04:51:36 +00:00
Misha Brukman 88be700644 * Fix order of #includes to follow style guide
* It's no longer a BasicBlock pass: update comment on run() method
* Fix placement of braces to be consistent
* Delete extraneous whitespace

llvm-svn: 9361
2003-10-22 03:27:45 +00:00
Misha Brukman 53d8490186 Converted tabs to spaces.
llvm-svn: 9360
2003-10-22 03:10:26 +00:00
Chris Lattner 73d9355fea Hrm, unbreak stuph :(
llvm-svn: 9334
2003-10-21 17:22:23 +00:00
Chris Lattner a62228d01a Fix preselection/lowerswitches bug
llvm-svn: 9333
2003-10-21 16:29:23 +00:00
Chris Lattner 4439aee504 Pull the PHI special case into it's own visit* method
llvm-svn: 9332
2003-10-21 16:09:23 +00:00
Chris Lattner 898a42afde The lastOp operand is never used
llvm-svn: 9331
2003-10-21 16:06:07 +00:00
John Criswell 9583cfafc5 Added LLVM copyright notice.
llvm-svn: 9324
2003-10-21 15:29:18 +00:00
John Criswell 29265fe981 Added LLVM copyright header.
llvm-svn: 9321
2003-10-21 15:17:13 +00:00
Chris Lattner 2e2a0ed7e1 Preselection is _not_ a basicblock pass, because it adds global variables to
the module.  This change converts it from being a basic block pass to being
a simple pass.  This allows elimination of the annotation and simplification
of the logic for moving constants into global variables.

llvm-svn: 9320
2003-10-21 14:49:19 +00:00
Vikram S. Adve 8264e29e01 When opcodes like ADD were split into reg. and immed. versions (ADDi and ADDr),
this code wasn't fixed correctly so it missed copy operations that used ADDi.

llvm-svn: 9318
2003-10-21 12:29:45 +00:00
Vikram S. Adve 64e8a13b7b Why does g++ not even generate a warning when you miss a break statement?
llvm-svn: 9317
2003-10-21 12:28:27 +00:00
Vikram S. Adve af2df5b7f9 Implement the new varargs instructions and intrinsics.
llvm-svn: 9316
2003-10-21 11:25:09 +00:00
John Criswell 4436c49787 Added LLVM copyright notice to Makefiles.
llvm-svn: 9312
2003-10-20 22:26:57 +00:00
Brian Gaeke e7621515c0 Goodbye, AddRegNumToValues
llvm-svn: 9309
2003-10-20 20:44:03 +00:00
John Criswell 482202a601 Added LLVM project notice to the top of every C++ source file.
Header files will be on the way.

llvm-svn: 9298
2003-10-20 19:43:21 +00:00
Brian Gaeke ca1789d3f5 Minor leftover fixups from replaceMachineCodeForFunction () change.
llvm-svn: 9295
2003-10-20 17:59:09 +00:00
Brian Gaeke 4bc3958c7b Make replaceMachineCodeForFunction() return void.
llvm-svn: 9289
2003-10-20 15:17:12 +00:00
Brian Gaeke 67a5a865ae Make replaceMachineCodeForFunction return void.
llvm-svn: 9288
2003-10-20 15:15:17 +00:00
Chris Lattner f187b7691d Apparently the dependencies are wrong for this file, so it didn't rebuild it
when changing Instruction.def.  :(

llvm-svn: 9286
2003-10-20 14:12:52 +00:00
Chris Lattner 6acb1bedb1 Emit x86 instructions for: A = B op C, where A and B are 16-bit registers,
C is a constant which can be sign-extended from 8 bits without value loss,
and op is one of: add, sub, imul, and, or, xor.

This allows the JIT to emit the one byte version of the constant instead of
the two or 4 byte version.  Because these instructions are very common, this
can save a LOT of code space.  For example, I sampled two benchmarks, 176.gcc
and 254.gap.

BM        Old     New    Reduction
176.gcc 2673621 2548962  4.89%
254.gap  498261  475104  4.87%

Note that while the percentage is not spectacular, this did eliminate
124.6 _KILOBYTES_ of codespace from gcc.  Not bad.

Note that this doesn't effect the llc version at all, because the assembler
already does this optimization.

llvm-svn: 9284
2003-10-20 05:53:31 +00:00
Chris Lattner 369246d855 Further cleanups and simplifications
llvm-svn: 9282
2003-10-20 04:48:06 +00:00
Chris Lattner 358e7c3edb Eliminate code for pointer size and endianness emulation.
llvm-svn: 9281
2003-10-20 04:11:23 +00:00
Misha Brukman 42856eb1bd The Grammar Police was here.
llvm-svn: 9280
2003-10-20 04:03:10 +00:00
Chris Lattner 97e1b55723 * Rename X86::IMULr16 -> X86::IMULrr16
* Implement R1 = R2 * C where R1 and R2 are 32 or 16 bits. This avoids an
  extra copy into a register, reducing register pressure.

llvm-svn: 9278
2003-10-20 03:42:58 +00:00
Chris Lattner b94550e537 Change the Opcode enum for PHI nodes from "Instruction::PHINode" to "Instruction::PHI" to be more consistent with the other instructions.
llvm-svn: 9269
2003-10-19 21:34:28 +00:00
Chris Lattner bf87734fa0 * Multiplications by 2^X are turned into shifts. This factors code out of the
getelementptr code path for use by other code paths (like malloc and alloca).
* Optimize comparisons with zero
* Generate neg, not, inc, and dec instructions, when possible.

This gives some code size wins, which might translate into performance.  We'll
see tommorow in the nightly tester.

llvm-svn: 9267
2003-10-19 21:09:10 +00:00
Chris Lattner 55a8ef0cc8 Add some new instructions. Wheee
llvm-svn: 9266
2003-10-19 19:25:35 +00:00
Chris Lattner 406ac8e741 .string adds an implicit zero at the end. This is not what we wanted.
This fixes PR#44.

llvm-svn: 9252
2003-10-19 02:51:01 +00:00
Chris Lattner ee898b35a1 Fix bug: Jello/2003-10-18-PHINode-ConstantExpr-CondCode-Failure.llx
This also fixes miscompilation of 176.gcc.

llvm-svn: 9249
2003-10-19 00:26:11 +00:00
Chris Lattner 80a308c920 Add support for the new varargs intrinsics
llvm-svn: 9224
2003-10-18 05:56:40 +00:00
Chris Lattner fb40334c25 Update the sparc backend to at least compile correctly with the new varargs stuff even if it's not all implemented yet.
llvm-svn: 9223
2003-10-18 05:55:58 +00:00
Brian Gaeke c42d7951f2 You can't just blat the address into memory, you have to blat its
displacement.

llvm-svn: 9210
2003-10-17 21:47:25 +00:00
Brian Gaeke 1a7668a9fd Implement replaceMachineCodeForFunction() for x86.
llvm-svn: 9204
2003-10-17 18:27:46 +00:00
Brian Gaeke 2e24fcadf5 Refactor jump insertion code from CompilationCallback() into insertJumpAtAddr().
Make insertFarJumpAtAddr() return void, because nothing uses its return value.
Remove some commented-out code.
Implement replaceMachineCodeForFunction() for SPARC.

llvm-svn: 9203
2003-10-17 18:27:37 +00:00
Brian Gaeke 240fc39b07 Add prototype for replaceMachineCodeForFunction().
llvm-svn: 9202
2003-10-17 18:27:25 +00:00
Brian Gaeke 09d40333a2 Remove extra blank line.
llvm-svn: 9196
2003-10-17 18:09:10 +00:00
Alkis Evlogimenos 8faf8d93d5 Eliminate some extraneous code in SlotCalculator::insertVal().
Rename SlotCalculator::getValSlot() to SlotCalculator::getSlot(),
       SlotCalculator::insertValue() to SlotCalculator::getOrCreateSlot(),
       SlotCalculator::insertVal() to SlotCalculator::insertValue(), and
       SlotCalculator::doInsertVal() to SlotCalculator::doInsertValue().

llvm-svn: 9190
2003-10-17 02:02:40 +00:00
Brian Gaeke c05684ad22 Fix typo in comment.
llvm-svn: 9187
2003-10-16 23:45:05 +00:00
Chris Lattner 068ad84038 Add support for 'weak' linkage.
llvm-svn: 9171
2003-10-16 18:29:00 +00:00
Chris Lattner f95d9b99b3 Decrease usage of use_size()
llvm-svn: 9135
2003-10-15 16:48:29 +00:00
Chris Lattner fdfe370406 Output a contorted sequence of instructions to make sure that we don't access
off the bottom of the stack.  This fixes PR#41

llvm-svn: 9114
2003-10-14 19:09:05 +00:00
Chris Lattner 97c7a8ed1a Disable the leaf function optimization, which is apparently not legal on
X86/linux.  :(  The problem is that a signal delivered while the function
is executing could clobber the functions stack.  This is a partial fix
for PR41.

llvm-svn: 9113
2003-10-14 18:52:41 +00:00
Brian Gaeke 6855f03c56 Remove WordsEmitted statistic; there's already a non-backend-specific
jello statistic for this (just divide #-bytes-of-code-emitted by 4).

Rewrite head-of-file comment.

llvm-svn: 9098
2003-10-13 19:51:20 +00:00
Chris Lattner 44d2c3514a Regularize header file comments
llvm-svn: 9071
2003-10-13 03:32:08 +00:00
Brian Gaeke 2797c131ef Don't include "Config/stdlib.h".
llvm-svn: 9037
2003-10-10 19:12:22 +00:00
Brian Gaeke b8a4ed6543 Include <cstdio> instead of <stdio.h>.
llvm-svn: 9032
2003-10-10 18:46:52 +00:00
Misha Brukman 8b2bd4ed47 Fix spelling.
llvm-svn: 9027
2003-10-10 17:57:28 +00:00
Brian Gaeke 4547ab19b0 Add # of printed instructions statistic to both the SPARC and X86 LLC backends.
llvm-svn: 8892
2003-10-06 15:41:21 +00:00
Chris Lattner fb25374170 Add support for the Invoke instruction by using the LowerInvoke pass
llvm-svn: 8872
2003-10-05 19:16:09 +00:00
Chris Lattner 37225efa97 Instead of hacking in custom support for Invoke/Unwind, use the LowerInvoke pass
llvm-svn: 8871
2003-10-05 19:15:47 +00:00
Alkis Evlogimenos 5facafaabe Moved enum and command-line option in separate file. Also added function that returns the user selected register allocator to the caller.
llvm-svn: 8819
2003-10-02 16:57:49 +00:00
Alkis Evlogimenos 8207a2c079 Change llc command line for register allocators
llvm-svn: 8815
2003-10-02 06:13:19 +00:00
Alkis Evlogimenos 3dfcbf1317 Revert previous change. For some reason this went into the main branch
llvm-svn: 8805
2003-10-01 19:40:13 +00:00
Alkis Evlogimenos 568e4386e8 Added command line option for linear scan allocator
llvm-svn: 8804
2003-10-01 19:38:10 +00:00
Misha Brukman cda2885499 The comment seems irrelevant as the pass has become a BasicBlock pass.
llvm-svn: 8803
2003-10-01 05:24:50 +00:00
Chris Lattner 1440902484 Make sure to get the definition of getRegisterAllocator
llvm-svn: 8801
2003-09-30 22:24:00 +00:00
Chris Lattner 8b583a229d RegisterAllocation.h is going away
llvm-svn: 8795
2003-09-30 20:15:04 +00:00
Brian Gaeke 167d87443a Add statistic for # of emitWord() calls.
llvm-svn: 8772
2003-09-30 17:49:41 +00:00
Misha Brukman 427929adfb Fixed spelling.
llvm-svn: 8687
2003-09-23 17:28:11 +00:00
Misha Brukman 84b1140e2c Fix spelling.
llvm-svn: 8686
2003-09-23 17:27:28 +00:00
Vikram S. Adve 49cf091005 Fix assertion so it doesn't not trip incorrectly.
llvm-svn: 8650
2003-09-21 07:55:27 +00:00
Brian Gaeke 7af0df0015 Fix a typo in Sparc.cpp.
Update names of some pass creator fns in addPassesToEmitAssembly().
FunctionInfo is gone.

llvm-svn: 8599
2003-09-18 17:37:46 +00:00
Brian Gaeke 310b1d899a Rename the pass creator fn to mimic the other creator fn names.
llvm-svn: 8598
2003-09-18 17:37:35 +00:00
Brian Gaeke 24e706c1ac Fix (and properly doxygenify) some comments. Incorporate
functionality of FunctionInfo pass as doFinalization method.
Rename pass to match names of other passes like it.
Rename the pass creator fn to mimic the other creator fn names.
Include StringExtras for utostr().
Make symbol prologue/epilogue stuff redundant with
 EmitBytecodeToAssembly, in preparation for refactoring.

llvm-svn: 8597
2003-09-18 17:37:25 +00:00
Brian Gaeke b4aa604093 Make the symbol prologue/epilogue stuff redundant with MappingInfo, in
preparation for refactoring.
Rename the pass creator fn to mimic the other creator fn names.

llvm-svn: 8596
2003-09-18 17:37:14 +00:00
Vikram S. Adve 256fc40375 Fix longjmp case so that, along with the call to abort(), we also
generate the appropriate CallArgsDescriptor and tmp. virtual regs.

llvm-svn: 8554
2003-09-16 05:56:22 +00:00
Chris Lattner 632cccf646 Be a little more specific about what is begin generated. Only print
command line if VERBOSE=1

llvm-svn: 8453
2003-09-10 19:52:54 +00:00
Chris Lattner 59068a0d71 Only emit inter-field-padding if the amount of padding is != 0
llvm-svn: 8452
2003-09-10 19:52:24 +00:00
John Criswell 732ae94521 Don't explicitly use $SourceDir to find the tblgen files. This causes make
some confusion when trying to generate files (it probably couldn't tell that
./file and $(SourceDir)/file may be the same file).
Now, just let VPATH find everything, and list the primary tblgen file first in
the list of dependencies so that we can just use $< to reference it in the make
rule.

This should hopefully fix the nightly tester.

llvm-svn: 8433
2003-09-10 14:10:44 +00:00
John Criswell ded9899d2d Updated to find source files using VPATH. This makes writing build rules
much cleaner and easier.
Labeled .td as a suffix for tblgen files in Makefile.rules.
Modified build rules so that source files generated during the build are placed
in the build directory and not the source directory (and not in a Debug
directory).  This makes the system cleaner and allows us to have a read-only
source tree.

llvm-svn: 8424
2003-09-09 20:57:03 +00:00
Chris Lattner 230cffbeb3 * Simplify printConstantValueOnly by moving the tail padding stuff directly
into the struct case.
* Extend printConstantValueOnly to print .zero's if the initializer is zero
* Delete dead isConstantFunctionPointerRef function
* Emit the appropriate assembly for the various linkage types!

llvm-svn: 8417
2003-09-09 16:23:36 +00:00
Chris Lattner 04ecefe232 Eliminate support for the llvm.unwind intrinisic, using the Unwind instruction instead
llvm-svn: 8411
2003-09-08 19:44:26 +00:00
Chris Lattner 9c58cf6d03 Add support for the unwind instruction
llvm-svn: 8408
2003-09-08 18:54:55 +00:00
John Criswell 0d1a26ddc2 Checkin of autoconf-style object root.
Adjusted Makefile to work with new autoconf-style object root.
Specifically, use the new -I option of tblgen to find include files.

llvm-svn: 8379
2003-09-06 14:50:22 +00:00
Misha Brukman c1ac706afb Added some optimizations:
* Generate a single BA instead of 6-instruction JUMP if possible
  (this occurs both in the creation and overwriting of the stub code)
* If possible, rewrite the ORIGINAL call to call the generated function
  directly, thus bypassing the stub entirely

Also added some statistics on how often calls are overwritten and how often the
CompilationCallback is invoked.

llvm-svn: 8376
2003-09-05 22:59:31 +00:00
Chris Lattner d189277f32 OptInfo is no longer required
llvm-svn: 8312
2003-09-01 20:41:07 +00:00
Chris Lattner b49a8d7e01 No longer provide an optinfo, noone uses it
llvm-svn: 8311
2003-09-01 20:40:59 +00:00
Chris Lattner 825624e954 Inline simple comparison which is sparc specific anyway
llvm-svn: 8309
2003-09-01 20:38:03 +00:00
Chris Lattner 0792315409 Move private interfaces into private .h file
llvm-svn: 8306
2003-09-01 20:33:07 +00:00
Chris Lattner 8a3d3d26a5 Simplify code a bit
llvm-svn: 8301
2003-09-01 20:24:06 +00:00
Chris Lattner eefb565449 LiveRange.h is now in lib/CodeGen/RegAlloc
llvm-svn: 8299
2003-09-01 20:17:13 +00:00
Chris Lattner e80612a28e LiveRangeInfo got moved into the lib/CodeGen/RegAlloc directory
llvm-svn: 8297
2003-09-01 20:12:17 +00:00
Chris Lattner 8c50571f12 IGNode got moved to lib/CodeGen/RegAlloc
llvm-svn: 8294
2003-09-01 20:00:08 +00:00
Chris Lattner 69382173e9 This file just needs LiveRange.h not IGNode.h
llvm-svn: 8293
2003-09-01 19:58:02 +00:00
Chris Lattner 3323829ecc No longer include IGNode.h in the Sparc global header
llvm-svn: 8292
2003-09-01 19:56:48 +00:00
Misha Brukman 9770b83509 * Use alloca() to force GCC not to eliminate frame pointer
* Break apart saving and restoring registers into separate functions
* Instead of saving single and double FP registers, just save the double
  registers -- aliasing helps preserve the single FP registers as well.
* Request just as much memory for a stub as we actually use

llvm-svn: 8200
2003-08-29 04:22:54 +00:00
Chris Lattner 147b66cd2b Add support for the llvm.unwind intrinsic, which we codegen to just do an abort
until we implement unwinding.
Add support for the invoke instruction, which codegens just like a call with
a branch after it.

The end effect of this change is that programs using the invoke instruction,
but never unwinding, will work fine.  Programs that unwind will abort until
we get unwind support.

llvm-svn: 8187
2003-08-28 21:23:43 +00:00
Chris Lattner 4fd144acc8 Targets should configure themselves based on a Module, not some wierd flags
llvm-svn: 8132
2003-08-24 19:49:48 +00:00
Chris Lattner 2a3b4e5bc7 Implement: Jello/test-constantexpr.ll
llvm-svn: 8127
2003-08-24 19:19:47 +00:00
Chris Lattner e34e200e16 Add support for 'any' pointer size and endianness
llvm-svn: 8120
2003-08-24 13:49:22 +00:00
Chris Lattner 43450cb075 Change all #include'd files to be :: rules instead of : rules
llvm-svn: 8019
2003-08-21 20:37:17 +00:00
Chris Lattner a592cac43c Add support for the sig(set|long)jmp intrinsics
llvm-svn: 7951
2003-08-18 16:06:09 +00:00
Misha Brukman 7eb05a170a Spell `necessary' correctly.
llvm-svn: 7944
2003-08-18 14:43:39 +00:00
Chris Lattner 4b422520ca Fix ABI issue: Longs really do need to be only 4 byte aligned on X86.
This bug caused miscompilation of programs using 'struct stat', but only if
compiled with support for 64-bit filesystems.  This could in theory effect
other things, but only if the LLVM code shared data structures with native code.

llvm-svn: 7928
2003-08-17 23:20:40 +00:00
Brian Gaeke f365176472 Rename -emitmaps to -enable-maps
llvm-svn: 7913
2003-08-16 00:23:16 +00:00
Misha Brukman 0238ea5d69 Now that the JIT memory manager allocates as many bytes as necessary rather than
rounding up to a page, we need to request (num instrs * 4) bytes. However, I
think that 64 bytes is overkill for the stub function.

llvm-svn: 7888
2003-08-15 18:03:06 +00:00
Misha Brukman 7d98bf2921 Fix register and parameter numbers in saving double FP registers.
llvm-svn: 7884
2003-08-15 16:15:28 +00:00
Chris Lattner 3830ba4cd8 Adjust to new API, add expandCall stub
llvm-svn: 7873
2003-08-15 04:51:59 +00:00
Chris Lattner 7235d86507 Add support for unconditional branches and for emitting JE instructions
llvm-svn: 7872
2003-08-15 04:50:49 +00:00
Chris Lattner 572c69ea1e Add a bunch of new node types, including a new Void dummy register class
llvm-svn: 7870
2003-08-15 04:35:14 +00:00
Misha Brukman a12864b1bd * Must save FP registers when calling CompilationCallback(), because FP
registers are global, are NOT windowed, and hence can be clobbered!
* Removed unused register shorthand notations
* Fixed and cleaned up comments in inline assembly

llvm-svn: 7853
2003-08-15 00:26:50 +00:00
Misha Brukman 4aab2b25b3 Since we now have TableGen editing modes for VIM and (X)Emacs, we no longer need
to mark TableGen description files with "C++ mode".

llvm-svn: 7841
2003-08-14 15:16:28 +00:00
Chris Lattner bf0c0100f6 Restore 'nice name' to pass
llvm-svn: 7840
2003-08-14 14:43:24 +00:00
Brian Gaeke 8c14ba96ca Factory methods for function passes now return type FunctionPass *.
llvm-svn: 7839
2003-08-14 06:09:32 +00:00
Brian Gaeke 74db4c7e27 Unbreak SPARC backend: addPassesToJITCompile and
addPassesToEmitMachineCode now both take a FunctionPassManager.

llvm-svn: 7837
2003-08-14 06:04:59 +00:00
Brian Gaeke cbd3a40626 Factory methods for function passes now return type FunctionPass *.
Get rid of RegisterLLC, which can't handle FunctionPasses anyway.

llvm-svn: 7836
2003-08-14 06:04:49 +00:00
Brian Gaeke ec8519d6b6 Unbreak SPARC backend: addPassesToJITCompile and
addPassesToEmitMachineCode now both take a FunctionPassManager.
Factory methods for function passes now return type FunctionPass *.

llvm-svn: 7835
2003-08-14 06:04:29 +00:00
Brian Gaeke ed474bb329 X86 static backend: smacked
Function at a time: smacked

Who you gonna call!!!  :-)

llvm-svn: 7826
2003-08-13 19:02:09 +00:00
Brian Gaeke 89207943a1 Factory methods for FunctionPasses now return type FunctionPass *.
llvm-svn: 7823
2003-08-13 18:18:15 +00:00
Brian Gaeke 845b5af4d4 addPassesToJITCompile and addPassesToEmitMachineCode now take a
FunctionPassManager, to support function-at-a-time compilation and
 emission of code.

llvm-svn: 7821
2003-08-13 18:17:27 +00:00
Brian Gaeke 02cbe2824c addPassesToJITCompile now takes a FunctionPassManager, to support
function-at-a-time compilation and emission of code.
Separate addPassesToEmitAssembly from addPassesToJITCompile, because
 the latter requires you to use FunctionPasses, and the former might
 diverge anyway.

llvm-svn: 7817
2003-08-13 18:15:52 +00:00
Brian Gaeke 1a6f2b83ab Factory methods for FunctionPasses now return type FunctionPass *.
Correct one of the functions' comments.

llvm-svn: 7816
2003-08-13 18:15:29 +00:00
Brian Gaeke 1600c4a70c Factory methods for FunctionPasses now return type FunctionPass *.
Revert (to v1.55) one of the hunks of Chris's change that messed up the
 %-register workaround.

llvm-svn: 7815
2003-08-13 18:15:15 +00:00
Chris Lattner ec611ae0d0 Adjust files for move of mapping info stuff into the Sparc directory
llvm-svn: 7802
2003-08-13 02:38:16 +00:00
Brian Gaeke dd306efa11 Just incorporating some notes I wrote for myself into a place where they won't
get lost...

llvm-svn: 7798
2003-08-13 00:30:48 +00:00
Vikram S. Adve d6f22ad8d3 Disable emitting LLVM-to-MI maps, by default.
Add -emitmaps options to turn this back on.

llvm-svn: 7774
2003-08-12 15:51:02 +00:00
Chris Lattner 58dc2187ac Rename DNVT_bool to DNVT_i1 to be consistent with type system
llvm-svn: 7768
2003-08-12 04:28:21 +00:00
Chris Lattner a8ae6c570f Add support for basicblocks, setCC instructions, and branches
llvm-svn: 7767
2003-08-12 04:17:29 +00:00
Vikram S. Adve 029ed09323 Fix va_arg to generate LDDFi for floating point values, instead of LDXi.
All non-FP cases use LDXi as before.

llvm-svn: 7765
2003-08-12 03:04:05 +00:00
Chris Lattner 7606fa0d41 Add basic support for 16 and 32 bit function arguments!
llvm-svn: 7755
2003-08-11 21:30:00 +00:00
Chris Lattner 6088a0b4cb add frameidx support
Make load work
Make type inference infer from Arg1 to arg0 as well as from arg0 to arg1

llvm-svn: 7754
2003-08-11 21:29:40 +00:00
Chris Lattner 1a2e6f7917 Sort #includes, eliminate #include of "llvm/Type.h" which was redundant
llvm-svn: 7746
2003-08-11 20:06:16 +00:00
Chris Lattner 262c832aea Cygwin apparently works with %'s on registers!
llvm-svn: 7745
2003-08-11 20:04:57 +00:00
Chris Lattner 1ae8eb0021 Whoops, accidental checkin. :(
llvm-svn: 7743
2003-08-11 19:35:46 +00:00
Chris Lattner 9a59f58d90 Add a new -enable-cygwin-compatible-output argument, which make the output more
consumably by the cygwin assembler.  This is really just a nasty hack until we
get real target triple support.

llvm-svn: 7742
2003-08-11 19:35:26 +00:00
Brian Gaeke 12b32533cc Print % signs before register names; turn off "noprefix" mode in gas output.
Fixes test case test/Programs/LLVMSource/2003-08-03-ReservedWordGlobal.ll.

Also: Refactor implicit-uses printing into its own method.
Remove a couple of unused variables.

llvm-svn: 7737
2003-08-11 19:05:46 +00:00
Vikram S. Adve 2df6ea2f38 Register argument to va_start must be marked as defined!
llvm-svn: 7734
2003-08-11 18:42:47 +00:00
Chris Lattner 2923637f63 Add (ret int) expander so that we can at least write testcases
llvm-svn: 7730
2003-08-11 15:48:00 +00:00
Misha Brukman 1117639691 Converted tabs to spaces.
llvm-svn: 7728
2003-08-11 15:38:50 +00:00
Misha Brukman 1024b0ef59 Removed `-debug' so that spurious printouts of patterns are not seen at
compilation time.

llvm-svn: 7727
2003-08-11 15:30:20 +00:00
Chris Lattner 5acb68de53 Remove dead code
llvm-svn: 7726
2003-08-11 15:24:02 +00:00
Chris Lattner 7fed97d00a Add patterns for multiply, and, or, and xor
llvm-svn: 7725
2003-08-11 15:23:25 +00:00
Chris Lattner c914a4847b add support for more nodes
llvm-svn: 7724
2003-08-11 15:23:05 +00:00