1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00
llvm-mirror/lib
Nate Begeman 3b1c0df702 Next round of PPC CR optimizations. For the following code:
int %bar(float %a, float %b, float %c, float %d) {
entry:
    %tmp.1 = setlt float %a, %d
    %tmp.2 = setlt float %b, %d
    %or = or bool %tmp.1, %tmp.2
    %tmp.3 = setgt float %c, %d
    %tmp.4 = or bool %or, %tmp.3
    %tmp.5 = and bool %tmp.4, true
    %retval = cast bool %tmp.5 to int
    ret int %retval
}

We now emit:

_bar:
.LBB_bar_0:     ; entry
        fcmpu cr0, f1, f4
        fcmpu cr1, f2, f4
        cror 0, 0, 4
        fcmpu cr1, f3, f4
        cror 28, 0, 5
        mfcr r2
        rlwinm r3, r2, 29, 31, 31
        blr

Instead of:

_bar:
.LBB_bar_0:     ; entry
        fcmpu cr7, f1, f4
        mfcr r2
        rlwinm r2, r2, 29, 31, 31
        fcmpu cr7, f2, f4
        mfcr r3
        rlwinm r3, r3, 29, 31, 31
        or r2, r2, r3
        fcmpu cr7, f3, f4
        mfcr r3
        rlwinm r3, r3, 30, 31, 31
        or r3, r2, r3
        blr

llvm-svn: 21321
2005-04-18 07:48:09 +00:00
..
Analysis Fix a crash analyzing MultiSource/Benchmarks/MallocBench/gs 2005-04-12 03:59:27 +00:00
AsmParser don't crash in some bad cases. 2005-03-23 01:29:26 +00:00
Bytecode This mega patch converts us from using Function::a{iterator|begin|end} to 2005-03-15 04:54:21 +00:00
CodeGen Fold setcc of MVT::i1 operands into logical operations 2005-04-18 04:48:12 +00:00
Debugger
ExecutionEngine Add support for targets that require stubs for external functions. 2005-04-18 01:44:27 +00:00
Linker fix some 80 column violations 2005-03-15 23:03:34 +00:00
Support Timers SHOULD NOT record the time taken to count the bytes allocated in the heap! 2005-03-22 03:20:38 +00:00
System Eliminate tabs 2005-04-11 03:44:22 +00:00
Target Next round of PPC CR optimizations. For the following code: 2005-04-18 07:48:09 +00:00
Transforms silence a bogus warning 2005-04-18 05:26:21 +00:00
VMCore add an argument to allow avoiding deleting phi nodes. 2005-04-12 18:52:14 +00:00
Makefile