[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-03-11 Thread Aleksei Vetrov via cfe-commits
noxwell wrote: Closing this PR, because these changes are incompatible to DWARF standard, see [83175#issuecomment-1969473992](https://github.com/llvm/llvm-project/pull/83175#issuecomment-1969473992) https://github.com/llvm/llvm-project/pull/83175 ___

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-03-11 Thread Aleksei Vetrov via cfe-commits
https://github.com/noxwell closed https://github.com/llvm/llvm-project/pull/83175 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-03-01 Thread Adrian Prantl via cfe-commits
@@ -0,0 +1,20 @@ +// RUN: mkdir -p %t/src +// RUN: cp %s %t/src/debug-info-debug-prefix-map.c + +// RUN: mkdir -p %t/out +// RUN: cd %t/out +// RUN: %clang_cc1 -debug-info-kind=limited -triple %itanium_abi_triple \ +// RUN: -fdebug-prefix-map="%t/=./"

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-28 Thread Aleksei Vetrov via cfe-commits
noxwell wrote: > Can you add a test for this? I added a test for remapping of absolute path. It passes with this PR and fails on trunk. However, I found much bigger problem. This fix fails test `debug-info-abspath.c`, more specifically the last case, which checks that CU file has absolute

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-28 Thread Aleksei Vetrov via cfe-commits
https://github.com/noxwell updated https://github.com/llvm/llvm-project/pull/83175 >From 731463e1134b0821e518a3e8e521a2d44dd18a8e Mon Sep 17 00:00:00 2001 From: Aleksei Vetrov Date: Tue, 27 Feb 2024 19:50:13 + Subject: [PATCH] [Clang][DebugInfo] Use CGDebugInfo::createFile in

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-28 Thread Aleksei Vetrov via cfe-commits
@@ -628,9 +628,8 @@ void CGDebugInfo::CreateCompileUnit() { // file was specified with an absolute path. if (CSKind) CSInfo.emplace(*CSKind, Checksum); - llvm::DIFile *CUFile = DBuilder.createFile( - remapDIPath(MainFileName), remapDIPath(getCurrentDirname()),

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread David Blaikie via cfe-commits
dwblaikie wrote: Some test coverage would be good to help demonstrate the issue/fix https://github.com/llvm/llvm-project/pull/83175 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread Adrian Prantl via cfe-commits
@@ -628,9 +628,8 @@ void CGDebugInfo::CreateCompileUnit() { // file was specified with an absolute path. if (CSKind) CSInfo.emplace(*CSKind, Checksum); - llvm::DIFile *CUFile = DBuilder.createFile( - remapDIPath(MainFileName), remapDIPath(getCurrentDirname()),

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl commented: Can you add a test for this? https://github.com/llvm/llvm-project/pull/83175 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread Aleksei Vetrov via cfe-commits
https://github.com/noxwell updated https://github.com/llvm/llvm-project/pull/83175 >From 237264fded2b9806d273d7bc5d593a7dd0011850 Mon Sep 17 00:00:00 2001 From: Aleksei Vetrov Date: Tue, 27 Feb 2024 19:50:13 + Subject: [PATCH] [Clang][DebugInfo] Use CGDebugInfo::createFile in

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff fd4204464905be198b158a0f30e5c06cc4ce3686 704f9042bb357cb600894c2a5caf19d0a53cf059 --

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Aleksei Vetrov (noxwell) Changes Use `CGDebugInfo::createFile` wrapper that handles file remapping and corner cases instead of directly using `DBuilder.createFile` in `CGDebugInfo::CreateCompileUnit`. Fixes #83174 --- Full

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you,

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread Aleksei Vetrov via cfe-commits
https://github.com/noxwell created https://github.com/llvm/llvm-project/pull/83175 Use `CGDebugInfo::createFile` wrapper that handles file remapping and corner cases instead of directly using `DBuilder.createFile` in `CGDebugInfo::CreateCompileUnit`. Fixes #83174 >From