llvm-project
2e7ea9c9 - [PowerPC] Exploit xxeval instruction for operations of the form ternary(A,X,B) and ternary(A,X,C). (#152956)

Commit
27 days ago
[PowerPC] Exploit xxeval instruction for operations of the form ternary(A,X,B) and ternary(A,X,C). (#152956) Adds support for ternary equivalent operations of the form `ternary(A, X, B)` and `ternary(A, X, C)` where `X=[and(B,C)| nor(B,C)| eqv(B,C)| nand(B,C)]`. The following are the patterns involved and the imm values: | **Operation** | **Immediate Value** | |----------------------------|---------------------| | ternary(A, and(B,C), B) | 49 | | ternary(A, nor(B,C), B) | 56 | | ternary(A, eqv(B,C), B) | 57 | | ternary(A, nand(B,C), B) | 62 | | | | | ternary(A, and(B,C), C) | 81 | | ternary(A, nor(B,C), C) | 88 | | ternary(A, eqv(B,C), C) | 89 | | ternary(A, nand(B,C), C) | 94 | eg. `xxeval XT, XA, XB, XC, 49` - performs `XA ? and(XB, XC) : B`and places the result in `XT`. This is the continuation of [[PowerPC] Exploit xxeval instruction for ternary patterns - ternary(A, X, and(B,C))](https://github.com/llvm/llvm-project/pull/141733#top). --------- Co-authored-by: Tony Varghese <tony.varghese@ibm.com>
Author
Parents
Loading