[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-24 Thread Tulio Magno Quites Machado Filho via cfe-commits
https://github.com/tuliom closed https://github.com/llvm/llvm-project/pull/73146 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-23 Thread David Blaikie via cfe-commits
dwblaikie wrote: > OK. I modified this PR in order to only make the changes that fix #73145 . > Sorting will remain broken as it has been since 2021. I will provide another > PR after this one gets merged. Thanks, really appreciate your patience/understanding here - I know it's a bit of a fus

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-23 Thread David Blaikie via cfe-commits
https://github.com/dwblaikie approved this pull request. Sounds reasonable to me, thanks! https://github.com/llvm/llvm-project/pull/73146 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-23 Thread Tulio Magno Quites Machado Filho via cfe-commits
tuliom wrote: OK. I modified this PR in order to only make the changes that fix #73145 . Sorting will remain broken as it has been since 2021. I will provide another PR after this one gets merged. https://github.com/llvm/llvm-project/pull/73146 ___ cf

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-23 Thread Tulio Magno Quites Machado Filho via cfe-commits
https://github.com/tuliom edited https://github.com/llvm/llvm-project/pull/73146 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-23 Thread Tulio Magno Quites Machado Filho via cfe-commits
https://github.com/tuliom updated https://github.com/llvm/llvm-project/pull/73146 >From d0a86b80256a45bfdee790a7aec5a48d2d71e6bb Mon Sep 17 00:00:00 2001 From: Tulio Magno Quites Machado Filho Date: Wed, 22 Nov 2023 14:01:24 -0300 Subject: [PATCH 1/3] [clang] Fix sorting module headers Struct

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread David Blaikie via cfe-commits
dwblaikie wrote: > Splitting it wouldn't help with bisect, as we would continue having a broken > commit. Not sure I understand - presumably this bug has existed for a while, separate from the qsort issue? So fixing it separately seems good so that patches do one thing clearly - makes it easy

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread Tulio Magno Quites Machado Filho via cfe-commits
tuliom wrote: > Sorry, I don't quite understand tnhis - but I guess the second field ( > PathRelativeToRootModuleDirectory ) comparison was to address this bug? @dwblaikie Yes. > It'd probably be good to fix that separately, so it can be discussed in more > detail, etc. The commit is already

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread Tulio Magno Quites Machado Filho via cfe-commits
tuliom wrote: > Sorry, I don't quite understand tnhis @dwblaikie Would you have any questions? I'd be glad to answer them. https://github.com/llvm/llvm-project/pull/73146 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread David Blaikie via cfe-commits
dwblaikie wrote: > This commit also fixes commit > https://github.com/llvm/llvm-project/commit/d3676d4b666ead794fc58bbc7e07aa406dcf487a > that caused all headers to have NameAsWritten set to a 0-length string > without adapting compareModuleHeaders() to the new field. Sorry, I don't quite und

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread Tulio Magno Quites Machado Filho via cfe-commits
tuliom wrote: I've just fixed the code format. https://github.com/llvm/llvm-project/pull/73146 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread Tulio Magno Quites Machado Filho via cfe-commits
https://github.com/tuliom updated https://github.com/llvm/llvm-project/pull/73146 >From d0a86b80256a45bfdee790a7aec5a48d2d71e6bb Mon Sep 17 00:00:00 2001 From: Tulio Magno Quites Machado Filho Date: Wed, 22 Nov 2023 14:01:24 -0300 Subject: [PATCH 1/2] [clang] Fix sorting module headers Struct

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 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 1dd387e10624ece478759ec95c18545d051b7dbe d0a86b80256a45bfdee790a7aec5a48d2d71e6bb --

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clang-modules Author: Tulio Magno Quites Machado Filho (tuliom) Changes Struct Module::Header is not a POD type. As such, qsort() and llvm::array_pod_sort() must not be used to sort it. This became an issue with the new imple

[clang] [clang] Fix sorting module headers (PR #73146)

2023-11-22 Thread Tulio Magno Quites Machado Filho via cfe-commits
https://github.com/tuliom created https://github.com/llvm/llvm-project/pull/73146 Struct Module::Header is not a POD type. As such, qsort() and llvm::array_pod_sort() must not be used to sort it. This became an issue with the new implementation of qsort() in glibc 2.39 that is not guaranteed t