Commit Graph

14663 Commits

Author SHA1 Message Date
Reid Spencer
0fd3061a28 Add HAVE_BZIP2 and HAVE_ZLIB
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16655 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 17:48:37 +00:00
Reid Spencer
047c009394 Excise the ill-advised RLCOMP compression algorithm and simply leave the
previously temporary NULLCOMP implementation that merely copies the data
verbatim without compression. Also, don't warn if there's no compression
library as that is taken care of during configuration time.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16654 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 17:45:44 +00:00
Misha Brukman
b8cbd9f39e Add example 'abstract' architectures for LLI: MIX, MMIX, and DLX
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16653 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 17:36:35 +00:00
Reid Spencer
469c34bdeb Add a context for the callback so different compression scenarios can be
distinguished. Tidy up documentation.  Thanks, Chris.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16652 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 17:29:25 +00:00
Reid Spencer
ce4e6ade3e Minor corrections suggested by Chris' ever-watchful eye.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16651 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 17:26:26 +00:00
Chris Lattner
ebe989c491 Fix build if not HAVE_BZIP2
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16650 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 16:33:25 +00:00
Reid Spencer
9737492204 First version of the MappedFile abstraction for operating system idependent
mapping of files. This first version uses mmap where its available. The
class needs to implement an alternate mechanism based on malloc'd memory
and file reading/writing for platforms without virtual memory.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16649 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 11:08:32 +00:00
Reid Spencer
460eb63612 First version of a support utility to provide generalized compression in
LLVM that handles availability and unavailability of bzip2 and zlib.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16648 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 10:49:41 +00:00
Chris Lattner
955f09666d * Prune #includes
* Update comments
* Rearrange code a bit
* Finally ELIMINATE the GAS workaround emitter for Intel mode.  woot!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16647 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 07:31:08 +00:00
Chris Lattner
ac5701c562 Add support for emitting AT&T style .s files, and make it the default. Users
may now choose their output format with the -x86-asm-syntax={intel|att} flag.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16646 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 07:24:48 +00:00
Chris Lattner
8f99eff156 Convert some missed patterns to support AT&T style
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16645 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 07:23:07 +00:00
Chris Lattner
10f873b420 Apparently the GNU assembler has a HUGE hack to be compatible with really
old and broken AT&T syntax assemblers.  The problem with this hack is that
*SOME* forms of the fdiv and fsub instructions have the 'r' bit inverted.
This was a real pain to figure out, but is trivially easy to support: thus
we are now bug compatible with gas and gcc.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16644 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 07:08:46 +00:00
Reid Spencer
37130d2b5e Provide support for auto-detection and use of compression libraries.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16643 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 07:05:07 +00:00
Chris Lattner
ac6a47588b Fix incorrect suffix
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16642 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 05:20:16 +00:00
Chris Lattner
707c6fe3ad Fix some more missed suffixes and swapped operands
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16641 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 01:38:10 +00:00
Chris Lattner
60c715c9a2 Add missing suffixes to FP instructions for AT&T mode
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16640 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-04 00:43:31 +00:00
Chris Lattner
9a3e49a1b3 Add support for the -x86-asm-syntax flag, which can be used to choose between
Intel and AT&T style assembly language.  The ultimate goal of this is to
eliminate the GasBugWorkaroundEmitter class, but for now AT&T style emission
is not fully operational.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16639 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-03 20:36:57 +00:00
Chris Lattner
3a173dfc72 Add support to the instruction patterns for AT&T style output, which will
hopefully lead to the death of the 'GasBugWorkaroundEmitter'.  This also
includes changes to wrap the whole file to 80 columns! Woot! :)

Note that the AT&T style output has not been tested at all.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16638 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-03 20:35:00 +00:00
Chris Lattner
953c6fe112 Correctly parse variant notation
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16637 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-03 20:19:02 +00:00
Chris Lattner
560a79f1ea Add initial support for variants. This just parses the new format, no
functionality is added


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16636 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-03 19:34:31 +00:00
Chris Lattner
0fa206615a Add initial support for variants
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16635 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-03 19:34:18 +00:00
Reid Spencer
c28d7ad257 Add checks for bzip2 and libz for use with the Compression concept for
lib/System and the compressing llvm archiver.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16634 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-02 08:50:58 +00:00
Chris Lattner
7cf3490892 Do not repeat the map lookup
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16633 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 23:16:43 +00:00
Chris Lattner
bec6a9ea12 When a virtual register is folded into an instruction, keep track of whether
it was a use, def, or both.  This allows us to be less pessimistic in our
analysis of them.  In practice, this doesn't make a big difference, but it
doesn't hurt either.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16632 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 23:15:36 +00:00
Chris Lattner
c2a5730118 Add project
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16631 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 22:25:28 +00:00
Chris Lattner
52b25db3ef Add a simple little improvement to the local spiller to keep track of stores
and delete them if they turn out to be dead.  This is a useful little hack
that even speeds up some programs.  For example, it speeds up Ptrdist/ks
from 17.53s to 15.59s, and 188.ammp from 149s to 146s.

This also speeds up llc :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16630 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 19:47:12 +00:00
Chris Lattner
7fb64347d7 Substantially revamp the local spiller, causing it to actually improve the
generated code over the simple spiller.  The new local spiller generates
substantially better code than the simple one in some cases, by reusing
values that are loaded out of stack slots and kept available in registers.

This primarily helps programs that are spilling a lot, and there is still
stuff that can be done to improve it.  This patch makes the local spiller
the default, as it's only a tiny bit slower than the simple spiller (it
increases the runtime of llc by < 1%).

Here are some numbers with speedups.

Program    #reuse  old(s)    new(s)  Speedup

Povray:     3452,  16.87 ->  15.93   (5.5%)
177.mesa:   2176,   2.77 ->   2.76   (0%)
179.art:      35,  28.43 ->  28.01   (1.5%)
183.equake:   55,  61.44 ->  61.41   (0%)
188.ammp:    869, 174    -> 149      (15%)

164.gzip:     43,  40.73 ->  40.71   (0%)
175.vpr:     351,  18.54 ->  17.34   (6.5%)
176.gcc:    2471,   5.01 ->   4.92   (1.8%)
181.mcf       42,  79.30 ->  75.20   (5.2%)
186.crafty:  484,  29.73 ->  30.04   (-1%)
197.parser:  251,  10.47 ->  10.67   (-1%)
252.eon:    1501,   1.98 ->   1.75   (12%)
253.perlbm: 1183,  14.83 ->  14.42   (2.8%)
254.gap:     825,   7.46 ->   7.29   (2.3%)
255.vortex:  285,  10.51 ->  10.27   (2.3%)
256.bzip2:    63,  55.70 ->  55.20   (0.9%)
300.twolf:   830,  21.63 ->  22.00   (-1%)

PtrDist/ks    14,  32.75 -> 17.53    (46.5%)
Olden/tsp     46,   8.71 ->  8.24    (5.4%)
Free/distray  70,   1.09 ->  0.99    (9.2%)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16629 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 19:04:51 +00:00
Chris Lattner
ef0543689f Pretty print a bit nicer :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16628 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 19:01:39 +00:00
Misha Brukman
6d84e0d781 Add note about converting Skeleton to a useful backend and using it in the
Interpreter.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16627 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 18:36:22 +00:00
Alkis Evlogimenos
c736b3a37a Document this class a bit :-)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16626 91177308-0d34-0410-b5e6-96231b3b80d8
2004-10-01 00:35:07 +00:00
Alkis Evlogimenos
4b97f23a00 Add const version of getLastBlock() member function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16625 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 21:42:02 +00:00
Alkis Evlogimenos
30eed211c9 Remove whitespace from the end of the line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16624 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 21:39:47 +00:00
Brian Gaeke
828c68a4de Make EmitMappingInfo into an "external location" option, so that it can be set
or cleared externally.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16623 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 20:20:01 +00:00
Brian Gaeke
f098ced848 Add accessor function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16622 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 20:14:29 +00:00
Brian Gaeke
b3b1e33632 Correct type of accessor functions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16621 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 20:14:18 +00:00
Brian Gaeke
ccb87cdf07 Namespacify. Add accessor function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16620 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 20:14:07 +00:00
Brian Gaeke
f858f7f380 Add accessor function prototypes for reoptimizer support passes.
Make accessors return FunctionPass* as appropriate.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16619 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 20:13:55 +00:00
Brian Gaeke
6672f86a4d I think this will handle double args.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16618 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 19:44:32 +00:00
Misha Brukman
14abc25f76 That should actually be __MING, not __MINGW.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16617 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 18:28:07 +00:00
Misha Brukman
231684adb4 #include DataTypes.h to compile on MinGW, patch by Henrik Bach.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16616 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 18:27:39 +00:00
Misha Brukman
34ec89cd48 Check for __MINGW define instead of __MINGW_H, patch by Henrik Bach.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16615 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 18:24:58 +00:00
Chris Lattner
dbea9731b1 Use more efficient map operations. Fix a bug that would affect hypothetical
targets that supported multiple memory operands.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16614 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 16:35:08 +00:00
Chris Lattner
477e4555de There is no need to call MachineInstr::print directly, just send the MI& to an ostream.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16613 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 16:10:45 +00:00
Chris Lattner
70ca358b7d * Wrap some comments to 80 cols
* Add const_iterator stuff
* Add a print method, which means that I can now call dump() from the
  debugger.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16612 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 15:59:17 +00:00
Brian Gaeke
d7bf501cc7 Mark the instructions that have delay slots with the hasDelaySlot flag.
Add some comments.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16611 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 04:04:48 +00:00
Brian Gaeke
870248b164 Use TargetMachine::hasDelaySlot() instead of our old switch statement
to find instrs that have delay slots.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16610 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 04:04:47 +00:00
Chris Lattner
0fc27ccdd3 Simplify the logic in the simple spiller and capitalize some variables
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16609 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 02:59:33 +00:00
Chris Lattner
5f7d2d45fd Switch from defaulting to the 'local' spiller to the 'simple' spiller. The
two spillers produce perfectly identical code (at least on povray and eon),
but the simple spiller is substantially faster than the local spiller. Once
the local spiller is improved, we can switch back.

Switching cuts 5.2% off of the llc time for povray (about 1.3s).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16608 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 02:40:06 +00:00
Chris Lattner
4ea1b828eb Don't use a densemap for keeping track of which vregs are already loaded, just
use a simple vector.  This speeds up -spiller=simple from taking 22s to taking
.1s on povray (debug build).  This change does not modify the generated code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16607 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 02:33:48 +00:00
Chris Lattner
7f690e6258 Use longer and more explicit names for instance vars (particularly important
data structures).  Fix the print method to send to the right ostream, not
always cerr.  Delete typedefs that are only used once.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16606 91177308-0d34-0410-b5e6-96231b3b80d8
2004-09-30 02:15:18 +00:00