llvm-project/llvm/lib
Pablo Barrio 512f7ee315 [ARM] Lower lower saturate to 0 and lower saturate to -1 using bit-operations
Summary:
Expressions of the form x < 0 ? 0 :  x; and x < -1 ? -1 : x can be lowered using bit-operations instead of branching or conditional moves

In thumb-mode this results in a two-instruction sequence, a shift followed by a bic or or while in ARM/thumb2 mode that has flexible second operand the shift can be folded into a single bic/or instructions. In most cases this results in smaller code and possibly less branches, and in no case larger than before.

Patch by Martin Svanfeldt

Reviewers: fhahn, pbarrio, rogfer01

Reviewed By: pbarrio, rogfer01

Subscribers: chrib, yroux, eugenis, efriedma, rogfer01, aemerson, javed.absar, kristof.beyls, llvm-commits

Differential Revision: https://reviews.llvm.org/D42574

llvm-svn: 326333
2018-02-28 17:13:07 +00:00
..
Analysis [Dominators] Remove verifyDomTree and add some verifying for Post Dom Trees 2018-02-28 11:00:08 +00:00
AsmParser Make the LLParser accept call instructions of variables in the program AS 2018-02-27 11:15:11 +00:00
BinaryFormat Add DWARF for discriminated unions 2018-02-06 23:45:59 +00:00
Bitcode [DebugInfo] Support DWARF v5 source code embedding extension 2018-02-23 23:01:06 +00:00
CodeGen [DEBUGINFO] Add flag for DWARF2 or less to use sections as references. 2018-02-28 15:02:59 +00:00
DebugInfo [CodeView] Lower __restrict and other pointer qualifiers correctly 2018-02-27 22:08:15 +00:00
Demangle Silence a bunch of implicit fallthrough warnings 2017-12-19 22:05:25 +00:00
ExecutionEngine [RuntimeDyld][MachO] Support ARM64_RELOC_BRANCH26 for BL instructions by 2018-02-28 00:58:21 +00:00
FuzzMutate [llvm-opt-fuzzer] Add another pack of passes for continuous fuzzing 2018-02-19 11:57:07 +00:00
Fuzzer [libFuzzer] Delete llvm/lib/Fuzzer 2017-10-16 20:48:19 +00:00
IR [Dominators] Remove verifyDomTree and add some verifying for Post Dom Trees 2018-02-28 11:00:08 +00:00
IRReader LLParser: add an argument for overriding data layout and do not check alloca addr space 2018-01-30 22:32:39 +00:00
LTO [LTO] Support filtering by hotness threshold 2018-02-26 18:37:45 +00:00
LineEditor
Linker Revert "[IRMover] Implement name based structure type mapping" 2018-02-21 20:12:18 +00:00
MC [WebAssembly] Remove DataSize from linking metadata section 2018-02-27 23:57:37 +00:00
Object [WebAssembly] Fix copy-paste error in debugging string 2018-02-28 14:03:18 +00:00
ObjectYAML [WebAssembly] Remove DataSize from linking metadata section 2018-02-27 23:57:37 +00:00
Option [Option] For typo '-foo', suggest '--foo' 2018-01-09 19:38:04 +00:00
Passes Another try to commit 323321 (aggressive instruction combine). 2018-01-25 12:06:32 +00:00
ProfileData [SampleProf] NFC. Expose reusable functionality in SampleProfile. 2018-02-22 06:42:57 +00:00
Support [ADT] Recognize ppc as valid architecture in target triple. 2018-02-27 10:09:58 +00:00
TableGen TableGen: Remove VarInit::getFieldType 2018-02-25 20:50:17 +00:00
Target [ARM] Lower lower saturate to 0 and lower saturate to -1 using bit-operations 2018-02-28 17:13:07 +00:00
Testing Force #define GTEST_LANG_CXX11. 2017-10-27 21:12:28 +00:00
ToolDrivers [COFF] Keep the underscore on exported decorated stdcall functions in MSVC mode 2018-01-20 11:44:32 +00:00
Transforms [InstCombine] move invariant call out of loop; NFC 2018-02-28 16:50:51 +00:00
WindowsManifest Fix bug 34608 by moving private header out of public header. 2017-09-14 23:01:13 +00:00
XRay [XRay] clarify error messages when parsing broken traces 2018-01-30 13:41:34 +00:00
CMakeLists.txt Moving libFuzzer from LLVM to compiler-rt. 2017-08-21 23:25:12 +00:00
LLVMBuild.txt Re-apply "Introduce FuzzMutate library" 2017-08-21 22:57:06 +00:00