llvm-6502/lib
Preston Gurd 2e2efd9600 Generic Bypass Slow Div
- CodeGenPrepare pass for identifying div/rem ops
- Backend specifies the type mapping using addBypassSlowDivType
- Enabled only for Intel Atom with O2 32-bit -> 8-bit
- Replace IDIV with instructions which test its value and use DIVB if the value
is positive and less than 256.
- In the case when the quotient and remainder of a divide are used a DIV
and a REM instruction will be present in the IR. In the non-Atom case
they are both lowered to IDIVs and CSE removes the redundant IDIV instruction,
using the quotient and remainder from the first IDIV. However,
due to this optimization CSE is not able to eliminate redundant
IDIV instructions because they are located in different basic blocks.
This is overcome by calculating both the quotient (DIV) and remainder (REM)
in each basic block that is inserted by the optimization and reusing the result
values when a subsequent DIV or REM instruction uses the same operands.
- Test cases check for the presents of the optimization when calculating
either the quotient, remainder,  or both.

Patch by Tyler Nowicki!



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163150 91177308-0d34-0410-b5e6-96231b3b80d8
2012-09-04 18:22:17 +00:00
..
Analysis Be conservative about allocations that may alias the accessed pointer. 2012-09-04 03:30:13 +00:00
Archive Remove references to compression in llvm-ar. It has been a long time since we 2012-08-10 01:57:52 +00:00
AsmParser Change the linker_private_weak_def_auto' linkage to linkonce_odr_auto_hide' to 2012-08-17 18:33:14 +00:00
Bitcode Change the linker_private_weak_def_auto' linkage to linkonce_odr_auto_hide' to 2012-08-17 18:33:14 +00:00
CodeGen Generic Bypass Slow Div 2012-09-04 18:22:17 +00:00
DebugInfo Add support for fetching inlining context (stack of source code locations) 2012-09-04 08:12:33 +00:00
ExecutionEngine Fix comment for function RuntimeDyldImpl.resolveRelocation() 2012-08-27 15:34:01 +00:00
Linker Move the "findUsedStructTypes" functionality outside of the Module class. 2012-08-03 00:30:35 +00:00
MC Allow targets to specify a minimum supported NOP size when performing NOP padding. If the desired padding is smaller than the supported NOP size, 2012-08-29 22:18:56 +00:00
Object Reverting r 160419. 2012-07-19 21:43:55 +00:00
Support Fix Android build of gtest and lib/Support. 2012-09-04 09:14:45 +00:00
TableGen Tristate mayLoad, mayStore, and hasSideEffects. 2012-08-23 19:34:46 +00:00
Target Generic Bypass Slow Div 2012-09-04 18:22:17 +00:00
Transforms Generic Bypass Slow Div 2012-09-04 18:22:17 +00:00
VMCore Move the GCOVFormat enums into their own namespace per the LLVM coding standard. 2012-08-31 17:31:28 +00:00
CMakeLists.txt
LLVMBuild.txt LLVMBuild: Introduce a common section which currently has a list of the 2011-12-12 22:45:54 +00:00
Makefile