llvm-project/clang
Simon Tatham 254b4f2500 [ARM,MVE] Add intrinsics for scalar shifts.
This fills in the small family of MVE intrinsics that have nothing to
do with vectors: they implement bit-shift operations on 32- or 64-bit
values held in one or two general-purpose registers. Most of these
shift operations saturate if shifting left, and round to nearest if
shifting right, although LSLL and ASRL behave like ordinary shifts.

When these instructions take a variable shift count in a register,
they pay attention to its sign, so that (for example) LSLL or UQRSHLL
will shift left if given a positive number but right if given a
negative one. That makes even LSLL and ASRL different enough from
standard LLVM IR shift semantics that I couldn't see any better
alternative than to simply model the whole family as a set of
MVE-specific IR intrinsics.

(The //immediate// forms of LSLL and ASRL, on the other hand, do
behave exactly like a standard IR shift of a 64-bit value. In fact,
those forms don't have ACLE intrinsics defined at all, because you can
just write an ordinary C shift operation if you want one of those.)

The 64-bit shifts have to be instruction-selected in C++, because they
deliver two output values. But the 32-bit ones are simple enough that
I could write a DAG isel pattern directly into each Instruction
record.

Reviewers: ostannard, MarkMurrayARM, dmgreen

Reviewed By: dmgreen

Subscribers: kristof.beyls, hiraditya, cfe-commits, llvm-commits

Tags: #clang, #llvm

Differential Revision: https://reviews.llvm.org/D70319
2019-11-19 14:47:29 +00:00
..
INPUTS
bindings Fixed more -Wreturn-type tests 2019-11-09 18:13:51 +01:00
cmake [CMake] Add cross Windows to ARM Linux toolchain CMake cache file. 2019-11-01 12:40:25 -07:00
docs [clang-format] [NFC] add recent changes to release notes 2019-11-19 08:44:27 +00:00
examples Fixup build of clang-interpreter example after change in r370122. 2019-08-28 02:13:24 +00:00
include [ARM,MVE] Add intrinsics for scalar shifts. 2019-11-19 14:47:29 +00:00
lib Revert "[RISCV] Support mutilib in baremetal environment" 2019-11-19 08:16:55 -05:00
runtime
test [ARM,MVE] Add intrinsics for scalar shifts. 2019-11-19 14:47:29 +00:00
tools Revert "[NFC] Refactor representation of materialized temporaries" 2019-11-17 02:09:25 -05:00
unittests [clang-format] fix regression in middle pointer alignment 2019-11-16 14:37:47 +00:00
utils [ARM,MVE] Add intrinsics for vector get/set lane. 2019-11-15 09:53:58 +00:00
www [cxx_status] Update with Belfast motions. 2019-11-09 03:13:21 -08:00
.arcconfig
.clang-format
.clang-tidy
.gitignore
CMakeLists.txt [clang] [cmake] Support LLVM_DISTRIBUTION_COMPONENTS in stand-alone build 2019-10-07 18:14:56 +00:00
CODE_OWNERS.TXT
INSTALL.txt
LICENSE.TXT
ModuleInfo.txt
NOTES.txt
README.txt Revert "test commit" 2019-11-08 14:09:09 +01:00

README.txt

//===----------------------------------------------------------------------===//
// C Language Family Front-end
//===----------------------------------------------------------------------===//

Welcome to Clang.  This is a compiler front-end for the C family of languages
(C, C++, Objective-C, and Objective-C++) which is built as part of the LLVM
compiler infrastructure project.

Unlike many other compiler frontends, Clang is useful for a number of things
beyond just compiling code: we intend for Clang to be host to a number of
different source-level tools.  One example of this is the Clang Static Analyzer.

If you're interested in more (including how to build Clang) it is best to read
the relevant web sites.  Here are some pointers:

Information on Clang:             http://clang.llvm.org/
Building and using Clang:         http://clang.llvm.org/get_started.html
Clang Static Analyzer:            http://clang-analyzer.llvm.org/
Information on the LLVM project:  http://llvm.org/

If you have questions or comments about Clang, a great place to discuss them is
on the Clang development mailing list:
  http://lists.llvm.org/mailman/listinfo/cfe-dev

If you find a bug in Clang, please file it in the LLVM bug tracker:
  http://llvm.org/bugs/