[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D112041#3073676 , @rampitec wrote: > In D112041#3073637 , @hliao wrote: > >> In D112041#3073560 , @rampitec >> wrote: >> >>> Is there anything

[PATCH] D111863: [libunwind] Add an interface for dynamic .eh_frame registration

2021-10-19 Thread Peter S. Housel via Phabricator via cfe-commits
housel added a comment. To be clear, this new code parses exactly as much of each FDE as the existing `__register_frame`/`__unw_add_dynamic_fde` does, including doing the same work to compute the record length. Neither needs to parse the instructions at registration time. Repository: rG

[PATCH] D112100: [clang] Add option to disable -clear-ast-before-backend

2021-10-19 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 rG063c2f89aa7f: [clang] Add option to disable -clear-ast-before-backend (authored by aeubanks). Changed prior to commit:

[clang] 063c2f8 - [clang] Add option to disable -clear-ast-before-backend

2021-10-19 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2021-10-19T20:51:48-07:00 New Revision: 063c2f89aa7f5b0b61a63d639d8124035f26935c URL: https://github.com/llvm/llvm-project/commit/063c2f89aa7f5b0b61a63d639d8124035f26935c DIFF:

[PATCH] D112100: [clang] Add option to disable -clear-ast-before-backend

2021-10-19 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks updated this revision to Diff 380847. aeubanks added a comment. use BoolOption td files are very hard to use... Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112100/new/ https://reviews.llvm.org/D112100 Files:

[PATCH] D112119: [ObjC Availability] Add missing const to getVersion function of ObjCAvailabilityCheckExpr class

2021-10-19 Thread Chaoshuai Lu via Phabricator via cfe-commits
lcs created this revision. lcs added a reviewer: manmanren. lcs requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add missing const to `getVersion` function of `ObjCAvailabilityCheckExpr` class. This feels like a bug on the original change

[PATCH] D111992: [MLIR][OpenMP] Added omp.atomic.read and omp.atomic.write

2021-10-19 Thread Shraiysh via Phabricator via cfe-commits
shraiysh added a comment. Hi all, the NFC has been merged, and the build is passing. This is ready for review now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111992/new/ https://reviews.llvm.org/D111992

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

2021-10-19 Thread George Burgess IV via Phabricator via cfe-commits
george.burgess.iv added a comment. Thanks for this! The idea LGTM, and sounds like a solid way for us to do better about diagnosing FORTIFY'ed calls in Clang. I have a handful of mostly nits/questions for you :) Comment at: clang/include/clang/Basic/Attr.td:3822 +def

[PATCH] D110287: [modules] While merging ObjCInterfaceDecl definitions, merge them as decl contexts too.

2021-10-19 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Serialization/ASTReaderDecl.cpp:1181-1184 + if (DD.Definition != NewDD.Definition) { +Reader.MergedDeclContexts.insert( +

[PATCH] D111833: [clang] Fortify warning for scanf calls with field width too big.

2021-10-19 Thread George Burgess IV via Phabricator via cfe-commits
george.burgess.iv accepted this revision. george.burgess.iv added a comment. This revision is now accepted and ready to land. LGTM % nits -- thanks for this! :) Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:836 +def warn_fortify_scanf_overflow : Warning < +

[PATCH] D112098: [ASan] Added stack safety support in address sanitizer.

2021-10-19 Thread Vitaly Buka via Phabricator via cfe-commits
vitalybuka added inline comments. Comment at: clang/include/clang/Basic/CodeGenOptions.def:227 CODEGENOPT(SanitizeAddressUseOdrIndicator, 1, 0) ///< Enable ODR indicator globals +CODEGENOPT(SanitizeAddressUseStackSafety, 1, 0) ///< Use stack safety result.

[PATCH] D111154: [WebAssembly] Implementation of table.get/set for reftypes in LLVM IR

2021-10-19 Thread Thomas Lively via Phabricator via cfe-commits
tlively accepted this revision. tlively added a comment. This revision is now accepted and ready to land. Nice! Just a couple nits but I think this is good to go. Comment at: llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp:1478-1479 + } else { +GA =

[PATCH] D110287: [modules] While merging ObjCInterfaceDecl definitions, merge them as decl contexts too.

2021-10-19 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added inline comments. Comment at: clang/lib/Serialization/ASTReaderDecl.cpp:1181-1184 + if (DD.Definition != NewDD.Definition) { +Reader.MergedDeclContexts.insert( +std::make_pair(NewDD.Definition, DD.Definition)); + } rsmith wrote: > A

[PATCH] D112022: [WebAssembly] Add prototype relaxed swizzle instructions

2021-10-19 Thread Thomas Lively via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG2542bfa43a97: [WebAssembly] Add prototype relaxed swizzle instructions (authored by ngzhian, committed by tlively). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[clang] 2542bfa - [WebAssembly] Add prototype relaxed swizzle instructions

2021-10-19 Thread Thomas Lively via cfe-commits
Author: Zhi An Ng Date: 2021-10-19T17:53:04-07:00 New Revision: 2542bfa43a9709982ee20f8d86f905f4115c41f9 URL: https://github.com/llvm/llvm-project/commit/2542bfa43a9709982ee20f8d86f905f4115c41f9 DIFF: https://github.com/llvm/llvm-project/commit/2542bfa43a9709982ee20f8d86f905f4115c41f9.diff

[PATCH] D112022: [WebAssembly] Add prototype relaxed swizzle instructions

2021-10-19 Thread Thomas Lively via Phabricator via cfe-commits
tlively accepted this revision. tlively added a comment. This revision is now accepted and ready to land. Thanks! I'll go ahead and land this. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112022/new/ https://reviews.llvm.org/D112022

[PATCH] D110287: [modules] While merging ObjCInterfaceDecl definitions, merge them as decl contexts too.

2021-10-19 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. In D110287#3074082 , @dblaikie wrote: > In D110287#3073804 , @vsapsai wrote: > >> Pre-merge checks are passing now after the rebase. I believe it is a >> straightforward change and we

[PATCH] D112098: [ASan] Added stack safety support in address sanitizer.

2021-10-19 Thread Florian Mayer via Phabricator via cfe-commits
fmayer added inline comments. Comment at: llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp:1499-1502 + if (ClUseStackSafety && findAllocaForValue(Ptr)) { +if (SSI && SSI->stackAccessIsSafe(*Inst)) { + return true; +} Doesn't need nested if.

[PATCH] D110287: [modules] While merging ObjCInterfaceDecl definitions, merge them as decl contexts too.

2021-10-19 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/lib/Serialization/ASTReaderDecl.cpp:1181-1184 + if (DD.Definition != NewDD.Definition) { +Reader.MergedDeclContexts.insert( +std::make_pair(NewDD.Definition, DD.Definition)); + } A couple of other

[PATCH] D112113: [ObjC] type method metadata `_imp`, messenger routine at callsite with program address space

2021-10-19 Thread Matt Jacobson via Phabricator via cfe-commits
mhjacobson created this revision. mhjacobson added reviewers: rjmccall, ddunbar. Herald added subscribers: pengfei, Jim, dylanmckay. mhjacobson requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. On targets with non-default program address

[PATCH] D112098: [ASan] Added stack safety support in address sanitizer.

2021-10-19 Thread Kirill Stoimenov via Phabricator via cfe-commits
kstoimenov updated this revision to Diff 380829. kstoimenov added a comment. Fixed the test to pass. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112098/new/ https://reviews.llvm.org/D112098 Files: clang/include/clang/Basic/CodeGenOptions.def

[PATCH] D109128: [VFS] Use original path when falling back to external FS

2021-10-19 Thread Keith Smiley via Phabricator via cfe-commits
keith updated this revision to Diff 380821. keith added a comment. Fix test paths on windows Otherwise this resulted in a json string with non-escaped backslashes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109128/new/

[PATCH] D110287: [modules] While merging ObjCInterfaceDecl definitions, merge them as decl contexts too.

2021-10-19 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. In D110287#3073804 , @vsapsai wrote: > Pre-merge checks are passing now after the rebase. I believe it is a > straightforward change and we are merging decl contexts for other Decls > already, so merging them for

[PATCH] D112100: [clang] Add option to disable -clear-ast-before-backend

2021-10-19 Thread David Blaikie via Phabricator via cfe-commits
dblaikie accepted this revision. dblaikie added a comment. This revision is now accepted and ready to land. Sounds good - possible flag def improvement with `BoolOption`. Comment at: clang/include/clang/Driver/Options.td:5317-5319 +def no_clear_ast_before_backend : Flag<["-"],

[PATCH] D112096: [clang] Add plugin ActionType to run command line plugin before main action

2021-10-19 Thread David Blaikie via Phabricator via cfe-commits
dblaikie accepted this revision. dblaikie added a comment. This revision is now accepted and ready to land. Sounds good Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112096/new/ https://reviews.llvm.org/D112096

[PATCH] D109707: [HIP] [AlwaysInliner] Disable AlwaysInliner to eliminate undefined symbols

2021-10-19 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: llvm/lib/Target/AMDGPU/AMDGPUResourceUsageAnalysis.cpp:67 + if (auto *GA = dyn_cast(Op.getGlobal())) +return cast(GA->getOperand(0)); return cast(Op.getGlobal()); I thought aliases could include embedded bitcasts

[PATCH] D112110: [OpenCL] queue_t and ndrange_t can't be defined in program scope.

2021-10-19 Thread Chuang-Yu Cheng via Phabricator via cfe-commits
cycheng created this revision. cycheng added a reviewer: Anastasia. Herald added subscribers: ldrumm, yaxunl. cycheng requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. OpenCL v2.0 s6.5.1 and OpenCL v3.0 s6.11.w both state: Program scope

[PATCH] D111471: [NVPTX] Add a late SROA pass which allows optimizing away more allocas.

2021-10-19 Thread Artem Belevich via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGb6b7fe60a444: [NVPTX] Add a late SROA pass which allows optimizing away more allocas. (authored by tra). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D109128: [VFS] Use original path when falling back to external FS

2021-10-19 Thread Keith Smiley via Phabricator via cfe-commits
keith added inline comments. Comment at: llvm/lib/Support/VirtualFileSystem.cpp:1179-1180 + if (ExternalFS) +ExternalFS->setCurrentWorkingDirectory(Path); + dexonsmith wrote: > keith wrote: > > JDevlieghere wrote: > > > I'm pretty sure there was a reason

[PATCH] D109128: [VFS] Use original path when falling back to external FS

2021-10-19 Thread Keith Smiley via Phabricator via cfe-commits
keith updated this revision to Diff 380802. keith marked 2 inline comments as done. keith added a comment. Remove `cd` of ExternalFS Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109128/new/ https://reviews.llvm.org/D109128 Files:

[PATCH] D112103: [WIP] Sample code for containerizing offload images into one ELF.

2021-10-19 Thread Vyacheslav Zakharin via Phabricator via cfe-commits
vzakhari created this revision. vzakhari added reviewers: saiislam, jdoerfert. Herald added a reviewer: alexander-shaposhnikov. vzakhari requested review of this revision. Herald added subscribers: cfe-commits, sstefan1. Herald added a project: clang. This code cannot currently work within llorg,

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao updated this revision to Diff 380798. hliao added a comment. Revise commit message. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112041/new/ https://reviews.llvm.org/D112041 Files: clang/test/CodeGen/thinlto-distributed-newpm.ll

[PATCH] D74531: [WebAssembly] Emit clangast in custom section aligned by 4 bytes

2021-10-19 Thread Sam Clegg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1813fde9cc0b: [WebAssembly] Emit clangast in custom section aligned by 4 bytes (authored by kateinoigakukun, committed by sbc100). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[clang] 1813fde - [WebAssembly] Emit clangast in custom section aligned by 4 bytes

2021-10-19 Thread Sam Clegg via cfe-commits
Author: Yuta Saito Date: 2021-10-19T15:50:08-07:00 New Revision: 1813fde9cc0b56cee42d9b82e6f22fa00a59cdf9 URL: https://github.com/llvm/llvm-project/commit/1813fde9cc0b56cee42d9b82e6f22fa00a59cdf9 DIFF: https://github.com/llvm/llvm-project/commit/1813fde9cc0b56cee42d9b82e6f22fa00a59cdf9.diff

[PATCH] D112102: [RISCV] Reduce the number of RISCV vector builtins by an order of magnitude.

2021-10-19 Thread Craig Topper via Phabricator via cfe-commits
craig.topper created this revision. craig.topper added reviewers: khchen, kito-cheng, arcbbb, HsiangKai, evandro, MaskRay, aeubanks, nikic. Herald added subscribers: achieveartificialintelligence, StephenFan, vkmr, frasercrmck, luismarques, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl,

[PATCH] D112053: [cuda] Add address space predicate funuctions.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao added inline comments. Comment at: clang/include/clang/Basic/BuiltinsNVPTX.def:691-694 +BUILTIN(__nvvm_isspacep_const, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_global, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_local, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_shared, "bvC*", "nc")

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao marked 4 inline comments as done. hliao added inline comments. Comment at: llvm/lib/Transforms/Scalar/InferAddressSpaces.cpp:196 void inferAddressSpaces(ArrayRef Postorder, - ValueToAddrSpaceMapTy *InferredAddrSpace) const; +

[clang] 922bf57 - [Driver][Gnu] Delete unneeded -Bstatic dispatch for arm/thumb

2021-10-19 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2021-10-19T15:24:07-07:00 New Revision: 922bf57fc8fe41ebcbbe581a7c8e730fbebf572f URL: https://github.com/llvm/llvm-project/commit/922bf57fc8fe41ebcbbe581a7c8e730fbebf572f DIFF: https://github.com/llvm/llvm-project/commit/922bf57fc8fe41ebcbbe581a7c8e730fbebf572f.diff

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao updated this revision to Diff 380791. hliao added a comment. Revise following reviewers' feedback. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112041/new/ https://reviews.llvm.org/D112041 Files:

[PATCH] D112100: [clang] Add option to disable -clear-ast-before-backend

2021-10-19 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks created this revision. aeubanks added reviewers: hans, dblaikie. Herald added a subscriber: dang. aeubanks requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Some downstream users have plugins that -clear-ast-before-backend may

[PATCH] D110287: [modules] While merging ObjCInterfaceDecl definitions, merge them as decl contexts too.

2021-10-19 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Pre-merge checks are passing now after the rebase. I believe it is a straightforward change and we are merging decl contexts for other Decls already, so merging them for `ObjCInterfaceDecl` makes sense. If there are no objections, I plan to land the change on Friday,

[PATCH] D112098: [ASan] Added stack safety support in address sanitizer.

2021-10-19 Thread Kirill Stoimenov via Phabricator via cfe-commits
kstoimenov created this revision. Herald added subscribers: ormris, dexonsmith, dang, hiraditya. kstoimenov requested review of this revision. Herald added a reviewer: jdoerfert. Herald added subscribers: llvm-commits, cfe-commits, sstefan1. Herald added projects: clang, LLVM. Added and

[PATCH] D112096: [clang] Add plugin ActionType to run command line plugin before main action

2021-10-19 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks created this revision. aeubanks added reviewers: hans, dblaikie. Herald added a subscriber: mgorny. aeubanks requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Currently we have a way to run a plugin if specified on the command line

[PATCH] D112022: [WebAssembly] Add prototype relaxed swizzle instructions

2021-10-19 Thread Ng Zhi An via Phabricator via cfe-commits
ngzhian updated this revision to Diff 380783. ngzhian added a comment. - Remove RELAXED_SWIZZLE sdnode Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112022/new/ https://reviews.llvm.org/D112022 Files:

[PATCH] D74531: [WebAssembly] Emit clangast in custom section aligned by 4 bytes

2021-10-19 Thread Yuta Saito via Phabricator via cfe-commits
kateinoigakukun added a comment. Thanks for reviewing! Can you merge this patch? I have no commit access. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74531/new/ https://reviews.llvm.org/D74531 ___

[PATCH] D111760: [clang] Support __float128 on DragonFlyBSD.

2021-10-19 Thread Frederic Cambus via Phabricator via cfe-commits
fcambus added inline comments. Comment at: clang/lib/Basic/Targets/OSTargets.h:182 DefineStd(Builder, "unix", Opts); +if (this->HasFloat128) + Builder.defineMacro("__FLOAT128__"); mgorny wrote: > Maybe I'm missing something but do you actually need

[PATCH] D112022: [WebAssembly] Add prototype relaxed swizzle instructions

2021-10-19 Thread Thomas Lively via Phabricator via cfe-commits
tlively added inline comments. Comment at: llvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td:1365 + +def wasm_relaxed_swizzle : SDNode<"WebAssemblyISD::RELAXED_SWIZZLE", wasm_swizzle_t>; + ngzhian wrote: > @tlively i'm not 100% sure if this is needed or the

[PATCH] D112022: [WebAssembly] Add prototype relaxed swizzle instructions

2021-10-19 Thread Ng Zhi An via Phabricator via cfe-commits
ngzhian updated this revision to Diff 380779. ngzhian added a comment. Wrong commits Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112022/new/ https://reviews.llvm.org/D112022 Files: clang/include/clang/Basic/BuiltinsWebAssembly.def

[PATCH] D112019: [clang-format] [PR51412] AlignConsecutiveMacros fights with Visual Studio and resource.h

2021-10-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D112019#3073628 , @HazardyKnusperkeks wrote: > Otherwise it looks good. Thanks @HazardyKnusperkeks Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112019/new/

[PATCH] D111579: [clang] Fix DIFile directory root on Windows

2021-10-19 Thread Keith Smiley via Phabricator via cfe-commits
keith added inline comments. Comment at: clang/test/CodeGen/debug-prefix-map.c:24 +// CHECK-NO-MAIN-FILE-NAME: !DIFile(filename: "{{/|C:}}UNLIKELY_PATH{{/|}}empty{{/|}}{{.*}}", +// CHECK-NO-MAIN-FILE-NAME-SAME:directory: "") +// CHECK-NO-MAIN-FILE-NAME:

[PATCH] D111457: [clang][test] Add lit helper for windows paths

2021-10-19 Thread Keith Smiley via Phabricator via cfe-commits
keith added a comment. In D111457#3066508 , @mstorsjo wrote: > Wouldn't this one also be solved pretty much the same, but differently, by > changing `if (llvm::sys::path::is_absolute(RemappedFile)) {` into > `is_absolute_gnu`? I think it //could// but

[PATCH] D112059: Fix inline builtin handling in case of redefinition

2021-10-19 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a subscriber: nathanchance. nickdesaulniers added a comment. Yes; GCC does behave this way. It does not consider a non-gnu-inline redefinition an error, and it does seem to prefer the non-gnu-inline redeclaration when both are present, AFAICT. The test is verifying that

[PATCH] D112089: consteval if does not form a discarded statement

2021-10-19 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/lib/Parse/ParseStmt.cpp:1445-1450 Sema::ExpressionEvaluationContext Context = Sema::ExpressionEvaluationContext::DiscardedStatement; -if (NotLocation.isInvalid() && IsConsteval) +if (NotLocation.isInvalid()

[PATCH] D111542: [analyzer] Retrieve incomplete array extent from its redeclaration.

2021-10-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Amazing, thanks a lot! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111542/new/ https://reviews.llvm.org/D111542 ___ cfe-commits mailing list

[PATCH] D112089: consteval if does not form a discarded statement

2021-10-19 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added inline comments. Comment at: clang/lib/Parse/ParseStmt.cpp:1445-1450 Sema::ExpressionEvaluationContext Context = Sema::ExpressionEvaluationContext::DiscardedStatement; -if (NotLocation.isInvalid() && IsConsteval) +

[PATCH] D111269: [clang][Driver] Make multiarch output file basenames reproducible

2021-10-19 Thread Keith Smiley 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 rG17386cb4dc89: [clang][Driver] Make multiarch output file basenames reproducible (authored by keith). Repository: rG LLVM Github Monorepo CHANGES

[clang] 17386cb - [clang][Driver] Make multiarch output file basenames reproducible

2021-10-19 Thread Keith Smiley via cfe-commits
Author: Keith Smiley Date: 2021-10-19T13:49:47-07:00 New Revision: 17386cb4dc89afad62623b9bc08516b99b9c6df7 URL: https://github.com/llvm/llvm-project/commit/17386cb4dc89afad62623b9bc08516b99b9c6df7 DIFF: https://github.com/llvm/llvm-project/commit/17386cb4dc89afad62623b9bc08516b99b9c6df7.diff

[PATCH] D112089: consteval if does not form a discarded statement

2021-10-19 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/lib/Parse/ParseStmt.cpp:1445-1450 Sema::ExpressionEvaluationContext Context = Sema::ExpressionEvaluationContext::DiscardedStatement; -if (NotLocation.isInvalid() && IsConsteval) +if (NotLocation.isInvalid() &&

[PATCH] D112089: consteval if does not form a discarded statement

2021-10-19 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin accepted this revision. cor3ntin added a comment. This revision is now accepted and ready to land. Oups, Sorry I missed that in my earlier PR. This fix LGTM. Thanks Aaron Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112089/new/

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Stanislav Mekhanoshin via Phabricator via cfe-commits
rampitec added a comment. In D112041#3073637 , @hliao wrote: > In D112041#3073560 , @rampitec > wrote: > >> Is there anything to remove assume() call after address space is inferred? >> We do not need it

[PATCH] D112056: [clang-format] git-clang-format throws an assertion when removing files as part of the commit

2021-10-19 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks accepted this revision. HazardyKnusperkeks added a comment. This revision is now accepted and ready to land. In D112056#3073569 , @MyDeveloperDay wrote: > In D112056#3073142 , @lhames wrote: >

[PATCH] D112053: [cuda] Add address space predicate funuctions.

2021-10-19 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/include/clang/Basic/BuiltinsNVPTX.def:691-694 +BUILTIN(__nvvm_isspacep_const, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_global, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_local, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_shared, "bvC*", "nc")

[PATCH] D110287: [modules] While merging ObjCInterfaceDecl definitions, merge them as decl contexts too.

2021-10-19 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai updated this revision to Diff 380771. vsapsai added a comment. Rebase as the pre-requisite change has landed. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110287/new/ https://reviews.llvm.org/D110287 Files:

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D112041#3073560 , @rampitec wrote: > Is there anything to remove assume() call after address space is inferred? We > do not need it anymore. along with a few other intrinsics, assume intrinsic is discarded in SDAG and GISel.

[PATCH] D111205: [driver] Explicitly specify `-fbuild-session-timestamp` in seconds.

2021-10-19 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Thanks for the review! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111205/new/ https://reviews.llvm.org/D111205 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D111205: [driver] Explicitly specify `-fbuild-session-timestamp` in seconds.

2021-10-19 Thread Volodymyr Sapsai 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 rG91e19f66e51a: [driver] Explicitly specify `-fbuild-session-timestamp` in seconds. (authored by vsapsai). Repository: rG LLVM Github Monorepo

[clang] 91e19f6 - [driver] Explicitly specify `-fbuild-session-timestamp` in seconds.

2021-10-19 Thread Volodymyr Sapsai via cfe-commits
Author: Volodymyr Sapsai Date: 2021-10-19T13:30:26-07:00 New Revision: 91e19f66e51ac3fda2309f5e67b02fcccd4d58a0 URL: https://github.com/llvm/llvm-project/commit/91e19f66e51ac3fda2309f5e67b02fcccd4d58a0 DIFF:

[PATCH] D112019: [clang-format] [PR51412] AlignConsecutiveMacros fights with Visual Studio and resource.h

2021-10-19 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks accepted this revision. HazardyKnusperkeks added a comment. This revision is now accepted and ready to land. Otherwise it looks good. Comment at: clang/include/clang/Format/Format.h:245 + /// \version 14 + bool AlignConsecutiveMacrosIgnoreMax; +

[PATCH] D112053: [cuda] Add address space predicate funuctions.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao added inline comments. Comment at: clang/include/clang/Basic/BuiltinsNVPTX.def:691-694 +BUILTIN(__nvvm_isspacep_const, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_global, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_local, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_shared, "bvC*", "nc")

[PATCH] D112053: [cuda] Add address space predicate funuctions.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
hliao added inline comments. Comment at: clang/include/clang/Basic/BuiltinsNVPTX.def:691-694 +BUILTIN(__nvvm_isspacep_const, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_global, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_local, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_shared, "bvC*", "nc")

[PATCH] D112053: [cuda] Add address space predicate funuctions.

2021-10-19 Thread Michael Liao via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6fe902daf931: [cuda] Add address space predicate funuctions. (authored by hliao). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112053/new/

[clang] 6fe902d - [cuda] Add address space predicate funuctions.

2021-10-19 Thread Michael Liao via cfe-commits
Author: Michael Liao Date: 2021-10-19T16:20:14-04:00 New Revision: 6fe902daf931dedf6e958b43c043cb57bb612daf URL: https://github.com/llvm/llvm-project/commit/6fe902daf931dedf6e958b43c043cb57bb612daf DIFF: https://github.com/llvm/llvm-project/commit/6fe902daf931dedf6e958b43c043cb57bb612daf.diff

[PATCH] D111720: [clang][deps] Ensure reported context hash is strict

2021-10-19 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith accepted this revision. dexonsmith added a comment. This revision is now accepted and ready to land. LGTM, if you expand the comment (see inline). Comment at: clang/lib/Tooling/DependencyScanning/ModuleDepCollector.cpp:56-58 + // Ensure the reported context hash is

[PATCH] D111986: [Clang] Add elementwise abs builtin.

2021-10-19 Thread Steve Canon via Phabricator via cfe-commits
scanon accepted this revision. scanon added a comment. This revision is now accepted and ready to land. Two minor questions, but also LGTM as is. Comment at: clang/lib/Sema/SemaChecking.cpp:16667 + + if (!TyA->getAs() && !ConstantMatrixType::isValidElementType(TyA)) +

[PATCH] D112056: [clang-format] git-clang-format throws an assertion when removing files as part of the commit

2021-10-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D112056#3073142 , @lhames wrote: > I think that this should fix the issue I saw, but `clang-format` will still > crash when passed a `-lines=0:X` option. Would it make sense to either error > out in that tool, or

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Stanislav Mekhanoshin via Phabricator via cfe-commits
rampitec added a comment. Is there anything to remove assume() call after address space is inferred? We do not need it anymore. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112041/new/ https://reviews.llvm.org/D112041

[PATCH] D112091: libfuzzer: All building libfuzzer for ARM32

2021-10-19 Thread Manoj Gupta via Phabricator via cfe-commits
manojgupta created this revision. manojgupta added a reviewer: metzman. Herald added subscribers: kristof.beyls, mgorny. manojgupta requested review of this revision. Herald added a project: Sanitizers. Herald added a subscriber: Sanitizers. We need libfuzzer libraries on Arm32 so that we can

[PATCH] D112049: [ObjC] avoid crashing when emitting synthesized getter/setter and ptrdiff_t is smaller than long

2021-10-19 Thread Matt Jacobson via Phabricator via cfe-commits
mhjacobson added a comment. The test is failing for a different reason (that I'd forgotten I worked around locally). I'll look into fixing that first. Sorry for noise. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112049/new/

[clang] 57553ce - Revert "Reland [clang] Pass -clear-ast-before-backend in Clang::ConstructJob()"

2021-10-19 Thread Zequan Wu via cfe-commits
Author: Zequan Wu Date: 2021-10-19T12:39:34-07:00 New Revision: 57553ce43281a7c379e375161320cc09d8236839 URL: https://github.com/llvm/llvm-project/commit/57553ce43281a7c379e375161320cc09d8236839 DIFF: https://github.com/llvm/llvm-project/commit/57553ce43281a7c379e375161320cc09d8236839.diff

[PATCH] D111986: [Clang] Add elementwise abs builtin.

2021-10-19 Thread Florian Hahn via Phabricator via cfe-commits
fhahn updated this revision to Diff 380756. fhahn added a comment. In D111986#3072946 , @scanon wrote: > What's the rationale for making abs undefined on the minimum value? AFAIK > every actual simd implementation defines the result and they agree (and

[PATCH] D111529: Specify Clang vector builtins.

2021-10-19 Thread Florian Hahn via Phabricator via cfe-commits
fhahn updated this revision to Diff 380755. fhahn added a comment. As @scanon pointed out in D111986 , most simd implementations should handle abs(INT_MIN) consistently by returngin INT_MIN. It's therefore better to avoid defining abs(INT_MIN) as UB, which

[PATCH] D111579: [clang] Fix DIFile directory root on Windows

2021-10-19 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added inline comments. Comment at: clang/test/CodeGen/debug-prefix-map.c:24 +// CHECK-NO-MAIN-FILE-NAME: !DIFile(filename: "{{/|C:}}UNLIKELY_PATH{{/|}}empty{{/|}}{{.*}}", +// CHECK-NO-MAIN-FILE-NAME-SAME:directory: "") +// CHECK-NO-MAIN-FILE-NAME:

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Nikita Popov via Phabricator via cfe-commits
nikic added a comment. Is it actually necessary to thread this through AssumptionCache, given how InferAddressSpaces is the only place that looks at these assumes? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112041/new/

[PATCH] D111579: [clang] Fix DIFile directory root on Windows

2021-10-19 Thread Keith Smiley via Phabricator via cfe-commits
keith added inline comments. Comment at: clang/test/CodeGen/debug-prefix-map.c:24 +// CHECK-NO-MAIN-FILE-NAME: !DIFile(filename: "{{/|C:}}UNLIKELY_PATH{{/|}}empty{{/|}}{{.*}}", +// CHECK-NO-MAIN-FILE-NAME-SAME:directory: "") +// CHECK-NO-MAIN-FILE-NAME:

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: llvm/include/llvm/Analysis/AssumptionCache.h:109 /// its instructions. - AssumptionCache(Function ) : F(F) {} + AssumptionCache(Function , TargetTransformInfo *TTI) : F(F), TTI(TTI) {} Perhaps this should have a

[PATCH] D111992: [MLIR][OpenMP] Added omp.atomic.read and omp.atomic.write

2021-10-19 Thread Shraiysh via Phabricator via cfe-commits
shraiysh updated this revision to Diff 380718. shraiysh added a comment. Herald added projects: clang, Flang. Herald added a subscriber: cfe-commits. Rebase with main Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111992/new/

[PATCH] D112089: consteval if does not form a discarded statement

2021-10-19 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman created this revision. aaron.ballman added reviewers: cor3ntin, erichkeane, rsmith. aaron.ballman requested review of this revision. Herald added a project: clang. When we added support for `if consteval`, we accidentally formed a discarded statement evaluation context for the

[PATCH] D76169: [WIP][AST] Allow ExprConstant to evaluate structs in C.

2021-10-19 Thread Tom Hughes via Phabricator via cfe-commits
tomhughes added a comment. I took the tests from https://reviews.llvm.org/D76096 and combined it with this change. As mentioned in the last comment 606a734755d1fb6c35a17680d0c251f834b79334 causes conflicts, so I tried

[clang] dc8a5f9 - [RISCV] Use llvm::stable_sort instead of std::stable_sort. NFC

2021-10-19 Thread Craig Topper via cfe-commits
Author: Craig Topper Date: 2021-10-19T11:37:40-07:00 New Revision: dc8a5f9419f5cc35fc3c9e8698ba3ebb6a3f974f URL: https://github.com/llvm/llvm-project/commit/dc8a5f9419f5cc35fc3c9e8698ba3ebb6a3f974f DIFF: https://github.com/llvm/llvm-project/commit/dc8a5f9419f5cc35fc3c9e8698ba3ebb6a3f974f.diff

[PATCH] D111863: [libunwind] Add an interface for dynamic .eh_frame registration

2021-10-19 Thread Lang Hames via Phabricator via cfe-commits
lhames added a comment. In D111863#3072827 , @joerg wrote: > `__register_frame` requires parsing the CIE header, but not the whole FDE > program. E.g. that's the `findPCRange` logic. After that, the FDE is just > added to the internal block list.

[PATCH] D112053: [cuda] Add address space predicate funuctions.

2021-10-19 Thread Artem Belevich via Phabricator via cfe-commits
tra accepted this revision. tra added a comment. This revision is now accepted and ready to land. LGTM in general. Comment at: clang/include/clang/Basic/BuiltinsNVPTX.def:691-694 +BUILTIN(__nvvm_isspacep_const, "bvC*", "nc") +BUILTIN(__nvvm_isspacep_global, "bvC*", "nc")

[PATCH] D112088: [clang][deps] Keep #pragma push_macro, pop_macro and include_alias when minimizing source code.

2021-10-19 Thread Sylvain Audi via Phabricator via cfe-commits
saudi created this revision. saudi added reviewers: dexonsmith, jansvoboda11, Bigcheese. saudi added a project: clang. Herald added a subscriber: jeroen.dobbelaere. saudi requested review of this revision. Herald added a subscriber: cfe-commits. The `#pragma` directives `push_macro`/`pop_macro`

[PATCH] D112041: [InferAddressSpaces] Support assumed addrspaces from addrspace predicates.

2021-10-19 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp:800-801 + // (!is_share(p) && !is_private(p)). + // FIXME: Even though there is no distinguish between CONSTANT and GLOBAL in + // the backend, it may still benefit by telling them from

[PATCH] D110663: [Driver] Support Debian multiarch style lib/clang/14.0.0/x86_64-linux-gnu runtime path and include/x86_64-linux-gnu/c++/v1 libc++ path

2021-10-19 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment.  Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110663/new/ https://reviews.llvm.org/D110663 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D112081: Define __STDC_NO_THREADS__ when targeting windows-msvc (PR48704)

2021-10-19 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. The standard answer is that compilers are designed to work with a specific set of system headers. In the Clang-on-Windows case, that's complicated by the fact that many people acquire Clang separately from the rest of the build environment (although Microsoft does

[PATCH] D109701: [clang] Emit SARIF Diagnostics: Create `clang::SarifDocumentWriter` interface

2021-10-19 Thread Artem Belevich via Phabricator via cfe-commits
tra resigned from this revision. tra added a comment. I'm not sure how/why I ended up as a reviewer here as I don't have much to do with diags, other than adding one now and then. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109701/new/

[PATCH] D112081: Define __STDC_NO_THREADS__ when targeting windows-msvc (PR48704)

2021-10-19 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D112081#3073067 , @aaron.ballman wrote: > Thanks for this! Should we similarly handle `__STDC_NO_ATOMICS__`, > `__STDC_NO_COMPLEX__`, et al at the same time? I'll look into those, thanks. > Also, how should we handle

[PATCH] D74130: [clang] fix consteval call in default arguments

2021-10-19 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. @Tyker -- are you planning to pick this review back up again sometime in the near future? If not, do you care if the review gets commandeered? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74130/new/

[PATCH] D112059: Fix inline builtin handling in case of redefinition

2021-10-19 Thread Manoj Gupta via Phabricator via cfe-commits
manojgupta added a comment. thanks, I can verify that it fixes the crash we were seeing. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112059/new/ https://reviews.llvm.org/D112059 ___ cfe-commits

[PATCH] D112013: [clang][ASTImporter] Fix for importing functions with EST_Unevaluated prototype.

2021-10-19 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added inline comments. Comment at: clang/unittests/AST/ASTImporterTest.cpp:6180 + ASSERT_FALSE(FromCtor->getTypeSourceInfo()); + // Set a TypeSourceInfo for the function, this state may occur in reality. + TypeSourceInfo *FromTSI =

  1   2   >