Commit Graph

338643 Commits

Author SHA1 Message Date
Raphael Isemann 2e03324441 [lldb][NFC] Remove forward declaration for non-existent type clang::Action and delete references to it
There is no clang::Action anymore so our forward decl for it and the obsolete pointer in the
ASTStructExtractor can both go (that code anyway didn't do anything).
2020-01-03 11:24:16 +01:00
Raphael Isemann 1711f886fd [lldb][NFC] Document TypeSystem and related Compiler* classes 2020-01-03 10:38:38 +01:00
Sam Parker 8f6a67632a [ARM][NFC] Move tail predication checks
Extract the tail predication validation checks out into their own
LowOverHeadLoop method.
2020-01-03 03:50:54 -05:00
Craig Topper 3186b18b99 [X86] Reorder X86any* PatFrags to put the strict node first so that chain property will be inferred for the instruction by the tablegen backend.
Also use X86any_vfpround instead of X86vfpround in some instruction
definitions so the strict version can be used to infer the chain
property.

Without these changes we don't propagate strict FP chain through
isel for some instructions.
2020-01-03 00:11:55 -08:00
Kadir Cetinkaya b2eaac3e3e
[clangd] Replace shortenNamespace with getQualification
Reviewers: ilya-biryukov

Subscribers: MaskRay, jkorous, arphaman, usaxena95, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D71652
2020-01-03 09:05:30 +01:00
TH3CHARLie abd707848b [llvm-size] print a blank line between archieve members when using sysv format
Summary: This patch is related to https://bugs.llvm.org/show_bug.cgi?id=42967 and it fixes llvm-size's sysv format output by adding a blank line between archieve members

Reviewers: jhenderson, Jim, MaskRay

Reviewed By: jhenderson, Jim, MaskRay

Subscribers: MaskRay, Jim, rupprecht, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D71957
2020-01-03 14:05:55 +08:00
Craig Topper bd46e29742 [X86] Re-enable lowerUINT_TO_FP_vXi32 under fast-math by using an FSUB instead of an FADD.
Summary:
We previously disabled this under fast math due to aggressive
reassociation by the machine combiner. But I think we can work
around this by using a FSUB instead of FADD for the first
operation.

This matches the similar algorithm we do for uint_to_fp i64->f64
in TargetLowering::expandUINT_TO_FP. If reassociation hasn't
been a problem for that, hopefully its not a problem here.

Reviewers: RKSimon, spatel, scanon

Reviewed By: spatel

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D71968
2020-01-02 21:46:53 -08:00
QingShan Zhang 2133d3c558 [DAGCombine] Initialize the default operation action for SIGN_EXTEND_INREG for vector type as 'expand' instead of 'legal'
For now, we didn't set the default operation action for SIGN_EXTEND_INREG for
vector type, which is 0 by default, that is legal. However, most target didn't
have native instructions to support this opcode. It should be set as expand by
default, as what we did for ANY_EXTEND_VECTOR_INREG.

Differential Revision: https://reviews.llvm.org/D70000
2020-01-03 03:26:41 +00:00
Wang, Pengfei 60333a5317 [X86] Enable strict FP by default and remove option -disable-strictnode-mutation. NFCI. 2020-01-03 10:59:34 +08:00
Kazuaki Ishizaki a050327064 [mlir] NFC: Fix broken links in docs
Summary: This commit fixes missing links that are caused by the repository movement.

Reviewers: Jim, rriddle, jpienaar

Reviewed By: Jim, rriddle, jpienaar

Subscribers: arpith-jacob, mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, nicolasvasilache, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D72065
2020-01-03 10:26:27 +08:00
Hideto Ueno 5fc02dc0a7 Revert "[Attributor] AAValueConstantRange: Value range analysis using constant range"
This reverts commit e996303431.
2020-01-03 11:03:56 +09:00
Kamil Rytarowski 0da15ff318 [compiler-rt] [netbsd] Switch to syscall for ThreadSelfTlsTcb()
This change avoids using internal, namespaced per-CPU calls that
are not a stable interface to read the TSL base value.
2020-01-03 02:40:52 +01:00
Justin Hibbits 2c4620ad57 [PowerPC]: Fix predicate handling with SPE
SPE floating-point compare instructions only update the GT bit in the CR
field.  All predicates must therefore be reduced to GT/LE.
2020-01-02 19:30:53 -06:00
Justin Hibbits a51c61ea33 Run update_llc_test_checks against SPE tests.
This is in preparation for further tests which are better generated with
the script.  No functional change.
2020-01-02 19:30:52 -06:00
Wang, Pengfei 9dc9e0ea64 [X86] Optimization of inserting vxi1 sub vector into vXi1 vector
Summary:
After bugfix the undef value case here, we used more operations to implement inserting vxi1 sub vector into vXi1 vector, I optimize it by use less operations.

The history information at https://reviews.llvm.org/D68311

Reviewers: craig.topper, LuoYuanke, yubing, annita.zhang, pengfei, LiuChen3, RKSimon

Reviewed By: craig.topper

Subscribers: hiraditya, llvm-commits

Patch by Xiang Zhang (xiangzhangllvm)

Differential Revision: https://reviews.llvm.org/D71917
2020-01-03 09:25:25 +08:00
Med Ismail Bennani 4117c8c019 Revert "[lldb/Command] Add --force option for `watchpoint delete` command"
This reverts commit 3620e5f28a.
2020-01-03 02:14:45 +01:00
Jonas Devlieghere d265c8bf0d [lldb/Python] Remove unused imports (NFC) 2020-01-02 16:55:09 -08:00
Jonas Devlieghere 8580397f2e [lldb/Python] Remove unused support file (NFC) 2020-01-02 16:55:09 -08:00
Med Ismail Bennani 3620e5f28a [lldb/Command] Add --force option for `watchpoint delete` command
Currently, there is no option to delete all the watchpoint without LLDB
asking for a confirmation. Besides making the watchpoint delete command
homogeneous with the breakpoint delete command, this option could also
become handy to trigger automated watchpoint deletion i.e. using
breakpoint actions.

rdar://42560586

Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
2020-01-03 01:51:22 +01:00
Petr Hosek b63bc648a4 [CMake] clang-scan-deps in Fuchsia distribution
We would like to use clang-scan-deps in Fuchsia build so include it
in the toolchain distribution.

Differential Revision: https://reviews.llvm.org/D72113
2020-01-02 16:49:52 -08:00
Sean Fertile 479e9406c2 [PowerPC][AIX] Enable sret arguments.
Removes the fatal error for sret arguments and adds lit testing.

Differential Revision: https://reviews.llvm.org/D71504
2020-01-02 19:31:01 -05:00
Reid Kleckner 783db78835 [PDB] Print the most redundant type record indices with /summary
Summary:
I used this information to motivate splitting up the Intrinsic::ID enum
(5d986953c8) and adding a key method to
clang::Sema (586f65d31f) which saved a
fair amount of object file size.

Example output for clang.pdb:

  Top 10 types responsible for the most TPI input bytes:
         index     total bytes   count     size
        0x3890:      8,671,220 = 1,805 *  4,804
       0xE13BE:      5,634,720 =   252 * 22,360
       0x6874C:      5,181,600 =   408 * 12,700
        0x2A1F:      4,520,528 = 1,574 *  2,872
       0x64BFF:      4,024,020 =   469 *  8,580
        0x1123:      4,012,020 = 2,157 *  1,860
        0x6952:      3,753,792 =   912 *  4,116
        0xC16F:      3,630,888 =   633 *  5,736
        0x69DD:      3,601,160 =   985 *  3,656
        0x678D:      3,577,904 =   319 * 11,216

In this case, we can see that record 0x3890 is responsible for ~8MB of
total object file size for objects in clang.

The user can then use llvm-pdbutil to find out what the record is:

  $ llvm-pdbutil dump -types -type-index 0x3890
                       Types (TPI Stream)
  ============================================================
    Showing 1 records.
       0x3890 | LF_FIELDLIST [size = 4804]
                - LF_STMEMBER [name = `WORDTYPE_MAX`, type = 0x1001, attrs = public]
                - LF_MEMBER [name = `U`, Type = 0x37F0, offset = 0, attrs = private]
                - LF_MEMBER [name = `BitWidth`, Type = 0x0075 (unsigned), offset = 8, attrs = private]
                - LF_METHOD [name = `APInt`, # overloads = 8, overload list = 0x3805]
  ...

In this case, we can see that these are members of the APInt class,
which is emitted in 1805 object files.

The next largest type is ASTContext:

  $ llvm-pdbutil dump -types -type-index 0xE13BE bin/clang.pdb
      0xE13BE | LF_FIELDLIST [size = 22360]
                - LF_BCLASS
                  type = 0x653EA, offset = 0, attrs = public
                - LF_MEMBER [name = `Types`, Type = 0x653EB, offset = 8, attrs = private]
                - LF_MEMBER [name = `ExtQualNodes`, Type = 0x653EC, offset = 24, attrs = private]
                - LF_MEMBER [name = `ComplexTypes`, Type = 0x653ED, offset = 48, attrs = private]
                - LF_MEMBER [name = `PointerTypes`, Type = 0x653EE, offset = 72, attrs = private]
  ...

ASTContext only appears 252 times, but the list of members is long, and
must be repeated everywhere it is used.

This was the output before I split Intrinsic::ID:

  Top 10 types responsible for the most TPI input:
        0x686C:     69,823,920 = 1,070 * 65,256
        0x686D:     69,819,640 = 1,070 * 65,252
        0x686E:     69,819,640 = 1,070 * 65,252
        0x686B:     16,371,000 = 1,070 * 15,300
        ...

These records were all lists of intrinsic enums.

Reviewers: MaskRay, ruiu

Subscribers: mgrang, zturner, thakis, hans, akhuang, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D71437
2020-01-02 16:10:36 -08:00
Lang Hames 355983103f [lli] Add a filter to avoid importing the process's main symbol.
If JIT'd code fails to define a main function and we import the process's
definition then we will end up recursively calling lli's main until we overflow
the stack and crash. This filter fixes the issue by ensuring that the process's
main function is never imported. This results in lli producing a much friendlier
"symbol not found" error when JIT'd code fails to define main.
2020-01-02 16:05:23 -08:00
Evgenii Stepanov 3e5eac0358 Fix llvm-symbolizer tests on Windows, one more time. 2020-01-02 15:27:51 -08:00
River Riddle fd01d8626c [mlir] Rewrite the internal representation of OpResult to be optimized for memory.
Summary:
This changes the implementation of OpResult to have some of the results be represented inline in Value, via a pointer int pair of Operation*+result number, and the rest being trailing objects on the main operation. The full details of the new representation is detailed in the proposal here:
https://groups.google.com/a/tensorflow.org/g/mlir/c/XXzzKhqqF_0/m/v6bKb08WCgAJ

The only difference between here and the above proposal is that we only steal 2-bits for the Value kind instead of 3. This means that we can only fit 2-results inline instead of 6. This allows for other users to steal the final bit for PointerUnion/etc. If necessary, we can always steal this bit back in the future to save more space if 3-6 results are common enough.

Reviewed By: jpienaar

Differential Revision: https://reviews.llvm.org/D72020
2020-01-02 14:40:09 -08:00
Evgenii Stepanov 1c45852c82 Add C source to two debug info tests.
Reviewers: dblaikie, jhenderson

Subscribers: aprantl, rupprecht, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D72024
2020-01-02 14:35:54 -08:00
Evgenii Stepanov b153fbefa3 Change dbg-*-tag-offset tests to use llvm-dwarfdump.
Reviewers: dblaikie

Subscribers: llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D72023
2020-01-02 14:35:54 -08:00
Matt Arsenault 25e7da0c24 AMDGPU/GlobalISel: Remove manual G_FENCE selection
The tablegen emitter now handles the immediate operand correctly, so
let the generatedd matcher works.
2020-01-02 17:16:10 -05:00
Matt Arsenault 0d9f919b73 DAG: Use TargetConstant for FENCE operands 2020-01-02 17:16:10 -05:00
Alexey Bataev a58da1a2ff [OPENMP50]Codegen for lastprivate conditional list items.
Added codegen support for lastprivate conditional. According to the
standard, if  when the conditional modifier appears on the clause, if an
assignment to a list item is encountered in the construct then the
original list item is assigned the value that is assigned to the new
list item in the sequentially last iteration or lexically last section
in which such an assignment is encountered.
We look for the assignment operations and check if the left side
references lastprivate conditional variable. Then the next code is
emitted:
if (last_iv_a <= iv) {
  last_iv_a = iv;
  last_a = lp_a;
}

At the end the implicit barrier is generated to wait for the end of all
threads and then in the check for the last iteration the private copy is
assigned the last value.

if (last_iter) {
  lp_a = last_a; // <--- new code
  a = lp_a;      // <--- store of private value to the original  variable.
}
2020-01-02 16:43:00 -05:00
Jonas Devlieghere f83801fb2a [lldb/CMake] Print whether an optional dependency was enabled.
Use a status message to convey whether an optional dependency was found
or not. With the auto-detection code it's not longer as simple as
checking the CMake cache.
2020-01-02 13:40:01 -08:00
Jonas Devlieghere f38234ed8b [lldb/CMake] Fix variable naming in FindLibEdit
The current FOUND_VAR for FindLibEdit is libedit_FOUND but wasn't set by
find_package_handle_standard_args. However this isn't valid for the
package name.

  The argument for FOUND_VAR is "libedit_FOUND", but only "LibEdit_FOUND" and
  "LIBEDIT_FOUND" are valid names.

This fixes all the variables set by FindLibEdit to match the desired
naming scheme.
2020-01-02 13:39:57 -08:00
Jonas Paulsson 982695c069 [SystemZ] Create brcl 0,0 instead of brcl 0,3 in EmitNop for 6 bytes.
For consistency with GCC, the target label is moved to the brcl itself
instead of the next instruction.

Review: Ulrich Weigand
2020-01-02 13:21:04 -08:00
Alexey Bataev 1fcc9b6ff8 [OPENMP] Restore allowing of braced initializers in the declare reduction
init.

Braced initializers were not accepted after the last fix in the initialier.Restored previous functionality.
2020-01-02 16:10:17 -05:00
Jonas Devlieghere 3ddfb04f41 [lldb/CMake] Use PYTHON_LIBRARIES instead of PYTHON_LIBRARY
PYTHON_LIBRARIES is the canonical variable set by FindPythonLibs while
PYTHON_LIBRARY is an implementation detail. This replaces the uses of
the latter with the former.
2020-01-02 13:01:17 -08:00
Matt Arsenault 086ac7e75c AMDGPU/GlobalISel: Correct MMO sizes in some tests
There intended to test non-extloads, but the memory size did not match
the result size.
2020-01-02 16:00:46 -05:00
Matt Arsenault 203182b7b6 AMDGPU/GlobalISel: Regenerate check lines
This avoids diff noise in a future commit from the check name change
from the G_GEP->G_PTR_ADD rename.
2020-01-02 16:00:45 -05:00
Saleem Abdulrasool a2ca1c2d56 build: disable zlib by default on Windows
zlib usage on Windows has caused issues in the past.  Furthermore, the
GNUWin32 library can be detected and used although the headers are not
available.  Require Windows to explicitly opt in.
2020-01-02 12:55:52 -08:00
Jacques Pienaar 8f1caf518f [mlir] Only generate default for uncovered cases
Have to explicitly check if all cases are covered instead.
2020-01-02 12:55:14 -08:00
Sanjay Patel 4bb4f5b1d9 [InstCombine] add tests for vector icmp with undef constant elements; NFC 2020-01-02 15:39:45 -05:00
Jacques Pienaar f533fa3af5 [mlir] Revert default case that was needed
This one isn't always complete.
2020-01-02 12:32:41 -08:00
Jacques Pienaar 98a88c1bee [mlir] Add parenthesis to avoid -Wparentheses 2020-01-02 12:30:53 -08:00
Craig Topper 6962eea2c3 [X86] Move STRICT_ ISD nodes into the new section of X86ISelLowering.h where STRICT nodes are collected after D71841 2020-01-02 12:29:28 -08:00
Jacques Pienaar 3d83d8259c [mlir] Remove redudant default cases
These provide no value and trigger -Wcovered-switch-default.
2020-01-02 12:24:42 -08:00
David Blaikie d45b394b3e Polly: Fix a tag type mismatch (struct/class) 2020-01-02 12:13:38 -08:00
Nemanja Ivanovic 781b78a361 [PowerPC] Only legalize FNEARBYINT with unsafe fp math
Commit 0f0330a787 legalized these nodes on PPC without consideration of
unsafe math which means that we get inexact exceptions raised for nearbyint.
Since this doesn't conform to the standard, switch this legalization to depend
on unsafe fp math.
2020-01-02 13:45:54 -06:00
Saleem Abdulrasool af340ae19f X86: remove unused variable
Remove the now unused-variable from
aa17d31edb.  This breaks `-Werror` builds.
2020-01-02 11:41:21 -08:00
Nico Weber 94d4ca9004 Reland "[gn build] (manually) merge 68a235d07f9e70"
This reverts commit 70342641b3.

68a235d relanded in abb0075306, so this relands the gn port of it.
2020-01-02 14:39:17 -05:00
Saleem Abdulrasool abb0075306 build: reduce CMake handling for zlib
Rather than handling zlib handling manually, use `find_package` from CMake
to find zlib properly. Use this to normalize the `LLVM_ENABLE_ZLIB`,
`HAVE_ZLIB`, `HAVE_ZLIB_H`. Furthermore, require zlib if `LLVM_ENABLE_ZLIB` is
set to `YES`, which requires the distributor to explicitly select whether
zlib is enabled or not. This simplifies the CMake handling and usage in
the rest of the tooling.

This restores 68a235d07f,
e6c7ed6d21.  The problem with the windows
bot is a need for clearing the cache.
2020-01-02 11:19:12 -08:00
Craig Topper aa17d31edb [X86] Remove FP0-6 operands from call instructions in FPStackifier pass. Only count defs as returns.
All FP0-6 operands should be removed by the FP stackifier. By
removing these we fix the machine verifier error in PR39437.

I've also made it so that only defs are counted for STReturns
which removes what I think were extra stack cleanup instructions.

And I've removed the regcall assert because it was checking the
attributes of the caller, but here we're concerned with the
attributes of the callee. But I don't know how to get that
information from this level.
2020-01-02 11:10:51 -08:00