https://github.com/augusto2112 closed
https://github.com/llvm/llvm-project/pull/109490
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/augusto2112 updated
https://github.com/llvm/llvm-project/pull/109490
>From b7271f2f4a638a5c03cb28b05bb836ca245acb41 Mon Sep 17 00:00:00 2001
From: Augusto Noronha
Date: Thu, 30 Mar 2023 14:01:36 -0700
Subject: [PATCH] [clang] Add "debug_transparent" attribute
The `debug_tran
augusto2112 wrote:
I accidentally rebased on top of the wrong branch which tagged a lot of people
as reviewers, I'm going to close this PR and open a new one as to not spam a
ton of people.
https://github.com/llvm/llvm-project/pull/109490
___
cfe-com
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
@@ -4160,6 +4178,8 @@ llvm::DISubprogram
*CGDebugInfo::getFunctionFwdDeclOrStub(GlobalDecl GD,
if (Stub) {
Flags |= getCallSiteRelatedAttrs();
SPFlags |= llvm::DISubprogram::SPFlagDefinition;
+if (usesDebugTransparent(FD, CGM))
augusto2112 wrote:
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
pogo59 wrote:
My first thought was "why not use the nodebug attribute" but looking back at
the Phab review, that question was raised and answered there. But I thought it
was worth mentioning here.
https://github.com/llvm/llvm-project/pull/109490
___
@@ -1379,6 +1379,9 @@ void DwarfUnit::applySubprogramAttributes(const
DISubprogram *SP, DIE &SPDie,
if (!SP->getTargetFuncName().empty())
addString(SPDie, dwarf::DW_AT_trampoline, SP->getTargetFuncName());
+ if (SP->isDebugTransparent())
pogo59 wrote:
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
@@ -4160,6 +4178,8 @@ llvm::DISubprogram
*CGDebugInfo::getFunctionFwdDeclOrStub(GlobalDecl GD,
if (Stub) {
Flags |= getCallSiteRelatedAttrs();
SPFlags |= llvm::DISubprogram::SPFlagDefinition;
+if (usesDebugTransparent(FD, CGM))
Michael137 wrote:
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
https://github.com/Michael137 commented:
Seems reasonable to me modulo nits.
We'll also need a test for the "attribute ignored because not DWARF" diagnostic
https://github.com/llvm/llvm-project/pull/109490
___
cfe-commits mailing list
cfe-commits@list
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
@@ -109,6 +110,21 @@ static bool IsArtificial(VarDecl const *VD) {
cast(VD->getDeclContext())->isImplicit());
}
+static bool usesDebugTransparent(const Decl *D, const CodeGenModule &CGM) {
+ if (!D)
+return false;
+
+ if (auto *attr = D->get
https://github.com/Michael137 edited
https://github.com/llvm/llvm-project/pull/109490
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
augusto2112 wrote:
@dwblaikie @AaronBallman this is the "debug_transparent" patch that I opened
last year but didn't get around to finish implementing
(https://reviews.llvm.org/D146595).
The current version addresses the comments left in the phabricator review:
- Changed the name from debug_tr
llvmbot wrote:
@llvm/pr-subscribers-clang-codegen
Author: Augusto Noronha (augusto2112)
Changes
The `debug_transparent` attribute is intended as a hint for debuggers that this
function itself is not interesting, but it calls a function that might be. So,
when stepping in arrives at a fu
https://github.com/augusto2112 created
https://github.com/llvm/llvm-project/pull/109490
The `debug_transparent` attribute is intended as a hint for debuggers that this
function itself is not interesting, but it calls a function that might be. So,
when stepping in arrives at a function with th
20 matches
Mail list logo