platform/upstream/llvm.git
3 years ago[lldb] Fix build errors from 3bea7306e8
Pavel Labath [Thu, 1 Apr 2021 07:01:35 +0000 (09:01 +0200)]
[lldb] Fix build errors from 3bea7306e8

The addition of the dummy constructors requires matching changes in os-
and arch-specific files, which I forgot about.

3 years ago[lldb] Fix compilation with gcc-6.5
Pavel Labath [Thu, 1 Apr 2021 06:13:50 +0000 (08:13 +0200)]
[lldb] Fix compilation with gcc-6.5

This fixes (works around) two errors with gcc-6.5.
- in the RegisterContext_x86 files, gcc is unable to synthesize a
  default constructor -- it thinks it needs to initialize the virtual
  base class, even though said classes are abstract. I fix that by
  providing a dummy constructor.
- In ReproducerInstrumentationTest, it is not able to deduce that the
  TestingRegistry class is movable (it contains a map of unique
  pointers). I change the type from Optional<TestingRegistry> to
  unique_ptr<TestingRegistry), so that moving is not required
  (copying/moving a polymorphic type is not a very good idea in any
  case).

3 years ago[libc++] Build and test with -Wundef warning. NFC.
Marek Kurdej [Thu, 1 Apr 2021 06:29:55 +0000 (08:29 +0200)]
[libc++] Build and test with -Wundef warning. NFC.

This will avoid typos like `_LIBCPP_STD_VERS` (<future>) or using `#if TEST_STD_VER > 17` without including "test_macros.h".

Reviewed By: ldionne, #libc

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

3 years ago[NFC] Undo some erroneous renamings
Max Kazantsev [Thu, 1 Apr 2021 06:10:10 +0000 (13:10 +0700)]
[NFC] Undo some erroneous renamings

Some vars renamed by mistake during auto-replacements. Undoing them.

3 years ago[NFC] Disambiguate LI in GVN
Max Kazantsev [Thu, 1 Apr 2021 05:31:57 +0000 (12:31 +0700)]
[NFC] Disambiguate LI in GVN

Name GVN uses name 'LI' for two different unrelated things:
LoadInst and LoopInfo. This patch relates the variables with
former meaning into 'Load' to disambiguate the code.

3 years ago[lldb] Remove references to LLDB_CAPTURE_REPRODUCER
Jonas Devlieghere [Thu, 1 Apr 2021 04:40:26 +0000 (21:40 -0700)]
[lldb] Remove references to LLDB_CAPTURE_REPRODUCER

Remove the remaining references to LLDB_CAPTURE_REPRODUCER. I removed
the functionality in an earlier commit but forgot that there was a
corresponding test and logic to unset it in our test suite.

3 years ago[lldb-vscode] Use LLVM's ScopeExit to ensure we always terminate the debugger
Jonas Devlieghere [Thu, 1 Apr 2021 04:34:47 +0000 (21:34 -0700)]
[lldb-vscode] Use LLVM's ScopeExit to ensure we always terminate the debugger

Make sure we always terminate the debugger by using a RAII object.

Differential revision: https://reviews.llvm.org/D99702

3 years ago[lldb-vscode] Consistently use return EXIT_SUCCESS and EXIT_FAILURE (NFC)
Jonas Devlieghere [Thu, 1 Apr 2021 04:35:45 +0000 (21:35 -0700)]
[lldb-vscode] Consistently use return EXIT_SUCCESS and EXIT_FAILURE (NFC)

Consistently use return with EXIT_SUCCESS or EXIT_FAILURE instead of
mix-and-matching return, exit 0, 1 etc.

Differential revision: https://reviews.llvm.org/D99701

3 years ago[debug-info] support new tuning debugger type DBX for XCOFF DWARF
Chen Zheng [Fri, 26 Mar 2021 07:21:46 +0000 (03:21 -0400)]
[debug-info] support new tuning debugger type DBX for XCOFF DWARF

Based on this debugger type, for now, we plan to:
1: use inline string by default for XCOFF DWARF
2: generate no column info for debug line table.

Reviewed By: aprantl

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

3 years ago[lldb] Remove LLDB_CAPTURE_REPRODUCER override
Jonas Devlieghere [Thu, 1 Apr 2021 04:08:55 +0000 (21:08 -0700)]
[lldb] Remove LLDB_CAPTURE_REPRODUCER override

Remove the LLDB_CAPTURE_REPRODUCER as it is inherently dangerous. The
reproducers require careful initialization which cannot be guaranteed by
overwriting the reproducer mode at this level.

If we want to provide this functionality, we should do it in the driver
instead. It was originally added to enable capture in CI, but we now
have a dedicated CI job that captures and replays the test suite.

3 years ago[clang][APINotes] Fix -Wunused-function warning (NFC)
Yang Fan [Thu, 1 Apr 2021 01:16:51 +0000 (09:16 +0800)]
[clang][APINotes] Fix -Wunused-function warning (NFC)

GCC warning:
```
/llvm-project/clang/lib/APINotes/APINotesYAMLCompiler.cpp:574:23: warning: ‘void {anonymous}::Module::dump()’ defined but not used [-Wunused-function]
  574 | LLVM_DUMP_METHOD void Module::dump() {
      |                       ^~~~~~
```

3 years ago[GVN] Propagate llvm.access.group metadata of loads
KAWASHIMA Takahiro [Wed, 31 Mar 2021 11:41:05 +0000 (20:41 +0900)]
[GVN] Propagate llvm.access.group metadata of loads

Before this change, the `llvm.access.group` metadata was dropped
when moving a load instruction in GVN. This prevents vectorizing
a C/C++ loop with `#pragma clang loop vectorize(assume_safety)`.
This change propagates the metadata as well as other metadata if
it is safe (the move-destination basic block and source basic
block belong to the same loop).

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

3 years ago[GVN][NFC] Pre-commit test for D93503
KAWASHIMA Takahiro [Wed, 31 Mar 2021 11:39:44 +0000 (20:39 +0900)]
[GVN][NFC] Pre-commit test for D93503

3 years ago[GVN][NFC] Refactor analyzeLoadFromClobberingWrite
qixingxue [Wed, 31 Mar 2021 23:08:23 +0000 (07:08 +0800)]
[GVN][NFC] Refactor analyzeLoadFromClobberingWrite

This commit adjusts the order of two swappable if statements to
make code cleaner.

Reviewed By: lattner, nikic
Differential Revision: https://reviews.llvm.org/D99648

3 years agoRevert "Add support to -Wa,--version in clang"
Nick Desaulniers [Thu, 1 Apr 2021 00:02:13 +0000 (17:02 -0700)]
Revert "Add support to -Wa,--version in clang"

This reverts commit 3cc3c0f8352ec33ca2f2636f94cb1d85fc57ac16.

Breaks non-linux platforms.

https://reviews.llvm.org/D99556#2662706
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
3 years ago[lld][MachO] Refactor handling of subsections
Alexander Shaposhnikov [Wed, 31 Mar 2021 22:23:19 +0000 (15:23 -0700)]
[lld][MachO] Refactor handling of subsections

This diff is a preparation for fixing FunStabs (incorrect size calculation).
std::map<uint32_t, InputSection*> (SubsectionMap) is replaced with
a sorted vector + binary search. If .subsections_via_symbols is set
this vector will contain the list of subsections, otherwise,
the offsets will be used for calculating the symbols sizes.

Test plan: make check-all

Differential revision: https://reviews.llvm.org/D98837

3 years ago[ValueTracking] Handle non-zero ashr/lshr recurrences
Philip Reames [Wed, 31 Mar 2021 23:47:32 +0000 (16:47 -0700)]
[ValueTracking] Handle non-zero ashr/lshr recurrences

If we know we don't shift out bits (e.g. exact), all we need to know is that input is non-zero.

3 years ago[tests] Add tests for ashr/lshr recurrences in isKnownNonZero
Philip Reames [Wed, 31 Mar 2021 23:36:19 +0000 (16:36 -0700)]
[tests] Add tests for ashr/lshr recurrences in isKnownNonZero

3 years agoAdd support to -Wa,--version in clang
Jian Cai [Wed, 31 Mar 2021 22:37:19 +0000 (15:37 -0700)]
Add support to -Wa,--version in clang

Clang currently only supports -Wa,--version when -no-integrated-as is
used. This adds support to -Wa,--version with -integrated-as.

Link:
https://github.com/ClangBuiltLinux/linux/issues/1320

Reviewed By: nickdesaulniers, MaskRay

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

3 years agoAdd debug printers for KnownBits [nfc]
Philip Reames [Wed, 31 Mar 2021 22:34:57 +0000 (15:34 -0700)]
Add debug printers for KnownBits [nfc]

3 years agoSupport {S,U}REMEqFold before legalization
Simonas Kazlauskas [Sat, 3 Oct 2020 17:25:02 +0000 (20:25 +0300)]
Support {S,U}REMEqFold before legalization

This allows these optimisations to apply to e.g. `urem i16` directly
before `urem` is promoted to i32 on architectures where i16 operations
are not intrinsically legal (such as on Aarch64). The legalization then
later can happen more directly and generated code gets a chance to avoid
wasting time on computing results in types wider than necessary, in the end.

Seems like mostly an improvement in terms of results at least as far as x86_64 and aarch64 are concerned, with a few regressions here and there. It also helps in preventing regressions in changes like {D87976}.

Reviewed By: lebedev.ri

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

3 years ago[RISCV] Add UnsupportedSchedZfh multiclass to reduce duplicate lines from RISCVSchedR...
Craig Topper [Wed, 31 Mar 2021 22:06:07 +0000 (15:06 -0700)]
[RISCV] Add UnsupportedSchedZfh multiclass to reduce duplicate lines from RISCVSchedRocket.td and RISCVSchedSiFive7.td. NFC

3 years ago[X86] add dwarf annotation for inline stack probe
YangKeao [Wed, 31 Mar 2021 20:44:54 +0000 (23:44 +0300)]
[X86] add dwarf annotation for inline stack probe

While probing stack, the stack register is moved without dwarf
information, which could cause panic if unwind the backtrace.
This commit only add annotation for the inline stack probe case.
Dwarf information for the loop case should be done in another
patch and need further discussion.

Reviewed By: nagisa

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

3 years ago[mlir][tosa] Add tosa.reciprocal and tosa.sigmoid lowerings
natashaknk [Wed, 31 Mar 2021 21:10:18 +0000 (14:10 -0700)]
[mlir][tosa] Add tosa.reciprocal and tosa.sigmoid lowerings

Lowering reciprocal and sigmoid elementwise operations to linalg dialect.

Reviewed By: rsuderman

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

3 years ago [dfsan] Set sigemptyset's return label to be 0
Jianzhou Zhao [Wed, 31 Mar 2021 19:44:25 +0000 (19:44 +0000)]
 [dfsan] Set sigemptyset's return label to be 0

This was not set from when the wrapper was introduced.

Reviewed By: gbalats

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

3 years ago[test, InferFunctionAttrs] Fix use of var defined in CHECK-NOT
Thomas Preud'homme [Sun, 28 Mar 2021 00:03:37 +0000 (00:03 +0000)]
[test, InferFunctionAttrs] Fix use of var defined in CHECK-NOT

LLVM test Transforms/InferFunctionAttrs/annotate contains two RUN
invokation (UNKNOWN and NVPTX lines) which involve a CHECK-NOT directive
with a variable not defined by the enabled CHECK prefixes. This commit
fixes that by:

- enabling CHECK prefix for unknown target with specialisation when it
  differs from other targets
- checking for absence of bcmp with any attribute for NVPTX

Reviewed By: tra

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

3 years ago[NFC][LoopRotation] Count the number of instructions hoisted/cloned into preheader
Roman Lebedev [Wed, 31 Mar 2021 20:23:57 +0000 (23:23 +0300)]
[NFC][LoopRotation] Count the number of instructions hoisted/cloned into preheader

3 years agoRevert "Make TableGenGlobalISel an object library"
Philip Reames [Wed, 31 Mar 2021 20:26:19 +0000 (13:26 -0700)]
Revert "Make TableGenGlobalISel an object library"

This reverts commit 2c3cf62d4a26de85aab180bb43a579c913b17f3e.

Causes build failures on x86_64, will respond to commit thread with link errors.

3 years agoMake TableGenGlobalISel an object library
Aaron Puchert [Wed, 31 Mar 2021 20:14:22 +0000 (22:14 +0200)]
Make TableGenGlobalISel an object library

That's how it was originally intended but that wasn't possible because
we still needed to support older CMake versions.

The problem here is that the sources in TableGenGlobalISel are meant to
be linked into both llvm-tblgen and TableGenTests (a unit test), but not
be part of LLVM proper. So they shouldn't be an ordinary LLVM component.
Because they are used in llvm-tblgen, they can't draw in the LLVM dylib
dependency, but then we'd have to do the same thing in TableGenTests to
make sure we don't link both a static Support library and another copy
through the LLVM dylib.

With an object library we're just reusing the object files and don't
have to care about dependencies at all.

Reviewed By: beanz

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

3 years ago[OPENMP]Fix PR48885: Crash in passing firstprivate args to tasks on Apple M1.
Alexey Bataev [Mon, 29 Mar 2021 17:26:42 +0000 (10:26 -0700)]
[OPENMP]Fix PR48885: Crash in passing firstprivate args to tasks on Apple M1.

Need to bitcast the function pointer passed as a parameter to the real
type to avoid possible problem with calling conventions.

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

3 years ago[OPENMP]Fix PR48658: [OpenMP 5.0] Compiler crash when OpenMP atomic sync hints used.
Alexey Bataev [Tue, 30 Mar 2021 17:36:23 +0000 (10:36 -0700)]
[OPENMP]Fix PR48658: [OpenMP 5.0] Compiler crash when OpenMP atomic sync hints used.

No need to consider hint clause kind as the main atomic clause kind at the
codegen.

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

3 years ago[tests] Exercise cases where SCEV can use trip counts to refine ashr/lshr recurrences
Philip Reames [Wed, 31 Mar 2021 19:48:14 +0000 (12:48 -0700)]
[tests] Exercise cases where SCEV can use trip counts to refine ashr/lshr recurrences

3 years ago[lld-macho] Parallelize UUID hash computation
Jez Ng [Wed, 31 Mar 2021 19:48:18 +0000 (15:48 -0400)]
[lld-macho] Parallelize UUID hash computation

This reuses the approach (and some code) from LLD-ELF.

It's a decent win when linking chromium_framework on a Mac Pro (3.2 GHz 16-Core Intel Xeon W):

      N           Min           Max        Median           Avg        Stddev
  x  20          4.58          4.83          4.66        4.6685   0.066591844
  +  20          4.42          4.61           4.5         4.505    0.04751731
  Difference at 95.0% confidence
          -0.1635 +/- 0.0370242
          -3.5022% +/- 0.793064%
          (Student's t, pooled s = 0.0578462)

The output binary is 381MB.

Reviewed By: #lld-macho, oontvoo

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

3 years ago[lld-macho][nfc] Test that -ObjC will import bitcode with category sections
Jez Ng [Wed, 31 Mar 2021 19:48:14 +0000 (15:48 -0400)]
[lld-macho][nfc] Test that -ObjC will import bitcode with category sections

The functionality was originally added in {D95265}, but the test in that
diff only checked if `-ObjC` would cause bitcode containing ObjC class
symbols to be loaded. It neglected to test for bitcode containing
categories but no class symbols.

This diff also changes the lto-archive.ll test to use `-why_load`
instead of inspecting the output binary's symbol table. This is
motivated by the stacked diff {D99105}, which will hide irrelevant
bitcode symbols.

Reviewed By: #lld-macho, oontvoo

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

3 years ago[SLP]Update test checks, NFC
Alexey Bataev [Wed, 31 Mar 2021 19:35:38 +0000 (12:35 -0700)]
[SLP]Update test checks, NFC

3 years ago[SelectionDAG] Remove unneeded vector resize from the end of FoldConstantArithmetic...
Craig Topper [Wed, 31 Mar 2021 19:25:42 +0000 (12:25 -0700)]
[SelectionDAG] Remove unneeded vector resize from the end of FoldConstantArithmetic. NFC

There's an assert right before that makes sure the size already matches.
Earlier in this function's life, scalars and vectors shared more
code.

3 years ago[mlir][cse] do not replace operands in previously simplified operations
Andrew Young [Mon, 29 Mar 2021 02:25:32 +0000 (19:25 -0700)]
[mlir][cse] do not replace operands in previously simplified operations

If an operation has been inserted as a key in to the known values
hashtable, then it can not be modified in a way which changes its hash.
This change avoids modifying the operands of any previously recorded
operation, which prevents their hash from changing.

In an SSACFG region, it is impossible to visit an operation before
visiting its operands, so this is not a problem. This situation can only
happen in regions without strict dominance, such as graph regions.

Reviewed By: rriddle

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

3 years ago[ConstantFolding] Fixing addo/subo with undef
George Mitenkov [Wed, 31 Mar 2021 18:46:28 +0000 (21:46 +0300)]
[ConstantFolding] Fixing addo/subo with undef

When folding addo/subo with undef, the current
convention is to use { -1, false } for addo and
{ 0, false } for subo. This was fixed for InstSimplify in
https://reviews.llvm.org/rGf094d65beaa492e845b03561eddd75b5be653a01,
but not in ConstantFolding.

Reviewed By: nikic, lebedev.ri

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

3 years ago[SLP]Add a test for the bug in `getVectorElementSize()`, NFC.
Alexey Bataev [Wed, 31 Mar 2021 18:21:54 +0000 (11:21 -0700)]
[SLP]Add a test for the bug in `getVectorElementSize()`, NFC.

3 years ago[flang] Refine checks for pointer initialization targets
peter klausler [Wed, 31 Mar 2021 16:12:28 +0000 (09:12 -0700)]
[flang] Refine checks for pointer initialization targets

f18 was emitting a bogus error message about the lack of a TARGET
attribute when a pointer was initialized with a component of a
variable that was a legitimate TARGET.

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

3 years ago[LoopVectorize] Use SetVector to track uniform uses to prevent non-determinism.
Huihui Zhang [Wed, 31 Mar 2021 17:58:36 +0000 (10:58 -0700)]
[LoopVectorize] Use SetVector to track uniform uses to prevent non-determinism.

Use SetVector instead of SmallPtrSet to track values with uniform use. Doing this
can help avoid non-determinism caused by iterating over unordered containers.

This bug was found with reverse iteration turning on,
--extra-llvm-cmake-variables="-DLLVM_REVERSE_ITERATION=ON".
Failing LLVM test consecutive-ptr-uniforms.ll .

Reviewed By: MaskRay

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

3 years agoMove non-spec TOSA operators into TosaUtilOps.td
Suraj Sudhir [Wed, 31 Mar 2021 17:48:21 +0000 (10:48 -0700)]
Move non-spec TOSA operators into TosaUtilOps.td

Reviewed By: stellaraccident

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

3 years ago[Driver] Move detectLibcxxIncludePath to ToolChain
Petr Hosek [Tue, 22 Sep 2020 08:01:16 +0000 (01:01 -0700)]
[Driver] Move detectLibcxxIncludePath to ToolChain

This helper method is useful even outside of Gnu toolchains, so move
it to ToolChain so it can be reused in other toolchains such as Fuchsia.

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

3 years ago[WebAssembly] Implement i64x2 comparisons
Thomas Lively [Wed, 31 Mar 2021 17:46:17 +0000 (10:46 -0700)]
[WebAssembly] Implement i64x2 comparisons

Removes the prototype builtin and intrinsic for i64x2.eq and implements that
instruction as well as the other i64x2 comparison instructions in the final SIMD
spec. Unsigned comparisons were not included in the final spec, so they still
need to be scalarized via a custom lowering.

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

3 years ago[ValueTracking] Add with.overflow intrinsics to poison analysis functions
Juneyoung Lee [Wed, 31 Mar 2021 17:01:17 +0000 (02:01 +0900)]
[ValueTracking] Add with.overflow intrinsics to poison analysis functions

This is a patch teaching ValueTracking that `s/u*.with.overflow` intrinsics do not
create undef/poison and they propagate poison.
I couldn't write a nice example like the one with ctpop; ValueTrackingTest.cpp were simply updated
to check these instead.
This patch helps reducing regression while fixing https://llvm.org/pr49688 .

Reviewed By: nikic

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

3 years ago[SCEV] Handle unreachable binop when matching shift recurrence
Philip Reames [Wed, 31 Mar 2021 17:29:21 +0000 (10:29 -0700)]
[SCEV] Handle unreachable binop when matching shift recurrence

This fixes an issue introduced with my change d4648e, and reported in pr49768.

The root problem is that dominance collapses in unreachable code, and that LoopInfo explicitly only models reachable code.  Since the recurrence matcher doesn't filter by reachability (and can't easily because not all consumers have domtree), we need to bailout before assuming that finding a recurrence implies we found a loop.

3 years ago[X86] Improve SMULO/UMULO codegen for vXi8 vectors.
Craig Topper [Wed, 31 Mar 2021 16:49:16 +0000 (09:49 -0700)]
[X86] Improve SMULO/UMULO codegen for vXi8 vectors.

The default expansion creates a MUL and either a MULHS/MULHU. Each
of those separately expand to sequences that use one or more
PMULLW instructions as well as additional instructions to
extend the types to vXi16. The MULHS/MULHU expansion computes the
whole 16-bit product, but only keeps the high part.

We can improve the lowering of SMULO/UMULO for some cases by using the MULHS/MULHU
expansion, but keep both the high and low parts. And we can use
those parts to calculate the overflow.

For AVX512 we might have vXi1 overflow outputs. We can improve those by using
vpcmpeqw to produce a k register if AVX512BW is enabled. This is a little better
than truncating the high result to use vpcmpeqb. If we don't have avx512bw we
can extend up to v16i32 to use vpcmpeqd to produce a k register.

Reviewed By: RKSimon

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

3 years ago[PowerPC] [MLICM] Enable hoisting of caller preserved registers on AIX
Shimin Cui [Wed, 31 Mar 2021 16:36:49 +0000 (12:36 -0400)]
[PowerPC] [MLICM] Enable hoisting of caller preserved registers on AIX

On ppc64 linux , MachineLICM will hoist caller preserved registers, including TOC loads of the global variable address, out of loops. This is to enable this on AIX for both ppc64 and ppc32.

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

3 years ago[X86] Improve optimizeCompareInstr for signed comparisons after BMI/TBM instructions
Craig Topper [Wed, 31 Mar 2021 16:41:02 +0000 (09:41 -0700)]
[X86] Improve optimizeCompareInstr for signed comparisons after BMI/TBM instructions

We previously couldn't optimize out a TEST if the branch/setcc/cmov
used the overflow flag. This patches allows the TEST to be removed
if the flag producing instruction is known to clear the OF flag.
Thats what the TEST instruction would have done so that should be
equivalent.

Need to add test cases. I'll try to get back to this if I have bandwidth.

Fixes PR48768.

Reviewed By: RKSimon

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

3 years ago[LTO][Legacy] Decouple option parsing from LTOCodeGenerator
Wael Yehia [Wed, 31 Mar 2021 16:42:12 +0000 (16:42 +0000)]
[LTO][Legacy] Decouple option parsing from LTOCodeGenerator

in this patch we add a new libLTO API to specify debug options independent of an lto_code_gen_t.
This allows clients to pass codegen flags (through libLTO) which otherwise today are ignored.

Reviewed By: steven_wu

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

3 years ago[RISCV] Add RISCVISD opcodes for CLZW and CTZW.
Craig Topper [Wed, 31 Mar 2021 16:27:22 +0000 (09:27 -0700)]
[RISCV] Add RISCVISD opcodes for CLZW and CTZW.

Our CLZW isel pattern is quite easily broken by surrounding code
preventing it from matching sometimes. This usually results in
failing to remove the and X, 0xffffffff inserted by type
legalization. The add with -32 that type legalization also inserts
will often gets combined into other add/sub nodes. That doesn't
usually result in extra code when we don't use clzw.

CTTZ seems to be less fragile, but I wanted to keep it consistent
with CTLZ.

Reviewed By: asb, HsiangKai

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

3 years ago[AMDGPU] Add some image tests with enable-prt-strict-null disabled. NFC.
Jay Foad [Wed, 31 Mar 2021 15:54:21 +0000 (16:54 +0100)]
[AMDGPU] Add some image tests with enable-prt-strict-null disabled. NFC.

3 years ago[AMDGPU] Use a common check prefix for some image tests. NFC.
Jay Foad [Wed, 31 Mar 2021 15:51:16 +0000 (16:51 +0100)]
[AMDGPU] Use a common check prefix for some image tests. NFC.

3 years ago[RISCV] Add isel patterns to select vsub_vx intrinsic to vadd.vi if it uses a small...
Craig Topper [Wed, 31 Mar 2021 16:22:38 +0000 (09:22 -0700)]
[RISCV] Add isel patterns to select vsub_vx intrinsic to vadd.vi if it uses a small enough immediate

Also modify the simm5_plus1 check because Imm-1 is UB if Imm happens
to be INT64_MIN. I don't think the compiler would optimize based on that in this
usage, but it could fail UBSan or -ftrapv.

Reviewed By: HsiangKai, frasercrmck

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

3 years ago[llvm-jitlink] Fix -Wunused-function on Windows
Arthur Eubanks [Tue, 30 Mar 2021 16:30:05 +0000 (09:30 -0700)]
[llvm-jitlink] Fix -Wunused-function on Windows

Reviewed By: sgraenitz

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

3 years ago[WebAssembly] Raname a test and fix comments
Heejin Ahn [Wed, 31 Mar 2021 09:32:51 +0000 (02:32 -0700)]
[WebAssembly] Raname a test and fix comments

D99627 fixed a decoding bug, not an encoding bug. This renames the test
to correct it and fix comments.

Reviewed By: dschuff

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

3 years ago[InstCombine] fold abs(srem X, 2)
Sanjay Patel [Wed, 31 Mar 2021 15:26:22 +0000 (11:26 -0400)]
[InstCombine] fold abs(srem X, 2)

This is a missing optimization based on an example in:
https://llvm.org/PR49763

As noted there and the test here, we could add a more
general fold if that is shown useful.

https://alive2.llvm.org/ce/z/xEHdTv
https://alive2.llvm.org/ce/z/97dcY5

3 years ago[InstCombine] add tests for srem+abs; NFC
Sanjay Patel [Wed, 31 Mar 2021 13:29:49 +0000 (09:29 -0400)]
[InstCombine] add tests for srem+abs; NFC

3 years ago[AArch64][SVE] Add tests for UREM/SREM using fixed SVE types
Bradley Smith [Wed, 24 Mar 2021 11:16:20 +0000 (11:16 +0000)]
[AArch64][SVE] Add tests for UREM/SREM using fixed SVE types

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

3 years ago[clang][parser] Allow GNU-style attributes in explicit template...
Timm Bäder [Wed, 3 Mar 2021 09:45:07 +0000 (10:45 +0100)]
[clang][parser] Allow GNU-style attributes in explicit template...

... instantiations

They are currently not being diagnosed because ProhibitAttributes() does
not handle attribute lists with an invalid source range. But once it
does, we need to allow GNU attributes in this place.

Additionally, start optionally diagnosing empty attr lists in
ProhibitCXX11Attributes(), since ProhibitAttribute() does it.

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

3 years ago[libc++] Mark convert_copy.pass.cpp as UNSUPPORTED on clang-13 (i.e. trunk).
Arthur O'Dwyer [Wed, 31 Mar 2021 14:18:51 +0000 (10:18 -0400)]
[libc++] Mark convert_copy.pass.cpp as UNSUPPORTED on clang-13 (i.e. trunk).

Because the constexpr-time codepath triggers a Clang bug. It seems
that Clang compiles it okay in release mode, but when Clang itself
is compiled in debug mode (with assertions turned on), this input
triggers an assertion failure in Clang itself. See comments on D96385
and Clang bug report https://bugs.llvm.org/show_bug.cgi?id=45879

This commit should get the debug-mode buildbots back to green.

3 years ago[RISCV] Add XFAIL riscv32 for known issue with the old pass manager
Luís Marques [Wed, 31 Mar 2021 14:18:02 +0000 (15:18 +0100)]
[RISCV] Add XFAIL riscv32 for known issue with the old pass manager

See D80668, rG7b4832648a63 and https://bugs.llvm.org/show_bug.cgi?id=46117
for details of the issue.

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

3 years ago[SVE] Fix LoopVectorizer test scalalable-call.ll
Sander de Smalen [Tue, 23 Feb 2021 17:10:12 +0000 (17:10 +0000)]
[SVE] Fix LoopVectorizer test scalalable-call.ll

This marks FSIN and other operations to EXPAND for scalable
vectors, so that they are not assumed to be legal by the cost-model.

Depends on D97470

Reviewed By: dmgreen, paulwalker-arm

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

3 years ago[CostModel] Align the cost model for intrinsics for scalable/fixed-width vectors.
Sander de Smalen [Mon, 25 Jan 2021 13:59:37 +0000 (13:59 +0000)]
[CostModel] Align the cost model for intrinsics for scalable/fixed-width vectors.

Let getIntrinsicInstrCost call getTypeBasedIntrinsicInstrCost for scalable vectors,
similar to how this is done for fixed-width vectors, instead of falling back
on BaseT::getIntrinsicInstrCost().

If the intrinsic cannot be costed (or is not overloaded by the target),
it will return InstructionCost::getInvalid() instead.

Depends on D97469

Reviewed By: david-arm

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

3 years ago[C++2b] Support size_t literals
Anton Bikineev [Sat, 27 Mar 2021 16:27:21 +0000 (16:27 +0000)]
[C++2b] Support size_t literals

This adds support for C++2b's z/uz suffixes for size_t literals (P0330).

3 years ago[libc++] Avoid <climits> dependency in <thread>
Joerg Sonnenberger [Thu, 18 Feb 2021 14:15:53 +0000 (15:15 +0100)]
[libc++] Avoid <climits> dependency in <thread>

The standard guarantees sleep durations of 2^63-1 nanoseconds to work.
Instead of depending on INT64_MAX or ULONGLONG_MAX to exist via the
header pollution, fold the constant directly. That has the additional
positive side effect that it avoids long double arithmetic bugs in GCC.

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

3 years agoRevert "[clang][Checkers] Extend PthreadLockChecker state dump (NFC)."
Balázs Kéri [Wed, 31 Mar 2021 13:28:53 +0000 (15:28 +0200)]
Revert "[clang][Checkers] Extend PthreadLockChecker state dump (NFC)."

This reverts commit 49c0ab6d7611050ae902f6369fc878e17da453ad.

Test failures showed up because non-deterministic output.

3 years agoNFC: Change getIntrinsicInstrCost to return InstructionCost
Sander de Smalen [Fri, 22 Jan 2021 17:14:44 +0000 (17:14 +0000)]
NFC: Change getIntrinsicInstrCost to return InstructionCost

This patch migrates the TTI cost interfaces to return an InstructionCost.

See this patch for the introduction of the type: https://reviews.llvm.org/D91174
See this thread for context: http://lists.llvm.org/pipermail/llvm-dev/2020-November/146408.html

Depends on D97468

Reviewed By: dmgreen

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

3 years agoNFC: Change getTypeBasedIntrinsicCost to return InstructionCost
Sander de Smalen [Fri, 22 Jan 2021 17:34:10 +0000 (17:34 +0000)]
NFC: Change getTypeBasedIntrinsicCost to return InstructionCost

This patch migrates the TTI cost interfaces to return an InstructionCost.

See this patch for the introduction of the type: https://reviews.llvm.org/D91174
See this thread for context: http://lists.llvm.org/pipermail/llvm-dev/2020-November/146408.html

Depends on D97466

Reviewed By: dmgreen

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

3 years ago[Test] Auto-update test checks
Max Kazantsev [Wed, 31 Mar 2021 11:20:19 +0000 (18:20 +0700)]
[Test] Auto-update test checks

3 years agoRevert "[LLDB] Arm64/Linux Add MTE and Pointer Authentication registers"
Muhammad Omair Javaid [Wed, 31 Mar 2021 12:10:03 +0000 (17:10 +0500)]
Revert "[LLDB] Arm64/Linux Add MTE and Pointer Authentication registers"

This reverts commit 1164b4e2957290e814c3dd781a68e504dd39148e.

Reason: LLDB AArch64 Linux buildbot failure

3 years agoRevert "[LLDB] Arm64/Linux test case for MTE and Pointer Authentication regset"
Muhammad Omair Javaid [Wed, 31 Mar 2021 12:08:07 +0000 (17:08 +0500)]
Revert "[LLDB] Arm64/Linux test case for MTE and Pointer Authentication regset"

This reverts commit 9ab677180091a690cd99d4ac55d5fb9e1149b1ec.

Reason: LLDB AArch64/Linux buildbot failure.

3 years ago[InlineCost] Remove TODO comment that consider other forms of savings in the cost...
Liqiang Tao [Wed, 31 Mar 2021 11:52:58 +0000 (19:52 +0800)]
[InlineCost] Remove TODO comment that consider other forms of savings in the cost-benefit analysis

Attempts to compute savings more accurately cannot impact the set of critically important call sites.

Reviewed By: kazu

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

3 years ago[X86] AMD Zen 3 has macro fusion
Roman Lebedev [Wed, 31 Mar 2021 11:14:13 +0000 (14:14 +0300)]
[X86] AMD Zen 3 has macro fusion

This is an improvement over Zen 2, where only branch fusion is supported,
as per Agner, 21.4 Instruction fusion.
AMD SOG 17h has no mention of fusion.

AMD SOG 19h, 2.9.3 Branch Fusion
The following flag writing instructions support branch fusion
with their reg/reg, reg/imm and reg/mem forms
* CMP
* TEST
* SUB
* ADD
* INC (no fusion with branches dependent on CF)
* DEC (no fusion with branches dependent on CF)
* OR
* AND
* XOR

Agner, 22.4 Instruction fusion
<...> This applies to CMP, TEST, ADD, SUB, AND, OR, XOR, INC, DEC and
all conditional jumps, except if the arithmetic or logic instruction has a rip-relative address or
both an address displacement and an immediate operand.

3 years ago[ASTImporter][NFC] Fix duplicated symbols in "Improve test coverage"
Balazs Benics [Wed, 31 Mar 2021 10:47:37 +0000 (12:47 +0200)]
[ASTImporter][NFC] Fix duplicated symbols in "Improve test coverage"

D99576 introduced a duplicate symbol, now im removing it.

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

3 years ago[RISCV] Add support for the stepvector intrinsic
Fraser Cormack [Tue, 30 Mar 2021 13:49:25 +0000 (14:49 +0100)]
[RISCV] Add support for the stepvector intrinsic

This adds almost everything required for supporting the new stepvector
intrinsic on RVV. It is lowered to the existing VID_VL SDNode.

The only exception is a limitation that RV32 cannot yet lower the
intrinsic on i64 vectors. This is because the step operand is
(currently) required to be at least as large as the vector element type.
I will look into patching that out and loosening the requirement to only
an integer pointer type.

Reviewed By: craig.topper

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

3 years agoRevert "[LLDB] Skip TestVSCode_disconnect.test_launch arm/linux"
Muhammad Omair Javaid [Wed, 31 Mar 2021 09:36:38 +0000 (14:36 +0500)]
Revert "[LLDB] Skip TestVSCode_disconnect.test_launch arm/linux"

This reverts commit 73cf85e527f69c495daece7c74743b9073d4717c.

3 years ago[AMDGPU][GlobalISel] Add support for global atomicrmw fadd
Jay Foad [Mon, 1 Mar 2021 17:24:57 +0000 (17:24 +0000)]
[AMDGPU][GlobalISel] Add support for global atomicrmw fadd

This includes gfx908 which only has a no-return version of the
global_atomic_add_f32 instruction, using the same hack that was
previously implemented for selecting from the
llvm.amdgcn.global.atomic.fadd intrinsic.

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

3 years ago[ASTImporter][NFC] Improve test coverage
Balazs Benics [Wed, 31 Mar 2021 10:10:23 +0000 (12:10 +0200)]
[ASTImporter][NFC] Improve test coverage

All three cases were imported correctly.
For BlockDecls, correctly means that we don't support importing them, thus an
error is the expected behaviour.

 - BlockDecls were not yet covered. I know that they are not imported but the
   test at least documents it.
 - Default values for ParmVarDecls were also uncovered.
 - Importing bitfield FieldDecls were imported correctly.

Reviewed By: martong, shafik

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

3 years ago[AArch64] Avoid SCALAR_TO_VECTOR for single FP constant vector.
Florian Hahn [Wed, 31 Mar 2021 08:38:12 +0000 (09:38 +0100)]
[AArch64] Avoid SCALAR_TO_VECTOR for single FP constant vector.

Currently the code only checks for integer constants (ConstantSDNode)
and triggers an infinite cycle for single-element floating point
vector constants. We need to check for both FP and integer constants.

Reviewed By: t.p.northover

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

3 years agoNFC: Change getUserCost to return InstructionCost
Sander de Smalen [Wed, 20 Jan 2021 17:17:23 +0000 (17:17 +0000)]
NFC: Change getUserCost to return InstructionCost

This patch migrates the TTI cost interfaces to return an InstructionCost.

See this patch for the introduction of the type: https://reviews.llvm.org/D91174
See this thread for context: http://lists.llvm.org/pipermail/llvm-dev/2020-November/146408.html

Depends on D97382

Reviewed By: ctetreau, paulwalker-arm

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

3 years ago[clang][Checkers] Extend PthreadLockChecker state dump (NFC).
Balázs Kéri [Wed, 31 Mar 2021 08:36:06 +0000 (10:36 +0200)]
[clang][Checkers] Extend PthreadLockChecker state dump (NFC).

Add printing of map 'DestroyRetVal'.

Reviewed By: steakhal

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

3 years ago[mlir] Change vector.transfer_read/write "masked" attribute to "in_bounds".
Matthias Springer [Wed, 31 Mar 2021 05:59:30 +0000 (14:59 +0900)]
[mlir] Change vector.transfer_read/write "masked" attribute to "in_bounds".

This is in preparation for adding a new "mask" operand. The existing "masked" attribute was used to specify dimensions that may be out-of-bounds. Such transfers can be lowered to masked load/stores. The new "in_bounds" attribute is used to specify dimensions that are guaranteed to be within bounds. (Semantics is inverted.)

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

3 years ago[OpenCL] Limit popcount to OpenCL 1.2 and above
Sven van Haastregt [Wed, 31 Mar 2021 08:54:18 +0000 (09:54 +0100)]
[OpenCL] Limit popcount to OpenCL 1.2 and above

s6.15.3 of the OpenCL C Specification v3.0.6 states that OpenCL 1.2 or
newer is required.

3 years ago[TableGen] Emit more helpful error messages on empty type set
Alex Richardson [Wed, 31 Mar 2021 08:24:03 +0000 (09:24 +0100)]
[TableGen] Emit more helpful error messages on empty type set

I have seen this error quite frequently in our out-of-tree CHERI backends
and the lack of location information sometimes makes it quite difficult
to track down the actual source of the error.
This patch changes the llvm_unreachable() to a PrintFatalError() so that
tablegen prints a stack of source locations.

Reviewed By: craig.topper

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

3 years ago[asan] Remove FreeBSD XFAIL from asan-sigbus.cpp test
Alex Richardson [Wed, 31 Mar 2021 08:17:39 +0000 (09:17 +0100)]
[asan] Remove FreeBSD XFAIL from asan-sigbus.cpp test

This test passes for me on FreeBSD 12.2 and was probably fixed by
https://svnweb.freebsd.org/base?view=revision&revision=352807.

Reviewed By: emaste

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

3 years ago[WebAssembly] Fix incorrect DW_TAG_pointer_type size in test
Alex Richardson [Wed, 31 Mar 2021 08:15:22 +0000 (09:15 +0100)]
[WebAssembly] Fix incorrect DW_TAG_pointer_type size in test

It should be 64 bits not 32 for wasm64-unknown-unknown. I noticed this
because this test was failing in our CHERI fork of LLVM due to a larger
.debug_abbrev section size. It turns out this happens because we add
DW_AT_byte_size for non-default pointer sizes to allow debugging our
hybrid compilation mode where we can have two different kinds of pointers.

Reviewed By: aardappel

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

3 years ago[mlir][Linalg][Python] Create the body of builtin named Linalg ops
Nicolas Vasilache [Tue, 30 Mar 2021 11:41:41 +0000 (11:41 +0000)]
[mlir][Linalg][Python] Create the body of builtin named Linalg ops

This revision adds support to properly add the body of registered
builtin named linalg ops.
At this time, indexing_map and iterator_type support is still
missing so the op is not executable yet.

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

3 years agoRevert "Revert "[mlir] Introduce CloneOp and adapt test cases in BufferDeallocation.""
Alexander Belyaev [Wed, 31 Mar 2021 07:34:03 +0000 (09:34 +0200)]
Revert "Revert "[mlir] Introduce CloneOp and adapt test cases in BufferDeallocation.""

This reverts commit 883912abe669ef246ada0adc9cf1c9748b742400.

3 years ago[X86] Add test cases for PR48768 and D94856. NFC
Craig Topper [Wed, 31 Mar 2021 05:47:25 +0000 (22:47 -0700)]
[X86] Add test cases for PR48768 and D94856. NFC

This covers the BMI and TBM instructions. More tests will be
needed for other instructions.

3 years ago[X86] Regenerate test to add missing @PLT
Craig Topper [Wed, 31 Mar 2021 05:45:58 +0000 (22:45 -0700)]
[X86] Regenerate test to add missing @PLT

3 years ago[libcxx] [test] Don't add dirs from the LIB env var to PATH
Martin Storsjö [Wed, 24 Mar 2021 07:31:54 +0000 (09:31 +0200)]
[libcxx] [test] Don't add dirs from the LIB env var to PATH

The directories in LIB normally only contain import libraries or
static libraries, no runtime DLLs that would need to be found
while running tests.

This code stems from 1cd196e7b46e49d170a4b4013879a577dee59cb2,
which (among other things) tried to do this:

> * [Test] Fix handling of library runtime search paths by correctly adding them
>   to the PATH variable when running the tests.

It's unclear to me exactly what this fixed (or tried to) at the time,
as the LIB var doesn't normally point to runtime libs.

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

3 years ago[libcxx] [test] Fix tests of <cuchar> that unexpectedly succeed on windows
Martin Storsjö [Sat, 20 Mar 2021 22:25:57 +0000 (00:25 +0200)]
[libcxx] [test] Fix tests of <cuchar> that unexpectedly succeed on windows

The tests expect that the <cuchar> include should fail. When libc++
is built on top of the MSVC runtime, the header does exist provided
by MSVC. Therefore, just mark the test as unsupported on windows,
to avoid tests that unexpectedly succeed.

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

3 years ago[RISCV] Refine pre-define macro tests
Jim Lin [Wed, 31 Mar 2021 05:11:41 +0000 (13:11 +0800)]
[RISCV] Refine pre-define macro tests

1. Undefined macro test for rv32i and rv64i.
  a. Reorder it with canonical order.
  b. Add missing  undefined macro check.
  c. Append defined value to `__riscv_a`, `__riscv_f` and `__riscv_c` to distinguish with
      `__riscv_arch_test`, `__riscv_cmodel_medlow` and `__riscv_float_abi_soft`. They have the same prefix.
2. Move abi macro test below f and d.
3. Unify coding style for newline.

Reviewed By: HsiangKai

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

3 years ago[JITLink] Delete copy and move constructors for jitlink::Section.
Lang Hames [Wed, 31 Mar 2021 05:56:41 +0000 (22:56 -0700)]
[JITLink] Delete copy and move constructors for jitlink::Section.

Sections are not movable or copyable.

3 years ago[mlir] Add C and python API for is_registered_operation.
Stella Laurenzo [Wed, 31 Mar 2021 05:19:10 +0000 (22:19 -0700)]
[mlir] Add C and python API for is_registered_operation.

* Suggested to be broken out of D99578

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

3 years agolibc: Default LIBC_INSTALL_PREFIX to ${CMAKE_INSTALL_PREFIX}
Nathan Chancellor [Wed, 31 Mar 2021 04:08:18 +0000 (21:08 -0700)]
libc: Default LIBC_INSTALL_PREFIX to ${CMAKE_INSTALL_PREFIX}

b22f448c21e718a3b6 added a rule to install libllvmlibc.a to
${LIBC_INSTALL_PREFIX}/${LIBC_INSTALL_LIBRARY_DIR}, which will be /lib
by default, which is disruptive to builds that stay within a user's
/home holder:

  $ ninja install
  ...
  -- Installing: /lib/libllvmlibc.a
  CMake Error at projects/libc/lib/cmake_install.cmake:54 (file):
    file INSTALL cannot copy file
   "/home/nathan/cbl/github/tc-build/build/llvm/stage1/projects/libc/lib/libllvmlibc.a"
    to "/lib/libllvmlibc.a": Permission denied.
  Call Stack (most recent call first):
    projects/libc/cmake_install.cmake:51 (include)
    projects/cmake_install.cmake:47 (include)
    cmake_install.cmake:76 (include)
  ...

Change LIBC_INSTALL_PREFIX's default value to ${CMAKE_INSTALL_PREFIX} so
that 'ninja install' does not attempt to install anything outside of the
user's requested installation location.

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

Reviewed By: sivachandra

Signed-off-by: Nathan Chancellor <nathan@kernel.org>
3 years ago[JITLink] Switch from StringRef to ArrayRef<char>, add some generic x86-64 utils
Lang Hames [Wed, 31 Mar 2021 03:56:03 +0000 (20:56 -0700)]
[JITLink] Switch from StringRef to ArrayRef<char>, add some generic x86-64 utils

Adds utilities for creating anonymous pointers and jump stubs to x86_64.h. These
are used by the GOT and Stubs builder, but may also be used by pass writers who
want to create pointer stubs for indirection.

This patch also switches the underlying type for LinkGraph content from
StringRef to ArrayRef<char>. This avoids any confusion when working with buffers
that contain null bytes in the middle like, for example, a newly added null
pointer content array. ;)

3 years ago[Coroutine] [Debug] Insert dbg.declare to entry.resume to print alloca in the corouti...
Chuanqi Xu [Wed, 31 Mar 2021 02:34:55 +0000 (10:34 +0800)]
[Coroutine] [Debug] Insert dbg.declare to entry.resume to print alloca in the coroutine frame under O2

Summary: Try to insert dbg.declare to entry.resume basic block in resume
function. In this way, we could print alloca such as __promise in
gdb/lldb under O2, which would be beneficial to debug coroutine program.

Test Plan: check-llvm

Reviewed by: aprantl

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

3 years ago[Utils][Emacs] Improve syntax highlight
Zhiwei Chen [Wed, 31 Mar 2021 02:32:29 +0000 (19:32 -0700)]
[Utils][Emacs] Improve syntax highlight

Reviewed By: MaskRay

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