llvm/lib
Reid Spencer 9c0696f153 First version that can process arith.cpp test case up to 1024 bits:
1. Ensure pVal is set to 0 in each constructor.
2. Fix roundToDouble to make correct calculations and not read beyond the
   end of allocated memory.
3. Implement Knuth's "classical algorithm" for division from scratch and
   eliminate buffer overflows and uninitialized mememory reads. Document
   it properly too.
4. Implement a wrapper function for KnuthDiv which handles the 64-bit to
   32-bit conversion and back. It also implement short division for the
   n == 1 case that Knuth's algorithm can't handle.
5. Simplify the logic of udiv and urem a little, make them exit early, and
   have them use the "divide" wrapper function to perform the division
   or remainder operation.
6. Move the toString function to the end of the file, closer to where
   the division functions are located.

Note: division is still broken for some > 64 bit values, but at least it
      doesn't crash any more.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34449 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-20 08:51:03 +00:00
..
Analysis For PR1195: 2007-02-15 02:26:10 +00:00
Archive move archive-specific stuff out of bcreader into archive library. 2007-02-07 23:53:17 +00:00
AsmParser remove dead methods 2007-02-19 07:44:24 +00:00
Bytecode For PR1195: 2007-02-15 03:39:18 +00:00
CodeGen Dead code. 2007-02-20 01:29:10 +00:00
Debugger Don't use <sstream> in Streams.h but <iosfwd> instead. 2006-12-07 23:41:45 +00:00
ExecutionEngine For PR1195: 2007-02-15 02:26:10 +00:00
Linker For PR1195: 2007-02-15 02:26:10 +00:00
Support First version that can process arith.cpp test case up to 1024 bits: 2007-02-20 08:51:03 +00:00
System Add possibility to set memory limit for binaries run via libSystem. This 2007-02-16 19:11:07 +00:00
Target How the heck did I forget patterns for llvm.x86.sse2.cmp.sd? 2007-02-20 00:39:09 +00:00
Transforms remove reoptimizer-specific passes 2007-02-20 05:31:49 +00:00
VMCore switch ConstantFP's from ValueMap to DenseMap, which is much faster to query 2007-02-20 07:17:17 +00:00
Makefile Changes to support making the shift instructions be true BinaryOperators. 2007-02-02 02:16:23 +00:00