[PATCH] D78374: [Analyzer][StreamChecker] Added evaluation of fread and fwrite.

2020-04-20 Thread Balázs Kéri via Phabricator via cfe-commits
balazske marked 2 inline comments as done. balazske added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:222 {StreamState::FEof, StreamState::FError, StreamState::NoError}}}, - {{"ftell", 1}, {&StreamChecker::preDefault, nullptr, 0,

[PATCH] D78457: [analyzer][Z3-refutation] Fix refutation BugReporterVisitor bug and refactor

2020-04-20 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. In D78457#1991288 , @xazax.hun wrote: > > As turned out we don't even need a BugReporterVisitor for doing the > > crosscheck. > > We should simply use the constraints of the ErrorNode since that has all > > the necessary informa

[PATCH] D75169: [ARM] Enforcing calling convention for half-precision FP arguments and returns for big-endian AArch32

2020-04-20 Thread Lucas Prates via Phabricator via cfe-commits
pratlucas added a comment. Herald added a subscriber: danielkiss. Ping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75169/new/ https://reviews.llvm.org/D75169 ___ cfe-commits mailing list cfe-commits

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-04-20 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 258674. gamesh411 added a comment. Update user documentation Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75665/new/ https://reviews.llvm.org/D75665 Files: clang/docs/analyzer/user-docs/CrossTranslationUn

[PATCH] D76996: [analyzer] Improve PlacementNewChecker

2020-04-20 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/CheckPlacementNew.cpp:189 + if (const MemRegion *MRegion = PlaceVal.getAsRegion()) { +if (const ElementRegion *TheElementRegion = +MRegion->getAs()) { f00kat wrote: > f0

[PATCH] D78457: [analyzer][Z3-refutation] Fix refutation BugReporterVisitor bug and refactor

2020-04-20 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. One way to test this change would be to add a statistic that is bumped each time a path is refuted (a report to be refuted we need all of the paths refuted, so using refuted reports might not be fine-grained enough). We can test on some big projects if the refuted pat

[PATCH] D78478: [UpdateTestChecks] Add UTC_ARGS support for update_{llc,cc}_test_checks.py

2020-04-20 Thread Alexander Richardson via Phabricator via cfe-commits
arichardson created this revision. arichardson added reviewers: jdoerfert, MaskRay. Herald added a project: clang. Herald added a subscriber: cfe-commits. https://reviews.llvm.org/D69701 added support for on-the-fly argument changes for update scripts. I recently wanted to keep some manual check l

[PATCH] D78457: [analyzer][Z3-refutation] Fix refutation BugReporterVisitor bug and refactor

2020-04-20 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. In D78457#1991780 , @martong wrote: > If a symbol is unused and garbage collected then that is not part of the path > constraint that leads to the ErrorNode, is it? So why should we care about > constraints on an unused symbol?

[PATCH] D78457: [analyzer][Z3-refutation] Fix refutation BugReporterVisitor bug and refactor

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. > If a symbol is unused and garbage collected then that is not part of the path > constraint that leads to the ErrorNode, is it? It is part of the path, it's just no longer accessible in the program, so it can't be observed at the //end// of the path. But it did play an imp

[PATCH] D78457: [analyzer][Z3-refutation] Fix refutation BugReporterVisitor bug and refactor

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Yup, just take a symbol that is completely unrelated to the bug report, make an impossible constraint on it that our normal constraint manager can't refute, forget about it. That'll be the example. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://

[PATCH] D78000: [ASTImporter] Fix handling of not defined FromRecord in ImportContext(...)

2020-04-20 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. Thanks for the test Shafik, that is pretty self explanatory! Comment at: clang/lib/AST/ASTImporter.cpp:8161 if (auto *ToRecord = dyn_cast(ToDC)) { auto *FromRecord = cast(FromDC); if (ToRecord->isCompleteDefinition()) { Wha

[PATCH] D78477: [profile] Don't crash when forking in several threads

2020-04-20 Thread calixte via Phabricator via cfe-commits
calixte updated this revision to Diff 258686. calixte added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. Export symbol for Darwin target Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78477/new/ https://reviews.l

[PATCH] D78457: [analyzer][Z3-refutation] Fix refutation BugReporterVisitor bug and refactor

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. (sry for the noise, just keep thinking of new things to reply) > To call the `visitor::finalizeVisitor` you would need almost the entire > world. (A ExprEngine, a CompilerInstance, etc.) We already have unittests that mock these objects, cf. `ExprEngineConsumer` (feel free

[PATCH] D76801: [AST] Print a> without extra spaces in C++11 or later.

2020-04-20 Thread Pavel Labath via Phabricator via cfe-commits
labath added a comment. David's example does work with gdb without -Wl,--gdb-index (the member variable is shown), presumably due to the aforementioned fuzzy matching. However, it does not work if gdb-index is enabled, nor with lldb (as lldb is always very index-oriented and assumes equality ev

[clang] 1f67508 - [analyzer] Do not report CFError null dereference for nonnull params.

2020-04-20 Thread Artem Dergachev via cfe-commits
Author: Valeriy Savchenko Date: 2020-04-20T12:33:01+03:00 New Revision: 1f67508b7fedb3a0c8ea55a1f5674346563e2bf2 URL: https://github.com/llvm/llvm-project/commit/1f67508b7fedb3a0c8ea55a1f5674346563e2bf2 DIFF: https://github.com/llvm/llvm-project/commit/1f67508b7fedb3a0c8ea55a1f5674346563e2bf2.d

[clang] 09a1f09 - [analyzer] Do not report NSError null dereference for _Nonnull params.

2020-04-20 Thread Artem Dergachev via cfe-commits
Author: Valeriy Savchenko Date: 2020-04-20T12:33:01+03:00 New Revision: 09a1f090509eb5971ade7089330008c6e4024d30 URL: https://github.com/llvm/llvm-project/commit/09a1f090509eb5971ade7089330008c6e4024d30 DIFF: https://github.com/llvm/llvm-project/commit/09a1f090509eb5971ade7089330008c6e4024d30.d

[PATCH] D76996: [analyzer] Improve PlacementNewChecker

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/CheckPlacementNew.cpp:125 +Msg = std::string(llvm::formatv( +"Possibly not enough {0} bytes for array allocation which " +"requires " f00kat wrote: > martong

[PATCH] D78024: [FileCheck] - Fix the false positive when -implicit-check-not is used with an unknown -check-prefix.

2020-04-20 Thread George Rimar via Phabricator via cfe-commits
grimar added a comment. In D78024#1989287 , @probinson wrote: > I'm just reading this review for the first time, and my thought was, why is > this interacting with implicit-check-not? It was interacting (this patch was committed and fixed the issue), be

[PATCH] D77722: [analyzer] Do not report NSError null dereference for _Nonnull params

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG09a1f090509e: [analyzer] Do not report NSError null dereference for _Nonnull params. (authored by vsavchenko, committed by dergachev.a). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D78286: [analyzer] Track runtime types represented by Obj-C Class objects

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp:113 + +bool isObjCClassType(QualType Type) { + if (const auto *PointerType = dyn_cast(Type)) { `static`? Comment at: clang/lib/StaticAnalyzer/C

[PATCH] D75068: libclang: Add static build support for Windows

2020-04-20 Thread Cristian Adam via Phabricator via cfe-commits
cristian.adam added a comment. @thakis ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75068/new/ https://reviews.llvm.org/D75068 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://li

[PATCH] D78204: [AArch64][SVE] Remove LD1/ST1 dependency on llvm.masked.load/store

2020-04-20 Thread Kerry McLaughlin via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG33ffce5414ec: [AArch64][SVE] Remove LD1/ST1 dependency on llvm.masked.load/store (authored by kmclaughlin). Changed prior to commit: https://reviews.llvm.org/D78204?vs=257702&id=258694#toc Repository:

[PATCH] D77806: [analyzer] Do not report CFError null dereference for nonnull params

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1f67508b7fed: [analyzer] Do not report CFError null dereference for nonnull params. (authored by vsavchenko, committed by dergachev.a). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D78454: [clangd] Highlight related control flow.

2020-04-20 Thread Adam Czachorowski via Phabricator via cfe-commits
adamcz added inline comments. Comment at: clang-tools-extra/clangd/XRefs.cpp:628 +return FD->getBody(); + if (const auto *FD = N.get()) +return FD->getBody(); You are checking for FunctionDecl twice Comment at: clang-tools-extra/clangd

[PATCH] D78481: [ARM] Release notes for the Custom Datapath Extension (CDE)

2020-04-20 Thread Mikhail Maltsev via Phabricator via cfe-commits
miyuki created this revision. miyuki added reviewers: kristof.beyls, simon_tatham. Herald added subscribers: cfe-commits, danielkiss. Herald added a project: clang. This change mentions CDE assembly in the LLVM release notes and CDE intrinsics in both Clang and LLVM release notes. Repository:

[PATCH] D78286: [analyzer] Track runtime types represented by Obj-C Class objects

2020-04-20 Thread Valeriy Savchenko via Phabricator via cfe-commits
vsavchenko marked 7 inline comments as done. vsavchenko added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp:113 + +bool isObjCClassType(QualType Type) { + if (const auto *PointerType = dyn_cast(Type)) { NoQ wrote: > `s

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-04-20 Thread Gabor Marton via Phabricator via cfe-commits
martong accepted this revision. martong added a comment. This revision is now accepted and ready to land. Thanks Endre for the docs! I checked the CI job also, seemed okay, so, I think we are ready! Nice work! Let's do the commit! Comment at: clang/docs/analyzer/user-docs/Cros

[PATCH] D78286: [analyzer] Track runtime types represented by Obj-C Class objects

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp:198 + // 'self' variable of the current class method. + if (ReceiverSVal == Message.getSelfSVal()) { +// In this case, we should return the type of the enclosing

[PATCH] D77221: [AVR] Rework MCU family detection to support more AVR MCUs

2020-04-20 Thread Ayke via Phabricator via cfe-commits
aykevl added inline comments. Comment at: clang/lib/Basic/Targets/AVR.cpp:35 +auto FamilyInfo = llvm::AVR::getFamilyInfo(Family.getValue()); +Builder.defineMacro("__AVR_ARCH__", Twine(FamilyInfo.Number)); + } This should have tests. Take a look at D78117

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-04-20 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/include/clang/CrossTU/CrossTranslationUnit.h:56 + load_threshold_reached, + ambiguous_compile_commands_database }; The two enum values refer to compilation database and compile command database. I'd prefer to

[clang] 8781944 - [analyzer] GenericTaint: Don't expect CallEvent to always have a Decl.

2020-04-20 Thread Artem Dergachev via cfe-commits
Author: Artem Dergachev Date: 2020-04-20T15:31:43+03:00 New Revision: 878194414107e94600de31a11be09a347fb2598b URL: https://github.com/llvm/llvm-project/commit/878194414107e94600de31a11be09a347fb2598b DIFF: https://github.com/llvm/llvm-project/commit/878194414107e94600de31a11be09a347fb2598b.dif

[PATCH] D78286: [analyzer] Track runtime types represented by Obj-C Class objects

2020-04-20 Thread Valeriy Savchenko via Phabricator via cfe-commits
vsavchenko marked an inline comment as done. vsavchenko added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp:198 + // 'self' variable of the current class method. + if (ReceiverSVal == Message.getSelfSVal()) { +// In th

[PATCH] D78487: Explicitly move from llvm::json Array/Object to Value

2020-04-20 Thread Michael Forster via Phabricator via cfe-commits
MForster created this revision. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous. Herald added a project: clang. MForster retitled this revision from "Explicitly move from llvm::json Array to Value" to "Explicitly move from llvm::json Array/Object to Value". MForster a

[clang-tools-extra] b36b889 - Explicitly move from llvm::json Array/Object to Value

2020-04-20 Thread Sam McCall via cfe-commits
Author: Michael Forster Date: 2020-04-20T15:18:52+02:00 New Revision: b36b889a3b81b893c220c1858d16493152b36852 URL: https://github.com/llvm/llvm-project/commit/b36b889a3b81b893c220c1858d16493152b36852 DIFF: https://github.com/llvm/llvm-project/commit/b36b889a3b81b893c220c1858d16493152b36852.dif

[PATCH] D77735: [SveEmitter] Implement builtins for gathers/scatters

2020-04-20 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer accepted this revision. SjoerdMeijer added a reviewer: efriedma. SjoerdMeijer added a comment. This revision is now accepted and ready to land. This is a big patch, but looks reasonable to me. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:7451 + } + llvm_unreachabl

[PATCH] D77845: [analyzer][CallAndMessage][NFC] Change old callbacks to rely on CallEvent

2020-04-20 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus marked an inline comment as done. Szelethus added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp:113-114 const CheckerContext &C) { - assert(Call.getDecl()); + if (!Call.getDecl(

[PATCH] D76291: [Support] Fix formatted_raw_ostream for UTF-8

2020-04-20 Thread Oliver Stannard (Linaro) via Phabricator via cfe-commits
ostannard added a reviewer: kristof.beyls. ostannard added a comment. Ping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76291/new/ https://reviews.llvm.org/D76291 ___ cfe-commits mailing list cfe-com

[PATCH] D78487: Explicitly move from llvm::json Array/Object to Value

2020-04-20 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78487/new/ https://reviews.llvm.org/D78487 __

[PATCH] D72035: [analyzer][NFC] Use CallEvent checker callback in GenericTaintChecker

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Herald added a subscriber: ASDenysPetrov. Comment at: clang/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp:113 const CheckerContext &C) { - const FunctionDecl *FDecl = C.getCalleeDecl(CE); + asser

[PATCH] D76929: [AArch64][SVE] Add SVE intrinsic for LD1RQ

2020-04-20 Thread Sander de Smalen via Phabricator via cfe-commits
sdesmalen added inline comments. Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:11622 + if (VT.isFloatingPoint()) +Load = DAG.getNode(ISD::BITCAST, DL, VT, Load); + kmclaughlin wrote: > sdesmalen wrote: > > I'd expect this to then use `Load.getV

[PATCH] D78487: Explicitly move from llvm::json Array/Object to Value

2020-04-20 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGb36b889a3b81: Explicitly move from llvm::json Array/Object to Value (authored by MForster, committed by sammccall). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.

[clang] 515020c - [SveEmitter] Add more immediate operand checks.

2020-04-20 Thread Sander de Smalen via cfe-commits
Author: Sander de Smalen Date: 2020-04-20T14:41:58+01:00 New Revision: 515020c091e74723ee0876229890d71a8aa79702 URL: https://github.com/llvm/llvm-project/commit/515020c091e74723ee0876229890d71a8aa79702 DIFF: https://github.com/llvm/llvm-project/commit/515020c091e74723ee0876229890d71a8aa79702.di

[PATCH] D78338: [clangd] Enable diagnostic fixes within macro argument expansions.

2020-04-20 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/Diagnostics.cpp:563 +for (auto &FixIt : FixIts) { + // Allow fixits within a single macro-arg expansion to be applied. + if (FixIt.RemoveRange.getBegin().isMacroID() && sammccall wro

[PATCH] D78401: [SveEmitter] IsInsertOp1SVALL and builtins for svqdec[bhwd] and svqinc[bhwd]

2020-04-20 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer accepted this revision. SjoerdMeijer added a comment. This revision is now accepted and ready to land. Looks reasonable Comment at: clang/include/clang/Basic/arm_sve.td:530 +class sat_type { string U = u; string T = t; } +def SIGNED_BYTE : sat_type<"", "c"

[PATCH] D78280: [Analyzer][StreamChecker] Track streams that were not found to be opened.

2020-04-20 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. The high level idea seems great after surveying the analyzer for similar issues, but I might need to think about this a bit longer. @baloghadamsoftware, IteratorChecker needs to solve similar problems, right? Do you have any input on this? Repository: rG LLVM Gith

[PATCH] D76679: [SveEmitter] Add more immediate operand checks.

2020-04-20 Thread Sander de Smalen via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG515020c091e7: [SveEmitter] Add more immediate operand checks. (authored by sdesmalen). Changed prior to commit: https://reviews.llvm.org/D76679?vs=252246&id=258724#toc Repository: rG LLVM Github Mono

[PATCH] D77594: [SveEmitter] Add support for _n form builtins

2020-04-20 Thread Sander de Smalen via Phabricator via cfe-commits
sdesmalen added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77594/new/ https://reviews.llvm.org/D77594 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[PATCH] D78100: [AST] Suppress the spammy "attempt to use a deleted fucntion" diagnostic.

2020-04-20 Thread Haojian Wu via Phabricator via cfe-commits
hokein marked an inline comment as done. hokein added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:12565 + auto RecoveryExpr = + CreateRecoveryExpr(Var->getLocation(), Var->getEndLoc(), {}); + if (RecoveryExpr.get()) sammccall wrote

[clang] fc64539 - [SveEmitter] Add immediate checks for lanes and complex imms

2020-04-20 Thread Sander de Smalen via cfe-commits
Author: Sander de Smalen Date: 2020-04-20T15:10:54+01:00 New Revision: fc645397498037ccb7df230a07e9a8762aaf8c8f URL: https://github.com/llvm/llvm-project/commit/fc645397498037ccb7df230a07e9a8762aaf8c8f DIFF: https://github.com/llvm/llvm-project/commit/fc645397498037ccb7df230a07e9a8762aaf8c8f.di

[PATCH] D78491: Avoid relying on address space zero default parameter in llvm/IR

2020-04-20 Thread Alexander Richardson via Phabricator via cfe-commits
arichardson created this revision. arichardson added reviewers: aykevl, dylanmckay, arsenm, bjope, theraven, jrtc27. Herald added subscribers: cfe-commits, hiraditya, mgorny, wdng. Herald added a reviewer: ctetreau. Herald added a project: clang. APIs such as PointerType::getUnqual/Type::getPoint

[PATCH] D78286: [analyzer] Track runtime types represented by Obj-C Class objects

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp:198 + // 'self' variable of the current class method. + if (ReceiverSVal == Message.getSelfSVal()) { +// In this case, we should return the type of the enclosing

[PATCH] D76932: [AIX] emit .extern and .weak directive linkage

2020-04-20 Thread Digger via Phabricator via cfe-commits
DiggerLin updated this revision to Diff 258732. DiggerLin marked 2 inline comments as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76932/new/ https://reviews.llvm.org/D76932 Files: clang/lib/Driver/ToolChains/AIX.cpp clang/test/Driver/aix

[PATCH] D76680: [SveEmitter] Add immediate checks for lanes and complex imms

2020-04-20 Thread Sander de Smalen via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. sdesmalen marked an inline comment as done. Closed by commit rGfc6453974980: [SveEmitter] Add immediate checks for lanes and complex imms (authored by sdesmalen). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST AC

[PATCH] D77594: [SveEmitter] Add support for _n form builtins

2020-04-20 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer accepted this revision. SjoerdMeijer added a comment. This revision is now accepted and ready to land. Looks reasonable to me Comment at: clang/utils/TableGen/SveEmitter.cpp:212 + bool hasSplat() const { +return Proto.find_first_of("ajfrKLR") != std::string::n

[PATCH] D78495: [nfc] Accept addrspacecast allocas in InitTempAlloca

2020-04-20 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield created this revision. JonChesterfield added reviewers: rjmccall, aaron.ballman, ABataev, jdoerfert, arsenm. Herald added subscribers: cfe-commits, wdng. Herald added a project: clang. [nfc] Accept addrspacecast allocas in InitTempAlloca Changes the precondition to be slightly mor

[PATCH] D72035: [analyzer][NFC] Use CallEvent checker callback in GenericTaintChecker

2020-04-20 Thread Balázs Benics via Phabricator via cfe-commits
steakhal marked 2 inline comments as done. steakhal added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp:113 const CheckerContext &C) { - const FunctionDecl *FDecl = C.getCalleeDecl(CE); +

[clang] 9986b3d - [SveEmitter] Explicitly merge with zero/undef

2020-04-20 Thread Sander de Smalen via cfe-commits
Author: Sander de Smalen Date: 2020-04-20T16:26:20+01:00 New Revision: 9986b3de26d31be26d978194333c44e82873f3ff URL: https://github.com/llvm/llvm-project/commit/9986b3de26d31be26d978194333c44e82873f3ff DIFF: https://github.com/llvm/llvm-project/commit/9986b3de26d31be26d978194333c44e82873f3ff.di

[clang] ee12edc - [Preamble] Allow recursive inclusion of header-guarded mainfile.

2020-04-20 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-04-20T17:28:42+02:00 New Revision: ee12edcb76423c78b55cdddae2edfe45cbb2ccd6 URL: https://github.com/llvm/llvm-project/commit/ee12edcb76423c78b55cdddae2edfe45cbb2ccd6 DIFF: https://github.com/llvm/llvm-project/commit/ee12edcb76423c78b55cdddae2edfe45cbb2ccd6.diff LO

[PATCH] D77735: [SveEmitter] Implement builtins for gathers/scatters

2020-04-20 Thread Sander de Smalen via Phabricator via cfe-commits
sdesmalen added inline comments. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:7601 + llvm::Type *SrcDataTy = getSVEType(TypeFlags); + llvm::Type *OverloadedTy = llvm::VectorType::get( + SVEBuiltinMemEltTy(TypeFlags), SrcDataTy->getVectorElementCount()); nit

[PATCH] D78495: [nfc] Accept addrspacecast allocas in InitTempAlloca

2020-04-20 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. Needs test? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78495/new/ https://reviews.llvm.org/D78495 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.o

[PATCH] D78495: [nfc] Accept addrspacecast allocas in InitTempAlloca

2020-04-20 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added a comment. In D78495#1992404 , @arsenm wrote: > Needs test? I'm not sure how to write said test. How do we normally hit asserts from the clang test suite? This fires a lot in the openmp on amdgcn downstream branch, but I'm happy

[PATCH] D77591: [SveEmitter] Explicitly merge with zero/undef

2020-04-20 Thread Sander de Smalen via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG9986b3de26d3: [SveEmitter] Explicitly merge with zero/undef (authored by sdesmalen). Changed prior to commit: https://reviews.llvm.org/D77591?vs=255501&id=258760#toc Repository: rG LLVM Github Monore

[PATCH] D78338: [clangd] Enable diagnostic fixes within macro argument expansions.

2020-04-20 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked an inline comment as done. sammccall added inline comments. Comment at: clang-tools-extra/clangd/Diagnostics.cpp:563 +for (auto &FixIt : FixIts) { + // Allow fixits within a single macro-arg expansion to be applied. + if (FixIt.RemoveRange.getBegin(

[PATCH] D78366: [Preamble] Allow recursive inclusion of header-guarded mainfile.

2020-04-20 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGee12edcb7642: [Preamble] Allow recursive inclusion of header-guarded mainfile. (authored by sammccall). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78366/n

[PATCH] D78100: [AST] Suppress the spammy "attempt to use a deleted fucntion" diagnostic.

2020-04-20 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. OK LG without changes Comment at: clang/lib/Sema/SemaDecl.cpp:12565 + auto RecoveryExpr = + CreateRecoveryExpr(Var->getLocation(), Var->getEndLoc(), {}); + if (RecoveryExpr.get()) hokein wrote: > sammccall wrote: >

[PATCH] D78501: Add a facility to get system cache directory and use it in clangd

2020-04-20 Thread Vojtěch Štěpančík via Phabricator via cfe-commits
VojtechStep created this revision. VojtechStep added reviewers: sammccall, chandlerc, Bigcheese. VojtechStep added a project: clang-tools-extra. Herald added subscribers: cfe-commits, usaxena95, ormris, kadircet, arphaman, dexonsmith, jkorous, MaskRay, ilya-biryukov, hiraditya. Herald added a proj

[PATCH] D77735: [SveEmitter] Implement builtins for gathers/scatters

2020-04-20 Thread Sander de Smalen via Phabricator via cfe-commits
sdesmalen added inline comments. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:7451 + } + llvm_unreachable("Unknown MemEltType"); +} SjoerdMeijer wrote: > nit: to be consistent, do this in the default clause? Doing that would lead to warning: default label in

[PATCH] D78501: Add a facility to get system cache directory and use it in clangd

2020-04-20 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Thanks! Looks good with a few nits. Once you're done, let me know if I should land this for you (after a few patches landed this way you can apply for commit access: https://llvm.org/do

[PATCH] D78000: [ASTImporter] Fix handling of not defined FromRecord in ImportContext(...)

2020-04-20 Thread Raphael Isemann via Phabricator via cfe-commits
teemperor added a comment. Beside Gabors comment I think I'm happy with this. Thanks! Comment at: clang/unittests/AST/ASTImporterTest.cpp:5939 + +/// An ExternalASTSource that keeps track of the tags is completed. +struct SourceWithCompletedTagList : clang::ExternalASTSource {

[PATCH] D77221: [AVR] Rework MCU family detection to support more AVR MCUs

2020-04-20 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Patch generally looks good, but I agree that it could use some basic tests. You don't need to do specifically test all 20 million releases, but make sure you cover the first and last in the array as well as something in the middle, just to make sure your scans are wor

[PATCH] D78491: Avoid relying on address space zero default parameter in llvm/IR

2020-04-20 Thread Ayke via Phabricator via cfe-commits
aykevl added a comment. I can't give an LGTM but at least from my perspective I very much welcome this change. I am still hitting problems with non-zero address spaces on AVR. One nit in an inline comment. Do you plan on eventually removing `LLVM_NO_IMPLICIT_ADDRESS_SPACE` when the transition

[PATCH] D74387: [SYCL] Defer __float128 type usage diagnostics

2020-04-20 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added a comment. Okay, seems like OpenMP needs unsupported types diagnosing as well. I'm trying to adapt this patch for OpenMP, but it doesn't work out of the box because it diagnoses memcpy like operations, so with the current patch the code like this will cause diagnostics: stru

[PATCH] D78506: [NFC] Common up TargetCodeGenInfo for all PowerPC target.

2020-04-20 Thread Jason Liu via Phabricator via cfe-commits
jasonliu created this revision. jasonliu added reviewers: sfertile, nemanjai, hubert.reinterpretcast, cebowleratibm. Herald added subscribers: steven.zhang, shchenz. jasonliu added a reviewer: PowerPC. jasonliu added a comment. To reviewers: Although the patch is showing changes on various ABIInf

[PATCH] D73290: [PowerPC] Add clang -msvr4-struct-return for 32-bit ELF

2020-04-20 Thread Nemanja Ivanovic via Phabricator via cfe-commits
nemanjai accepted this revision. nemanjai added a comment. Aside from a couple of minor nits that shouldn't require another review, LGTM. Comment at: clang/docs/ClangCommandLineReference.rst:2631 + +Override the default ABI for 32-bit targets to return small structs in +registe

[PATCH] D78286: [analyzer] Track runtime types represented by Obj-C Class objects

2020-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp:198 + // 'self' variable of the current class method. + if (ReceiverSVal == Message.getSelfSVal()) { +// In this case, we should return the type of the enclosing

[PATCH] D78506: [NFC] Common up TargetCodeGenInfo for all PowerPC target.

2020-04-20 Thread Jason Liu via Phabricator via cfe-commits
jasonliu added a comment. To reviewers: Although the patch is showing changes on various ABIInfo classes. But those classes are actually untouched. This patch only touches PowerPC TargetCodeGenInfo related classes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78506/new/ https://review

[PATCH] D78390: [dfsan] Add "DataFlow" option to LLVM_USE_SANITIZER

2020-04-20 Thread Zola Bridges via Phabricator via cfe-commits
zbrid added a comment. Gonna land this and file a bug for the failing tests. The tests shouldn't block anyone upstream since I'm only adding a build mode. I'll do some more digging into those failures in the future. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://rev

[clang] 0f12480 - [dfsan] Add "DataFlow" option to LLVM_USE_SANITIZER

2020-04-20 Thread Zola Bridges via cfe-commits
Author: Zola Bridges Date: 2020-04-20T10:30:52-07:00 New Revision: 0f12480bd13ad2d08b6ef3d64388dd8a12e1a503 URL: https://github.com/llvm/llvm-project/commit/0f12480bd13ad2d08b6ef3d64388dd8a12e1a503 DIFF: https://github.com/llvm/llvm-project/commit/0f12480bd13ad2d08b6ef3d64388dd8a12e1a503.diff

[clang] 9b2ab41 - Revert "[MS] Fix assert handling enum forward decls in hasVisibleDefinition"

2020-04-20 Thread Rumeet Dhindsa via cfe-commits
Author: Rumeet Dhindsa Date: 2020-04-20T10:40:27-07:00 New Revision: 9b2ab41037f45ad92ab4e850591093ffc45d3e10 URL: https://github.com/llvm/llvm-project/commit/9b2ab41037f45ad92ab4e850591093ffc45d3e10 DIFF: https://github.com/llvm/llvm-project/commit/9b2ab41037f45ad92ab4e850591093ffc45d3e10.diff

[PATCH] D78390: [dfsan] Add "DataFlow" option to LLVM_USE_SANITIZER

2020-04-20 Thread Zola Bridges via Phabricator via cfe-commits
zbrid added a comment. Bug: https://bugs.llvm.org/show_bug.cgi?id=45621 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78390/new/ https://reviews.llvm.org/D78390 ___ cfe-commits mailing list cfe-commits

[PATCH] D78390: [dfsan] Add "DataFlow" option to LLVM_USE_SANITIZER

2020-04-20 Thread Zola Bridges via Phabricator via cfe-commits
zbrid updated this revision to Diff 258789. zbrid added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78390/new/ https://reviews.llvm.org/D78390 Files: clang/docs/DataFlowSanitizer.rst libcxx/CMakeLists.txt libcxx/utils/lib

[PATCH] D78509: [AArch64][SVE] Add addressing mode for contiguous loads & stores

2020-04-20 Thread Kerry McLaughlin via Phabricator via cfe-commits
kmclaughlin created this revision. kmclaughlin added reviewers: sdesmalen, fpetrogalli, efriedma. Herald added subscribers: danielkiss, psnobl, rkruppe, hiraditya, kristof.beyls, tschuett. Herald added a reviewer: rengolin. Herald added a project: LLVM. This patch adds the register + register add

[PATCH] D78390: [dfsan] Add "DataFlow" option to LLVM_USE_SANITIZER

2020-04-20 Thread Zola Bridges via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0f12480bd13a: [dfsan] Add "DataFlow" option to LLVM_USE_SANITIZER (authored by zbrid). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78390/new/ https://revi

[PATCH] D78508: [Clang] Allow long as size_t printf argument on 32-bit Windows platforms.

2020-04-20 Thread Jacek Caban via Phabricator via cfe-commits
jacek created this revision. jacek added a reviewer: clang. Herald added subscribers: cfe-commits, mstorsjo. Herald added a project: clang. On 32-bit Windows platform, int and long is mixed all over the place in platform headers. The most notable example is SIZE_T, which is unsigned long, unlike

[PATCH] D77229: [Analyzer][WIP] Avoid handling of LazyCompundVals in IteratorModeling

2020-04-20 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 258798. baloghadamsoftware added a comment. I commented out lines which prevent creation of `StackFrameContext` for non-inlined functions. Now everything works regarding the iterator checkers. I also simplified things and created new methods for `

[PATCH] D78509: [AArch64][SVE] Add addressing mode for contiguous loads & stores

2020-04-20 Thread Francesco Petrogalli via Phabricator via cfe-commits
fpetrogalli requested changes to this revision. fpetrogalli added a comment. This revision now requires changes to proceed. Hi @kmclaughlin , thank you for working on this! The patch LGTM, but please consider renaming the multiclass for the non faulting loads like I suggested. The rest of the fe

[PATCH] D77156: [CMAKE] Plumb include_directories() into tablegen()

2020-04-20 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. Herald added a subscriber: frgossen. I'm not sure this is actually the right approach. Adding the directory's `INCLUDE_DIRECTORIES` option also adds any path added with `include_directories`, which includes system paths and other locations that shouldn't ever have tablege

[PATCH] D77776: [Driver] Default to libc++ on FreeBSD

2020-04-20 Thread Ed Maste via Phabricator via cfe-commits
emaste added a comment. In D6#1981271 , @jbeich wrote: > - Limit the scope to `-stdlib` > > In D6#1972543 , @dim wrote: > > > the lowest supported version, which is currently 10 > > > Where is this defined?

[PATCH] D77776: [Driver] Default to libc++ on FreeBSD

2020-04-20 Thread Ed Maste via Phabricator via cfe-commits
emaste accepted this revision. emaste added a comment. This revision is now accepted and ready to land. Looks ok to me Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D6/new/ https://reviews.llvm.org/D6 _

[PATCH] D78509: [AArch64][SVE] Add addressing mode for contiguous loads & stores

2020-04-20 Thread Francesco Petrogalli via Phabricator via cfe-commits
fpetrogalli accepted this revision. fpetrogalli added a comment. This revision is now accepted and ready to land. I think I made a mess with the Actions for this review! I mean to accept it, not to enforce the nit comments! Francesco Repository: rG LLVM Github Monorepo CHANGES SINCE LAST AC

[PATCH] D78501: Add a facility to get system cache directory and use it in clangd

2020-04-20 Thread Vojtěch Štěpančík via Phabricator via cfe-commits
VojtechStep updated this revision to Diff 258805. VojtechStep edited the summary of this revision. VojtechStep added a comment. @sammccall I think I fixed all raised issues. Let me know if there is anything else I can do, otherwise feel free to commit it. Also Note to self: Once this is pushed t

[clang-tools-extra] 6529b0c - [clangd] Enable diagnostic fixes within macro argument expansions.

2020-04-20 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-04-20T21:18:31+02:00 New Revision: 6529b0c48aab83bdada1d21a79da13b0971d1aec URL: https://github.com/llvm/llvm-project/commit/6529b0c48aab83bdada1d21a79da13b0971d1aec DIFF: https://github.com/llvm/llvm-project/commit/6529b0c48aab83bdada1d21a79da13b0971d1aec.diff LO

[clang] 85cca94 - [SemaObjC] Forbid storing an unboxed integer literal in an NSNumber

2020-04-20 Thread Erik Pilkington via cfe-commits
Author: Erik Pilkington Date: 2020-04-20T15:22:51-04:00 New Revision: 85cca945b4c93ecfd3f3bb7a7b2d5fa4104c3560 URL: https://github.com/llvm/llvm-project/commit/85cca945b4c93ecfd3f3bb7a7b2d5fa4104c3560 DIFF: https://github.com/llvm/llvm-project/commit/85cca945b4c93ecfd3f3bb7a7b2d5fa4104c3560.dif

[PATCH] D78495: [nfc] Accept addrspacecast allocas in InitTempAlloca

2020-04-20 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. You're not testing an assertion, you're testing that code is generated correctly for some file on amdgcn. Just write an ordinary IR-generation test that currently crashes and this test fixes. This is not an NFC change. Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D78511: [Driver][doc] Document option -mtune as a no-op. NFC.

2020-04-20 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer created this revision. SjoerdMeijer added a reviewer: dblaikie. This is a doc change documenting that option -mtune does not perform any CPU type specific tuning but exists for compatability reasons with GCC. https://reviews.llvm.org/D78511 Files: clang/docs/ClangCommandLineRefe

[PATCH] D78338: [clangd] Enable diagnostic fixes within macro argument expansions.

2020-04-20 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6529b0c48aab: [clangd] Enable diagnostic fixes within macro argument expansions. (authored by sammccall). Changed prior to commit: https://reviews.llvm.org/D78338?vs=258202&id=258812#toc Repository:

[PATCH] D78066: [SemaObjC] Forbid storing an unboxed integer literal in an NSNumber

2020-04-20 Thread Erik Pilkington via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG85cca945b4c9: [SemaObjC] Forbid storing an unboxed integer literal in an NSNumber (authored by erik.pilkington). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST AC

[PATCH] D78511: [Driver][doc] Document option -mtune as a no-op. NFC.

2020-04-20 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added inline comments. Comment at: clang/docs/ClangCommandLineReference.rst:2738 +Accepts any value for compatability reasons with GCC, thus not performing any CPU type specific tuning. + "Accepts any value, for compatibility with GCC. Does not per

[PATCH] D78513: [hip] Claim builtin type `__float128` supported if the host target supports it.

2020-04-20 Thread Michael Liao via Phabricator via cfe-commits
hliao created this revision. hliao added reviewers: tra, yaxunl. Herald added subscribers: cfe-commits, kerbowa, nhaehnle, jvesely. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D78513 Files: clang/lib/Basic/Targets/AMDGPU.cpp clang/test/SemaCU

[PATCH] D78511: [Driver][doc] Document option -mtune as a no-op. NFC.

2020-04-20 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer updated this revision to Diff 258823. SjoerdMeijer added a comment. Cheers, that's probably what I wanted to say. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78511/new/ https://reviews.llvm.org/D78511 Files: clang/docs/ClangCommandLineReference.rst clang/include/clan

  1   2   >