[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -749,13 +752,8 @@ genHTML(const EnumInfo &I, const ClangDocContext &CDCtx) { Out.emplace_back(std::move(Table)); - if (I.DefLoc) { -if (!CDCtx.RepositoryUrl) - Out.emplace_back(writeFileDefinition(*I.DefLoc)); -else - Out.emplace_back( - write

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -57,11 +58,13 @@ static void writeFileDefinition(const ClangDocContext &CDCtx, const Location &L, OS << "*Defined at " << L.Filename << "#" << std::to_string(L.LineNumber) << "*"; } else { -OS << "*Defined at [" << L.Filename << "#" << std::to_string(L.Line

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -276,6 +286,62 @@ // HTML-CIRCLE: return // HTML-CIRCLE: double The perimeter of the circle. +// HTML-SHAPE-PREFIX: class Shape +// HTML-SHAPE-PREFIX-NEXT: +// HTML-SHAPE-PREFIX-NEXT: Defined at line +// HTML-SHAPE-PREFIX-NEXT: https://repository.com/./incl

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -383,4 +449,4 @@ // MD-ALL-FILES: ## [GlobalNamespace](GlobalNamespace{{[\/]}}index.md) // MD-INDEX: # C/C++ Reference -// MD-INDEX: * Namespace: [GlobalNamespace](GlobalNamespace) +// MD-INDEX: * Namespace: [GlobalNamespace](GlobalNamespace) ilovepi wrote

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-21 Thread Paul Kirth via cfe-commits
ilovepi wrote: Yeah that seems reasonable. You'll still want to check the validity of the optionals, which could make the logic a bit less nice, but overall I expect the code to be cleaner than what we have in a lot of places, right now. https://github.com/llvm/llvm-project/pull/131280 ___

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -749,13 +752,8 @@ genHTML(const EnumInfo &I, const ClangDocContext &CDCtx) { Out.emplace_back(std::move(Table)); - if (I.DefLoc) { -if (!CDCtx.RepositoryUrl) - Out.emplace_back(writeFileDefinition(*I.DefLoc)); -else - Out.emplace_back( - write

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -516,15 +518,16 @@ writeFileDefinition(const Location &L, std::make_unique(HTMLTag::TAG_A, std::to_string(L.LineNumber)); // The links to a specific line in the source code use the github / // googlesource notation so it won't work for all hosting pages. - // FIXM

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -57,11 +58,13 @@ static void writeFileDefinition(const ClangDocContext &CDCtx, const Location &L, OS << "*Defined at " << L.Filename << "#" << std::to_string(L.LineNumber) << "*"; } else { -OS << "*Defined at [" << L.Filename << "#" << std::to_string(L.Line

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-22 Thread Paul Kirth via cfe-commits
@@ -3,6 +3,16 @@ // RUN: clang-doc --format=html --output=%t/docs --executor=all-TUs %t/build/compile_commands.json // RUN: FileCheck %s -input-file=%t/docs/index_json.js -check-prefix=JSON-INDEX +// RUN: FileCheck %s -input-file=%t/docs/GlobalNamespace/Shape.html -check-pre

[clang] [Fuchsia] Support PGO (PR #128680)

2025-03-14 Thread Paul Kirth via cfe-commits
@@ -165,33 +175,57 @@ endif() set(BOOTSTRAP_LLVM_ENABLE_LLD ON CACHE BOOL "") set(BOOTSTRAP_LLVM_ENABLE_LTO ON CACHE BOOL "") -set(_FUCHSIA_BOOTSTRAP_TARGETS - check-all - check-clang - check-lld - check-llvm - check-polly - llvm-config - clang-test-depends - lld-test-

[clang] [Fuchsia] Support PGO (PR #128680)

2025-03-14 Thread Paul Kirth via cfe-commits
@@ -165,33 +175,57 @@ endif() set(BOOTSTRAP_LLVM_ENABLE_LLD ON CACHE BOOL "") set(BOOTSTRAP_LLVM_ENABLE_LTO ON CACHE BOOL "") -set(_FUCHSIA_BOOTSTRAP_TARGETS - check-all - check-clang - check-lld - check-llvm - check-polly - llvm-config - clang-test-depends - lld-test-

[clang] [clang][driver] Use rva22u64_v as the default march for Fuchsia targets (PR #131183)

2025-03-17 Thread Paul Kirth via cfe-commits
ilovepi wrote: ### Merge activity * **Mar 17, 7:02 PM EDT**: A user started a stack merge that includes this pull request via [Graphite](https://app.graphite.dev/github/pr/llvm/llvm-project/131183). https://github.com/llvm/llvm-project/pull/131183

[clang] [clang][driver] Use rva22u64_v as the default march for Fuchsia targets (PR #131183)

2025-03-17 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi closed https://github.com/llvm/llvm-project/pull/131183 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-03-18 Thread Paul Kirth via cfe-commits
@@ -494,7 +494,7 @@ genReferencesBlock(const std::vector &References, static std::unique_ptr writeFileDefinition(const Location &L, std::optional RepositoryUrl = std::nullopt) { - if (!L.IsFileInRootDir && !RepositoryUrl) + if (!L.IsFileInRootDir || !Repos

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-03-18 Thread Paul Kirth via cfe-commits
@@ -494,7 +494,7 @@ genReferencesBlock(const std::vector &References, static std::unique_ptr writeFileDefinition(const Location &L, std::optional RepositoryUrl = std::nullopt) { - if (!L.IsFileInRootDir && !RepositoryUrl) + if (!L.IsFileInRootDir || !Repos

[clang-tools-extra] [clang-doc] Add testing without --repository for HTML documentation (PR #131894)

2025-03-18 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi created https://github.com/llvm/llvm-project/pull/131894 https://github.com/llvm/llvm-project/issues/131697 reported a crash when --repository was unused, so make sure we test the project in both configurations. >From 45cd7803d3555c6be8dd41a971ac801d92b41ccf Mon Sep 1

[clang-tools-extra] [clang-doc] Add testing without --repository for HTML documentation (PR #131894)

2025-03-18 Thread Paul Kirth via cfe-commits
ilovepi wrote: * **#131894** https://app.graphite.dev/github/pr/llvm/llvm-project/131894?utm_source=stack-comment-icon"; target="_blank">https://static.graphite.dev/graphite-32x32-black.png"; alt="Graphite" width="10px" height="10px"/> 👈 https://app.graphite.dev/github/pr/llvm/llvm-project/1318

[clang-tools-extra] [clang-doc] Add testing without --repository for HTML documentation (PR #131894)

2025-03-18 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi ready_for_review https://github.com/llvm/llvm-project/pull/131894 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-03-18 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/131698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-03-18 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi requested changes to this pull request. Thanks for the PR, but I don't think this is logic is quite right as it stands. There should also be some accompanying test changes to reflect what's being fixed. As this patch stands it removes basic functionality. https://git

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-03-19 Thread Paul Kirth via cfe-commits
@@ -494,7 +494,7 @@ genReferencesBlock(const std::vector &References, static std::unique_ptr writeFileDefinition(const Location &L, std::optional RepositoryUrl = std::nullopt) { - if (!L.IsFileInRootDir && !RepositoryUrl) + if (!L.IsFileInRootDir || !Repos

[clang] [llvm] [fatlto] Use the ThinLTO default pipeline for FatLTO (PR #134434)

2025-04-04 Thread Paul Kirth via cfe-commits
ilovepi wrote: cc: @mcatanzaro https://github.com/llvm/llvm-project/pull/134434 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [fatlto] Use the ThinLTO default pipeline for FatLTO (PR #134434)

2025-04-04 Thread Paul Kirth via cfe-commits
ilovepi wrote: hmm, I tried adding some of the individual passes, and ran into some other errors. Let me give that another try w/ that PR as an example. https://github.com/llvm/llvm-project/pull/134434 ___ cfe-commits mailing list cfe-commits@lists.l

[clang] [llvm] [fatlto] Use the ThinLTO default pipeline for FatLTO (PR #134434)

2025-04-04 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi updated https://github.com/llvm/llvm-project/pull/134434 >From 80c36153e55398bee01e0167e722c930732b48e7 Mon Sep 17 00:00:00 2001 From: Paul Kirth Date: Fri, 4 Apr 2025 11:49:02 -0700 Subject: [PATCH 1/2] [fatlto] Add coroutine passes when using FatLTO with ThinLTO W

[clang] [clang-tools-extra] [lldb] [llvm] Add test to clang-doc, it can test comments in macro. Original issue is #59819. (PR #132360)

2025-04-05 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,32 @@ +// RUN: rm -rf %t && mkdir -p %t +// RUN: clang-doc --format=md --doxygen --output=%t --executor=standalone %s +// RUN: clang-doc --format=html --doxygen --output=%t --executor=standalone %s +// RUN: FileCheck %s < %t/GlobalNamespace/MyClass.md --check-prefix=MD

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-04-05 Thread Paul Kirth via cfe-commits
ilovepi wrote: > @ilovepi I see you opened a PR to solve the same issue > [here](https://github.com/llvm/llvm-project/pull/131939). Wouldn't be better > if I continue working on it with your suggestions? 😅 I'm fine either way, but I wanted some kind of testing so I could verify the fix. htt

[clang-tools-extra] [clang-doc][NFC] Remove unnecessary directory cleanup (PR #132101)

2025-04-05 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/132101 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Add regression test for test comments in macros (PR #132510)

2025-04-05 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,34 @@ +// Fixes #59819. The underlying problem was fixed in https://reviews.llvm.org/D142560, but this patch adds a proper regression test. +// RUN: rm -rf %t && mkdir -p %t +// RUN: clang-doc --format=md --doxygen --output=%t --executor=standalone %s +// RUN: FileChec

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-04-05 Thread Paul Kirth via cfe-commits
@@ -490,15 +490,17 @@ genReferencesBlock(const std::vector &References, } return Out; } - static std::unique_ptr -writeFileDefinition(const Location &L, -std::optional RepositoryUrl = std::nullopt) { - if (!L.IsFileInRootDir && !RepositoryUrl) +writeF

[clang-tools-extra] [clang-doc][NFC] Remove unnecessary directory cleanup (PR #132101)

2025-04-05 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi updated https://github.com/llvm/llvm-project/pull/132101 >From b00e1c89af66387040727993b1f092c84909eaa2 Mon Sep 17 00:00:00 2001 From: Paul Kirth Date: Wed, 19 Mar 2025 20:58:15 + Subject: [PATCH] [clang-doc][NFC] Remove unnecessary directory cleanup The tests al

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-25 Thread Paul Kirth via cfe-commits
ilovepi wrote: The patch is mostly in good shape. However, there is a build error. you can see it in the premerge CI. looks like you need to update the initialization of the clang doc context objects. Also you need to `git clang-format HEAD~` on your patch to get formatting check to pass. Aft

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-26 Thread Paul Kirth via cfe-commits
ilovepi wrote: > Should I modify `HTMLGeneratorTest.cpp` to test `RepositoryLinePrefix`? > > https://github.com/llvm/llvm-project/blob/7a370748c0928b9ccfe26127e54eb3c1a1827d75/clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp#L179 You can, but please make that its own test. https://g

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-26 Thread Paul Kirth via cfe-commits
ilovepi wrote: The failures on the presubmit bot look unrelated, but you need to update your branch, since it looks like the base revision is broken. https://github.com/llvm/llvm-project/pull/131280 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang-tools-extra] [clang-doc] Allow setting a base directory for hosted pages (PR #132482)

2025-03-26 Thread Paul Kirth via cfe-commits
@@ -1,9 +1,10 @@ function genLink(Ref) { ilovepi wrote: Looks like the current directory was left around when we moved from relative paths to absolute. I don't think we can use that instead of base, though. When I log what the CurrentDirectory is on docs.fuchs

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,75 @@ +//===-- FileHelpersClangDoc.cpp - File Helpers ---*- C++-*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -32,6 +33,183 @@ populateParentNamespaces(llvm::SmallVector &Namespaces, static void populateMemberTypeInfo(MemberTypeInfo &I, const FieldDecl *D); +void getTemplateParameters(const TemplateParameterList *TemplateParams, + llvm::raw_ostream &Str

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -455,8 +473,9 @@ struct EnumValueInfo { // Stores the user-supplied initialization expression for this enumeration // constant. This will be empty for implicit enumeration values. SmallString<16> ValueExpr; - - std::vector Description; /// Comment description of this

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/133161 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -359,6 +371,9 @@ struct FunctionInfo : public SymbolInfo { // Full qualified name of this function, including namespaces and template // specializations. SmallString<16> FullName; + + // Function Prototype + SmallString<256> ProtoType; ilovepi wrot

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -379,7 +394,7 @@ struct RecordInfo : public SymbolInfo { // Full qualified name of this record, including namespaces and template // specializations. SmallString<16> FullName; - + ilovepi wrote: nit: empty space. the newline is fine though. https:/

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,523 @@ +//===-- HTMLMustacheGenerator.cpp - HTML Mustache Generator -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -32,6 +33,183 @@ populateParentNamespaces(llvm::SmallVector &Namespaces, static void populateMemberTypeInfo(MemberTypeInfo &I, const FieldDecl *D); +void getTemplateParameters(const TemplateParameterList *TemplateParams, + llvm::raw_ostream &Str

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi commented: I know you're planing to split this up, but here's some preliminary feedback. https://github.com/llvm/llvm-project/pull/133161 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -152,7 +153,9 @@ struct ScopeChildren { // A base struct for TypeInfos struct TypeInfo { + ilovepi wrote: unnecessary https://github.com/llvm/llvm-project/pull/133161 ___ cfe-commits mailing list cfe-commits@l

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -521,8 +540,9 @@ struct ClangDocContext { // Path of CSS stylesheets that will be copied to OutDirectory and used to // style all HTML files. std::vector UserStylesheets; - // JavaScript files that will be imported in all HTML files. ilovepi wrote: I

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -412,12 +427,15 @@ struct TypedefInfo : public SymbolInfo { void merge(TypedefInfo &&I); TypeInfo Underlying; - - // Inidicates if this is a new C++ "using"-style typedef: + // Underlying type declaration + SmallString<16> TypeDeclaration; + // Indicates if this is

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -32,6 +33,183 @@ populateParentNamespaces(llvm::SmallVector &Namespaces, static void populateMemberTypeInfo(MemberTypeInfo &I, const FieldDecl *D); +void getTemplateParameters(const TemplateParameterList *TemplateParams, + llvm::raw_ostream &Str

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,26 @@ +//===-- FileHelpersClangDoc.h --- File Helpers ---*- C++-*-===// ilovepi wrote: probably putting this in `clang-doc/support/File.h` is a bit more typical. At the least the file shouldn't have helper in the name, and probably do

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -516,15 +518,16 @@ writeFileDefinition(const Location &L, std::make_unique(HTMLTag::TAG_A, std::to_string(L.LineNumber)); // The links to a specific line in the source code use the github / // googlesource notation so it won't work for all hosting pages. - // FIXM

[clang-tools-extra] [clang-doc] Avoid deref of invalid std::optional (PR #131939)

2025-03-26 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi updated https://github.com/llvm/llvm-project/pull/131939 >From b1653a1167f9923d1266d2971773d585251109a1 Mon Sep 17 00:00:00 2001 From: Paul Kirth Date: Tue, 18 Mar 2025 23:38:09 + Subject: [PATCH] [clang-doc] Avoid deref of invalid std::optional Since our existin

[clang-tools-extra] [clang-doc] Correct improper file paths in HTML output (PR #132103)

2025-03-27 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/132103 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -161,8 +164,11 @@ struct TypeInfo { : Type(SymbolID(), Name, InfoType::IT_default, Name, Path) {} bool operator==(const TypeInfo &Other) const { return Type == Other.Type; } - + ilovepi wrote: nit: whitespace on empty line. https://github.com/ll

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-27 Thread Paul Kirth via cfe-commits
@@ -209,6 +215,7 @@ struct FieldTypeInfo : public TypeInfo { return std::tie(Type, Name, DefaultValue) == std::tie(Other.Type, Other.Name, Other.DefaultValue); } + ilovepi wrote: remove https://github.com/llvm/llvm-project/pull/133161 _

[clang-tools-extra] [clang-doc][NFC] refactor out file helpers (PR #134298)

2025-04-07 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,72 @@ +//===-- FileHelpersClangDoc.cpp - File Helpers ---*- C++-*-===// ilovepi wrote: Apparently, we don't use that line anymore. https://llvm.org/docs/CodingStandards.html#file-headers Was brought up here when I saw this the first

[clang-tools-extra] [clang-doc][NFC] refactor out file helpers (PR #134298)

2025-04-07 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/134298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Add Start and End Line Numbers (PR #135081)

2025-04-10 Thread Paul Kirth via cfe-commits
ilovepi wrote: seems like some tests need to be updated w/ the new interface. https://github.com/llvm/llvm-project/pull/135081 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-04-10 Thread Paul Kirth via cfe-commits
ilovepi wrote: FYI the new GSOC period is going to start around May 8. We hope to have new students working on clang-doc, so this patch series needs to be landed by then so we don't have students blocked on this. While there has been some progress on the patch set, its been up in one form or a

[clang] [llvm] Add clang driver changes to support MTI RISC-V (PR #134065)

2025-04-08 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi approved this pull request. LGTM. Probably give @mshockwave a chance to weigh in before landing, though. https://github.com/llvm/llvm-project/pull/134065 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.l

[clang-tools-extra] [clang-doc] Add Start and End Line Numbers (PR #135081)

2025-04-09 Thread Paul Kirth via cfe-commits
@@ -681,7 +675,7 @@ emitInfo(const RecordDecl *D, const FullComment *FC, int LineNumber, } // TODO: remove first call to parseBases, that function should be deleted parseBases(*I, C); -parseBases(*I, C, IsFileInRootDir, PublicOnly, true); +parseBases(*I, C,

[clang-tools-extra] [clang-doc] Add Start and End Line Numbers (PR #135081)

2025-04-09 Thread Paul Kirth via cfe-commits
@@ -238,31 +238,32 @@ struct MemberTypeInfo : public FieldTypeInfo { }; struct Location { - Location(int LineNumber = 0, StringRef Filename = StringRef(), - bool IsFileInRootDir = false) - : LineNumber(LineNumber), Filename(Filename), -IsFileInRootDir(I

[clang-tools-extra] [clang-doc] Add Start and End Line Numbers (PR #135081)

2025-04-09 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi approved this pull request. Mostly good, modulo a few small issues. https://github.com/llvm/llvm-project/pull/135081 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang-tools-extra] [clang-doc] Add Start and End Line Numbers (PR #135081)

2025-04-09 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/135081 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Add Start and End Line Numbers (PR #135081)

2025-04-09 Thread Paul Kirth via cfe-commits
@@ -85,7 +85,7 @@ llvm::Error decodeRecord(const Record &R, std::optional &Field, if (R[0] > INT_MAX) return llvm::createStringError(llvm::inconvertibleErrorCode(), "integer too large to parse"); - Field.emplace((int)R[0], Blob, (bool)

[clang-tools-extra] [clang-doc] Add Start and End Line Numbers (PR #135081)

2025-04-09 Thread Paul Kirth via cfe-commits
@@ -135,7 +135,7 @@ llvm::Error decodeRecord(const Record &R, if (R[0] > INT_MAX) return llvm::createStringError(llvm::inconvertibleErrorCode(), "integer too large to parse"); - Field.emplace_back((int)R[0], Blob, (bool)R[1]); + Field.

[clang-tools-extra] [clang-doc] Allow setting a base directory for hosted pages (PR #132482)

2025-03-28 Thread Paul Kirth via cfe-commits
ilovepi wrote: ### Merge activity * **Mar 28, 3:48 PM EDT**: A user started a stack merge that includes this pull request via [Graphite](https://app.graphite.dev/github/pr/llvm/llvm-project/132482). https://github.com/llvm/llvm-project/pull/132482

[clang-tools-extra] [clang-doc] Allow setting a base directory for hosted pages (PR #132482)

2025-03-28 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi closed https://github.com/llvm/llvm-project/pull/132482 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Add regression test for test comments in macros (PR #132510)

2025-03-28 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,34 @@ +// Fixes #59819. The underlying problem was fixed in https://reviews.llvm.org/D142560, but this patch adds a proper regression test. ilovepi wrote: ```suggestion // Regression test for https://github.com/llvm/llvm-project/issues/59819 ``` htt

[clang-tools-extra] [clang-doc] Add regression test for test comments in macros (PR #132510)

2025-03-28 Thread Paul Kirth via cfe-commits
ilovepi wrote: > I just have submitted a GSoC proposal, can you give me some advices? This is a review thread for this feature. Please ask for feedback on the discourse thread. Typically you'd share a draft of your proposal w/ both prospective mentors over email (e.g. share a google doc or equ

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-28 Thread Paul Kirth via cfe-commits
ilovepi wrote: If the premerge checks pass, then I'll land this. https://github.com/llvm/llvm-project/pull/131280 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Add regression test for test comments in macros (PR #132510)

2025-03-28 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,34 @@ +// Fixes #59819. The underlying problem was fixed in https://reviews.llvm.org/D142560, but this patch adds a proper regression test. +// RUN: rm -rf %t && mkdir -p %t +// RUN: clang-doc --format=md --doxygen --output=%t --executor=standalone %s +// RUN: FileChec

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-28 Thread Paul Kirth via cfe-commits
ilovepi wrote: The branch has conflicts that need to be resolved. While its not a problem, we typically wait for 1 week between reviews to "ping" a reviewer. https://llvm.org/docs/CodeReview.html#lgtm-how-a-patch-is-accepted https://github.com/llvm/llvm-project/pull/131280 ___

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-28 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,227 @@ +{{! +Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +See https://llvm.org/LICENSE.txt for license information. +SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +This file defines the template for cla

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-28 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,47 @@ +{{! +Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +See https://llvm.org/LICENSE.txt for license information. +SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +This file defines the template for gene

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-28 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,104 @@ +//===- mustache.cpp - The LLVM Modular Optimizer ilovepi wrote: Can you remove this since you have a separate PR for it? https://github.com/llvm/llvm-project/pull/133161 ___ cfe-commits mailing list

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-28 Thread Paul Kirth via cfe-commits
@@ -26,5 +26,3 @@ class Shape { */ virtual double perimeter() const = 0; }; - - ilovepi wrote: unrelated https://github.com/llvm/llvm-project/pull/133161 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang-tools-extra] [llvm] [clang-doc] Adds a mustache backend (PR #133161)

2025-03-28 Thread Paul Kirth via cfe-commits
ilovepi wrote: @PeterChou1 when you split this up, please include me, @petrhosek, and @mysterymath. https://github.com/llvm/llvm-project/pull/133161 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-28 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi approved this pull request. LGTM, assuming CI passes. https://github.com/llvm/llvm-project/pull/131280 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Add regression test for test comments in macros (PR #132510)

2025-03-31 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,34 @@ +// Fixes #59819. The underlying problem was fixed in https://reviews.llvm.org/D142560, but this patch adds a proper regression test. +// RUN: rm -rf %t && mkdir -p %t +// RUN: clang-doc --format=md --doxygen --output=%t --executor=standalone %s +// RUN: FileChec

[clang] [clang][driver][NFC] Remove else after return (PR #131182)

2025-03-17 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi closed https://github.com/llvm/llvm-project/pull/131182 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][driver] Use rva22u64_v as the default march for Fuchsia targets (PR #131183)

2025-03-17 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/131183 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][driver][NFC] Remove else after return (PR #131182)

2025-03-17 Thread Paul Kirth via cfe-commits
ilovepi wrote: ### Merge activity * **Mar 17, 1:32 PM EDT**: A user started a stack merge that includes this pull request via [Graphite](https://app.graphite.dev/github/pr/llvm/llvm-project/131182). https://github.com/llvm/llvm-project/pull/131182

[clang] [clang][driver] Use rva22u64_v as the default march for Fuchsia targets (PR #131183)

2025-03-17 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi updated https://github.com/llvm/llvm-project/pull/131183 >From 8ea1c3731175dfcd3c44a4917d1b5f96a81ad9c6 Mon Sep 17 00:00:00 2001 From: Paul Kirth Date: Thu, 13 Mar 2025 10:19:56 -0700 Subject: [PATCH] [clang][driver] Use rva22u64_v as the default march for Fuchsia ta

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -750,11 +754,15 @@ genHTML(const EnumInfo &I, const ClangDocContext &CDCtx) { Out.emplace_back(std::move(Table)); if (I.DefLoc) { -if (!CDCtx.RepositoryUrl) - Out.emplace_back(writeFileDefinition(*I.DefLoc)); -else - Out.emplace_back( - writeF

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -518,10 +519,12 @@ struct ClangDocContext { // the file is in this dir. // URL of repository that hosts code used for links to definition locations. std::optional RepositoryUrl; + // Prefix of line code for repository. + std::optional Reposi

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -57,7 +57,12 @@ static void writeFileDefinition(const ClangDocContext &CDCtx, const Location &L, OS << "*Defined at " << L.Filename << "#" << std::to_string(L.LineNumber) << "*"; } else { -OS << "*Defined at [" << L.Filename << "#" << std::to_string(L.LineN

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -99,6 +99,12 @@ URL of repository that hosts code. Used for links to definition locations.)"), llvm::cl::cat(ClangDocCategory)); +static llvm::cl::opt +RepositoryCodeLinePrefix("repository-line-prefix", llvm::cl::desc(R"( +Prefix of line code for repos

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,342 @@ +// RUN: rm -rf %t && mkdir -p %t/docs %t/build ilovepi wrote: Instead of an entirely new test, I'd prefer to see the differences in the existing test. Ideally expressed in a way that makes it clear what's different between the two. So someth

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -514,17 +514,21 @@ writeFileDefinition(const Location &L, Node->Children.emplace_back(std::make_unique("Defined at line ")); auto LocNumberNode = std::make_unique(HTMLTag::TAG_A, std::to_string(L.LineNumber)); - // The links to a specific line in the source code u

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -514,17 +514,21 @@ writeFileDefinition(const Location &L, Node->Children.emplace_back(std::make_unique("Defined at line ")); auto LocNumberNode = std::make_unique(HTMLTag::TAG_A, std::to_string(L.LineNumber)); - // The links to a specific line in the source code u

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -514,17 +514,21 @@ writeFileDefinition(const Location &L, Node->Children.emplace_back(std::make_unique("Defined at line ")); auto LocNumberNode = std::make_unique(HTMLTag::TAG_A, std::to_string(L.LineNumber)); - // The links to a specific line in the source code u

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-17 Thread Paul Kirth via cfe-commits
@@ -866,11 +878,15 @@ genHTML(const RecordInfo &I, Index &InfoIndex, const ClangDocContext &CDCtx, Out.emplace_back(std::make_unique(HTMLTag::TAG_H1, InfoTitle)); if (I.DefLoc) { -if (!CDCtx.RepositoryUrl) - Out.emplace_back(writeFileDefinition(*I.DefLoc)); -

[clang] [llvm] [fatlto] Add coroutine passes when using FatLTO with ThinLTO (PR #134434)

2025-04-07 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/134434 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][test][NFC] Use -fdriver-only over /dev/null (PR #135255)

2025-04-11 Thread Paul Kirth via cfe-commits
@@ -1,6 +1,6 @@ -// RUN: %clang -fopenacc -S %s -o /dev/null 2>&1 | FileCheck %s -check-prefix=ERROR -// RUN: %clang -fclangir -fopenacc -S %s -o /dev/null 2>&1 | FileCheck %s --allow-empty -check-prefix=NOERROR -// RUN: %clang -fopenacc -fclangir -S %s -o /dev/null 2>&1 | FileC

[clang] [clang][test][NFC] Use -fdriver-only over /dev/null (PR #135255)

2025-04-11 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi closed https://github.com/llvm/llvm-project/pull/135255 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][test][NFC] Use -fdriver-only over /dev/null (PR #135255)

2025-04-11 Thread Paul Kirth via cfe-commits
ilovepi wrote: > This one shouldn't work. We explicitly don't diagnose this in non-codegen > invocations. That's surprising, but if that's the case, I don't think this patch makes much sense. https://github.com/llvm/llvm-project/pull/135255 ___ cfe

[clang-tools-extra] [clang-doc] Pre-commit tests for static members and functions (PR #135456)

2025-04-11 Thread Paul Kirth via cfe-commits
ilovepi wrote: * **#135457** https://app.graphite.dev/github/pr/llvm/llvm-project/135457?utm_source=stack-comment-icon"; target="_blank">https://static.graphite.dev/graphite-32x32-black.png"; alt="Graphite" width="10px" height="10px"/> * **#135456** https://app.graphite.dev/github/pr/llvm/llvm-

[clang-tools-extra] [clang-doc] Pre-commit tests for static members and functions (PR #135456)

2025-04-11 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi ready_for_review https://github.com/llvm/llvm-project/pull/135456 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Pre-commit tests for static members and functions (PR #135456)

2025-04-11 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi created https://github.com/llvm/llvm-project/pull/135456 Issue #59813 mentions that static members are not included in the documentation generated by clang-doc. This patch adds some basic testing for that property, with the current incorrect behavior. Follow up patches

[clang-tools-extra] [clang-doc][NFC] refactor out file helpers (PR #134298)

2025-04-07 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/134298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [fatlto] Use the ThinLTO default pipeline for FatLTO (PR #134434)

2025-04-07 Thread Paul Kirth via cfe-commits
@@ -1692,6 +1692,19 @@ PassBuilder::buildFatLTODefaultPipeline(OptimizationLevel Level, bool ThinLTO, if (ThinLTO && PGOOpt && PGOOpt->Action == PGOOptions::SampleUse) MPM.addPass(buildThinLTODefaultPipeline(Level, /*ImportSummary=*/nullptr)); else { +// ModuleSimp

<    5   6   7   8   9   10   11   12   >