[PATCH] D92634: [Analyzer] Diagnose signed integer overflow

2020-12-03 Thread Daniel Marjamäki via Phabricator via cfe-commits
danielmarjamaki created this revision. danielmarjamaki added reviewers: NoQ, xazax.hun. Herald added subscribers: steakhal, ASDenysPetrov, martong, Charusso, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware. danielmarjamaki requested review of this r

[PATCH] D92633: Add -f[no-]direct-access-external-data to deprecate -mpie-copy-relocations

2020-12-03 Thread Sriraman Tallam via Phabricator via cfe-commits
tmsriram added a comment. You said : "The name -mpie-copy-relocations is misleading [1] and does not capture the idea that this option can actually apply to all of -fno-pic,-fpie, ..." Could you please clarify why this option needs to apply to -fno-pic? Here is what I tried with trunk clang:

[PATCH] D88394: [Driver][M68k] (Patch 8/8) Add driver support for M68k

2020-12-03 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu marked 2 inline comments as done. myhsu added inline comments. Comment at: clang/include/clang/Driver/Options.td:3125 +foreach i = {0-4} in + def m680#i#0 : Flag<["-"], "m680"#i#"0">, Group; myhsu wrote: > bruno wrote: > > rengolin wrote: > > > Same ques

[PATCH] D88394: [Driver][M68k] (Patch 8/8) Add driver support for M68k

2020-12-03 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu updated this revision to Diff 309462. myhsu added a comment. - Add support for M68060 sub-target CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88394/new/ https://reviews.llvm.org/D88394 Files: clang/include/clang/Driver/Options.td clang/lib/Driver/CMakeLists.txt clang/lib/D

[PATCH] D88393: [cfe][M68k] (Patch 7/8) Basic Clang support

2020-12-03 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu updated this revision to Diff 309461. myhsu added a comment. - Add support for M68060 sub-target CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88393/new/ https://reviews.llvm.org/D88393 Files: clang/include/clang/Basic/Attr.td clang/lib/Basic/CMakeLists.txt clang/lib/Basic/

[PATCH] D92633: Add -f[no-]direct-access-external-data to deprecate -mpie-copy-relocations

2020-12-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. MaskRay added reviewers: hjl.tools, rnk, tmsriram. Herald added subscribers: dexonsmith, dang, pengfei, s.egerton, simoncook. MaskRay requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. GCC r218397 "x86-64: Optimi

[clang] dec1bbb - Fix -allow-deprecated-dag-overlap in test/CodeGen/dso-local-executable.c

2020-12-03 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2020-12-03T21:24:38-08:00 New Revision: dec1bbb47cda3098c1621f780f10cee3fd91e7b1 URL: https://github.com/llvm/llvm-project/commit/dec1bbb47cda3098c1621f780f10cee3fd91e7b1 DIFF: https://github.com/llvm/llvm-project/commit/dec1bbb47cda3098c1621f780f10cee3fd91e7b1.diff

[clang] c4af1c8 - PR48383: Disallow decltype(auto) in pseudodestructor calls

2020-12-03 Thread David Blaikie via cfe-commits
Author: David Blaikie Date: 2020-12-03T20:41:06-08:00 New Revision: c4af1c8d939b21ac7deb631887fc26db7451c592 URL: https://github.com/llvm/llvm-project/commit/c4af1c8d939b21ac7deb631887fc26db7451c592 DIFF: https://github.com/llvm/llvm-project/commit/c4af1c8d939b21ac7deb631887fc26db7451c592.diff

[PATCH] D92361: [trivial-abi] Support types without a copy or move constructor.

2020-12-03 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added a comment. > You're right; thinking about it in the context of four value operations is > helpful. FWIW, I think dragging "value operations" into the mix is exactly wrong (and referring to "destructive move" is extra wrong, in the specific context of C++). For a C++ object, w

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:3957 + RenderDebugEnablingArgs(Args, CmdArgs, DebugInfoKind, + std::min(DWARFVersion, TC.getMaxDwarfVersion()), DebuggerTuning);

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/test/Driver/cuda-unsupported-debug-options.cu:22 +// Make sure we do not see any dwarf version other than 2, regardless of what's used on the host side. +// CHECK-NOT: {{-dwarf-version=[^2]}} // CHECK: "-triple" "x86_64 -

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/test/Driver/cuda-unsupported-debug-options.cu:22 +// Make sure we do not see any dwarf version other than 2, regardless of what's used on the host side. +// CHECK-NOT: {{-dwarf-version=[^2]}} // CHECK: "-triple" "x86_64 -

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:3957 + RenderDebugEnablingArgs(Args, CmdArgs, DebugInfoKind, + std::min(DWARFVersion, TC.getMaxDwarfVersion()), DebuggerTuning); dbla

[PATCH] D92544: [NFC] [Clang] Fix ppc64le vaarg OpenMP test in CodeGen

2020-12-03 Thread Qiu Chaofan via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rG9378a366b2b2: [NFC] [Clang] Fix ppc64le vaarg OpenMP test in CodeGen (authored by qiucf). Herald added a project: clang. H

[clang] 9378a36 - [NFC] [Clang] Fix ppc64le vaarg OpenMP test in CodeGen

2020-12-03 Thread Qiu Chaofan via cfe-commits
Author: Qiu Chaofan Date: 2020-12-04T11:29:55+08:00 New Revision: 9378a366b2b256ebd1b2763141f683ab9b48c303 URL: https://github.com/llvm/llvm-project/commit/9378a366b2b256ebd1b2763141f683ab9b48c303 DIFF: https://github.com/llvm/llvm-project/commit/9378a366b2b256ebd1b2763141f683ab9b48c303.diff L

[PATCH] D92080: [Clang] Mutate long-double math builtins into f128 under IEEE-quad

2020-12-03 Thread Qiu Chaofan via Phabricator via cfe-commits
qiucf added a comment. Any comments...? I don't have knowledge if there's any plan about implementing `*f128` math functions on X86 libcs. But as I see so far, `*l` doesn't work well on `fp128`. Keeping this target independent currently seems reasonable to me. Repository: rG LLVM Github Mon

[PATCH] D92628: [HIP] Fix bug in driver about wavefront size

2020-12-03 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm accepted this revision. arsenm added a comment. This revision is now accepted and ready to land. LGTM although I thought there were existing test files for this CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92628/new/ https://reviews.llvm.org/D92628 _

[PATCH] D92630: ARCMigrate: Use hash_combine in the DenseMapInfo for EditEntry

2020-12-03 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith created this revision. dexonsmith added reviewers: JDevlieghere, jansvoboda11, arphaman. Herald added a subscriber: ributzka. dexonsmith requested review of this revision. Herald added a project: clang. Simplify the DenseMapInfo for `EditEntry` by migrating from `FoldingSetNodeID` to `l

[PATCH] D92628: [HIP] Fix bug in driver about wavefront size

2020-12-03 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added reviewers: tra, arsenm. Herald added subscribers: kerbowa, nhaehnle, jvesely. yaxunl requested review of this revision. Herald added a subscriber: wdng. The static variable causes it only initialized once and take the same value for different GPU archs, w

[PATCH] D92627: Basic: Add hashing support for FileEntryRef and DirectoryEntryRef

2020-12-03 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith created this revision. dexonsmith added reviewers: arphaman, JDevlieghere, jansvoboda11. Herald added a subscriber: ributzka. dexonsmith requested review of this revision. Herald added a project: clang. Allow hashing FileEntryRef and DirectoryEntryRef via `hash_value`, and use that to i

[PATCH] D92078: [asan] Default to -asan-use-private-alias=1

2020-12-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 309434. MaskRay marked an inline comment as done. MaskRay added a comment. Improve odr-vtable.cpp Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92078/new/ https://reviews.llvm.org/D92078 Files: clang/test/Co

[PATCH] D87974: [Builtin] Add __builtin_zero_non_value_bits.

2020-12-03 Thread Zoe Carver via Phabricator via cfe-commits
zoecarver added a subscriber: BillyONeal. zoecarver added a comment. So, it looks like GCC already uses `__builtin_clear_padding` and MSVC already uses `__builtin_zero_non_value_bits`. This patch (obviously) is currently implementing `__builtin_zero_non_value_bits ` but, I had planned to update

[PATCH] D90893: Support: Change InMemoryFileSystem::addFileNoOwn to take a MemoryBufferRef, NFC

2020-12-03 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGe763e032f8bb: Support: Change InMemoryFileSystem::addFileNoOwn to take a MemoryBufferRef, NFC (authored by dexonsmith). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository:

[clang] e763e03 - Support: Change InMemoryFileSystem::addFileNoOwn to take a MemoryBufferRef, NFC

2020-12-03 Thread Duncan P. N. Exon Smith via cfe-commits
Author: Duncan P. N. Exon Smith Date: 2020-12-03T18:09:52-08:00 New Revision: e763e032f8bbf5a4da60d099b1df4cd16e44e139 URL: https://github.com/llvm/llvm-project/commit/e763e032f8bbf5a4da60d099b1df4cd16e44e139 DIFF: https://github.com/llvm/llvm-project/commit/e763e032f8bbf5a4da60d099b1df4cd16e44

[PATCH] D92361: [trivial-abi] Support types without a copy or move constructor.

2020-12-03 Thread Zoe Carver via Phabricator via cfe-commits
zoecarver added a comment. @rjmccall Thanks for all that information. You're right; thinking about it in the context of four value operations is helpful. > Hmm. My first instinct is to say that a type that "adds new information" > about its special members — i.e. that explicitly declares its de

[PATCH] D92480: [llvm] Unify interface of (ThreadSafe)?RefCountedBase

2020-12-03 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. I've committed 2e83ccc2ee89110659f3cb313968a0c970d4 which takes parts of this patch - specifically fixing the test that was already intended to test the RefCountedBase's copy constructor, but did

[PATCH] D90275: [clang][IR] Add support for leaf attribute

2020-12-03 Thread Gulfem Savrun Yeniceri via Phabricator via cfe-commits
gulfem marked an inline comment as not done. gulfem added inline comments. Comment at: clang/include/clang/Basic/Attr.td:1435 + let Spellings = [GCC<"leaf">]; + let Subjects = SubjectList<[Function]>; + let Documentation = [Undocumented]; gulfem wrote: > gulfe

[PATCH] D92361: [trivial-abi] Support types without a copy or move constructor.

2020-12-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D92361#2432578 , @ahatanak wrote: > It seems like you are discussing the case where a class/struct annotated with > `trivial_abi` contains a member that isn't destructively movable. In that > case, clang correctly diagnoses i

[PATCH] D92078: [asan] Default to -asan-use-private-alias=1

2020-12-03 Thread Vitaly Buka via Phabricator via cfe-commits
vitalybuka added a comment. alias change is LGTM, we can try to figure-out how to roll out -fsanitize-address-use-odr-indicator Comment at: compiler-rt/test/asan/TestCases/Linux/odr-vtable.cpp:5 +// RUN: %clangxx_asan -fno-rtti -DBUILD_SO1 -fPIC -shared -mllvm -asan-use-priva

[PATCH] D87216: [NewPM] Support --print-before/after in NPM

2020-12-03 Thread Arthur Eubanks via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG2f0de582949d: [NewPM] Support --print-before/after in NPM (authored by aeubanks). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D92600: [ASTImporter] Add support for importing GenericSelectionExpr AST nodes.

2020-12-03 Thread Tom Roeder via Phabricator via cfe-commits
tmroeder updated this revision to Diff 309406. tmroeder added a comment. Renamed context to ToCtx as suggested. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92600/new/ https://reviews.llvm.org/D92600 Files: clang/docs/LibASTMatchersReference.ht

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:3957 + RenderDebugEnablingArgs(Args, CmdArgs, DebugInfoKind, + std::min(DWARFVersion, TC.getMaxDwarfVersion()), DebuggerTuning);

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:3857 + auto AdjustedDwarfVersion = TC.GetAdjustedDwarfVersion(DWARFVersion); + dblaikie wrote: > I worry a bit about having both DWARFVersion and AdjustedDwarfVersion in this > scope

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread Artem Belevich via Phabricator via cfe-commits
tra updated this revision to Diff 309404. tra edited the summary of this revision. tra added a comment. Updated according to Devid's feedback. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92617/new/ https://reviews.llvm.org/D92617 Files: clang/

[PATCH] D92361: [trivial-abi] Support types without a copy or move constructor.

2020-12-03 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. It seems like you are discussing the case where a class/struct annotated with `trivial_abi` contains a member that isn't destructively movable. In that case, clang correctly diagnoses it today. For example, if you remove the attribute from `S2` in the above example and

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/include/clang/Driver/ToolChain.h:495 + // compilation uses DWARF5. + virtual unsigned GetAdjustedDwarfVersion(unsigned v) const { return v; } + Given these semantics (pass/return the version) maybe "AdjustDwarfV

[PATCH] D90888: Frontend: Remove redundant call to CompilerInstance::setFileManager, NFC

2020-12-03 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG99b823c2eba3: Frontend: Remove redundant call to CompilerInstance::setFileManager, NFC (authored by dexonsmith). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST AC

[clang] 99b823c - Frontend: Remove redundant call to CompilerInstance::setFileManager, NFC

2020-12-03 Thread Duncan P. N. Exon Smith via cfe-commits
Author: Duncan P. N. Exon Smith Date: 2020-12-03T16:10:59-08:00 New Revision: 99b823c2eba391877a0fcd6bc5f03f0d9f0077cb URL: https://github.com/llvm/llvm-project/commit/99b823c2eba391877a0fcd6bc5f03f0d9f0077cb DIFF: https://github.com/llvm/llvm-project/commit/99b823c2eba391877a0fcd6bc5f03f0d9f00

[PATCH] D92617: [DWARF] Allow toolchain to adjust specified DWARF version.

2020-12-03 Thread Artem Belevich via Phabricator via cfe-commits
tra created this revision. tra added reviewers: dblaikie, ABataev. Herald added a subscriber: bixia. tra requested review of this revision. Herald added a project: clang. This is needed for CUDA compilation where NVPTX back-end only supports DWARF2, but host compilation should be allowed to use ne

[clang] eccc734 - P0857R0: Parse a requires-clause after an explicit

2020-12-03 Thread Richard Smith via cfe-commits
Author: Richard Smith Date: 2020-12-03T15:54:16-08:00 New Revision: eccc734a69c0c012ae3160887b65a535b35ead3e URL: https://github.com/llvm/llvm-project/commit/eccc734a69c0c012ae3160887b65a535b35ead3e DIFF: https://github.com/llvm/llvm-project/commit/eccc734a69c0c012ae3160887b65a535b35ead3e.diff

[clang] be162f4 - PR45699: Fix crash if an unexpanded parameter pack appears in a

2020-12-03 Thread Richard Smith via cfe-commits
Author: Richard Smith Date: 2020-12-03T15:26:06-08:00 New Revision: be162f4c0e8563c8de510121435281ae628c8654 URL: https://github.com/llvm/llvm-project/commit/be162f4c0e8563c8de510121435281ae628c8654 DIFF: https://github.com/llvm/llvm-project/commit/be162f4c0e8563c8de510121435281ae628c8654.diff

[PATCH] D91944: OpenMP 5.0 metadirective

2020-12-03 Thread Alok Mishra via Phabricator via cfe-commits
alokmishra.besu added inline comments. Comment at: clang/include/clang/Serialization/ASTBitCodes.h:1952 - STMT_MS_DEPENDENT_EXISTS, // MSDependentExistsStmt - EXPR_LAMBDA,// LambdaExpr STMT_COROUTINE_BODY, jdoerfert wrote: > alo

[PATCH] D91944: OpenMP 5.0 metadirective

2020-12-03 Thread Alok Mishra via Phabricator via cfe-commits
alokmishra.besu updated this revision to Diff 309382. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91944/new/ https://reviews.llvm.org/D91944 Files: clang/include/clang-c/Index.h clang/include/clang/AST/RecursiveASTVisitor.h clang/include/cla

[PATCH] D91980: [OpenMP] Add initial support for `omp [begin/end] assumes`

2020-12-03 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert updated this revision to Diff 309381. jdoerfert added a comment. Early exit Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91980/new/ https://reviews.llvm.org/D91980 Files: clang/include/clang/Basic/DiagnosticParseKinds.td clang/inclu

[PATCH] D92130: [HIP] cmath promote long double args to double

2020-12-03 Thread Aaron Enye Shi via Phabricator via cfe-commits
ashi1 added a comment. In D92130#2423801 , @tra wrote: > LGTM in general. Will defer to Sam as it's HIP. > > Nit: > >> long double, promote them to double, and use the fp64 > > I'd say `long double` -> `double` qualifies as a demotion. Thanks, I've change

[PATCH] D92130: [HIP] cmath promote long double args to double

2020-12-03 Thread Aaron Enye Shi via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGba2612ce01ea: [HIP] cmath demote long double args to double (authored by ashi1). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE

[clang] ba2612c - [HIP] cmath demote long double args to double

2020-12-03 Thread Aaron En Ye Shi via cfe-commits
Author: Aaron En Ye Shi Date: 2020-12-03T23:00:14Z New Revision: ba2612ce01eae5859ae7adb99161775fb2c4e0b2 URL: https://github.com/llvm/llvm-project/commit/ba2612ce01eae5859ae7adb99161775fb2c4e0b2 DIFF: https://github.com/llvm/llvm-project/commit/ba2612ce01eae5859ae7adb99161775fb2c4e0b2.diff LO

[PATCH] D91980: [OpenMP] Add initial support for `omp [begin/end] assumes`

2020-12-03 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:3203-3206 + if (!SkippedClauses && Assumptions.empty()) +Diag(Loc, diag::err_omp_no_clause_for_directive) +<< llvm::omp::getAllAssumeClauseOptions() +<< llvm::omp::getOpenMPDirectiveNa

[PATCH] D92606: Clean up debug locations for logical-and/or expressions

2020-12-03 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Probably worth separating these changes/fixes/tests (looks like 3 different changes?) - at least it'd help me understand what each one of the changes does, separately (I'm especially curious about the EmitScalarConversion one and would like to better understand why the

[PATCH] D92606: Clean up debug locations for logical-and/or expressions

2020-12-03 Thread Paul Robinson via Phabricator via cfe-commits
probinson added inline comments. Comment at: clang/lib/CodeGen/CGExprScalar.cpp:4293 + { +// There is no need to emit line number for unconditional branch. +auto NL = ApplyDebugLocation::CreateEmpty(CGF); rnk wrote: > I see this is consistent with LAnd h

[PATCH] D92606: Clean up debug locations for logical-and/or expressions

2020-12-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: clang/lib/CodeGen/CGExprScalar.cpp:4293 + { +// There is no need to emit line number for unconditional branch. +auto NL = ApplyDebugLocation::CreateEmpty(CGF); I see this is consistent with LAnd handling above, but

[PATCH] D91893: [clang-tidy] performance-unnecessary-copy-initialization: Prevent false positives when dependent variable is modified.

2020-12-03 Thread Felix Berger via Phabricator via cfe-commits
flx updated this revision to Diff 309361. flx added a comment. Fixed clang tidy warnings. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91893/new/ https://reviews.llvm.org/D91893 Files: clang-tools-extra/clang-tidy/performance/UnnecessaryCopyIni

[PATCH] D92001: [ubsan] Fix crash on __builtin_assume_aligned

2020-12-03 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri requested changes to this revision. lebedev.ri added a comment. This revision now requires changes to proceed. @orivej please can you look where we create AST nodes for these builtins and ensure that the "pointer" argument is actually converted into a pointer beforehand? I'm afraid i

[PATCH] D92606: Clean up debug locations for logical-and/or expressions

2020-12-03 Thread Paul Robinson via Phabricator via cfe-commits
probinson created this revision. probinson added reviewers: dblaikie, rnk. probinson added a project: debug-info. probinson requested review of this revision. Herald added a project: clang. Attaches a more appropriate debug location to the PHIs used for the short-circuit evaluations, and makes log

[PATCH] D89909: [SYCL] Implement SYCL address space attributes handling

2020-12-03 Thread Alexey Bader via Phabricator via cfe-commits
bader added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:4596 + IRFuncTy->getParamType(FirstIRArg)); +} + bader wrote: > rjmccall wrote: > > This seems problematic; code like this shouldn't be neces

[PATCH] D92600: [ASTImporter] Add support for importing GenericSelectionExpr AST nodes.

2020-12-03 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. `ASTImporter` changes looks good to me. Comment at: clang/lib/AST/ASTImporter.cpp:6525 + + const ASTContext &context = Importer.getToContext(); + if (E->isResultDependent()) { nitpick `context` -> `ToCtx` to be consistent with other co

[PATCH] D89909: [SYCL] Implement SYCL address space attributes handling

2020-12-03 Thread Alexey Bader via Phabricator via cfe-commits
bader updated this revision to Diff 309357. bader added a comment. Apply code review comment from @rjmccall Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89909/new/ https://reviews.llvm.org/D89909 Files: clang/include/clang/AST/Type.h clang/in

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-12-03 Thread Michael Schellenberger Costa via Phabricator via cfe-commits
miscco added a comment. As someone who has extensivly worked with conscepts I cannot stress how much this would improve my live CHANGES SINCE LAST ACTION https://reviews.llvm.org/D79773/new/ https://reviews.llvm.org/D79773 ___ cfe-commits mailing

[PATCH] D91980: [OpenMP] Add initial support for `omp [begin/end] assumes`

2020-12-03 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:3203-3206 + if (!SkippedClauses && Assumptions.empty()) +Diag(Loc, diag::err_omp_no_clause_for_directive) +<< llvm::omp::getAllAssumeClauseOptions() +<< llvm::omp::getOpenMPDirectiveName

[PATCH] D92480: [llvm] Unify interface of (ThreadSafe)?RefCountedBase

2020-12-03 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/lib/ASTMatchers/ASTMatchersInternal.cpp:190-196 +// Use a custom deleter for the TrueMatcherInstance ManagedStatic. This prevents +// an assert firing when the refcount is nonzero while running its destructor. +struct DynMatcherI

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-12-03 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Having reviewed the current status I'm going to leave this patch with just minor changes from where its been for some time, if others feel it has merits in landing as experimental support I'd be happy with that. I would rather build from a base than try and keep

[PATCH] D92597: ARCMigrate: Initialize fields in EditEntry inline, NFC

2020-12-03 Thread Jonas Devlieghere via Phabricator via cfe-commits
JDevlieghere added a comment. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92597/new/ https://reviews.llvm.org/D92597 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-12-03 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 309350. MyDeveloperDay marked an inline comment as done. MyDeveloperDay added a comment. Address the issue with still munching the semi mark as experimental in the release notes CHANGES SINCE LAST ACTION https://reviews.llvm.org/D79773/new/ https:/

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-12-03 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay marked an inline comment as done. MyDeveloperDay added inline comments. Comment at: clang/lib/Format/UnwrappedLineParser.cpp:2314 + nextToken(); + if (FormatTok->Tok.is(tok::less)) { +while (!FormatTok->Tok.is(tok::greater)) { kli

[PATCH] D92602: [objc] diagnose protocol conformance in categories with direct members in their corresponding class interfaces

2020-12-03 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: erik.pilkington, MadCoder. Herald added subscribers: ributzka, jfb, jkorous. arphaman requested review of this revision. Herald added a project: clang. Categories that add protocol conformances to classes with direct members should prohibi

[PATCH] D92600: [ASTImporter] Add support for importing GenericSelectionExpr AST nodes.

2020-12-03 Thread Tom Roeder via Phabricator via cfe-commits
tmroeder updated this revision to Diff 309344. tmroeder edited the summary of this revision. tmroeder added a comment. Fix a typo in the summary. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92600/new/ https://reviews.llvm.org/D92600 Files: cla

[PATCH] D91980: [OpenMP] Add initial support for `omp [begin/end] assumes`

2020-12-03 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added inline comments. Comment at: clang/lib/Sema/SemaLambda.cpp:999-1002 + // OpenMP lambdas might get assumumption attributes. + if (LangOpts.OpenMP) +ActOnFinishedFunctionDefinitionInOpenMPAssumeScope(Method); + ABataev wrote: > Are there any o

[PATCH] D91980: [OpenMP] Add initial support for `omp [begin/end] assumes`

2020-12-03 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert updated this revision to Diff 309340. jdoerfert marked 4 inline comments as done. jdoerfert added a comment. Addressed comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91980/new/ https://reviews.llvm.org/D91980 Files: clang/inclu

[PATCH] D91949: [clang-format] Add BeforeStructInitialization option in BraceWrapping configuration

2020-12-03 Thread Anastasiia Lukianenko via Phabricator via cfe-commits
anastasiia_lukianenko updated this revision to Diff 309336. anastasiia_lukianenko retitled this revision from "[clang-format] Add BreakBeforeStructInitialization configuration" to "[clang-format] Add BeforeStructInitialization option in BraceWrapping configuration". anastasiia_lukianenko added re

[PATCH] D92257: [clang-format] Add option to control the space at the front of a line comment

2020-12-03 Thread Marek Kurdej via Phabricator via cfe-commits
curdeius accepted this revision. curdeius added a comment. LGTM Comment at: clang/lib/Format/Format.cpp:963 LLVMStyle.SpacesInCStyleCastParentheses = false; + LLVMStyle.SpacesInLineComments = {/*Minimum=*/1, /*Maximum=*/-1u}; LLVMStyle.SpaceAfterCStyleCast = false; -

[PATCH] D87216: [NewPM] Support --print-before/after in NPM

2020-12-03 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks updated this revision to Diff 309338. aeubanks added a comment. forward declare class Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87216/new/ https://reviews.llvm.org/D87216 Files: llvm/include/llvm/IR/IRPrintingPasses.h llvm/include

[PATCH] D92600: [ASTImporter] Add support for importing GenericSelectionExpr AST nodes.

2020-12-03 Thread Tom Roeder via Phabricator via cfe-commits
tmroeder created this revision. tmroeder added reviewers: aaron.ballman, klimek. Herald added subscribers: teemperor, martong. Herald added a reviewer: a.sidorin. Herald added a reviewer: shafik. tmroeder requested review of this revision. Herald added a project: clang. This allows ASTs to be merg

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-12-03 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 309335. MyDeveloperDay marked an inline comment as done. MyDeveloperDay added a comment. rebase before making any further changes CHANGES SINCE LAST ACTION https://reviews.llvm.org/D79773/new/ https://reviews.llvm.org/D79773 Files: clang/docs/Cl

[PATCH] D92257: [clang-format] Add option to control the space at the front of a line comment

2020-12-03 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks added inline comments. Comment at: clang/lib/Format/Format.cpp:963 LLVMStyle.SpacesInCStyleCastParentheses = false; + LLVMStyle.SpacesInLineComments = {/*Minimum=*/1, /*Maximum=*/-1u}; LLVMStyle.SpaceAfterCStyleCast = false; curdeius wro

[PATCH] D92257: [clang-format] Add option to control the space at the front of a line comment

2020-12-03 Thread Marek Kurdej via Phabricator via cfe-commits
curdeius added inline comments. Comment at: clang/lib/Format/Format.cpp:963 LLVMStyle.SpacesInCStyleCastParentheses = false; + LLVMStyle.SpacesInLineComments = {/*Minimum=*/1, /*Maximum=*/-1u}; LLVMStyle.SpaceAfterCStyleCast = false; I don't know precisely

[PATCH] D92363: [HIP] Warn no --offload-arch option

2020-12-03 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D92363#2431812 , @yaxunl wrote: > > There are still valid use cases for not providing GPU arch. For example, > users would like to test syntax of a HIP program for which GPU arch does not > matter, or users would like to get P

[PATCH] D92597: ARCMigrate: Initialize fields in EditEntry inline, NFC

2020-12-03 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith created this revision. dexonsmith added reviewers: jansvoboda11, JDevlieghere, akyrtzi. Herald added a subscriber: ributzka. dexonsmith requested review of this revision. Herald added a project: clang. Initialize the fields inline instead of having to manually write out a default constr

[PATCH] D92596: [FPEnv] Correct constrained metadata in fp16-ops-strict.c

2020-12-03 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: sepavloff, mibintc. kpn added a project: clang. kpn requested review of this revision. Herald added a subscriber: cfe-commits. This test shows we're in some cases not getting strictfp information from the AST. Correct that. Repository: rG LLVM G

[PATCH] D92257: [clang-format] Add option to control the space at the front of a line comment

2020-12-03 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. This LGTM, I'm not sure if others have any comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92257/new/ https://reviews.llv

[PATCH] D87216: [NewPM] Support --print-before/after in NPM

2020-12-03 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D87216#2431626 , @aeubanks wrote: > In D87216#2431508 , @ychen wrote: > >> It is very unfortunate that we have to manage and translate between two sets >> of names (one pass name and one t

[PATCH] D92579: [clangd] AddUsing: Fix a crash on ElaboratedTypes without NestedNameSpecfiiers.

2020-12-03 Thread Adam Czachorowski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc282b7de5a5d: [clangd] AddUsing: Fix a crash on ElaboratedTypes without NestedNameSpecfiiers. (authored by adamcz). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.

[clang-tools-extra] c282b7d - [clangd] AddUsing: Fix a crash on ElaboratedTypes without NestedNameSpecfiiers.

2020-12-03 Thread Adam Czachorowski via cfe-commits
Author: Adam Czachorowski Date: 2020-12-03T20:25:38+01:00 New Revision: c282b7de5a5de8151a19228702867e2299f1d3fe URL: https://github.com/llvm/llvm-project/commit/c282b7de5a5de8151a19228702867e2299f1d3fe DIFF: https://github.com/llvm/llvm-project/commit/c282b7de5a5de8151a19228702867e2299f1d3fe.d

[PATCH] D92363: [HIP] Warn no --offload-arch option

2020-12-03 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In D92363#2426401 , @tra wrote: > While I agree that the default GPU choice is not likely to be correct, or > usable, for everyone, but the warning seems to be a half-measure. > If the default is not usable, then it should not be t

[PATCH] D92480: [llvm] Unify interface of (ThreadSafe)?RefCountedBase

2020-12-03 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: llvm/include/llvm/ADT/IntrusiveRefCntPtr.h:75-76 RefCountedBase() = default; + // Copy and move constructors/assignments are no-ops as the RefCount isn't + // dictated by the class directly. RefCountedBase(const RefCountedBase

[PATCH] D92570: [clang] [Headers] Use the corresponding _aligned_free or __mingw_aligned_free in _mm_free

2020-12-03 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added inline comments. Comment at: clang/lib/Headers/mm_malloc.h:42 void *__mallocedMemory; #if defined(__MINGW32__) __mallocedMemory = __mingw_aligned_malloc(__size, __align); rnk wrote: > This has been here since 2011, and somehow nobody complai

[PATCH] D90173: [PowerPC] Exploit splat instruction xxsplti32dx in Power10

2020-12-03 Thread Albion Fung via Phabricator via cfe-commits
Conanap added a comment. addressed a comment Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:9366 +SplatNode = DAG.getNode( +PPCISD::XXSPLTI32DX, SDLoc(SplatNode), MVT::v2i64, SplatNode, +DAG.getTargetConstant(isLE ? 1 : 0, SplatNode, MVT

[PATCH] D92231: [OpenCL] Implement extended subgroups fully in headers

2020-12-03 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added a comment. In D92231#2425323 , @Anastasia wrote: > In D92231#2425305 , @PiotrFusik > wrote: > >> The specification for these extensions was edited by Ben Ashbaugh @Intel. >> I've asked him about th

[PATCH] D87216: [NewPM] Support --print-before/after in NPM

2020-12-03 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. In D87216#2431508 , @ychen wrote: > It is very unfortunate that we have to manage and translate between two sets > of names (one pass name and one type name). This makes me wonder if we just > keep the pass name as the return va

[PATCH] D92209: [ASTImporter] Support CXXDeductionGuideDecl with local typedef

2020-12-03 Thread Gabor Marton via Phabricator via cfe-commits
martong marked an inline comment as done. martong added a comment. > I was thinking about to create a separate ASTImporter implementation > specifically for CTU and LLDB could have it's own implementation. For that we > just need to create an interface class with virtual functions. One implemen

[PATCH] D92427: [OPENMP51] Add present modifier in defaultmap clause

2020-12-03 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:3490 +OMPC_MAP_MODIFIER_present); +ImplicitMapModifierLoc[ClauseKind].push_back(SourceLocation()); + } cchen wrote: > ABataev wrote: > > Why need to add

[PATCH] D91944: OpenMP 5.0 metadirective

2020-12-03 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added inline comments. Comment at: clang/include/clang/Serialization/ASTBitCodes.h:1952 - STMT_MS_DEPENDENT_EXISTS, // MSDependentExistsStmt - EXPR_LAMBDA,// LambdaExpr STMT_COROUTINE_BODY, alokmishra.besu wrote: > jdo

[PATCH] D91944: OpenMP 5.0 metadirective

2020-12-03 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/include/clang/AST/StmtOpenMP.h:373 +/// +class OMPMetaDirective final : public OMPExecutableDirective { + friend class ASTStmtReader; alokmishra.besu wrote: > ABataev wrote: > > I think, metadirective should be a

[PATCH] D87216: [NewPM] Support --print-before/after in NPM

2020-12-03 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen accepted this revision. ychen added a comment. It is very unfortunate that we have to manage and translate between two sets of names (one pass name and one type name). This makes me wonder if we just keep the pass name as the return value of PassInfoMixin::name and get rid of class name e

[PATCH] D92427: [OPENMP51] Add present modifier in defaultmap clause

2020-12-03 Thread Chi Chun Chen via Phabricator via cfe-commits
cchen updated this revision to Diff 309292. cchen added a comment. Update based on comment Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92427/new/ https://reviews.llvm.org/D92427 Files: clang/include/clang/Basic/OpenMPKinds.def clang/lib/Sema

[PATCH] D91944: OpenMP 5.0 metadirective

2020-12-03 Thread Alok Mishra via Phabricator via cfe-commits
alokmishra.besu added inline comments. Comment at: clang/include/clang/AST/StmtOpenMP.h:373 +/// +class OMPMetaDirective final : public OMPExecutableDirective { + friend class ASTStmtReader; ABataev wrote: > I think, metadirective should be a kind of a container

[PATCH] D91885: [clang-tidy] Add support for diagnostics with no location

2020-12-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/clang-tidy/ClangTidyCheck.h:183 + + /// Adds a diagnostic to report errors in the checks configuration. + DiagnosticBuilder checks -> check's Comment at: clang-tools-extra/cla

[PATCH] D92570: [clang] [Headers] Use the corresponding _aligned_free or __mingw_aligned_free in _mm_free

2020-12-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. lgtm Comment at: clang/lib/Headers/mm_malloc.h:42 void *__mallocedMemory; #if defined(__MINGW32__) __mallocedMemory = __mingw_aligned_malloc(__size, __align); --

[PATCH] D92024: [clang] Implement P0692R1 from C++20 (access checking on specializations and instantiations)

2020-12-03 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added a comment. The subject line says "access checking on specializations and instantiations," but I don't see any tests for explicit instantiations here — just specializations. In particular, I'm very interested to know if P0692 is intended to have any effect on the legality of ht

[PATCH] D92495: [clang] Add a new nullability annotation for swift async: _Nullable_result

2020-12-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/AttrDocs.td:3516 +``_Nullable_result`` pointer can be ``nil``, just like ``_Nullable``. Where this +attribute differs from ``_Nullable`` is when its used on a parameter to a +completion handler in a Swift

[PATCH] D92209: [ASTImporter] Support CXXDeductionGuideDecl with local typedef

2020-12-03 Thread Gabor Marton via Phabricator via cfe-commits
martong marked an inline comment as done. martong added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:2522 + // Add to the lookupTable because we could not do that in MapImported. + Importer.AddToLookupTable(ToTypedef); + shafik wrote: > I am not s

  1   2   >