Skip to content

LLVM and SPIRV-LLVM-Translator pulldown (WW38) #2468

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 401 commits into from
Sep 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
401 commits
Select commit Hold shift + click to select a range
2b71b7f
[NFC][Asan] Set AP32::kMetadataSize to 0
vitalybuka Sep 1, 2020
3d54976
[llvm-symbolizer] Add back --use-symbol-table=true
MaskRay Sep 3, 2020
e6393ee
Canonicalize declaration pointers when forming APValues.
zygoloid Sep 2, 2020
052dbe2
Remove unused and dangerous overload of PerformImplicitConversion.
zygoloid Sep 3, 2020
bf41c4d
[codegen] Ensure target flags are cleared/set properly. NFC.
darkbuck Oct 23, 2019
aaf1a96
[DebugInfo] Add size to class declarations in debug info.
amykhuang Sep 3, 2020
673484b
[libunwind] Minor SJLJ config cleanup. NFCI.
rprichard Sep 3, 2020
0851350
[X86] Update stale comment. NFC
topperc Sep 3, 2020
3c2a7bd
AMDGPU: Remove code to handle tied si_else operands
arsenm Sep 2, 2020
2dd9a4d
[SmallVector] Include stdexcept if LLVM_ENABLE_EXCEPTIONS
MaskRay Sep 4, 2020
a803ddc
[NFC][Asan] Add FIXME into GetAsanChunk
vitalybuka Sep 4, 2020
99a93c3
[NFC][Asan] Rename internal enum value.
vitalybuka Sep 4, 2020
0ac8133
[NFC] Adding pythonenv* to .gitignore
plotfi Sep 4, 2020
060c9dd
[mlir] [VectorOps] Improve SIMD compares with narrower indices
aartbik Sep 3, 2020
8514ecb
[libc] Add implementations of remquo[f|l] and remainder[f|l].
Aug 17, 2020
23bcfbc
Add comment to describe a field member (NFC)
joker-eph Sep 4, 2020
17ac454
[libc][obvious] Use constants of type double in remquo_test.
Sep 4, 2020
a9c0bf0
[NFC][Asan] Inline enum doc strings
vitalybuka Sep 4, 2020
bdc4c0b
Revert "[lldb] avoid assert in threadsanitizer tests on linux"
Teemperor Sep 4, 2020
aec9e20
[mlir] introduce type constraints for operands of LLVM dialect operat…
ftynse Sep 4, 2020
e2fc6a3
[MemCpyOpt] Preserve MemorySSA.
fhahn Sep 4, 2020
48ac5b4
[NFC][Asan] Reformat some allocator code
vitalybuka Sep 4, 2020
ab86e64
[DSE] Remove some dead code from DSE tests.
fhahn Sep 4, 2020
73a3d35
[SVE][CodeGen] Fix up warnings in sve-split-insert/extract tests
david-arm Aug 21, 2020
4770f80
[NFC][Asan] Fix typo in comment
vitalybuka Sep 4, 2020
0c2a4d3
[mlir][VectorOps] Simplify code. NFCI.
d0k Sep 4, 2020
f9ad112
[lldb] Speed up TestValueObjectRecursion by making it a no_debug_info…
Teemperor Sep 4, 2020
a633da5
[FPEnv] Partially implement #pragma STDC FENV_ROUND
spavloff Aug 24, 2020
fe0972d
[analyzer][StdLibraryFunctionsChecker] Do not match based on the rest…
Sep 3, 2020
b7c1810
[llvm-readobj/elf] - Refine signature of print*Reloc methods.
Sep 3, 2020
3a1308b
MIRFormatter.h - remove MachineInstr.h include. NFC.
RKSimon Sep 4, 2020
0faf393
[llvm-readelf/obj] - Use `RelSymbol<ELFT>` instead of std::pair. NFCI.
Sep 3, 2020
294c0cc
[ARM] Fold predicate_cast(load) into vldr p0
davemgreen Sep 4, 2020
740625f
[X86] Make lowerShuffleAsLanePermuteAndPermute use sublanes on AVX2
RKSimon Sep 4, 2020
7582c5c
CallingConvLower.h - remove unnecessary MachineFunction.h include. NFC.
RKSimon Sep 4, 2020
2c9dbcd
[modules] Correctly parse LateParsedTemplates in case of dependent mo…
gargvaibhav64 Sep 4, 2020
101f37a
[lldb][NFC] Rewrite CPP11EnumTypes test to make it faster
Teemperor Sep 4, 2020
691d436
Fix typos in doc LangRef.rst
yangzh-fnst Sep 4, 2020
8784e90
[Test] Range fix in test
xortator Sep 4, 2020
4d536c6
[x86] add tests for store merging; NFC
rotateright Sep 3, 2020
6bc5e86
[MemCpyOpt] Account for case that MemInsertPoint == BI.
fhahn Sep 4, 2020
c633842
[mlir] Fix includes in mlir-translate
marbre Sep 4, 2020
4f7cdc1
[mlir] Refactor standalone-translate to use mlirTranslateMain()
marbre Sep 4, 2020
6cb54cf
[DSE] Move legacy tests to DeadStoreElimination/MemDepAnalysis.
fhahn Sep 4, 2020
7b03323
Revert "Canonicalize declaration pointers when forming APValues."
nico Sep 4, 2020
c88a776
[gn build] fix llvm-lit after d23b15cc16077
nico Sep 4, 2020
7d53fec
[spirv] Add more target and resource limit fields
antiagainst Sep 4, 2020
2a03f27
clang: Add test for -Wunreachable-code + weak redeclaration
nico Sep 4, 2020
3404add
[EarlyCSE] Verify hash code in regression tests
bryanpkc Aug 30, 2020
2966d6e
[MachOYAML] Allow handcrafting custom contents for DWARF sections.
higuoxing Sep 4, 2020
dbf04aa
Revert "[Asan] Cleanup atomic usage in allocator"
nico Sep 4, 2020
fab6066
sanitizer_common: Implement COMPILER_CHECK using static_assert
nico Sep 4, 2020
1ffcbe3
[AArch64][SVE] Add lowering for rounding operations
Sep 4, 2020
8c810ac
[clang-format] Parse __ptr32/__ptr64 as a pointer qualifier
arichardson Sep 4, 2020
e0ff5a8
[clang-format] Add a test showing the current config file list parsing
arichardson Sep 4, 2020
2108bce
FormatTest: Provide real line number in failure messages
arichardson Sep 4, 2020
45c3560
[HeapProf] Address post-review comments in instrumentation code
teresajohnson Sep 4, 2020
4eef14f
[OpenMPOpt] Assume indirect call always changes ICV
apolloww Sep 4, 2020
baf3c77
[libclang] Add translateCXRangeToCharRange conversion
jkorous-apple Sep 2, 2020
f0b9dbc
[analyzer][StdLibraryFunctionsChecker] Add POSIX time handling functions
Jul 21, 2020
51932fc
[DSE,MemorySSA] Remove some duplicated test functions.
fhahn Sep 4, 2020
3f1a9b7
[objdump][macho] Emit segment names along with section names
dsandersllvm Sep 4, 2020
dde16ef
[tests][libFuzzer] Fix `-Wmissing-field-initializers` after D86092
hubert-reinterpretcast Sep 4, 2020
8760048
[lld] Test corrections after 3f1a9b7eca0 added segment names to objdu…
dsandersllvm Sep 4, 2020
64bb582
Fix the type of the invoke function in the block ABI documentation
ahatanaka Sep 4, 2020
00eb6fe
[DSE,MemorySSA] Check for throwing instrs between killing/killed def.
fhahn Sep 4, 2020
54205f0
[PowerPC] Allow const pointers for load builtins in altivec.h
nemanjai Sep 4, 2020
1eae19a
[compiler-rt] Try to correct test after 3f1a9b7eca0 added segment nam…
dsandersllvm Sep 4, 2020
97866b8
[ThinLTO][Legacy] Fix StringRef assertion from ThinLTO bots
cachemeifyoucan Sep 4, 2020
6b50ce3
[SCEV] Add tests for min/max intrinsics (NFC)
nikic Sep 4, 2020
3b64052
[ORC] Fix some bugs in TPCDynamicLibrarySearchGenerator, use in llvm-…
lhames Sep 4, 2020
398ba37
[LiveDebugVariables] Delete unneeded doInitialization
MaskRay Sep 4, 2020
052f838
[libclang] Expose couple more AST details via cursors
jkorous-apple Sep 1, 2020
b3e1394
[BDCE] Add tests for min/max intrinsincs (NFC)
nikic Sep 4, 2020
c5d6b2b
[InstCombine] add test for assume in block with unreachable (PR47416)…
rotateright Sep 4, 2020
35c6d56
[InstCombine] rename tmp values to avoid scripted FileCheck conflicts…
rotateright Sep 4, 2020
35b35a3
[X86] Prevent shuffle combining from creating an identical X86ISD::SH…
topperc Sep 4, 2020
69e5abb
[libclang] Add CXRewriter to libclang API
jkorous-apple Sep 4, 2020
b07cbcc
[gn build] Port 69e5abb57b7
llvmgnsyncbot Sep 4, 2020
781a438
[InstSimplify] Add tests for min/max with dominating condition (NFC)
nikic Sep 4, 2020
7cfc8f0
[libclang] Add missing dependency on clangRewrite lib
jkorous-apple Sep 4, 2020
2bccd2b
[Driver] Allow -specs and -nostartfiles to be forwarded to GCC
pzhengqc Sep 4, 2020
89a4fe7
[Hexagon] Unindent everything in HexagonISelLowering.h, NFC
Sep 4, 2020
5e04b53
[compiler-rt] Try again to correct test after 3f1a9b7eca0 added segme…
dsandersllvm Sep 4, 2020
a5d6af4
[compiler-rt] Add .clang-tidy with customization to disable readabili…
MaskRay Sep 4, 2020
2d65294
[PowerPC] Provide vec_cmpne on pre-Power9 architectures in altivec.h
nemanjai Sep 5, 2020
705271d
[PowerPC] Expand constrained ppc_fp128 to i32 conversion
ecnelises Sep 5, 2020
3a6f3fc
Fix return status of SimplifyCFG
Sep 4, 2020
39caf9e
[SCCP] Add tests for intrinsic ranges (NFC)
nikic Sep 5, 2020
714ceef
[SelectionDAG] Always intersect SDNode flags during getNode() node me…
JonPsson Aug 31, 2020
d401e37
[InstCombine] Test abs with dominating condition (NFC)
nikic Sep 5, 2020
1903a1a
[InstCombine] Add tests for cttz of abs intrinsic (NFC)
nikic Sep 5, 2020
10cb23c
[InstCombine] Fold cttz of abs intrinsic
nikic Sep 5, 2020
3ab1334
[InstCombine] Add tests for mul of abs intrinsic (NFC)
nikic Sep 5, 2020
58b28fa
[InstCombine] Fold mul of abs intrinsic
nikic Sep 5, 2020
8544def
Thread safety analysis: Document how try-acquire is handled
aaronpuchert Sep 5, 2020
16975a6
Set InvalidDecl directly when deserializing a Decl
aaronpuchert Sep 5, 2020
430b47a
[MLIR] Remove unused arg from affine tiling validity check
bondhugula Sep 4, 2020
94c71d6
[InstCombine] Add tests for abs intrinsic eq zero (NFC)
nikic Sep 5, 2020
ada8a17
[InstCombine] Fold abs intrinsic eq zero
nikic Sep 5, 2020
73104b0
[InstSimplify] Fold min/max based on dominating condition
nikic Sep 4, 2020
4892d3a
[InstCombine] Fold abs with dominating condition
nikic Sep 5, 2020
ac87480
[SCEV] Recognize min/max intrinsics
nikic Sep 4, 2020
9dcc82f
Thread safety analysis: Consider global variables in scope
aaronpuchert Sep 5, 2020
b2ce79e
Thread safety analysis: ValueDecl in Project is non-null
aaronpuchert Jul 25, 2020
5ad6552
[InstCombine] Add tests for known negative abs intrinsic (NFC)
nikic Sep 5, 2020
d3a779f
Restore size of TemplateParameterList after D44352
aaronpuchert Sep 5, 2020
da6b3aa
Attempt to fix Sphinx build failure, NFC
aaronpuchert Sep 5, 2020
bef38e8
[ELF] Handle SHT_RISCV_ATTRIBUTES similarly to SHT_ARM_ATTRIBUTES
jrtc27 Aug 20, 2020
0c64282
scan-build-py: fix multiprocessing error
lawrence-danna-apple Sep 5, 2020
1ddb3a3
[LangRef] Adjust guarantee for llvm.memcpy to also allow equal argume…
fhahn Sep 4, 2020
621b10c
[InstSimplify] Add tests for a peculiar abs of abs form (NFC)
nikic Sep 5, 2020
1387f96
[Hexagon] Handle widening of vector truncate
Sep 5, 2020
298c9fa
[NFC][compiler-rt] Refine .clang-tidy checks
vitalybuka Sep 5, 2020
51597cc
[NFC][Asan] Rename internal enum value.
vitalybuka Sep 4, 2020
398c44b
[NFC][Asan] Inline enum doc strings
vitalybuka Sep 4, 2020
d5d09d9
[NFC][Asan] Reformat some allocator code
vitalybuka Sep 4, 2020
8789f2b
[Hexagon] Resize the mem operand when widening loads and stores
Sep 5, 2020
9518f03
[Hexagon] When widening truncate result, also widen operand if necessary
Sep 5, 2020
62f89a8
[Hexagon] Add assertions about V6_pred_scalar2
Sep 5, 2020
aff94ec
[AMDGPU] Remove the dead spill slots while spilling FP/BP to memory
RamNalamothu Sep 6, 2020
9128f5c
[NFC][Asan] Move free_tid from ChunkHeader
vitalybuka Sep 5, 2020
289c08e
[NFC][Asan] Fix clang-tidy warning
vitalybuka Sep 6, 2020
eb87e1d
[Asan] Cleanup atomic usage in allocator
vitalybuka Sep 6, 2020
d0abc75
[GlobalISel] Disable the indexed loads combine completely unless forc…
aemerson Sep 6, 2020
b2e27a8
Revert "[Asan] Cleanup atomic usage in allocator"
vitalybuka Sep 6, 2020
b11db36
[Asan] Cleanup atomic usage in allocator
vitalybuka Sep 6, 2020
ff218cb
[InstSimplify] Fold degenerate abs of abs form
nikic Sep 5, 2020
4d0312c
Add proper move ctor/move assign to APValue. NFCI.
d0k Sep 6, 2020
d866dc3
[ARM] Regenerate tests. NFC
davemgreen Sep 6, 2020
667e800
[ARM] Remove -O3 from mve intrinsic tests. NFC
davemgreen Sep 6, 2020
ecac5c2
[X86][AVX] lowerShuffleWithPERMV - adjust binary shuffle masks to acc…
RKSimon Sep 6, 2020
8c386c9
[SmallVector] Move error handling out of line
d0k Sep 6, 2020
cc6713a
Thread safety analysis: Test and document release_generic_capability
aaronpuchert Sep 6, 2020
bbb3baf
Thread safety analysis: Improve documentation for scoped capabilities
aaronpuchert Sep 6, 2020
54d432a
[mlir] Add Shaped Type, Tensor Type and MemRef Type to python bindings.
zhanghb97 Sep 6, 2020
16bb71f
[DSE,MemorySSA] Add a few additional debug messages.
fhahn Sep 6, 2020
8542dab
[compiler-rt] Implement __clear_cache() on OpenBSD/arm
brad0 Sep 6, 2020
b536cba
[ValueTracking] Avoid known bits fallback for non-zero get check (NFCI)
nikic Sep 6, 2020
ab68517
[asan_symbolize] Pass --demangle/--no-demangle instead of --demangle=…
MaskRay Sep 6, 2020
efa57f9
[PowerPC] Implement Vector Expand Mask builtins in LLVM/Clang
amy-kwan Sep 3, 2020
caee15a
[WebAssembly] Fix incorrect assumption of simple value types
tlively Sep 6, 2020
d5c4504
[machinesink] add testcase for more sinking - NFC
Sep 7, 2020
69f2c79
[ELF] Add a new e_machine value EM_CSKY and add some CSKY relocation …
zixuan-wu Sep 2, 2020
9bee13f
Move targetHasSVE function to lldbtest.py
omjavaid Sep 7, 2020
1fd7dc4
When dumping results of StackLifetime, it will print the following
dongAxis Sep 7, 2020
7695332
Move NativeRegisterContextLinux/RegisterContextPOSIX*_arm to Register…
omjavaid Sep 7, 2020
7403e3e
Extend PyConcreteType to support intermediate base classes.
stellaraccident Sep 6, 2020
70523ec
[Sparc] Select the UltraSPARC instruction set with the external assem…
brad0 Sep 7, 2020
b3205e2
[scan-view] Explicitly use utf-8 in send_string
Sep 7, 2020
80186e4
[CMake][TableGen] Simplify code by using list(TRANSFORM)
tambry Sep 5, 2020
098130f
[CMake][Polly] Remove dead CMake code
tambry Sep 5, 2020
21c0e74
[CMake][OpenMP] Remove old dead CMake code
tambry Sep 5, 2020
f4835b9
[CMake][TableGen] Remove dead CMake version checks
tambry Sep 5, 2020
04ea680
[cmake] Fix build of attribute plugin example on Windows
chbessonova Sep 7, 2020
5350e1b
[KnownBits] Implement accurate unsigned and signed max and min
jayfoad Sep 2, 2020
a98b126
Add BinaryFormat/ELFRelocs/CSKY.def to LLVM modulemap
Teemperor Sep 7, 2020
40f4131
[DWARFYAML] Make the debug_addr section optional.
higuoxing Sep 7, 2020
0af4147
[ARM][CostModel] CodeSize costs for i1 arith ops
sparker-arm Aug 25, 2020
713c2ad
[GlobalISel] Extend not_cmp_fold to work on conditional expressions
jayfoad Aug 27, 2020
65f78e7
[SimplifyCFG] Consider cost of combining predicates.
sparker-arm Sep 7, 2020
e7bd058
[clang-format] Allow configuring list of macros that map to attributes
arichardson Sep 7, 2020
8aa3b8d
[clang-format] Handle typename macros inside cast expressions
arichardson Sep 7, 2020
cd01eec
[clang-format] Check that */& after typename macros are pointers/refe…
arichardson Sep 7, 2020
56fa7d1
[clang-format] Fix formatting of _Atomic() qualifier
arichardson Sep 1, 2020
9a22eba
[clang-format] Parse __underlying_type(T) as a type
arichardson Sep 7, 2020
05147d3
[clang-format] Correctly parse function declarations with TypenameMacros
arichardson Sep 7, 2020
7634c64
[OpenMP][AMDGPU] Use DS_Max_Warp_Number instead of WARPSIZE
pdhaliwal-amd Sep 3, 2020
8d64df9
[mlir][Vector] Revisit VectorToSCF.
nicolasvasilache Sep 4, 2020
81aa66f
Extract infrastructure to ignore intermediate expressions into `clang…
Aug 28, 2020
1a7a2cd
[Ignore Expressions][NFC] Refactor to better use `IgnoreExpr.h` and nits
Aug 31, 2020
0dbe250
[X86] Use Register instead of unsigned. NFCI.
RKSimon Sep 7, 2020
22fa6b2
[X86] Use Register instead of unsigned. NFCI.
RKSimon Sep 7, 2020
ee68b66
[NFC][PowerPC] Add tests for `mul` with big constants.
Sep 7, 2020
9ad2615
[X86] Use Register instead of unsigned. NFCI.
RKSimon Sep 7, 2020
aa3fcb9
[X86][AVX] Add extra vperm2f128+vpermilvar combine coverage
RKSimon Sep 7, 2020
71dfdbe
[X86] getFauxShuffleMask - handle insert_subvector(zero, sub, C)
RKSimon Sep 7, 2020
7ba0f81
[X86] Unbreak the build after 22fa6b20d92e
d0k Sep 7, 2020
56d1f31
[gn build] Port 81aa66f65f5
llvmgnsyncbot Sep 7, 2020
0478720
[clang] Prevent that Decl::dump on a CXXRecordDecl deserialises furth…
Teemperor Sep 7, 2020
9764eb9
[gn build] Port 0478720157f
llvmgnsyncbot Sep 7, 2020
928c4b4
[SCEV] Refactor isHighCostExpansionHelper
sparker-arm Sep 7, 2020
136eb79
[MLIR][Standard] Add `dynamic_tensor_from_elements` operation
frgossen Sep 7, 2020
3097427
[obj2yaml] Add support for dumping the .debug_str section.
higuoxing Sep 7, 2020
9b645eb
[X86][AVX] Use lowerShuffleWithPERMV in shuffle combining to support …
RKSimon Sep 7, 2020
5bb27e7
X86AvoidStoreForwardingBlocks.cpp - use unsigned for Opcode values. N…
RKSimon Sep 7, 2020
3a86eb0
[llvm-readobj/elf] - Introduce Relocation<ELFT> helper.
Sep 4, 2020
e57cbcb
LegalizeTypes.h - remove orphan SplitVSETCC declaration. NFCI.
RKSimon Sep 7, 2020
15acdd7
[MLIR][Shape] Merge `shape` to `std`/`scf` lowerings.
frgossen Sep 7, 2020
1c849ec
[MLIR] Fix Win test due to partial order of CHECK directives
nicolasvasilache Sep 7, 2020
3ca8b9a
[InstCombine] give a name to an intermediate value for easier trackin…
rotateright Sep 7, 2020
28aa60a
[InstCombine] add test with more unreachable insts; NFC
rotateright Sep 7, 2020
79ea83e
[SelectionDAG] memcpy expansion of const volatile struct ignores cons…
simonwallis2 Sep 7, 2020
a8a9153
[X86] Replace EmitX86AddSubSatExpr with EmitX86BinaryIntrinsic generi…
RKSimon Sep 7, 2020
6670f5d
MachineStableHash.h - remove MachineInstr.h include. NFC.
RKSimon Sep 7, 2020
dbb8188
[llvm-readobj/elf] - Generalize the code for printing dynamic relocat…
Sep 7, 2020
973800d
Revert "[MLIR][Shape] Merge `shape` to `std`/`scf` lowerings."
DavidTruby Sep 7, 2020
23f700c
Revert "[clang] Prevent that Decl::dump on a CXXRecordDecl deserialis…
Teemperor Sep 7, 2020
bb73fcf
[gn build] Port 23f700c785a
llvmgnsyncbot Sep 7, 2020
2853ae3
[X86] Update SSE/AVX ABS intrinsics to emit llvm.abs.* (PR46851)
RKSimon Sep 7, 2020
f6db681
[X86][SSE] Move llvm.x86.ssse3.pabs.*.128 intrinsics to ssse3-intrins…
RKSimon Sep 7, 2020
6b954f1
[KillTheDoctor/CMake] Add missing keyword PRIVATE in target_link_libr…
dmm9 Sep 7, 2020
4368739
[llvm-readobj] - Remove code duplication when printing dynamic reloca…
Sep 7, 2020
a5046f7
[NFC][PowerPC] Add tests in constants-i64.ll.
Sep 7, 2020
1e1a4a4
[mlir] Take ValueRange instead of ArrayRef<Value> in StructuredIndexed
ftynse Sep 4, 2020
4b530f7
[X86][SSE] Use llvm.abs.* vector intrinsics instead of old (deprecate…
RKSimon Sep 7, 2020
96e0f34
[X86] Auto upgrade SSE/AVX PABS intrinsics to generic Intrinsic::abs
RKSimon Sep 7, 2020
288c582
Follow up of rG5f1cad4d296a, slightly reduced test case. NFC.
Sep 7, 2020
a70f2eb
[MLIR][Shape] Merge `shape` to `std`/`scf` lowerings.
frgossen Sep 7, 2020
b22910d
[InstCombine] erase instructions leading up to unreachable
rotateright Sep 7, 2020
6016262
[X86] Replace UpgradeX86AddSubSatIntrinsics with UpgradeX86BinaryIntr…
RKSimon Sep 7, 2020
7993431
[X86][SSE] Add test cases for PR47448
RKSimon Sep 7, 2020
9de0a3d
[X86][SSE] Don't use LowerVSETCCWithSUBUS for unsigned compare with +…
RKSimon Sep 7, 2020
c4056f8
[Sparc] Add reduced funnel shift test case for PR47303
RKSimon Sep 7, 2020
783d711
AntiDepBreaker.h - remove unnecessary ScheduleDAG.h include. NFCI.
RKSimon Sep 7, 2020
2e18272
[flang] Fix link to old repo location in doxygen mainpage. NFC.
RichBarton-Arm Sep 7, 2020
d012805
[analyzer][StdLibraryFunctionsChecker] Add POSIX pthread handling fun…
Jul 23, 2020
7e5dab5
[flang] Spelling and format edits to README.txt. NFC.
RichBarton-Arm Sep 7, 2020
8248c2a
[analyzer][StdLibraryFunctionsChecker] Have proper weak dependencies
Sep 7, 2020
eb482af
Reduce the number of memory allocations when displaying
momchil-velikov Sep 7, 2020
2480a31
[AMDGPU] SILowerControlFlow::optimizeEndCF should remove empty basic …
alex-t Sep 7, 2020
11d8eed
[InstCombine] move/add tests for icmp with mul operands; NFC
rotateright Sep 7, 2020
7a6d6f0
[InstCombine] improve folds for icmp with multiply operands (PR47432)
rotateright Sep 7, 2020
1c34ac0
LeonPasses.h - remove orphan function declarations. NFCI.
RKSimon Sep 7, 2020
dfc3330
LeonPasses.h - remove unnecessary includes. NFCI.
RKSimon Sep 7, 2020
95ca3aa
BTFDebug.h - reduce MachineInstr.h include to forward declaration. NFCI.
RKSimon Sep 7, 2020
4e89a0a
MipsISelLowering.h - remove CCState/CCValAssign forward declarations.…
RKSimon Sep 7, 2020
5ea9e65
VPlan.h - remove unnecessary forward declarations. NFCI.
RKSimon Sep 7, 2020
e52e7ad
[ms] [llvm-ml] Add support for bitwise named operators (AND, NOT, OR)…
ericastor Sep 7, 2020
2feb6e9
[ms] [llvm-ml] Fix STRUCT field alignment
ericastor Sep 7, 2020
a3ec4a3
[ms] [llvm-ml] Allow use of locally-defined variables in expressions
ericastor Sep 7, 2020
7a06b16
[DAGCombiner] allow more store merging for non-i8 truncated ops
rotateright Sep 7, 2020
f3a6f6c
[X86] Pre-commit new test case for D87214. NFC
topperc Sep 7, 2020
01b3e16
[X86] Use the same sequence for i128 ISD::ABS on 64-bit targets as we…
topperc Sep 7, 2020
7020781
[InstCombine] add ptr difference tests; NFC
rotateright Sep 7, 2020
8b30067
[InstCombine] improve fold of pointer differences
rotateright Sep 7, 2020
cee7f3b
[SYCL] Take into account auxiliary cmake options for Level Zero loader
againull Sep 8, 2020
c107c05
Merge from 'sycl' to 'sycl-web' (#33)
Sep 8, 2020
07dea1c
Merge from 'master' to 'sycl-web' (#26)
robertcox-github Sep 9, 2020
202ca55
Merge from 'sycl' to 'sycl-web' (#1)
Sep 9, 2020
ff09484
Merge from 'master' to 'sycl-web' (#46)
Sep 9, 2020
cf4203b
Merge from 'sycl' to 'sycl-web' (#1)
Sep 9, 2020
f9f3df3
Merge from 'master' to 'sycl-web' (#1)
Sep 9, 2020
feb8d3e
Merge remote-tracking branch 'otcshare_llvm/sycl-web' into llvmspirv_…
vladimirlaz Sep 13, 2020
f2de7e9
Merge commit master into llvmspirv_pulldown
vladimirlaz Sep 13, 2020
52c753b
Add Constrained Floating-Point Intrinsics support
MochalovaAn Aug 25, 2020
15dd186
Do not translate arbitrary precision operations without corresponding…
vmaksimo Sep 9, 2020
3addf30
Fix nullptr dereference (#741)
fadeeval Sep 9, 2020
ce75da7
Avoid usage of deprecated "VectorType::getNumElements" (#737)
MochalovaAn Sep 10, 2020
4f76639
Revert "[SYCL] XFAIL test blcoking pulldown"
vladimirlaz Sep 13, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ autoconf/autom4te.cache
# VS2017 and VSCode config files.
.vscode
.vs
# pythonenv for github Codespaces
pythonenv*
# clangd index. (".clangd" is a config file now, thus trailing slash)
.clangd/
.cache
Expand Down
2 changes: 1 addition & 1 deletion clang-tools-extra/clang-tidy/modernize/UseAutoCheck.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ void UseAutoCheck::replaceIterators(const DeclStmt *D, ASTContext *Context) {

// Drill down to the as-written initializer.
const Expr *E = (*Construct->arg_begin())->IgnoreParenImpCasts();
if (E != E->IgnoreConversionOperator()) {
if (E != E->IgnoreConversionOperatorSingleStep()) {
// We hit a conversion operator. Early-out now as they imply an implicit
// conversion from a different type. Could also mean an explicit
// conversion from the same type but that's pretty rare.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ std::string compareExpressionToZero(const MatchFinder::MatchResult &Result,

std::string replacementExpression(const MatchFinder::MatchResult &Result,
bool Negated, const Expr *E) {
E = E->ignoreParenBaseCasts();
E = E->IgnoreParenBaseCasts();
if (const auto *EC = dyn_cast<ExprWithCleanups>(E))
E = EC->getSubExpr();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ Known limitations

The ``else`` branch is not checked currently for negated condition variable:

.. code-block:: c

bool onFire = isBurning();
if (onFire) {
scream();
Expand Down
5 changes: 3 additions & 2 deletions clang/docs/Block-ABI-Apple.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,16 @@ High Level
==========

The ABI of ``Blocks`` consist of their layout and the runtime functions required
by the compiler. A ``Block`` consists of a structure of the following form:
by the compiler. A ``Block`` of type ``R (^)(P...)`` consists of a structure of
the following form:

.. code-block:: c

struct Block_literal_1 {
void *isa; // initialized to &_NSConcreteStackBlock or &_NSConcreteGlobalBlock
int flags;
int reserved;
void (*invoke)(void *, ...);
R (*invoke)(struct Block_literal_1 *, P...);
struct Block_descriptor_1 {
unsigned long int reserved; // NULL
unsigned long int size; // sizeof(struct Block_literal_1)
Expand Down
17 changes: 17 additions & 0 deletions clang/docs/ClangFormatStyleOptions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -758,7 +758,24 @@ the configuration (without a prefix: ``Auto``).
int bbbbbbbbbbbbbbbbbbbbb) {
}

**AttributeMacros** (``std::vector<std::string>``)
A vector of strings that should be interpreted as attributes/qualifiers
instead of identifiers. This can be useful for language extensions or
static analyzer annotations:

.. code-block:: c++

x = (char *__capability)&y;
int function(void) __ununsed;
void only_writes_to_buffer(char *__output buffer);

In the .clang-format configuration file, this can be configured like:

.. code-block:: yaml

AttributeMacros: ['__capability', '__output', '__ununsed']

For example: __capability.

**BinPackArguments** (``bool``)
If ``false``, a function call's arguments will either be all on the
Expand Down
114 changes: 103 additions & 11 deletions clang/docs/ThreadSafetyAnalysis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -209,21 +209,21 @@ must be held on entry to the function, *and must still be held on exit*.
}


ACQUIRE(...), ACQUIRE_SHARED(...), RELEASE(...), RELEASE_SHARED(...)
--------------------------------------------------------------------
ACQUIRE(...), ACQUIRE_SHARED(...), RELEASE(...), RELEASE_SHARED(...), RELEASE_GENERIC(...)
------------------------------------------------------------------------------------------

*Previously*: ``EXCLUSIVE_LOCK_FUNCTION``, ``SHARED_LOCK_FUNCTION``,
``UNLOCK_FUNCTION``

``ACQUIRE`` is an attribute on functions or methods, which
declares that the function acquires a capability, but does not release it. The
caller must not hold the given capability on entry, and it will hold the
capability on exit. ``ACQUIRE_SHARED`` is similar.
``ACQUIRE`` and ``ACQUIRE_SHARED`` are attributes on functions or methods
declaring that the function acquires a capability, but does not release it.
The given capability must not be held on entry, and will be held on exit
(exclusively for ``ACQUIRE``, shared for ``ACQUIRE_SHARED``).

``RELEASE`` and ``RELEASE_SHARED`` declare that the function releases the given
capability. The caller must hold the capability on entry, and will no longer
hold it on exit. It does not matter whether the given capability is shared or
exclusive.
``RELEASE``, ``RELEASE_SHARED``, and ``RELEASE_GENERIC`` declare that the
function releases the given capability. The capability must be held on entry
(exclusively for ``RELEASE``, shared for ``RELEASE_SHARED``, exclusively or
shared for ``RELEASE_GENERIC``), and will no longer be held on exit.

.. code-block:: c++

Expand Down Expand Up @@ -402,6 +402,13 @@ the destructor. Such classes require special handling because the constructor
and destructor refer to the capability via different names; see the
``MutexLocker`` class in :ref:`mutexheader`, below.

Scoped capabilities are treated as capabilities that are implicitly acquired
on construction and released on destruction. They are associated with
the set of (regular) capabilities named in thread safety attributes on the
constructor. Acquire-type attributes on other member functions are treated as
applying to that set of associated capabilities, while ``RELEASE`` implies that
a function releases all associated capabilities in whatever mode they're held.


TRY_ACQUIRE(<bool>, ...), TRY_ACQUIRE_SHARED(<bool>, ...)
---------------------------------------------------------
Expand All @@ -414,6 +421,26 @@ The first argument must be ``true`` or ``false``, to specify which return value
indicates success, and the remaining arguments are interpreted in the same way
as ``ACQUIRE``. See :ref:`mutexheader`, below, for example uses.

Because the analysis doesn't support conditional locking, a capability is
treated as acquired after the first branch on the return value of a try-acquire
function.

.. code-block:: c++

Mutex mu;
int a GUARDED_BY(mu);

void foo() {
bool success = mu.TryLock();
a = 0; // Warning, mu is not locked.
if (success) {
a = 0; // Ok.
mu.Unlock();
} else {
a = 0; // Warning, mu is not locked.
}
}


ASSERT_CAPABILITY(...) and ASSERT_SHARED_CAPABILITY(...)
--------------------------------------------------------
Expand Down Expand Up @@ -800,6 +827,9 @@ implementation.
#define RELEASE_SHARED(...) \
THREAD_ANNOTATION_ATTRIBUTE__(release_shared_capability(__VA_ARGS__))

#define RELEASE_GENERIC(...) \
THREAD_ANNOTATION_ATTRIBUTE__(release_generic_capability(__VA_ARGS__))

#define TRY_ACQUIRE(...) \
THREAD_ANNOTATION_ATTRIBUTE__(try_acquire_capability(__VA_ARGS__))

Expand Down Expand Up @@ -844,6 +874,9 @@ implementation.
// Release/unlock a shared mutex.
void ReaderUnlock() RELEASE_SHARED();

// Generic unlock, can unlock exclusive and shared mutexes.
void GenericUnlock() RELEASE_GENERIC();

// Try to acquire the mutex. Returns true on success, and false on failure.
bool TryLock() TRY_ACQUIRE(true);

Expand All @@ -860,19 +893,78 @@ implementation.
const Mutex& operator!() const { return *this; }
};

// Tag types for selecting a constructor.
struct adopt_lock_t {} inline constexpr adopt_lock = {};
struct defer_lock_t {} inline constexpr defer_lock = {};
struct shared_lock_t {} inline constexpr shared_lock = {};

// MutexLocker is an RAII class that acquires a mutex in its constructor, and
// releases it in its destructor.
class SCOPED_CAPABILITY MutexLocker {
private:
Mutex* mut;
bool locked;

public:
MutexLocker(Mutex *mu) ACQUIRE(mu) : mut(mu) {
// Acquire mu, implicitly acquire *this and associate it with mu.
MutexLocker(Mutex *mu) ACQUIRE(mu) : mut(mu), locked(true) {
mu->Lock();
}

// Assume mu is held, implicitly acquire *this and associate it with mu.
MutexLocker(Mutex *mu, adopt_lock_t) REQUIRES(mu) : mut(mu), locked(true) {}

// Acquire mu in shared mode, implicitly acquire *this and associate it with mu.
MutexLocker(Mutex *mu, shared_lock_t) ACQUIRE_SHARED(mu) : mut(mu), locked(true) {
mu->ReaderLock();
}

// Assume mu is held in shared mode, implicitly acquire *this and associate it with mu.
MutexLocker(Mutex *mu, adopt_lock_t, shared_lock_t) REQUIRES_SHARED(mu)
: mut(mu), locked(true) {}

// Assume mu is not held, implicitly acquire *this and associate it with mu.
MutexLocker(Mutex *mu, defer_lock_t) EXCLUDES(mu) : mut(mu), locked(false) {}

// Release *this and all associated mutexes, if they are still held.
// There is no warning if the scope was already unlocked before.
~MutexLocker() RELEASE() {
if (locked)
mut->GenericUnlock();
}

// Acquire all associated mutexes exclusively.
void Lock() ACQUIRE() {
mut->Lock();
locked = true;
}

// Try to acquire all associated mutexes exclusively.
bool TryLock() TRY_ACQUIRE(true) {
return locked = mut->TryLock();
}

// Acquire all associated mutexes in shared mode.
void ReaderLock() ACQUIRE_SHARED() {
mut->ReaderLock();
locked = true;
}

// Try to acquire all associated mutexes in shared mode.
bool ReaderTryLock() TRY_ACQUIRE_SHARED(true) {
return locked = mut->ReaderTryLock();
}

// Release all associated mutexes. Warn on double unlock.
void Unlock() RELEASE() {
mut->Unlock();
locked = false;
}

// Release all associated mutexes. Warn on double unlock.
void ReaderUnlock() RELEASE() {
mut->ReaderUnlock();
locked = false;
}
};

Expand Down
2 changes: 1 addition & 1 deletion clang/docs/analyzer/checkers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1747,7 +1747,7 @@ Check for integer to enumeration casts that could result in undefined values.
void foo() {
TestEnum t = static_cast(-1);
// warn: the value provided to the cast expression is not in
the valid range of values for the enum
// the valid range of values for the enum

.. _alpha-cplusplus-InvalidatedIterator:

Expand Down
2 changes: 1 addition & 1 deletion clang/examples/Attribute/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
add_llvm_library(Attribute MODULE Attribute.cpp PLUGIN_TOOL clang)

if(LLVM_ENABLE_PLUGINS AND (WIN32 OR CYGWIN))
target_link_libraries(Attribute ${cmake_2_8_12_PRIVATE}
target_link_libraries(Attribute PRIVATE
clangAST
clangBasic
clangFrontend
Expand Down
20 changes: 20 additions & 0 deletions clang/include/clang-c/Index.h
Original file line number Diff line number Diff line change
Expand Up @@ -2940,6 +2940,26 @@ CINDEX_LINKAGE int clang_getCursorPlatformAvailability(
CINDEX_LINKAGE void
clang_disposeCXPlatformAvailability(CXPlatformAvailability *availability);

/**
* If cursor refers to a variable declaration and it has initializer returns
* cursor referring to the initializer otherwise return null cursor.
*/
CINDEX_LINKAGE CXCursor clang_Cursor_getVarDeclInitializer(CXCursor cursor);

/**
* If cursor refers to a variable declaration that has global storage returns 1.
* If cursor refers to a variable declaration that doesn't have global storage
* returns 0. Otherwise returns -1.
*/
CINDEX_LINKAGE int clang_Cursor_hasVarDeclGlobalStorage(CXCursor cursor);

/**
* If cursor refers to a variable declaration that has external storage
* returns 1. If cursor refers to a variable declaration that doesn't have
* external storage returns 0. Otherwise returns -1.
*/
CINDEX_LINKAGE int clang_Cursor_hasVarDeclExternalStorage(CXCursor cursor);

/**
* Describe the "language" of the entity referred to by a cursor.
*/
Expand Down
63 changes: 63 additions & 0 deletions clang/include/clang-c/Rewrite.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
/*===-- clang-c/Rewrite.h - C CXRewriter --------------------------*- C -*-===*\
|* *|
|* Part of the LLVM Project, under the Apache License v2.0 with LLVM *|
|* Exceptions. *|
|* See https://llvm.org/LICENSE.txt for license information. *|
|* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception *|
|* *|
|*===----------------------------------------------------------------------===*/

#ifndef LLVM_CLANG_C_REWRITE_H
#define LLVM_CLANG_C_REWRITE_H

#include "clang-c/CXString.h"
#include "clang-c/ExternC.h"
#include "clang-c/Index.h"
#include "clang-c/Platform.h"

LLVM_CLANG_C_EXTERN_C_BEGIN

typedef void *CXRewriter;

/**
* Create CXRewriter.
*/
CINDEX_LINKAGE CXRewriter clang_CXRewriter_create(CXTranslationUnit TU);

/**
* Insert the specified string at the specified location in the original buffer.
*/
CINDEX_LINKAGE void clang_CXRewriter_insertTextBefore(CXRewriter Rew, CXSourceLocation Loc,
const char *Insert);

/**
* Replace the specified range of characters in the input with the specified
* replacement.
*/
CINDEX_LINKAGE void clang_CXRewriter_replaceText(CXRewriter Rew, CXSourceRange ToBeReplaced,
const char *Replacement);

/**
* Remove the specified range.
*/
CINDEX_LINKAGE void clang_CXRewriter_removeText(CXRewriter Rew, CXSourceRange ToBeRemoved);

/**
* Save all changed files to disk.
* Returns 1 if any files were not saved successfully, returns 0 otherwise.
*/
CINDEX_LINKAGE int clang_CXRewriter_overwriteChangedFiles(CXRewriter Rew);

/**
* Write out rewritten version of the main file to stdout.
*/
CINDEX_LINKAGE void clang_CXRewriter_writeMainFileToStdOut(CXRewriter Rew);

/**
* Free the given CXRewriter.
*/
CINDEX_LINKAGE void clang_CXRewriter_dispose(CXRewriter Rew);

LLVM_CLANG_C_EXTERN_C_END

#endif
11 changes: 4 additions & 7 deletions clang/include/clang/AST/APValue.h
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ class APValue {
MakeComplexFloat(); setComplexFloat(std::move(R), std::move(I));
}
APValue(const APValue &RHS);
APValue(APValue &&RHS) : Kind(None) { swap(RHS); }
APValue(APValue &&RHS);
APValue(LValueBase B, const CharUnits &O, NoLValuePath N,
bool IsNullPtr = false)
: Kind(None) {
Expand Down Expand Up @@ -339,6 +339,9 @@ class APValue {
return Result;
}

APValue &operator=(const APValue &RHS);
APValue &operator=(APValue &&RHS);

~APValue() {
if (Kind != None && Kind != Indeterminate)
DestroyDataAndMakeUninit();
Expand Down Expand Up @@ -591,12 +594,6 @@ class APValue {
((AddrLabelDiffData*)(char*)Data.buffer)->RHSExpr = RHSExpr;
}

/// Assign by swapping from a copy of the RHS.
APValue &operator=(APValue RHS) {
swap(RHS);
return *this;
}

private:
void DestroyDataAndMakeUninit();
void MakeInt() {
Expand Down
Loading