Chris Lattner [Mon, 20 Oct 2003 17:58:43 +0000 (17:58 +0000)]
fix file header
llvm-svn: 9294
Chris Lattner [Mon, 20 Oct 2003 17:57:13 +0000 (17:57 +0000)]
fix file headers
llvm-svn: 9293
Chris Lattner [Mon, 20 Oct 2003 17:52:11 +0000 (17:52 +0000)]
Fix file header
llvm-svn: 9292
John Criswell [Mon, 20 Oct 2003 17:47:21 +0000 (17:47 +0000)]
Added copyright header to all C++ source files.
llvm-svn: 9291
John Criswell [Mon, 20 Oct 2003 16:39:52 +0000 (16:39 +0000)]
Made the Requirements information its own major section and moved it
between the "Getting Started Quickly" and "Getting Started Slowly" sections.
:)
Removed some of the nit-picky requirements information (i.e. GNU tar and
GNU zip).
Attempted to compact the requirements information so that it is less scary.
llvm-svn: 9290
Brian Gaeke [Mon, 20 Oct 2003 15:17:12 +0000 (15:17 +0000)]
Make replaceMachineCodeForFunction() return void.
llvm-svn: 9289
Brian Gaeke [Mon, 20 Oct 2003 15:15:17 +0000 (15:15 +0000)]
Make replaceMachineCodeForFunction return void.
llvm-svn: 9288
Brian Gaeke [Mon, 20 Oct 2003 15:14:33 +0000 (15:14 +0000)]
Make replaceMachineCodeForFunction return void.
Make it assert by default.
llvm-svn: 9287
Chris Lattner [Mon, 20 Oct 2003 14:12:52 +0000 (14:12 +0000)]
Apparently the dependencies are wrong for this file, so it didn't rebuild it
when changing Instruction.def. :(
llvm-svn: 9286
Chris Lattner [Mon, 20 Oct 2003 05:54:26 +0000 (05:54 +0000)]
Reorder for minor efficiency gain
llvm-svn: 9285
Chris Lattner [Mon, 20 Oct 2003 05:53:31 +0000 (05:53 +0000)]
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
Chris Lattner [Mon, 20 Oct 2003 05:45:49 +0000 (05:45 +0000)]
Hrm, a relic from the past. How cute :)
llvm-svn: 9283
Chris Lattner [Mon, 20 Oct 2003 04:48:06 +0000 (04:48 +0000)]
Further cleanups and simplifications
llvm-svn: 9282
Chris Lattner [Mon, 20 Oct 2003 04:11:23 +0000 (04:11 +0000)]
Eliminate code for pointer size and endianness emulation.
llvm-svn: 9281
Misha Brukman [Mon, 20 Oct 2003 04:03:10 +0000 (04:03 +0000)]
The Grammar Police was here.
llvm-svn: 9280
Misha Brukman [Mon, 20 Oct 2003 03:59:05 +0000 (03:59 +0000)]
* Fixed grammar in header
* Added description of `mem2reg'
llvm-svn: 9279
Chris Lattner [Mon, 20 Oct 2003 03:42:58 +0000 (03:42 +0000)]
* 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
Chris Lattner [Sun, 19 Oct 2003 23:32:50 +0000 (23:32 +0000)]
Don't bother forwarding function references which are external to the program entirely
llvm-svn: 9274
Chris Lattner [Sun, 19 Oct 2003 21:54:13 +0000 (21:54 +0000)]
Ok, return an explicit path to the shared object, unbreaking code generator
debugging with the JIT
llvm-svn: 9273
Chris Lattner [Sun, 19 Oct 2003 21:48:27 +0000 (21:48 +0000)]
Fix iterator invalidation problem
llvm-svn: 9272
Chris Lattner [Sun, 19 Oct 2003 21:39:41 +0000 (21:39 +0000)]
Eliminate unused class
llvm-svn: 9270
Chris Lattner [Sun, 19 Oct 2003 21:34:28 +0000 (21:34 +0000)]
Change the Opcode enum for PHI nodes from "Instruction::PHINode" to "Instruction::PHI" to be more consistent with the other instructions.
llvm-svn: 9269
Chris Lattner [Sun, 19 Oct 2003 21:34:11 +0000 (21:34 +0000)]
Change the Opcode enum for PHI nodes from "Instruction::PHINode" to "Instruction::PHI" to be more consistent with the other instructions.
This allows removal of a special case from the instvisitor
llvm-svn: 9268
Chris Lattner [Sun, 19 Oct 2003 21:09:10 +0000 (21:09 +0000)]
* 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
Chris Lattner [Sun, 19 Oct 2003 19:25:35 +0000 (19:25 +0000)]
Add some new instructions. Wheee
llvm-svn: 9266
Brian Gaeke [Sun, 19 Oct 2003 18:23:05 +0000 (18:23 +0000)]
Change it to match llvmgcc.html ... why do we have separate pages for these two?
llvm-svn: 9265
Brian Gaeke [Sun, 19 Oct 2003 18:15:18 +0000 (18:15 +0000)]
Clarify the roles of gccld and gccas.
Mention that they should really read the gcc manual.
llvm-svn: 9264
Brian Gaeke [Sun, 19 Oct 2003 18:09:24 +0000 (18:09 +0000)]
Minor edits; also expand description of '-v' option.
llvm-svn: 9263
Brian Gaeke [Sun, 19 Oct 2003 18:08:57 +0000 (18:08 +0000)]
Tweak -plugin description to match bugpoint.html
llvm-svn: 9262
Brian Gaeke [Sun, 19 Oct 2003 18:03:11 +0000 (18:03 +0000)]
Mostly rewritten.
llvm-svn: 9261
Chris Lattner [Sun, 19 Oct 2003 17:37:33 +0000 (17:37 +0000)]
A minor fix
llvm-svn: 9260
Brian Gaeke [Sun, 19 Oct 2003 17:37:12 +0000 (17:37 +0000)]
Take out extra paragraph tag.
llvm-svn: 9259
Brian Gaeke [Sun, 19 Oct 2003 17:35:35 +0000 (17:35 +0000)]
Make this (-run) set look like the other (-disable) set.
llvm-svn: 9258
Brian Gaeke [Sun, 19 Oct 2003 17:30:36 +0000 (17:30 +0000)]
Always say "the test program", part 2.
Refer to the various "modules" of bugpoint as "debuggers", not
"debugging modes" or "modules". I think this is more evocative of
how they typically act, and it's shorter.
Add a note about how a linker bug can crash bugpoint early.
llvm-svn: 9257
Chris Lattner [Sun, 19 Oct 2003 17:27:12 +0000 (17:27 +0000)]
Two minor fixes
llvm-svn: 9256
Brian Gaeke [Sun, 19 Oct 2003 17:20:15 +0000 (17:20 +0000)]
Minor edits to Description section.
Add Design Philosophy as a separate subsection. Clarify its last sentence.
Give Automatic Mode Selection a uniquely-named anchor.
Always call the program the "test program", instead of the "initial program",
the "LLVM program", the "test case", the "resultant module", etc.
Try to explain the assumptions a little more, instead of just describing the
process.
llvm-svn: 9255
Brian Gaeke [Sun, 19 Oct 2003 17:03:59 +0000 (17:03 +0000)]
Spell-check.
Many minor edits.
Rewrite some of the options section for grammatical parallelism,
clarity, and brevity.
llvm-svn: 9254
Chris Lattner [Sun, 19 Oct 2003 16:54:00 +0000 (16:54 +0000)]
DeHTMLify the email so that it only gets sent out if something changes.
Add printouts about failed building and testing.
llvm-svn: 9253
Chris Lattner [Sun, 19 Oct 2003 02:51:01 +0000 (02:51 +0000)]
.string adds an implicit zero at the end. This is not what we wanted.
This fixes PR#44.
llvm-svn: 9252
Chris Lattner [Sun, 19 Oct 2003 02:27:40 +0000 (02:27 +0000)]
Add debugtype, make output marginally more nice
llvm-svn: 9251
Chris Lattner [Sun, 19 Oct 2003 02:14:58 +0000 (02:14 +0000)]
Fix PR #47
llvm-svn: 9250
Chris Lattner [Sun, 19 Oct 2003 00:26:11 +0000 (00:26 +0000)]
Fix bug: Jello/2003-10-18-PHINode-ConstantExpr-CondCode-Failure.llx
This also fixes miscompilation of 176.gcc.
llvm-svn: 9249
Chris Lattner [Sat, 18 Oct 2003 23:54:45 +0000 (23:54 +0000)]
New testcase, distilled from 176.gcc codegen failure
llvm-svn: 9248
Chris Lattner [Sat, 18 Oct 2003 21:55:47 +0000 (21:55 +0000)]
Update compile information
llvm-svn: 9247
Chris Lattner [Sat, 18 Oct 2003 21:55:35 +0000 (21:55 +0000)]
Add usage blurb
llvm-svn: 9246
Chris Lattner [Sat, 18 Oct 2003 21:54:47 +0000 (21:54 +0000)]
Without this option, the -run-llc mode does not work with shared objects at
all, making it pointless for use with the code generator debugger. With it,
it works like a charm.
llvm-svn: 9245
Chris Lattner [Sat, 18 Oct 2003 21:34:15 +0000 (21:34 +0000)]
Add bugpoint advice section
llvm-svn: 9244
Chris Lattner [Sat, 18 Oct 2003 21:08:57 +0000 (21:08 +0000)]
Print -fno-strict-aliasing as well
llvm-svn: 9243
Chris Lattner [Sat, 18 Oct 2003 21:02:51 +0000 (21:02 +0000)]
Don't leave a trail of bugpoint-execution-output-* breadcrumbs all over the place
llvm-svn: 9242
Chris Lattner [Sat, 18 Oct 2003 20:57:23 +0000 (20:57 +0000)]
Expand the --args section
llvm-svn: 9241
Chris Lattner [Sat, 18 Oct 2003 20:54:37 +0000 (20:54 +0000)]
* Add the -additional-so option
* Add info about codegen and miscompilation mode
llvm-svn: 9240
Chris Lattner [Sat, 18 Oct 2003 20:36:15 +0000 (20:36 +0000)]
Beef up the description of bugpoint a lot. Update for renamed options
llvm-svn: 9239
Chris Lattner [Sat, 18 Oct 2003 20:30:48 +0000 (20:30 +0000)]
Change run-lli -> run-int
Many people associate lli with the jit, so we don't want to suprise them
llvm-svn: 9238
Chris Lattner [Sat, 18 Oct 2003 20:18:20 +0000 (20:18 +0000)]
Default to using the CBE instead of the Interpreter if no -run-* option is specified
llvm-svn: 9237
Chris Lattner [Sat, 18 Oct 2003 19:48:10 +0000 (19:48 +0000)]
Fix warning
llvm-svn: 9236
Chris Lattner [Sat, 18 Oct 2003 19:31:39 +0000 (19:31 +0000)]
Print stuff to stdout if something changes.
llvm-svn: 9235
Chris Lattner [Sat, 18 Oct 2003 19:27:48 +0000 (19:27 +0000)]
If we detect a pass crash during miscompilation testing, immediately enter the
crash debugger
llvm-svn: 9234
Chris Lattner [Sat, 18 Oct 2003 06:30:21 +0000 (06:30 +0000)]
add support for new linkage types
llvm-svn: 9228
Chris Lattner [Sat, 18 Oct 2003 06:14:59 +0000 (06:14 +0000)]
Fix PR#50
llvm-svn: 9227
Chris Lattner [Sat, 18 Oct 2003 05:57:43 +0000 (05:57 +0000)]
Add support for the new varargs intrinsics and instructions
llvm-svn: 9226
Chris Lattner [Sat, 18 Oct 2003 05:56:52 +0000 (05:56 +0000)]
ADd support for the new varargs instructions
llvm-svn: 9225
Chris Lattner [Sat, 18 Oct 2003 05:56:40 +0000 (05:56 +0000)]
Add support for the new varargs intrinsics
llvm-svn: 9224
Chris Lattner [Sat, 18 Oct 2003 05:55:58 +0000 (05:55 +0000)]
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
Chris Lattner [Sat, 18 Oct 2003 05:55:25 +0000 (05:55 +0000)]
Interpret the new varargs intrinsics correctly
llvm-svn: 9222
Chris Lattner [Sat, 18 Oct 2003 05:54:48 +0000 (05:54 +0000)]
Updated to emit the final 1.0 bytecode format. This supports weak linkage,
more efficient encoding of varargs calls, and the new varargs intrinsics.
llvm-svn: 9221
Chris Lattner [Sat, 18 Oct 2003 05:54:18 +0000 (05:54 +0000)]
* New revised variable argument handling support
* More dense bytecode encoding for varargs calls (like printf)
* Eliminated the extremely old bytecode format. rev #0 is now 1.0
llvm-svn: 9220
Chris Lattner [Sat, 18 Oct 2003 05:53:13 +0000 (05:53 +0000)]
New revised variable argument handling support
llvm-svn: 9219
Chris Lattner [Sat, 18 Oct 2003 05:51:36 +0000 (05:51 +0000)]
Update for new varargs support
llvm-svn: 9218
Chris Lattner [Sat, 18 Oct 2003 00:14:13 +0000 (00:14 +0000)]
Fix bug in my checkin
llvm-svn: 9217
Chris Lattner [Sat, 18 Oct 2003 00:05:05 +0000 (00:05 +0000)]
Another formatting fix
llvm-svn: 9216
Chris Lattner [Fri, 17 Oct 2003 23:07:47 +0000 (23:07 +0000)]
More cleanups
llvm-svn: 9215
Chris Lattner [Fri, 17 Oct 2003 23:03:16 +0000 (23:03 +0000)]
Be more helpful if a pass fails while chasing down a miscompilation
llvm-svn: 9214
Misha Brukman [Fri, 17 Oct 2003 23:00:03 +0000 (23:00 +0000)]
* Align comments into 80 columns
* Stop using full pathnames (we don't know where the source could be)
* Use only relative distance to the source, so a user can download the code and
generate their own copy of the doxygen documentation easily
* Since `docs' has moved one level up, all relative path names lost a `..'
llvm-svn: 9213
Misha Brukman [Fri, 17 Oct 2003 21:59:57 +0000 (21:59 +0000)]
Chris says it's better to assert that TheModule is valid than silently return 0.
llvm-svn: 9212
John Criswell [Fri, 17 Oct 2003 21:50:38 +0000 (21:50 +0000)]
Added additional information about linking dynamic libraries.
llvm-svn: 9211
Brian Gaeke [Fri, 17 Oct 2003 21:47:25 +0000 (21:47 +0000)]
You can't just blat the address into memory, you have to blat its
displacement.
llvm-svn: 9210
John Criswell [Fri, 17 Oct 2003 21:37:26 +0000 (21:37 +0000)]
Adding license information for the sample project.
llvm-svn: 9209
John Criswell [Fri, 17 Oct 2003 21:10:57 +0000 (21:10 +0000)]
Updated the README so that it catagorizes the docs similar to the web page.
Added a few missing docs as well.
llvm-svn: 9208
Misha Brukman [Fri, 17 Oct 2003 18:31:59 +0000 (18:31 +0000)]
Don't release the Module, as that invalidates the Module* within the
ModuleProvider, which has bad consequences in lli::callAsMain() which tries to
access that same Module*.
llvm-svn: 9205
Brian Gaeke [Fri, 17 Oct 2003 18:27:46 +0000 (18:27 +0000)]
Implement replaceMachineCodeForFunction() for x86.
llvm-svn: 9204
Brian Gaeke [Fri, 17 Oct 2003 18:27:37 +0000 (18:27 +0000)]
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
Brian Gaeke [Fri, 17 Oct 2003 18:27:25 +0000 (18:27 +0000)]
Add prototype for replaceMachineCodeForFunction().
llvm-svn: 9202
Misha Brukman [Fri, 17 Oct 2003 18:27:13 +0000 (18:27 +0000)]
Return the Module that we just materialized.
llvm-svn: 9201
Brian Gaeke [Fri, 17 Oct 2003 18:27:12 +0000 (18:27 +0000)]
Tidy up doxygen comment for getPointerToFunction().
Add prototypes for recompileAndRelinkFunction() and runJITOnFunction().
llvm-svn: 9200
Brian Gaeke [Fri, 17 Oct 2003 18:27:00 +0000 (18:27 +0000)]
Refactor running the JIT passes on a single function into the new method,
runJITOnFunction().
Add new method for recompiling and patching in new versions of functions,
recompileAndRelinkFunction().
llvm-svn: 9199
Misha Brukman [Fri, 17 Oct 2003 18:26:51 +0000 (18:26 +0000)]
Return the Module being materialized to avoid always calling getModule().
llvm-svn: 9198
Brian Gaeke [Fri, 17 Oct 2003 18:26:45 +0000 (18:26 +0000)]
Add stub version of replaceMachineCodeForFunction. It will live here until
we have a better place for it to go.
llvm-svn: 9197
Brian Gaeke [Fri, 17 Oct 2003 18:09:10 +0000 (18:09 +0000)]
Remove extra blank line.
llvm-svn: 9196
Chris Lattner [Fri, 17 Oct 2003 18:03:54 +0000 (18:03 +0000)]
Do not crash on empty structures
llvm-svn: 9195
John Criswell [Fri, 17 Oct 2003 17:47:08 +0000 (17:47 +0000)]
Modified the Makefile so that the sample library is linked dynamically.
llvm-svn: 9194
Misha Brukman [Fri, 17 Oct 2003 17:28:21 +0000 (17:28 +0000)]
* Give credit where credit's due
* `Quote' names of projects
* Add emails to people's records
llvm-svn: 9193
Chris Lattner [Fri, 17 Oct 2003 05:20:51 +0000 (05:20 +0000)]
New testcase for C++ frontend crash
llvm-svn: 9192
Chris Lattner [Fri, 17 Oct 2003 05:11:44 +0000 (05:11 +0000)]
Tighten up handling of checks for shift instructions
llvm-svn: 9191
Alkis Evlogimenos [Fri, 17 Oct 2003 02:02:40 +0000 (02:02 +0000)]
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
Alkis Evlogimenos [Fri, 17 Oct 2003 00:50:38 +0000 (00:50 +0000)]
Someone forgot to commit an updated configure after adding tools/llvm-nm to configure.ac :-)
llvm-svn: 9189
Brian Gaeke [Thu, 16 Oct 2003 23:46:01 +0000 (23:46 +0000)]
Add debug variable.
llvm-svn: 9188
Brian Gaeke [Thu, 16 Oct 2003 23:45:05 +0000 (23:45 +0000)]
Fix typo in comment.
llvm-svn: 9187
Brian Gaeke [Thu, 16 Oct 2003 23:43:35 +0000 (23:43 +0000)]
This file has funny include guards and funny extra whitespace.
Make this file less funny.
llvm-svn: 9186
Brian Gaeke [Thu, 16 Oct 2003 23:39:10 +0000 (23:39 +0000)]
Document that llvm-nm works in pipe mode, thanks to the efforts of Chris.
llvm-svn: 9185
Brian Gaeke [Thu, 16 Oct 2003 23:33:38 +0000 (23:33 +0000)]
Fix a typo in a comment, and zap a blank line.
llvm-svn: 9184