[PATCH] D114394: Compile-time computation of string attribute hashes

2021-11-23 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added subscribers: aeubanks, rnk. rnk added a comment. I think @aeubanks might be a good reviewer for this. I like the performance wins here. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114394/new/ https://reviews.llvm.org/D114394 ___

[PATCH] D114082: [WIP] Normalize String Attributes

2021-11-23 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added subscribers: void, rnk. rnk added a comment. > it is possible to list all internal keys in one place I think one of the original goals of adding support for string attributes (maybe @void will give some input) was specifically to avoid having one giant list with all the attributes sup

[PATCH] D108479: [Clang] Add __builtin_addressof_nocfi

2021-11-23 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/lib/Sema/SemaChecking.cpp:208 +if (UnaryOp->getOpcode() == UnaryOperator::Opcode::UO_AddrOf) + E = UnaryOp->getSubExpr(); + samitolvanen wrote: > rjmccall wrote: > > samitolvanen wrote: > > > rjmccall wro

[PATCH] D114317: [clang-tidy][WIP] Do not run perfect alias checks

2021-11-23 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added a comment. In D114317#3149504 , @salman-javed-nz wrote: > What would you say are the key differences between this patch differ and > previous attempts, e.g. https://reviews.llvm.org/D72566? How does this patch > address the concerns

[PATCH] D113393: [c++2b] Implement P0849R8 auto(x)

2021-11-23 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray updated this revision to Diff 389304. lichray added a comment. - Implement decltype(auto)(x) as well Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113393/new/ https://reviews.llvm.org/D113393 Files: clang/docs/ReleaseNotes.rst clang/in

[PATCH] D113372: [Driver] Add CLANG_DEFAULT_PIE to emulate GCC --enable-default-pie

2021-11-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 389305. MaskRay added a comment. Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Add a release note Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113372/new/ https://reviews.llvm.org/D113

[PATCH] D114454: [NFC][AIX]Disable unstable CSA tests failing on AIX

2021-11-23 Thread Gabor Marton via Phabricator via cfe-commits
martong edited reviewers, added: steakhal; removed: vsavchenko. martong added a comment. vsavchenko is inactive, presumably he is no longer working with CSA Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114454/new/ https://reviews.llvm.org/D114454

[PATCH] D113393: [c++2b] Implement P0849R8 auto(x)

2021-11-23 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray added a comment. In D113393#3128835 , @rsmith wrote: > It looks like we'll need some additional work on disambiguation to handle > cases like: > > struct A { int n; } a; > void f() { auto(&a)->n = 0; } > > I think that's valid, but right now

[PATCH] D113393: [c++2b] Implement P0849R8 auto(x)

2021-11-23 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray added a comment. In D113393#3128840 , @rsmith wrote: > I also wonder whether we should accept `decltype(auto)(x)` as an extension, > but we can discuss that separately. Implemented. To produce a reference rather than a temporary, I had to speci

[PATCH] D114317: [clang-tidy][WIP] Do not run perfect alias checks

2021-11-23 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Thank you for looking into it! In D114317#3149693 , @carlosgalvezp wrote: > In D114317#3149504 , > @salman-javed-nz wrote: > >> What would you say are the key differences between thi

[PATCH] D114481: [NFC][AIX]Disable precompiled module file tests on AIX

2021-11-23 Thread Steven Wan via Phabricator via cfe-commits
stevewan created this revision. stevewan requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. The PCH reader looks for `__clangast` section in the precompiled module file, which is not present in the file on AIX, and we don't support writing th

[PATCH] D114058: [clangd] Add ObjC method support to prepareCallHierarchy

2021-11-23 Thread Sheldon Neuberger via Phabricator via cfe-commits
sheldonneuberger-sc updated this revision to Diff 389333. sheldonneuberger-sc added a comment. - inline test helper for readability - fix indentation Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114058/new/ https://reviews.llvm.org/D114058 Files:

[PATCH] D114058: [clangd] Add ObjC method support to prepareCallHierarchy

2021-11-23 Thread Sheldon Neuberger via Phabricator via cfe-commits
sheldonneuberger-sc updated this revision to Diff 389334. sheldonneuberger-sc added a comment. - revert whitespace change Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114058/new/ https://reviews.llvm.org/D114058 Files: clang-tools-extra/clangd/

[PATCH] D114483: Add support for sycl_special_class attribute

2021-11-23 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam created this revision. zahiraam added reviewers: bader, Naghasan, keryell, Fznamznon, aaron.ballman, erichkeane. Herald added subscribers: jdoerfert, Anastasia, ebevhan, yaxunl. zahiraam requested review of this revision. Herald added a project: clang. Special classes such as accessor, s

[PATCH] D114058: [clangd] Add ObjC method support to prepareCallHierarchy

2021-11-23 Thread Sheldon Neuberger via Phabricator via cfe-commits
sheldonneuberger-sc added a comment. Made suggested changes, ready for another review. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114058/new/ https://reviews.llvm.org/D114058 ___ cfe-commits mailing l

[PATCH] D114484: [NFC][AIX]Disable unsupported hip test on AIX

2021-11-23 Thread Steven Wan via Phabricator via cfe-commits
stevewan created this revision. Herald added a subscriber: yaxunl. stevewan requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. AIX doesn't support GPU. There is no point testing HIP on it. Repository: rG LLVM Github Monorepo https://revie

[PATCH] D108479: [Clang] Add __builtin_addressof_nocfi

2021-11-23 Thread Sami Tolvanen via Phabricator via cfe-commits
samitolvanen updated this revision to Diff 389346. samitolvanen added a comment. Changed the code to evaluate the argument as a constant expression. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108479/new/ https://reviews.llvm.org/D108479 Files:

[PATCH] D108479: [Clang] Add __builtin_addressof_nocfi

2021-11-23 Thread Sami Tolvanen via Phabricator via cfe-commits
samitolvanen added inline comments. Comment at: clang/lib/Sema/SemaChecking.cpp:208 +if (UnaryOp->getOpcode() == UnaryOperator::Opcode::UO_AddrOf) + E = UnaryOp->getSubExpr(); + rjmccall wrote: > samitolvanen wrote: > > rjmccall wrote: > > > samitolvanen

[PATCH] D112024: [clang] diagnose_as attribute for Fortify diagnosing like builtins.

2021-11-23 Thread Michael Benfield via Phabricator via cfe-commits
mbenfield updated this revision to Diff 389355. mbenfield added a comment. Error on member function. Test case for this. Test case for attribute applied to a non-function declaration. Handle variadic functions. Document this. Test case for variadic functions. Remove const from some local values

[Diffusion] rGc93f93b2e3f2: Revert "Revert "Recommit "Revert "[CVP] processSwitch: Remove default case when…

2021-11-23 Thread JunMa via Phabricator via cfe-commits
junparser added a comment. In rGc93f93b2e3f28997f794265089fb8138dd5b5f13#1040054 , @lkail wrote: > Looks a more general way should be implemented in tailduplicator to avoid > adding quadratic edges in CFGs. yep, firs

[PATCH] D108479: [Clang] Add __builtin_addressof_nocfi

2021-11-23 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Your builtin is using custom type-checking (`t`), which suppresses all the normal conversions that happen on expressions. Specifically, it skips lvalue-to-rvalue conversion, so in this example the argument ends up being an l-value reference to a variable rather than a

[Diffusion] rGc93f93b2e3f2: Revert "Revert "Recommit "Revert "[CVP] processSwitch: Remove default case when…

2021-11-23 Thread JunMa via Phabricator via cfe-commits
junparser added a reverting change: rG07333810caee: Revert "Revert "Revert "Recommit "Revert "[CVP] processSwitch: Remove default…. BRANCHES EmptyLineAfterFunctionDefinition, fix_asan, main Users: junparser (Author) https://reviews.llvm.org/rGc93f93b2e3f2 __

[PATCH] D112913: Misleading bidirectional detection

2021-11-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang-tools-extra/clang-tidy/misc/MisleadingBidirectional.cpp:49 + if (C == '\n' || C == '\r' || C == '\f' || C == '\v' || + C == 0x85 /*next line*/) +EmbeddingOverride = Isolate = 0; `/*next line=*

[PATCH] D114151: [clang-format] [C++20] [Module] clang-format couldn't recognize partitions

2021-11-23 Thread Owen Pan via Phabricator via cfe-commits
owenpan added inline comments. Comment at: clang/lib/Format/UnwrappedLineParser.cpp:1057 + nextToken(); + do { +if (FormatTok->is(tok::colon)) { A `while (!eof())` or `while (FormatTok->isNot(tok::eof)` would be safer here just in case the last line is `i

[PATCH] D114411: [WIP][modules] Avoid deserializing Decls from hidden (sub)modules.

2021-11-23 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai updated this revision to Diff 389374. vsapsai added a comment. Fix some failing tests to demonstrate the magnitued of changes better. In some places check if a decl is deserialized successfully as it's not guaranteed. Also tried to make sure a module is marked as visible *before* we try

[PATCH] D114394: Compile-time computation of string attribute hashes

2021-11-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: llvm/lib/IR/AttributeImpl.h:214 - DenseMap StringAttrs; + std::unordered_map StringAttrs; std::unordered_map is inefficient. Why is this change? Comment at: llvm/lib/IR/Attributes.cpp:862 + auto

LLVM build master will be restarted soon

2021-11-23 Thread Galina Kistanova via cfe-commits
Hello, LLVM build master will be restarted in the nearest hour. Thanks Galina ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D114411: [WIP][modules] Avoid deserializing Decls from hidden (sub)modules.

2021-11-23 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai updated this revision to Diff 389379. vsapsai added a comment. Mark identifiers as out-of-date not only on loading a new module but on making a (sub)module visible too. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114411/new/ https://revi

[PATCH] D114497: [Driver] Stop adding stdlib paths in -ffreestanding

2021-11-23 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray created this revision. Herald added subscribers: krytarowski, arichardson, emaste. lichray requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When targeting FreeBSD on a Linux host with a copy of system libc++, Clang prepends /usr/incl

[PATCH] D114497: [Driver] Stop adding stdlib paths in -ffreestanding

2021-11-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. GCC -ffreestanding doesn't change libstdc++ search paths. Clang's behavior matches GCC. To drop /usr/include/c++/v1, you need -nostdinc++. If you want to drop /usr/include etc, you need to specify --sysroot= Repository: rG LLVM Github Monorepo CHANGES SINCE LAST AC

[PATCH] D114394: Compile-time computation of string attribute hashes

2021-11-23 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini added inline comments. Comment at: llvm/lib/IR/Attributes.cpp:125 FoldingSetNodeID ID; - ID.AddString(Kind); + ID.AddString(Kind.value()); if (!Val.empty()) ID.AddString(Val); Carrying over my comment from the original revision: it seem that y

[PATCH] D114497: [Driver] Stop adding stdlib paths in -ffreestanding

2021-11-23 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray updated this revision to Diff 389391. lichray added a comment. Herald added subscribers: kbarton, nemanjai. - Adapt tests instead Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114497/new/ https://reviews.llvm.org/D114497 Files: clang/tes

[PATCH] D114504: [clang][DebugInfo] Debug support for private variables inside an OpenMP task construct

2021-11-23 Thread Alok Kumar Sharma via Phabricator via cfe-commits
alok created this revision. alok added reviewers: aprantl, djtodoro. alok added a project: debug-info. Herald added subscribers: pengfei, guansong, yaxunl. alok requested review of this revision. Herald added a reviewer: jdoerfert. Herald added subscribers: cfe-commits, sstefan1. Herald added a pro

[PATCH] D114058: [clangd] Add ObjC method support to prepareCallHierarchy

2021-11-23 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! let me know of your email address (for commit attribution) if you want me to land this for you. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://re

[PATCH] D114249: [clang-tidy] performance-unnecessary-copy-initialization: Fix false negative.

2021-11-23 Thread Clement Courbet via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGba4411e7c6a5: [clang-tidy] performance-unnecessary-copy-initialization: Fix false negative. (authored by courbet). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.

[clang-tools-extra] ba4411e - [clang-tidy] performance-unnecessary-copy-initialization: Fix false negative.

2021-11-23 Thread Clement Courbet via cfe-commits
Author: Clement Courbet Date: 2021-11-24T08:07:21+01:00 New Revision: ba4411e7c6a5879ce8acf246b0cd03ec738d9d6b URL: https://github.com/llvm/llvm-project/commit/ba4411e7c6a5879ce8acf246b0cd03ec738d9d6b DIFF: https://github.com/llvm/llvm-project/commit/ba4411e7c6a5879ce8acf246b0cd03ec738d9d6b.dif

[PATCH] D114317: [clang-tidy][WIP] Do not run perfect alias checks

2021-11-23 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added a comment. > it is likely that the options were tuned, but most likely only for a single > check. Yes, if the alias check has a different configuration than the primary check then they are considered as "different" checks (as they should be, since they produce potentially d

[PATCH] D114505: [clang][unittests]Fix a clang unittest linking issue

2021-11-23 Thread Lu Weining via Phabricator via cfe-commits
SixWeining created this revision. SixWeining added reviewers: cfe-commits, dexonsmith. Herald added a subscriber: mgorny. SixWeining requested review of this revision. Herald added a project: clang. Currently the clang/unittests/Basic/CMakeLists.txt links LLVMTestingSupport in an incorrect way th

<    1   2