[PATCH] D50870: Close FileEntries of cached files in ModuleManager::addModule().

2018-08-16 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added reviewers: bruno, rsmith, teemperor. Herald added a subscriber: llvm-commits. Close FileEntries of cached files in ModuleManager::addModule(). While investigating why LLDB (which can build hundreds of clang modules during one debug session) was getting

[PATCH] D50870: Close FileEntries of cached files in ModuleManager::addModule().

2018-08-16 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. @bruno: When we last discussed this my plan was to avoid the stat() in lookupModuleFile() for files that were just added to the PCMCache by WriteAST() entirely, but ModuleManager::Modules is a DenseMap and lookupModuleFile() is the easiest way to create a new FileEntry.

[PATCH] D47260: Testcase for dwarf 5 crash/assert when calculating a checksum for an expansion

2018-05-23 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Once we encounter a # directive we are (most likely) looking at some form of preprocessed source and that means that the checksum will inevitably be different than what we would have gotten were we reading the file directly, because of the preprocessing. At this point t

[PATCH] D47097: [DebugInfo] Preserve scope in auto generated StoreInst

2018-05-23 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/CodeGen/CGExpr.cpp:72 + // Set debug location in order to preserve the scope + Alloca->setDebugLoc(Builder.getCurrentDebugLocation()); if (AllocaAddr) vsk wrote: > I think we need to be a bit more careful here.

[PATCH] D47097: [DebugInfo] Preserve scope in auto generated StoreInst

2018-05-23 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/CodeGen/CGExpr.cpp:72 + // Set debug location in order to preserve the scope + Alloca->setDebugLoc(Builder.getCurrentDebugLocation()); if (AllocaAddr) vsk wrote: > aprantl wrote: > > vsk wrote: > > > I think we

[PATCH] D47097: [DebugInfo] Preserve scope in auto generated StoreInst

2018-05-23 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/CodeGen/CGExpr.cpp:72 + // Set debug location in order to preserve the scope + Alloca->setDebugLoc(Builder.getCurrentDebugLocation()); if (AllocaAddr) vsk wrote: > aprantl wrote: > > vsk wrote: > > > aprantl wro

[PATCH] D47097: [DebugInfo] Preserve scope in auto generated StoreInst

2018-05-24 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In https://reviews.llvm.org/D47097#223, @gramanas wrote: > In https://reviews.llvm.org/D47097#149, @probinson wrote: > > > Can we step back a second and better explain what the problem is? With > > current Clang the debug info for this function looks okay to me.

[PATCH] D47260: [DebugInfo] Skip MD5 checksums of preprocessed files

2018-05-25 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Minor comment inline. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:378 return None; + if (Entry.getFile().hasLineDirectives()) { +EmitFileChecksums = false;

[PATCH] D14358: DWARF's forward decl of a template should have template parameters.

2017-09-26 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Does this have to be exposed through the driver or could this be a cc1 option only? Comment at: include/clang/Basic/LangOptions.def:144 BENIGN_LANGOPT(EmitAllDecls , 1, 0, "emitting all declarations") +BENIGN_LANGOPT(EmitFwdTemplateChildren, 1, 0

[PATCH] D38042: EmitAssemblyHelper: CodeGenOpts.DisableLLVMOpts should not overrule CodeGenOpts.VerifyModule.

2017-10-02 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl abandoned this revision. aprantl added a comment. Abandoning in favor of https://reviews.llvm.org/D38184 https://reviews.llvm.org/D38042 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/c

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-03 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. This needs some kind of testcase. Either a unittest or a test-only executable similar to, for example, clang-index-test. https://reviews.llvm.org/D38473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.l

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-10 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. I can commit this for you if John is happy with it. https://reviews.llvm.org/D38473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D51393: Provide a method for generating deterministic IDs for pointers allocated in BumpPtrAllocator

2018-08-29 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: llvm/include/llvm/Support/Allocator.h:292 +const char *P = reinterpret_cast(Ptr); +for (size_t Idx=0; Idx < Slabs.size(); Idx++) { + const char *S = reinterpret_cast(Slabs[Idx]); clang-format?

[PATCH] D51393: Provide a method for generating deterministic IDs for pointers allocated in BumpPtrAllocator

2018-08-29 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Just for consideration: The raw pointers in dumps are sometimes useful while in a debugger session, because you can cast a pointer and dump the object in the debugger. https://reviews.llvm.org/D51393 ___ cfe-commits mailin

[PATCH] D51576: Enable DWARF accelerator tables by default when tuning for lldb (-glldb => -gpubnames)

2018-09-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. This is DWARF5+ only, right? (We shouldn't change the preference of Apple accelerator tables for DWARF 4 and earlier). Repository: rC Clang https://reviews.llvm.org/D51576 ___ cfe-commits mailing list cfe-commits@lists.l

[PATCH] D51576: Enable DWARF accelerator tables by default when tuning for lldb (-glldb => -gpubnames)

2018-09-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In https://reviews.llvm.org/D51576#1223562, @labath wrote: > The interactions here are a bit weird, but the short answer is no, this will > not affect apple tables in any way. Then I have no problem with this patch :-) Repository: rC Clang https://reviews.llvm.org

[PATCH] D51807: Remove all uses of DIFlagBlockByrefStruct from Clang

2018-09-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added a reviewer: debug-info. Herald added a subscriber: JDevlieghere. This patch removes the last reason why DIFlagBlockByrefStruct from Clang by directly implementing the drilling into the member type done in DwarfDebug::DbgVariable::getType() into the f

[PATCH] D51807: Remove all uses of DIFlagBlockByrefStruct from Clang

2018-09-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. ( https://reviews.llvm.org/D51763 is not *really* a dependency, but it's closely related. ) https://reviews.llvm.org/D51807 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

[PATCH] D51910: [Modules] Add platform feature to requires clause

2018-09-11 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: docs/Modules.rst:470 +*platform variant* + A specific os/platform variant (e.g. ``ios``, ``macos``, ``android``, ``win32``, ``linux``, etc) is available. Does this work with platforms+environment combinations, such a

[PATCH] D51990: [DebugInfo] Fix emitting of bit offset for ObjC

2018-09-12 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl requested changes to this revision. aprantl added inline comments. This revision now requires changes to proceed. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:2369 + ? CGM.getObjCRuntime().ComputeBitfieldBitOffset(CGM, ID, Field) + : 0; } e

[PATCH] D51990: [DebugInfo] Fix emitting of bit offset for ObjC

2018-09-12 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:2369 + ? CGM.getObjCRuntime().ComputeBitfieldBitOffset(CGM, ID, Field) + : 0; } else { aprantl wrote: > It might help to attempt some git blame archeology.

[PATCH] D51990: [DebugInfo] Fix emitting of bit offset for ObjC

2018-09-12 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:2369 + ? CGM.getObjCRuntime().ComputeBitfieldBitOffset(CGM, ID, Field) + : 0; } else { JDevlieghere wrote: > JDevlieghere wrote: > > aprantl wrote: > > > a

[PATCH] D50089: [DWARF v4] Suppressing the __debug_ranges section when there are no ranges

2018-07-31 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added inline comments. This revision is now accepted and ready to land. Comment at: apple-accel.cpp:11 +__attribute__((section("1,__text_foo"))) void foo() {} int main (int argc, char const *argv[]) { return argc; } A co

[PATCH] D50122: Complex Variable defined in InitCapture Crash fix

2018-08-01 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: test/SemaCXX/lambda-init-capture-vardefine.cpp:3 +// RUN: %clang_cc1 -std=c++17 -fsyntax-only -verify %s +// expected-no-diagnostics + These kinds of tests that don't check for any output are a bit dangerous, because t

[PATCH] D43044: [DebugInfo] Update Checksum handling in CGDebugInfo

2018-02-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. SGTM. Repository: rC Clang https://reviews.llvm.org/D43044 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi

[PATCH] D43128: Introduce an API for LLDB to compute the default module cache path

2018-02-09 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added reviewers: bruno, jingham. LLDB creates Clang modules and had an incomplete copy of the clang Driver code that compute the -fmodule-cache-path. This patch makes the clang driver code accessible to LLDB. https://reviews.llvm.org/D43128 Files: incl

[PATCH] D42351: Emit DWARF "constructor" calling convention for every supported Clang CC

2018-02-12 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Looks good with one additional change to the test. Side note: We should also add all the LLVM extensions to http://wiki.dwarfstd.org/index.php?title=Vendor_Extensions. Co

[PATCH] D43189: [DebugInfo] Avoid name conflict of generated VLA expression variable.

2018-02-12 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added inline comments. This revision is now accepted and ready to land. Comment at: lib/CodeGen/CGDecl.cpp:1002 getContext().CreateTypeSourceInfo(QT), SC_Auto); + ArtificialDecl->setImplicit(); Thanks! h

[PATCH] D43494: [Modules] Fix creating fake definition data for lambdas.

2018-02-19 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/lib/Serialization/ASTReaderDecl.cpp:2969 +if (!DD && RD->isBeingDefined()) + return nullptr; Perhaps add a comment explaining what's going on in this early exit? https://reviews.llvm.org/D43494

[PATCH] D33705: [CGVTables] Finalize SP before attempting to clone it

2017-06-01 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Looks good.. Are you also planning to change DIBuilder to not finalize subprograms automatically any more (and not insert them into AllSubprograms)? (That will be the more impactful change as it will force all non-clang frontends to make a similar change). https://rev

[PATCH] D33893: Align definition of DW_OP_plus with DWARF spec [2/3]

2017-06-05 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Thanks, this LGTM! https://reviews.llvm.org/D33893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailma

[PATCH] D34121: [ubsan] Teach the pointer overflow check that "p - <= p" (PR33430)

2017-06-14 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/CodeGen/CGExpr.cpp:3010 +return CGF.EmitCheckedInBoundsGEP(ptr, indices, signedIndices, + /*IsSubtraction=*/false, loc, name); } else { Might want to define an `enum { Not

[PATCH] D41259: [debuginfo] Remove temporary FIXME.

2017-12-14 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. I suppose this is fine, please check on the green dragon builders after committing to make sure there's no unexpected fallout. Repository: rC Clang https://reviews.llvm.org/D41259 ___

[PATCH] D41698: [DebugInfo] Enable debug information for C99 VLA types

2018-01-03 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. It would be awesome if you could also add an end-to-end test to the debuginfo-tests repository so we can verify that this actually works in LLDB and GDB. Comment at: lib/CodeGen/CGDebugInfo.cpp:2358 +if (auto *SizeNode = getVLASizeExpressionForTyp

[PATCH] D41743: Debug Info: Support DW_AT_calling_convention on composite types.

2018-01-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added reviewers: echristo, dblaikie, probinson. aprantl added a project: debug-info. Herald added a subscriber: JDevlieghere. This implements the DWARF 5 feature described at http://www.dwarfstd.org/ShowIssue.php?issue=141215.1 This allows a consumer to unde

[PATCH] D41743: Debug Info: Support DW_AT_calling_convention on composite types.

2018-01-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. I related https://reviews.llvm.org/D41039 (Add support for attribute "trivial_abi") which will also benefit from this feature. It is not a hard dependency though, this patch is also useful for standard C++. Repository: rL LLVM https://reviews.llvm.org/D41743

[PATCH] D41743: Debug Info: Support DW_AT_calling_convention on composite types.

2018-01-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Thanks! I think you got me convinced that we should probably stick the calling convention attribute unconditionally on all C++ types. At least in DWARF 5 it should be part of the abbreviation and thus almost free. Repository: rL LLVM https://reviews.llvm.org/D41743

[PATCH] D41743: Debug Info: Support DW_AT_calling_convention on composite types.

2018-01-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 128686. aprantl added a comment. Just unconditionally emit the flags for all CXXRecordDecls. Richard convinced me that a debugger does not want to be in the business of determining the correct calling convention. https://reviews.llvm.org/D41743 Files: l

[PATCH] D41039: Add support for attribute "trivial_abi"

2018-01-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl reopened this revision. aprantl added a comment. I'm sorry, I made a copy&paste error in a the commit message for https://reviews.llvm.org/D41743 and accidentally associated that commit with this review. I suppose I should learn to use arcanist. Reopening, and my apologies for the noise!

[PATCH] D41039: Add support for attribute "trivial_abi"

2018-01-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Unfortunately it looks like I do not have permission to re-upload Akira's last patch to this review. Repository: rL LLVM https://reviews.llvm.org/D41039 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://list

[PATCH] D44605: [Driver] Default to DWARF 5 for Fuchsia

2018-03-19 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. I should also point out that even in DWARF v5 mode LLVM does not yet emit DWARF 5 variants of all sections as DWARF v5 support in LLVM is not yet feature-complete. Repository: rC Clang https://reviews.llvm.org/D44605 __

[PATCH] D47720: [DebugInfo] Inline for without DebugLocation

2018-06-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: test/CodeGen/debug-info-inline-for.c:2 +// RUN: %clang_cc1 -debug-info-kind=limited -emit-llvm -o - %s | FileCheck %s + +int func(int n) { Please add a comment explaining what is being tested here. Repository: rC Cla

[PATCH] D47720: [DebugInfo] Inline for without DebugLocation

2018-06-05 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: test/CodeGen/debug-info-inline-for.c:13 + +// CHECK: ![[DbgLoc]] = !DILocation( Shouldn't you also check *which* location is attached to it? Repository: rC Clang https://reviews.llvm.org/D47720 __

[PATCH] D47097: [DebugInfo] Preserve scope in auto generated StoreInst

2018-06-06 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/CodeGen/CGDecl.cpp:1949 + // Set artificial debug location in order to preserve the scope + auto DL = ApplyDebugLocation::CreateArtificial(*this); Can you make that comment elaborate more about why this is being

[PATCH] D47996: Added modulemap for lldb-mi

2018-06-12 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. That should work. Thanks! https://reviews.llvm.org/D47996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin

[PATCH] D48241: [DebugInfo] Emit ObjC methods as part of interface.

2018-06-15 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Thanks! Is there also a companion patch for LLVM that disables the objc accelerator table? Note that this is not a 100% replacement of the apple_objc accelerator table, since the apple_objc table also lists all methods defined in categories of that interface. Is the id

[PATCH] D48241: [DebugInfo] Emit ObjC methods as part of interface.

2018-06-15 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. > could you provide some examples (just in comments/description in this code > review) of what the DWARF used to look like and what it looks like after this > change? Thus far an Objective-C interface is a DW_TAG_structure_type that only has variables and properties as

[PATCH] D48241: [DebugInfo] Emit ObjC methods as part of interface.

2018-06-15 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:4250 + + SmallVector EltTys; + EltTys.append(InterfaceDecl->getElements().begin(), ``` auto &Elements = InterfaceDecl->getElements(); EltTys.append(Elements.begin(), Elements.e

[PATCH] D48367: [modules] Fix 37878; Autoload subdirectory modulemaps with specific LangOpts

2018-06-20 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/lib/Lex/HeaderSearch.cpp:285 // directory. -loadSubdirectoryModuleMaps(SearchDirs[Idx]); +if (ModMap.getLangOpts().ObjC1 || ModMap.getLangOpts().ObjC2) + loadSubdirectoryModuleMaps(SearchDirs[Idx]); --

[PATCH] D53329: Generate DIFile with main program if source is not available

2018-10-16 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Couldn't you just pass `-main-file-name` to cc1 instead? Repository: rC Clang https://reviews.llvm.org/D53329 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[PATCH] D38061: Set AnonymousTagLocations false for ASTContext if column info is expected not to be used

2018-10-19 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. I have a vague recollection that this column info hack was added to disambiguate two types defined on the same line (which is something that happened more often than one would think because of macro expansion). Did you do the git archeology to ensure that the original

[PATCH] D38061: Set AnonymousTagLocations false for ASTContext if column info is expected not to be used

2018-10-19 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Oh wait, this patch is just for dumping the ASTs? Can you elaborate why this makes it into a binary then? Repository: rC Clang https://reviews.llvm.org/D38061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http:

[PATCH] D38061: Set AnonymousTagLocations false for ASTContext if column info is expected not to be used

2018-10-19 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. RTTI? Repository: rC Clang https://reviews.llvm.org/D38061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D53459: Ensure sanitizer check function calls have a !dbg location

2018-10-19 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added a reviewer: vsk. Function calls without a !dbg location inside a function that has a DISubprogram make it impossible to construct inline information and are rejected by the verifier. This patch ensures that sanitizer check function calls have a !dbg

[PATCH] D53459: Ensure sanitizer check function calls have a !dbg location

2018-10-19 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/CodeGen/CGExpr.cpp:2871 + auto *DI = CGF.getDebugInfo(); + SourceLocation Loc = DI ? DI->getLocation() : SourceLocation(); + auto DL = ApplyDebugLocation::CreateDefaultArtificial(CGF, Loc); vsk wrote: > Why should

[PATCH] D53459: Ensure sanitizer check function calls have a !dbg location

2018-10-22 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 170433. aprantl added a comment. Simplify testcase https://reviews.llvm.org/D53459 Files: lib/CodeGen/CGExpr.cpp test/CodeGenCXX/ubsan-check-debuglocs.cpp Index: test/CodeGenCXX/ubsan-check-debuglocs.cpp ===

[PATCH] D53459: Ensure sanitizer check function calls have a !dbg location

2018-10-22 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 170434. aprantl added a comment. further simplify testcase https://reviews.llvm.org/D53459 Files: lib/CodeGen/CGExpr.cpp test/CodeGenCXX/ubsan-check-debuglocs.cpp Index: test/CodeGenCXX/ubsan-check-debuglocs.cpp ===

[PATCH] D45045: [DebugInfo] Generate debug information for labels.

2018-10-22 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In https://reviews.llvm.org/D45045#1270442, @HsiangKai wrote: > In https://reviews.llvm.org/D45045#1247427, @vitalybuka wrote: > > > Reverted in r343183 > > https://bugs.llvm.org/show_bug.cgi?id=39094 > > > > http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-aut

[PATCH] D54187: Add debuginfo-tests that use cdb on Windows

2018-11-06 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. It would be nice if instead of having a set of windows-only tests, we could wrap cdb similar to llgdb.py wraps LLDB, so these tests run on all platforms. If the Windows debugger is just too different for this to make sense, let me know. https://reviews.llvm.org/D54187

[PATCH] D54187: Add debuginfo-tests that use cdb on Windows

2018-11-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. > I think the only way to realistically make this work for all platforms would > be to separate the source file from the input/output. The source file would > be the test case, and if you wanted to support a different debugger you would > need to supply a different inpu

[PATCH] D54187: Add debuginfo-tests that use cdb on Windows

2018-11-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In https://reviews.llvm.org/D54187#1290293, @zturner wrote: > Especially since as far as I can tell, nobody has even run debuginfo-tests > since late August, because it was actually broken by r341135 on August 30 > (fixed in r346060 yesterday) Can you please refrain f

[PATCH] D54187: Add debuginfo-tests that use cdb on Windows

2018-11-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In https://reviews.llvm.org/D54187#1290298, @probinson wrote: > In https://reviews.llvm.org/D54187#1290294, @zturner wrote: > > > In https://reviews.llvm.org/D54187#1290282, @probinson wrote: > > > > > +gbedwell > > > > > > Just to throw the idea out there, why not abando

[PATCH] D54187: Add debuginfo-tests that use cdb on Windows

2018-11-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In https://reviews.llvm.org/D54187#1290317, @zturner wrote: > In https://reviews.llvm.org/D54187#1290297, @aprantl wrote: > > > In https://reviews.llvm.org/D54187#1290293, @zturner wrote: > > > > > Especially since as far as I can tell, nobody has even run > > > debuginf

[PATCH] D54756: [DebugInfo] NFC Clang test changes for DISubprogram flags

2018-11-28 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Everybody with out-of-tree tests will be excited ;-) Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54756/new/ https://reviews.llvm.org/D54756

[PATCH] D44100: [ASTImporter] Reorder fields after structure import is finished

2018-11-28 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In D44100#1302478 , @a_sidorin wrote: > I don't mean only review. As I guess, you guys have MacOS machines so you can > check if the problem is still present in the updated version. FYI, typically problems with ASTImporter in LL

[PATCH] D55037: [-gmodules] Honor -fdebug-prefix-map in the debug info inside PCMs.

2018-11-28 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added reviewers: bruno, rsmith. This patch passes -fdebug-prefix-map (a feature for renaming source paths in the debug info) through to the per-module codegen options and adds the debug prefix map to the module hash. rdar://problem/46045865 https

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-11-29 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added reviewers: dblaikie, probinson. aprantl added a project: debug-info. As discussed on llvm-dev today, Clang currently emits redundant directories in DIFile entries, such as `.file 1 "/Volumes/Data/llvm" "/Volumes/Data/llvm/tools/clang/test/CodeGen/de

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-11-29 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 175982. aprantl added a comment. Bugfix for LexicalBlockFiles + testcase updates. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55085/new/ https://reviews.llvm.org/D55085 Files: lib/CodeGen/CGDebugInfo.cpp test/CodeGen/debug-info-abspath.c te

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 176148. aprantl added a reviewer: davide. aprantl added a comment. Herald added subscribers: nhaehnle, jvesely. Turns out that my patch had an unintended interaction with the backend diagnostics engine. This is an updated version of the patch that also update

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 176152. aprantl added a comment. Remove debugging code accidentally left in the patch. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55085/new/ https://reviews.llvm.org/D55085 Files: include/llvm/IR/DiagnosticInfo.h lib/CodeGen/MachineLoopInfo.

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Adding a few more reviewers since I'm touching the backend diagnostics. The backend change is supposed to be NFC, but it never hurts to have more feedback. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55085/new/ https://reviews.llvm.org/D55085 _

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl marked an inline comment as done. aprantl added inline comments. Comment at: lib/IR/DiagnosticInfo.cpp:39 #include "llvm/Support/ScopedPrinter.h" +#include "llvm/Support/raw_ostream.h" #include probinson wrote: > Do we use a case-sensitive sort of incl

[PATCH] D55137: Honor -fdebug-prefix-map when creating function names for the debug info.

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added reviewers: dblaikie, davide. aprantl added a project: debug-info. This adds a callback to `PrintingPolicy` to allow `CGDebugInfo` to remap file paths according to `-fdebug-prefix-map`. Otherwise the debug info (particularly function names for C++ lamb

[PATCH] D55137: Honor -fdebug-prefix-map when creating function names for the debug info.

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 176174. aprantl added a comment. fix a comment. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55137/new/ https://reviews.llvm.org/D55137 Files: include/clang/AST/PrettyPrinter.h lib/AST/TypePrinter.cpp lib/CodeGen/CGDebugInfo.cpp lib/CodeGe

[PATCH] D55137: Honor -fdebug-prefix-map when creating function names for the debug info.

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. In D55137#1315133 , @dblaikie wrote: > Can't say I know much abouth the path remapping functionality - what it's > used for, where it's implemented in general, etc - so figure someone with > more of that knowledge might be best o

[PATCH] D55137: Honor -fdebug-prefix-map when creating function names for the debug info.

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 176194. aprantl added a comment. Only initialize `RemapFilePaths` when `DebugPrefixMap` is nonempty. Should be slightly faster. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55137/new/ https://reviews.llvm.org/D55137 Files: include/clang/AST/Pre

[PATCH] D55137: Honor -fdebug-prefix-map when creating function names for the debug info.

2018-11-30 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl marked an inline comment as done. aprantl added inline comments. Comment at: test/CodeGenCXX/debug-prefix-map-lambda.cpp:7 + // CHECK: !DISubprogram(name: "b<(lambda at + // CHECK-SAME: /SOURCE_ROOT/debug-prefix-map-lambda.cpp + // CHECK-SAME: [[@LINE

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-12-04 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl updated this revision to Diff 176677. aprantl added a reviewer: ilya-biryukov. aprantl added a comment. Ilya, this updated revision should restore the original GCOV behavior both for absolute and relative paths. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55085/new/ https://r

[PATCH] D55085: Avoid emitting redundant or unusable directories in DIFile metadata entries

2018-12-07 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Thanks, should be fixed in r348610! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55085/new/ https://reviews.llvm.org/D55085 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mail

[PATCH] D58992: [CUDA][HIP][DebugInfo] Skip reference device function

2019-03-06 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:1755 +} +V = V->stripPointerCasts(); } This wasn't there before... why is this necessary? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION http

[PATCH] D58992: [CUDA][HIP][DebugInfo] Skip reference device function

2019-03-06 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:1755 +} +V = V->stripPointerCasts(); } hliao wrote: > aprantl wrote: > > This wasn

[PATCH] D59197: [NFC][clang][PCH][ObjC] Add some missing `VisitStmt(S); `

2019-03-11 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. How can this change be NFC? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59197/new/ https://reviews.llvm.org/D59197 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm

[PATCH] D54978: Move the SMT API to LLVM

2019-03-25 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. I'm afraid this broke some bots that build with `LLVM_ENABLE_MODULES=1`. For example: http://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/22411/consoleFull#710926295dd1929ea-7054-4089-b7ef-4624c3781fa4 Undefined symbols for architecture x86_64: "llvm::errs()"

[PATCH] D54978: Move the SMT API to LLVM

2019-03-26 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Thanks! The problem with these methods is that LLVM_DUMP_METHOD forces the function to be emitted even if it is not used and Clang modules without local submodule visibility will implicitly include all header files in a module, which will then cause the missing symbol

[PATCH] D49863: [istream] Fix error flags and exceptions propagated from input stream operations

2019-04-02 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. It looks like this may have broken some LLDB data formatters: http://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/22934/ http://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/22934/testReport/junit/lldb-Suite/functionalities_data-formatter_data-formatter-stl_libcx

[PATCH] D60238: Verify that Android targets generate DWARF 4 by default.

2019-04-03 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/test/Driver/debug-options.c:280 // G_STANDALONE: "-debug-info-kind=standalone" +// G_DWARF2: "-dwarf-version=2" // G_DWARF4: "-dwarf-version=4" What's that for? Repository: rG LLVM Github Monorepo CHANGES SI

[PATCH] D60238: Verify that Android targets generate DWARF 4 by default.

2019-04-03 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Good catch! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60238/new/ https://reviews.llvm.org/D60238 __

[PATCH] D54187: Add debuginfo-tests that use cdb on Windows

2019-04-09 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Did anyone take the time to look at dexter and whether it would fit the bill here? It would be great to avoid reimplementing its functionality just to have something that then only works on Windows. My position is that for the kind of very basic end-to-end testing that

[PATCH] D54187: Add debuginfo-tests that use cdb on Windows

2019-04-09 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Okay, so it looks like dexter might be a replacement for the lldgb.py wrapper and would support gdb, lldb, and the visual studio debugger. I think it would be nice to migrate the bulk of the

[PATCH] D58033: Add option for emitting dbg info for call sites

2019-04-15 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: include/clang/Driver/Options.td:919 HelpText<"Do not use jump tables for lowering switches">; +def emit_param_entry_values : Joined<["-"], "femit-param-entry-values">, + Group, I assume that this

[PATCH] D58035: [clang/DIVar] Emit flag for params that have unchanged values

2019-04-15 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/CodeGen/CGDebugInfo.cpp:4537 + CGM.getLangOpts().Optimize) { +for (auto &SP : DeclCache) { + auto *D = SP.first; Just looking at the type declarations in CGDebugInfo.h: Why not iterate over the `SPCach

[PATCH] D58033: Add option for emitting dbg info for call sites

2019-04-16 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. And if we plan to enable it by default, too, perhaps not adding a driver option (CC1 only) is preferable, since we need to maintain compatibility with driver options indefinitely. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58033/new/ https://reviews.llvm.or

[PATCH] D58033: Add option for emitting dbg info for call site parameters

2019-04-22 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. Is there some kind of testcase? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58033/new/ https://reviews.llvm.org/D58033 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman

[PATCH] D61079: Skip type units/type uniquing when we know we're only emitting the type once (vtable-based emission when triggered by a strong vtable, with -fno-standalone-debug)

2019-04-24 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. I hope I'm getting this right, but if I remember correctly, the significant part in this test is what is a FwdDecl as opposed to a definition. The identifiers no longer make it into the debug info and you should see no difference in the produced binaries with this chang

[PATCH] D61140: Copy Argument Passing Restrictions setting when importing a CXXRecordDecl definition

2019-04-25 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Could we test this by doing -dump-ast of From and To and FileCheck-ing the output? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61140/new/ https://reviews.llvm.org/D61140 _

[PATCH] D61438: [ASTImporter] Use llvm::Expected and Error in the importer API

2019-05-08 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:5039 + if (!ToOrErr) +// FIXME: return the error? +consumeError(ToOrErr.takeError()); We don't typically commit FIXME's into LLVM code. Why not just deal wit

[PATCH] D61438: [ASTImporter] Use llvm::Expected and Error in the importer API

2019-05-09 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/include/clang/AST/ASTImporter.h:203 /// context, or the import error. -llvm::Expected Import_New(TypeSourceInfo *FromTSI); -// FIXME: Remove this version. -TypeSourceInfo *Import(TypeSourceInfo *FromTSI); +llvm

[PATCH] D51910: [Modules] Add platform feature to requires clause

2018-09-14 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: docs/Modules.rst:470 +*platform variant* + A specific os/platform variant (e.g. ``ios``, ``macos``, ``android``, ``win32``, ``linux``, etc) is available. aprantl wrote: > Does this work with platforms+environment com

[PATCH] D51910: [Modules] Add platform feature to requires clause

2018-09-14 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: lib/Basic/Module.cpp:101 + // variant (2), the simulator is hardcoded as part of the platform name. Both + // forms above should match "iossimulator" and "ios-simulator" features. + if (Target.getTriple().isOSDarwin() && PlatformEnv.e

[PATCH] D57976: -gmodules: Don't emit incomplete breadcrumbs pointing to nonexistant PCM files.

2019-02-08 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl created this revision. aprantl added reviewers: JDevlieghere, bruno. When a module name is specified as -fmodule-name, that module gets a clang::Module object, but it won't actually be built or imported; it will be textual. CGDebugInfo wouldn't detect this and them emit a DICompileUnit tha

  1   2   3   4   5   6   >