[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-07-25 Thread Jonathon Penix via Phabricator via cfe-commits
jpenix-quic added inline comments. Comment at: clang/include/clang/Driver/Options.td:4897 def ffixed_line_length_VALUE : Joined<["-"], "ffixed-line-length-">, Group, Alias; +def fconvert_EQ : Joined<["-"], "fconvert=">, Group, + HelpText<"Set endian conversion of data for

[clang] 620ca75 - fix comment typo to cycle bots

2022-07-25 Thread Nico Weber via cfe-commits
Author: Nico Weber Date: 2022-07-26T01:55:10-04:00 New Revision: 620ca754e3f769f2be4668feccee84071d785be3 URL: https://github.com/llvm/llvm-project/commit/620ca754e3f769f2be4668feccee84071d785be3 DIFF: https://github.com/llvm/llvm-project/commit/620ca754e3f769f2be4668feccee84071d785be3.diff

[PATCH] D130545: [cmake] Slight fix ups to make robust to the full range of GNUInstallDirs

2022-07-25 Thread John Ericson via Phabricator via cfe-commits
Ericson2314 updated this revision to Diff 447569. Ericson2314 added a comment. Herald added a reviewer: jdoerfert. Herald added subscribers: llvm-commits, sstefan1. Herald added a project: LLVM. Add another fix Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D119792: [Clang] [P2025] Analyze only potential scopes for NRVO

2022-07-25 Thread Roman Rusyaev via Phabricator via cfe-commits
rusyaev-roman added inline comments. Comment at: clang/lib/Sema/Scope.cpp:152-154 + // Consider the variable as NRVO candidate if the return slot is available + // for it in the current scope, or if it can be available in outer scopes. + NRVO = CanBePutInReturnSlot ? VD :

[PATCH] D129160: libclang.so: Make SONAME the same as LLVM version

2022-07-25 Thread Tom Stellard via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbc39d7bdd497: libclang.so: Make SONAME the same as LLVM version (authored by tstellar). Changed prior to commit: https://reviews.llvm.org/D129160?vs=444843=447566#toc Repository: rG LLVM Github

[clang] bc39d7b - libclang.so: Make SONAME the same as LLVM version

2022-07-25 Thread Tom Stellard via cfe-commits
Author: Tom Stellard Date: 2022-07-25T22:03:34-07:00 New Revision: bc39d7bdd4977a953b2e102f8f7eb479ad78984e URL: https://github.com/llvm/llvm-project/commit/bc39d7bdd4977a953b2e102f8f7eb479ad78984e DIFF: https://github.com/llvm/llvm-project/commit/bc39d7bdd4977a953b2e102f8f7eb479ad78984e.diff

[PATCH] D129160: libclang.so: Make SONAME the same as LLVM version

2022-07-25 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added a comment. In D129160#3678441 , @h-vetinari wrote: > In D129160#3678431 , @tstellar > wrote: > >> @h-vetinari Does the release note look OK? > > Basically yes, thank you! I'd still be more

[PATCH] D129160: libclang.so: Make SONAME the same as LLVM version

2022-07-25 Thread H. Vetinari via Phabricator via cfe-commits
h-vetinari added a comment. In D129160#3678431 , @tstellar wrote: > @h-vetinari Does the release note look OK? Basically yes, thank you! I'd still be more precise and say "soversion" rather than "soname", but otherwise OK. Repository: rG LLVM

[PATCH] D129160: libclang.so: Make SONAME the same as LLVM version

2022-07-25 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added a comment. @h-vetinari Does the release note look OK? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129160/new/ https://reviews.llvm.org/D129160 ___ cfe-commits mailing list

[PATCH] D130420: [CodeGen] Consider MangleCtx when move lazy emission States

2022-07-25 Thread Jun Zhang 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 rG58c94808450d: [CodeGen] Consider MangleCtx when move lazy emission States (authored by junaire). Repository: rG LLVM Github Monorepo CHANGES

[clang] 58c9480 - [CodeGen] Consider MangleCtx when move lazy emission States

2022-07-25 Thread Jun Zhang via cfe-commits
Author: Jun Zhang Date: 2022-07-26T12:34:03+08:00 New Revision: 58c94808450d0ec73bed38d1661314c1a3d56e2f URL: https://github.com/llvm/llvm-project/commit/58c94808450d0ec73bed38d1661314c1a3d56e2f DIFF: https://github.com/llvm/llvm-project/commit/58c94808450d0ec73bed38d1661314c1a3d56e2f.diff

[PATCH] D130545: [cmake] Slight fix ups to make robust to the full range of GNUInstallDirs

2022-07-25 Thread John Ericson via Phabricator via cfe-commits
Ericson2314 created this revision. Ericson2314 added reviewers: sebastian-ne, beanz, phosek, sterni, lebedev.ri. Herald added a subscriber: mgorny. Herald added a project: All. Ericson2314 requested review of this revision. Herald added projects: clang, OpenMP. Herald added subscribers:

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, jyu2

[PATCH] D101070: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs

2022-07-25 Thread John Ericson 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 rG7f9e6f6fa654: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs (authored by Ericson2314). Repository: rG LLVM Github

[PATCH] D129824: [RISCV] Set triple based on -march flag which can be deduced in more generic way

2022-07-25 Thread Jessica Clarke via Phabricator via cfe-commits
jrtc27 added a comment. If you still want to pursue this, discussion belongs at https://github.com/riscv-non-isa/riscv-toolchain-conventions, not here, since it's an interface shared by Clang and GCC and the two should be consistent CHANGES SINCE LAST ACTION

[PATCH] D119792: [Clang] [P2025] Analyze only potential scopes for NRVO

2022-07-25 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added inline comments. Comment at: clang/lib/Sema/Scope.cpp:152-154 + // Consider the variable as NRVO candidate if the return slot is available + // for it in the current scope, or if it can be available in outer scopes. + NRVO = CanBePutInReturnSlot ? VD :

[PATCH] D129824: [RISCV] Set triple based on -march flag which can be deduced in more generic way

2022-07-25 Thread Zixuan Wu via Phabricator via cfe-commits
zixuan-wu added a comment. In D129824#3670586 , @reames wrote: > This was very briefly discussed at today's sync up call. We were running > short on time, so we didn't get a chance to talk through it, but there did > seem to be a consensus that

[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-07-25 Thread Peixin Qiao via Phabricator via cfe-commits
peixin added inline comments. Comment at: clang/include/clang/Driver/Options.td:4897 def ffixed_line_length_VALUE : Joined<["-"], "ffixed-line-length-">, Group, Alias; +def fconvert_EQ : Joined<["-"], "fconvert=">, Group, + HelpText<"Set endian conversion of data for

[PATCH] D129873: [clang-offload-bundler] Library-ize ClangOffloadBundler

2022-07-25 Thread Jacob Lambert via Phabricator via cfe-commits
lamb-j updated this revision to Diff 447531. lamb-j added a comment. Removing trailing whitespace Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129873/new/ https://reviews.llvm.org/D129873 Files: clang/include/clang/Driver/OffloadBundler.h

[PATCH] D130255: [Clang][LoongArch] Add initial LoongArch target and driver support

2022-07-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/lib/Driver/ToolChains/Gnu.cpp:2226 + static const char *const LoongArch64LibDirs[] = {"/lib64", "/lib"}; + static const char *const LoongArch64Triples[] = { xry111 wrote: > SixWeining wrote: > > xry111 wrote:

[PATCH] D130531: [IR] Use Min behavior for module flag "PIC Level"

2022-07-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. MaskRay added reviewers: davide, tejohnson. Herald added subscribers: StephenFan, okura, kuter, hiraditya. Herald added a project: All. MaskRay requested review of this revision. Herald added a reviewer: jdoerfert. Herald added a reviewer: sstefan1. Herald added

[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-07-25 Thread Jonathon Penix via Phabricator via cfe-commits
jpenix-quic added a comment. Thank you for taking a look at this and thank you for the feedback! I'm not sure if I am entirely following/I think I am confusing myself on some of the specifics. My understanding of your suggestion is that, rather than add and create a call to a fconvert-specific

[PATCH] D128142: [MemProf] Memprof profile matching and annotation

2022-07-25 Thread Snehasish Kumar via Phabricator via cfe-commits
snehasish added inline comments. Herald added a subscriber: mingmingl. Comment at: llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp:1249 +void addCallStack(CallStackTrie , const AllocationInfo *AllocInfo) { + auto AllocType =

[PATCH] D130301: [Clang] Fix how we set the NumPositiveBits on an EnumDecl to cover the case of single enumerator with value zero or an empty enum

2022-07-25 Thread Shafik Yaghmour 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 rGaea82d455113: [Clang] Fix how we set the NumPositiveBits on an EnumDecl to cover the case of… (authored by shafik). Herald added projects: clang,

[clang] aea82d4 - [Clang] Fix how we set the NumPositiveBits on an EnumDecl to cover the case of single enumerator with value zero or an empty enum

2022-07-25 Thread Shafik Yaghmour via cfe-commits
Author: Shafik Yaghmour Date: 2022-07-25T16:01:01-07:00 New Revision: aea82d4551139ded0290afab739f0b367d055628 URL: https://github.com/llvm/llvm-project/commit/aea82d4551139ded0290afab739f0b367d055628 DIFF:

[PATCH] D130411: [clang-format] Fix a hang when formatting C# $@ string literals

2022-07-25 Thread Owen Pan via Phabricator via cfe-commits
owenpan added inline comments. Comment at: clang/lib/Format/FormatTokenLexer.cpp:536 + // $"{x ?? "null"}" + // should not be split into $"{x ?? ", null, "}" but should treated as a + // single string-literal. curdeius wrote: > I left the original comments

[PATCH] D130301: [Clang] Fix how we set the NumPositiveBits on an EnumDecl to cover the case of single enumerator with value zero or an empty enum

2022-07-25 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added inline comments. Comment at: compiler-rt/test/ubsan/TestCases/Misc/enum.cpp:27 + return ((int)e1 != -1) & ((int)e2 != -1) & + // CHECK: error: load of value , which is not a valid value for type 'enum EBool' + ((int)e3 != -1) & ((int)e4 == 1) &

[PATCH] D130301: [Clang] Fix how we set the NumPositiveBits on an E numDecl to cover the case of single enumerator with value zero or an empty enum

2022-07-25 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik updated this revision to Diff 447500. shafik marked 5 inline comments as done. shafik added a comment. - Adding release note - Fixing comments - Removing top level const on local variable - Adjusting test so checks go after the line they are checking CHANGES SINCE LAST ACTION

[PATCH] D130526: [Driver][PowerPC] Support -mtune=

2022-07-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. MaskRay added reviewers: PowerPC, nemanjai, jsji. Herald added subscribers: luke957, StephenFan, s.egerton, shchenz, simoncook, kbarton. Herald added a project: All. MaskRay requested review of this revision. Herald added a project: clang. Herald added a subscriber:

[PATCH] D124063: [LegacyPM] Rename and deprecate populateModulePassManager

2022-07-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. So nobody has managed to fix all the in-tree usage. I think having this for the upcoming release/15.x will be nice... Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124063/new/ https://reviews.llvm.org/D124063

[PATCH] D130519: [clang][dataflow] Add explicit "AST" nodes for implications and iff

2022-07-25 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/WatchedLiteralsSolver.cpp:332 + + if (LeftSubVar == RightSubVar) { +// `X <=> (A <=> A)` is equvalent to `X` which is already in gribozavr2 wrote: > xazax.hun wrote: > >

[PATCH] D130516: [Support] compression classes

2022-07-25 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/lib/Serialization/ASTWriter.cpp:2003-2004 // consumers will not want its contents. + llvm::compression::CompressionAlgorithm CompressionScheme = + llvm::compression::ZlibCompressionAlgorithm(); +

[PATCH] D130519: [clang][dataflow] Add explicit "AST" nodes for implications and iff

2022-07-25 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/WatchedLiteralsSolver.cpp:332 + + if (LeftSubVar == RightSubVar) { +// `X <=> (A <=> A)` is equvalent to `X` which is already in xazax.hun wrote: > xazax.hun wrote: > > I

[PATCH] D123319: Change how we handle auto return types for lambda operator() to be consistent with gcc

2022-07-25 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D123319/new/ https://reviews.llvm.org/D123319 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D119051: Extend the C++03 definition of POD to include defaulted functions

2022-07-25 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119051/new/ https://reviews.llvm.org/D119051 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D130055: Clang extensions yolo, woot & kaboom

2022-07-25 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Any chance this could be a generalization of https://clang.llvm.org/doxygen/Consumed_8cpp_source.html ? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130055/new/ https://reviews.llvm.org/D130055

[PATCH] D130519: [clang][dataflow] Add explicit "AST" nodes for implications and iff

2022-07-25 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/WatchedLiteralsSolver.cpp:332 + + if (LeftSubVar == RightSubVar) { +// `X <=> (A <=> A)` is equvalent to `X` which is already in xazax.hun wrote: > I wonder why this

[PATCH] D130519: [clang][dataflow] Add explicit "AST" nodes for implications and iff

2022-07-25 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/WatchedLiteralsSolver.cpp:332 + + if (LeftSubVar == RightSubVar) { +// `X <=> (A <=> A)` is equvalent to `X` which is already in I wonder why this simplification is done

[clang] 1d23f6c - [Driver] Ignore unimplemented -mtune= for ARM/PowerPC

2022-07-25 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2022-07-25T15:05:38-07:00 New Revision: 1d23f6c5a4f6ebb101c282f8f506588fe4d9e92f URL: https://github.com/llvm/llvm-project/commit/1d23f6c5a4f6ebb101c282f8f506588fe4d9e92f DIFF: https://github.com/llvm/llvm-project/commit/1d23f6c5a4f6ebb101c282f8f506588fe4d9e92f.diff

[PATCH] D130523: [pseudo] Perform unconstrained recovery prior to completion.

2022-07-25 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Apart from this patch, the main other things we need to allow missing brackets to be inferred: - allow recovery to trigger subsequent recovery, even at EOF. (Simplest way is to address the FIXME at 660, it's pretty involved) - allow opaque nodes to represent

[PATCH] D130516: [Support] compression classes

2022-07-25 Thread Cole Kissane via Phabricator via cfe-commits
ckissane added inline comments. Comment at: clang/lib/Serialization/ASTWriter.cpp:2003-2004 // consumers will not want its contents. + llvm::compression::CompressionAlgorithm CompressionScheme = + llvm::compression::ZlibCompressionAlgorithm(); +

[PATCH] D130523: [pseudo] Perform unconstrained recovery prior to completion.

2022-07-25 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 447487. sammccall added a comment. restore removed debug Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130523/new/ https://reviews.llvm.org/D130523 Files:

[PATCH] D130523: [pseudo] Perform unconstrained recovery prior to completion.

2022-07-25 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: hokein. Herald added a project: All. sammccall requested review of this revision. Herald added subscribers: cfe-commits, alextsao1999. Herald added a project: clang-tools-extra. Our GLR uses lookahead: only perform reductions that might

[PATCH] D130519: [clang][dataflow] Add explicit "AST" nodes for implications and iff

2022-07-25 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr updated this revision to Diff 447484. gribozavr added a comment. Normalized more comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130519/new/ https://reviews.llvm.org/D130519 Files:

[PATCH] D130522: [clang][dataflow] Fix SAT solver crashes on `X ^ X` and `X v X`

2022-07-25 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr created this revision. Herald added subscribers: martong, tschuett, xazax.hun. Herald added a reviewer: NoQ. Herald added a project: All. gribozavr requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. BooleanFormula::addClause has an

[PATCH] D130516: [Support] compression classes

2022-07-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. Thanks for experimenting the refactoring. My gut feeling is that - for inheritance `llvm/lib/Support/Compression.cpp` introduces quite a bit of complexity. - BestSpeedCompression/DefaultCompression/BestSizeCompression may be kinda weird. Not all algorithms may need all

[PATCH] D119296: KCFI sanitizer

2022-07-25 Thread Sami Tolvanen via Phabricator via cfe-commits
samitolvanen added a comment. In D119296#3673297 , @MaskRay wrote: > It seems that we can miss the branch to have more time mature the feature and > have it for 16.0. Sure, that sounds reasonable. Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D130516: [Support] compression classes

2022-07-25 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/lib/Serialization/ASTWriter.cpp:2003-2004 // consumers will not want its contents. + llvm::compression::CompressionAlgorithm CompressionScheme = + llvm::compression::ZlibCompressionAlgorithm(); + Doesn't

[PATCH] D130519: [clang][dataflow] Add explicit "AST" nodes for implications and iff

2022-07-25 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr created this revision. Herald added subscribers: martong, tschuett, xazax.hun. Herald added a reviewer: NoQ. Herald added a project: All. gribozavr requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Previously we used to desugar

[PATCH] D130516: [Support] compression classes

2022-07-25 Thread Cole Kissane via Phabricator via cfe-commits
ckissane updated this revision to Diff 447469. ckissane added a comment. - format - merge fix Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130516/new/ https://reviews.llvm.org/D130516 Files: clang-tools-extra/clangd/index/Serialization.cpp

[PATCH] D130516: [Support] compression classes

2022-07-25 Thread Cole Kissane via Phabricator via cfe-commits
ckissane created this revision. ckissane added a reviewer: dblaikie. Herald added subscribers: wenlei, usaxena95, kadircet, arphaman, hiraditya, arichardson, emaste. Herald added a reviewer: alexander-shaposhnikov. Herald added a reviewer: rupprecht. Herald added a reviewer: jhenderson. Herald

[PATCH] D101070: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs

2022-07-25 Thread John Ericson via Phabricator via cfe-commits
Ericson2314 updated this revision to Diff 447465. Ericson2314 added a comment. Avoid extend_path Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101070/new/ https://reviews.llvm.org/D101070 Files: llvm/cmake/modules/AddLLVM.cmake

[PATCH] D101070: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs

2022-07-25 Thread John Ericson 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 rG5acd376438a5: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs (authored by Ericson2314). Repository: rG LLVM Github

[PATCH] D129884: [clang][deps] Include canonical invocation in ContextHash

2022-07-25 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Would it make sense for this to replace the existing strict context hash implementation? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129884/new/ https://reviews.llvm.org/D129884

[PATCH] D117973: [cmake] Support custom package install paths

2022-07-25 Thread John Ericson via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Ericson2314 marked 2 inline comments as done. Closed by commit rGac0d1d5c7b7e: [cmake] Support custom package install paths (authored by Ericson2314). Repository:

[PATCH] D119792: [Clang] [P2025] Analyze only potential scopes for NRVO

2022-07-25 Thread Roman Rusyaev via Phabricator via cfe-commits
rusyaev-roman added a comment. @ChuanqiXu , I've added additional comments. Could you check again please? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119792/new/ https://reviews.llvm.org/D119792 ___

[PATCH] D130511: [pseudo][wip] Eliminate simple-type-specifier ambiguities.

2022-07-25 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. My main concern here is that this might reject valid code (and if it doesn't, it's not obvious why). It does look like C++ forbids the cases I can come up with (e.g. trying to provide a definition for `::Foo` is rejected by clang with "definition or redeclaration of

[PATCH] D119792: [Clang] [P2025] Analyze only potential scopes for NRVO

2022-07-25 Thread Roman Rusyaev via Phabricator via cfe-commits
rusyaev-roman added inline comments. Comment at: clang/include/clang/Sema/Scope.h:213-215 + /// A single NRVO candidate variable in this scope, or nullptr if the + /// candidate is not available/allowed in this scope. + Optional NRVO; ChuanqiXu wrote: > Now

[PATCH] D130510: Missing tautological compare warnings due to unary operators

2022-07-25 Thread Muhammad Usman Shahid via Phabricator via cfe-commits
Codesbyusman updated this revision to Diff 447453. Codesbyusman added a comment. also updating for the Xor bitwise operator Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130510/new/ https://reviews.llvm.org/D130510 Files:

[PATCH] D130095: [clangd] Improve XRefs support for ObjCMethodDecl

2022-07-25 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet accepted this revision. kadircet added a comment. This revision is now accepted and ready to land. thanks, lgtm! Comment at: clang-tools-extra/clangd/XRefs.cpp:89 + return MD; +auto *DeclCtx = cast(MD->getDeclContext()); +if (DeclCtx->isInvalidDecl())

[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-07-25 Thread Peter Klausler via Phabricator via cfe-commits
klausler added inline comments. Comment at: flang/runtime/main.cpp:51 + if (Fortran::runtime::executionEnvironment.conversion != + Fortran::runtime::Convert::Unknown) +return; We always use braces on if/for/while/ constructs in the runtime.

[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-07-25 Thread Peter Klausler via Phabricator via cfe-commits
klausler added a comment. Instead of adding new custom APIs that let command-line options control behavior is a way that is redundant with the runtime environment, I suggest that you try a more general runtime library API by which the main program can specify a default environment variable

[PATCH] D129973: [clang] Pass FoundDecl to DeclRefExpr creator for operator overloads

2022-07-25 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. In D129973#3673094 , @SimplyDanny wrote: > Thank you for the review! Before I push the change into main I may add an > entry to `clang/docs/ReleaseNotes.rst`, right? Yes, please add an entry in the release notes. > And do you

[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-07-25 Thread Jonathon Penix via Phabricator via cfe-commits
jpenix-quic added a comment. I do have a few related lingering questions as well: 1. While this implementation mimics gfortran's behavior, there are still differences with other compilers (please see the comment here: https://github.com/llvm/llvm-project/issues/55961#issuecomment-1175677659).

[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

2022-07-25 Thread Jonathon Penix via Phabricator via cfe-commits
jpenix-quic created this revision. jpenix-quic added reviewers: schweitz, klausler, peixin, awarzynski. jpenix-quic added a project: Flang. Herald added subscribers: mehdi_amini, jdoerfert, mgorny. Herald added a reviewer: sscalpone. Herald added a project: All. jpenix-quic requested review of

[PATCH] D130224: [Clang][Attribute] Introduce maybe_undef attribute for function arguments which accepts undef values

2022-07-25 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. In D130224#3677224 , @aaron.ballman wrote: > However, what I think I'm hearing from this thread is that there are > alternative approaches that have been thought about but not tried, we're not > certain how feasible those

[PATCH] D130511: [pseudo][wip] Eliminate simple-type-specifier ambiguities.

2022-07-25 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: sammccall. Herald added a project: All. hokein requested review of this revision. Herald added a subscriber: alextsao1999. Herald added a project: clang-tools-extra. The solution is to favor the longest possible nest-name-specifier, and drop

[PATCH] D129973: [clang] Pass FoundDecl to DeclRefExpr creator for operator overloads

2022-07-25 Thread Danny Mösch via Phabricator via cfe-commits
SimplyDanny added a comment. In D129973#3673094 , @SimplyDanny wrote: > Thank you for the review! Before I push the change into main I may add an > entry to `clang/docs/ReleaseNotes.rst`, right? > > And do you agree that the test failures are unrelated

[PATCH] D130301: [Clang] Fix how we set the NumPositiveBits on an E numDecl to cover the case of single enumerator with value zero or an empty enum

2022-07-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM (aside from some small nits that you can fix when landing). Comment at: compiler-rt/test/ubsan/TestCases/Misc/enum.cpp:27 + return ((int)e1 != -1) &

[PATCH] D101070: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs

2022-07-25 Thread Sebastian Neubauer via Phabricator via cfe-commits
sebastian-ne accepted this revision. sebastian-ne added a comment. This revision is now accepted and ready to land. No problem, thanks for the fixes! LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101070/new/ https://reviews.llvm.org/D101070

[PATCH] D130224: [Clang][Attribute] Introduce maybe_undef attribute for function arguments which accepts undef values

2022-07-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D130224#3677144 , @arsenm wrote: > In D130224#3668243 , @aaron.ballman > wrote: > >> I'm still not seeing the issue fully. My understanding of the situation >> (which may be

[PATCH] D130510: Missing tautological compare warnings due to unary operators

2022-07-25 Thread Muhammad Usman Shahid via Phabricator via cfe-commits
Codesbyusman updated this revision to Diff 447440. Codesbyusman edited the summary of this revision. Codesbyusman added a comment. updating to more efficient Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130510/new/

[PATCH] D130510: updating the function for the tautological warnings for the unary operators

2022-07-25 Thread Muhammad Usman Shahid via Phabricator via cfe-commits
Codesbyusman created this revision. Codesbyusman added reviewers: aaron.ballman, erichkeane, xgupta. Herald added a reviewer: NoQ. Herald added a project: All. Codesbyusman requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG

[PATCH] D130224: [Clang][Attribute] Introduce maybe_undef attribute for function arguments which accepts undef values

2022-07-25 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. > I'm still not seeing the issue fully. My understanding of the situation > (which may be wrong) is that Clang lowers to LLVM IR and adds noundef > markings at call sites that this patch attempts to let the user then undo. > However, why can Clang's CodeGen not

[PATCH] D130374: [Passes] add a tail-call-elim pass near the end of the opt pipeline

2022-07-25 Thread Sanjay Patel 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 rGbfb9b8e075ee: [Passes] add a tail-call-elim pass near the end of the opt pipeline (authored by spatel). Herald added subscribers: cfe-commits,

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, ABataev

[PATCH] D130224: [Clang][Attribute] Introduce maybe_undef attribute for function arguments which accepts undef values

2022-07-25 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. In D130224#3668243 , @aaron.ballman wrote: > I'm still not seeing the issue fully. My understanding of the situation > (which may be wrong) is that Clang lowers to LLVM IR and adds `noundef` > markings at call sites that this

[PATCH] D130493: Disable stack-sizes section by default for PS4.

2022-07-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:5883 if (Args.hasFlag(options::OPT_fstack_size_section, - options::OPT_fno_stack_size_section, RawTriple.isPS4())) + options::OPT_fno_stack_size_section,

[PATCH] D130301: [Clang] Fix how we set the NumPositiveBits on an E numDecl to cover the case of single enumerator with value zero or an empty enum

2022-07-25 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added inline comments. Comment at: compiler-rt/test/ubsan/TestCases/Misc/enum.cpp:27 + return ((int)e1 != -1) & ((int)e2 != -1) & + // CHECK: error: load of value , which is not a valid value for type 'enum EBool' + ((int)e3 != -1) & ((int)e4 == 1) &

[PATCH] D128619: [Clang] Implement P0848 (Conditionally Trivial Special Member Functions)

2022-07-25 Thread Roy Jacobson via Phabricator via cfe-commits
royjacobson added a comment. @erichkeane @cor3ntin If you have time for review right now, I think it's reasonably ready and I would still like to merge it this week so it can land in Clang15. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D128619: [Clang] Implement P0848 (Conditionally Trivial Special Member Functions)

2022-07-25 Thread Roy Jacobson via Phabricator via cfe-commits
royjacobson updated this revision to Diff 447425. royjacobson marked an inline comment as done. royjacobson added a comment. Rebase on main and slightly update docs. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128619/new/

[PATCH] D130224: [Clang][Attribute] Introduce maybe_undef attribute for function arguments which accepts undef values

2022-07-25 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D130224#3668267 , @arsenm wrote: > In D130224#3668243 , @aaron.ballman > wrote: > >> In D130224#3668240 , @arsenm wrote: >> >>> In

[PATCH] D130420: [CodeGen] Consider MangleCtx when move lazy emission States

2022-07-25 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. I think this seems reasonable. I suspect we'll need to do more plumbing here if we need to support snapshotting / resetting to a snapshot, but this probably isn't the only place, and the

[PATCH] D130423: [clang][dataflow] Rename iterators from IT to It

2022-07-25 Thread Dmitri Gribenko 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 rGc0c9d717dfd2: [clang][dataflow] Rename iterators from IT to It (authored by gribozavr). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[clang] c0c9d71 - [clang][dataflow] Rename iterators from IT to It

2022-07-25 Thread Dmitri Gribenko via cfe-commits
Author: Dmitri Gribenko Date: 2022-07-25T20:28:47+02:00 New Revision: c0c9d717dfd2cbb4d940ce23d20698b4b8f6 URL: https://github.com/llvm/llvm-project/commit/c0c9d717dfd2cbb4d940ce23d20698b4b8f6 DIFF:

[clang] 29d35ec - [clang][dataflow] Fix MapLattice::insert() to not drop return value

2022-07-25 Thread Eric Li via cfe-commits
Author: Eric Li Date: 2022-07-25T14:24:33-04:00 New Revision: 29d35ece8249f2d8a51437a5c008e6bf63da9874 URL: https://github.com/llvm/llvm-project/commit/29d35ece8249f2d8a51437a5c008e6bf63da9874 DIFF: https://github.com/llvm/llvm-project/commit/29d35ece8249f2d8a51437a5c008e6bf63da9874.diff LOG:

[PATCH] D130497: [clang][dataflow] Fix MapLattice::insert() to not drop return value

2022-07-25 Thread Eric Li 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 rG29d35ece8249: [clang][dataflow] Fix MapLattice::insert() to not drop return value (authored by li.zhe.hua). Repository: rG LLVM Github Monorepo

[PATCH] D121997: [clang][driver] Fix compilation database dump with multiple architectures

2022-07-25 Thread Alan Phipps via Phabricator via cfe-commits
alanphipps added a comment. Should there be an aarch64 guard on the test? There exist downstream Arm compilers that don't support Arm64 and fail. I know other tests explicitly state "REQUIRES: aarch64-registered-target" Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D130306: [clang][dataflow] Analyze calls to in-TU functions

2022-07-25 Thread Sam Estep via Phabricator via cfe-commits
samestep added a comment. In D130306#3676672 , @xazax.hun wrote: > Thanks! Knowing the context, I am much happier with the direction overall. Is > the plan to analyze a mock of std::optional instead of the actual code in the > STL? How will that mock

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, jyu2

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, ABataev

[PATCH] D130493: Disable stack-sizes section by default for PS4.

2022-07-25 Thread Paul Robinson via Phabricator via cfe-commits
probinson accepted this revision. probinson added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130493/new/ https://reviews.llvm.org/D130493

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, jyu2

[clang] 2e80d2d - [Clang] Status of the C++23 papers approved by WG21 at the July plenary

2022-07-25 Thread Corentin Jabot via cfe-commits
Author: Corentin Jabot Date: 2022-07-25T19:43:06+02:00 New Revision: 2e80d2d7c3f4ed4433f747a5644817d095250df9 URL: https://github.com/llvm/llvm-project/commit/2e80d2d7c3f4ed4433f747a5644817d095250df9 DIFF:

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, ABataev

[PATCH] D101070: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs

2022-07-25 Thread John Ericson via Phabricator via cfe-commits
Ericson2314 added a comment. Also sorry, I had missed D130256 all along! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101070/new/ https://reviews.llvm.org/D101070 ___

[PATCH] D128465: [llvm] add zstd to `llvm::compression` namespace

2022-07-25 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: llvm/include/llvm/Support/Compression.h:48 + +constexpr int NoCompression = -5; +constexpr int BestSpeedCompression = 1; I missed the values here. Why is -5 picked for NoCompression? What does it mean? zstd.h says

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, jyu2

[PATCH] D129872: [clang][OpenMP] Fix runtime crash in the call to __kmp_alloc.

2022-07-25 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:16379 +// UnsignedPointerDiffType avoid truncate. +AllocatorHT = Context.getUnsignedPointerDiffType(); + Allocator = PerformImplicitConversion(Allocator.get(), AllocatorHT, ABataev

[PATCH] D101070: [llvm][cmake] Make `install_symlink` workflow work with absolute install dirs

2022-07-25 Thread John Ericson via Phabricator via cfe-commits
Ericson2314 updated this revision to Diff 447391. Ericson2314 added a comment. Oops! `ExtendPath` was not already imported Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101070/new/ https://reviews.llvm.org/D101070 Files:

  1   2   >