Re: [clang-tools-extra] r338017 - [clangd] Proof-of-concept query iterators for Dex symbol index

2018-07-26 Thread Jeremy Morse via cfe-commits
[Resending with cfe-commits@, whoops] Hi Kirill, We believe this patch might be breaking one of the buildbots: http://lab.llvm.org:8011/builders/clang-x86_64-linux- abi-test/builds/29719 Which is complaining about the std::unique_ptr copy constructor being called in DexIndexTests.cpp. It s

r333989 - Detect an incompatible VLA pointer assignment

2018-06-05 Thread Jeremy Morse via cfe-commits
Author: jmorse Date: Tue Jun 5 02:18:26 2018 New Revision: 333989 URL: http://llvm.org/viewvc/llvm-project?rev=333989&view=rev Log: Detect an incompatible VLA pointer assignment For pointer assignments of VLA types, Clang currently detects when array dimensions _lower_ than a variable dimension

Re: r351316 - Reapply [Tooling] Make clang-tool find libc++ dir on mac when running on a file without compilation database.

2019-01-16 Thread Jeremy Morse via cfe-commits
Hi Sam, Unfortunately this trips up a variety of buildbots: http://lab.llvm.org:8011/builders/clang-hexagon-elf/builds/22376 http://lab.llvm.org:8011/builders/clang-x64-ninja-win7/builds/15053 http://lab.llvm.org:8011/builders/clang-hexagon-elf/builds/22376 http://lab.llvm.org:801

Re: r351316 - Reapply [Tooling] Make clang-tool find libc++ dir on mac when running on a file without compilation database.

2019-01-16 Thread Jeremy Morse via cfe-commits
We do rather need this working for our downstream merging to continue, and to clear up the buildbots -- without objection I'll drop the "REQUIRES: system-darwin" line in there. Depending on what's actually supposed to be tested that might be sufficient, but please do follow up. -- Thanks, Jeremy

r351360 - Add a REQUIRES: darwin line for a mac test.

2019-01-16 Thread Jeremy Morse via cfe-commits
Author: jmorse Date: Wed Jan 16 09:41:29 2019 New Revision: 351360 URL: http://llvm.org/viewvc/llvm-project?rev=351360&view=rev Log: Add a REQUIRES: darwin line for a mac test. This test, apparently for macs, fails on Windows as lit can't emulate the shell subprocess $(which...) correctly. Some o

Re: r351316 - Reapply [Tooling] Make clang-tool find libc++ dir on mac when running on a file without compilation database.

2019-01-16 Thread Jeremy Morse via cfe-commits
Platform REQUIRES added in r351360, please do revert & fix if this test is supposed to work elsewhere. -- Thanks, Jeremy ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: r371663 - Start porting ivfsoverlay tests to Windows

2019-09-12 Thread Jeremy Morse via cfe-commits
Hi Reid, On Wed, Sep 11, 2019 at 9:55 PM Reid Kleckner via cfe-commits wrote: > +// XFAIL: windows Looks like this should be system-windows, the PS4 buildbots [0] have a windows host but target x86_64-scei-ps4, and croak on this change. Assuming no-one else is looking at this, I'll commit a fix

r371726 - Switch "windows" to "system-windows" in some XFAILs

2019-09-12 Thread Jeremy Morse via cfe-commits
Author: jmorse Date: Thu Sep 12 04:19:12 2019 New Revision: 371726 URL: http://llvm.org/viewvc/llvm-project?rev=371726&view=rev Log: Switch "windows" to "system-windows" in some XFAILs The test failure mode appears to be due to the host machine rather than the target. The PS4 buildbots are window

Re: r371663 - Start porting ivfsoverlay tests to Windows

2019-09-12 Thread Jeremy Morse via cfe-commits
On Thu, Sep 12, 2019 at 11:24 AM Jeremy Morse wrote: > Assuming no-one else is looking at this, I'll commit a fix in ~30 mins. r371726 -- Thanks, Jeremy ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/list

Re: [clang-tools-extra] 97c407d - [clangd] Make use of URIs in FileShardedIndex

2020-04-30 Thread Jeremy Morse via cfe-commits
Hi Kadir, I'm seeing a couple of windows buildbots failing to build FileIndexTests.cpp, even after the follow up in 0dedb43153e6: http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/32109 http://lab.llvm.org:8011/builders/clang-x64-windows-msvc/builds/15

[llvm] [clang] [clang-tools-extra] [DebugInfo][RemoveDIs] Don't allocate one DPMarker per instruction (PR #79345)

2024-02-06 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse closed https://github.com/llvm/llvm-project/pull/79345 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang-tools-extra] [clang] [DebugInfo][RemoveDIs] Don't allocate one DPMarker per instruction (PR #79345)

2024-02-06 Thread Jeremy Morse via cfe-commits
jmorse wrote: Landed in ddc4935 https://github.com/llvm/llvm-project/pull/79345 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-02-06 Thread Jeremy Morse via cfe-commits
jmorse wrote: I see what you're saying about the metadata being incorrect; I feel like I've seen it before, but can't pin it down. For the record, all the builds where we saw this assertion were thin/full LTO. I've kicked off a reduction of a large reproducer that I have to hand; I'm not imme

[clang] [dataflow] CXXOperatorCallExpr equal operator might not be a glvalue (PR #80991)

2024-02-07 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse updated https://github.com/llvm/llvm-project/pull/80991 >From 0d03870ef82fac51387c353bbe4e095e431d7ce8 Mon Sep 17 00:00:00 2001 From: Paul Semel Date: Wed, 7 Feb 2024 13:59:40 + Subject: [PATCH] [dataflow] CXXOperatorCallExpr equal operator might not be a glvalue

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-02-12 Thread Jeremy Morse via cfe-commits
jmorse wrote: ``` https://github.com/llvm/llvm-project/pull/75385 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-02-12 Thread Jeremy Morse via cfe-commits
jmorse wrote: Several decades later; I applied this check to the verifier and reduced around it: ``` diff --git a/llvm/lib/IR/Verifier.cpp b/llvm/lib/IR/Verifier.cpp index b1cf81a3dbdc..9e2250b584b1 100644 --- a/llvm/lib/IR/Verifier.cpp +++ b/llvm/lib/IR/Verifier.cpp @@ -1421,6 +1421,9 @@ void V

[llvm] [clang] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-01-31 Thread Jeremy Morse via cfe-commits
jmorse wrote: Rats; we should be able to pin down where the problem originates from -- would you be able to describe what's malformed about the metadata, as it's not clear to us (sorry). We'll probably be able to llvm-reduce (or similar) around that description. Unfortunately IIRC it comes fr

[llvm] [clang] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-01-31 Thread Jeremy Morse via cfe-commits
jmorse wrote: ...ah, actually is it malformed because there's a DICompositeType in the retainedNodes list for a DISubprogram? I remember that the verifier considered that illegal before your patch landed, but not after. https://github.com/llvm/llvm-project/pull/75385 __

[clang-tools-extra] [llvm] [clang] [DebugInfo][RemoveDIs] Don't allocate one DPMarker per instruction (PR #79345)

2024-02-05 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse updated https://github.com/llvm/llvm-project/pull/79345 >From 0620bf77b4a8586dc1aa96d72bd088a3e601edd4 Mon Sep 17 00:00:00 2001 From: Jeremy Morse Date: Wed, 24 Jan 2024 16:33:16 + Subject: [PATCH 1/4] [DebugInfo][RemoveDIs] Don't allocate one DPMarker per instruc

[llvm] [clang] [clang-tools-extra] [DebugInfo][RemoveDIs] Don't allocate one DPMarker per instruction (PR #79345)

2024-02-05 Thread Jeremy Morse via cfe-commits
jmorse wrote: (Note that I've merged main into this branch for various reasons,) I've adjusted `adoptDbgValues` to always clean up the `DPMarker` that it adopts, so that there's no return value for people to accidentally miss. This means that we have to test in `adoptDbgValues` whether we're a

[clang] [clang-tools-extra] [llvm] [DebugInfo][RemoveDIs] Add a DPValue implementation for instcombine sinking (PR #77930)

2024-01-25 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse closed https://github.com/llvm/llvm-project/pull/77930 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-01-16 Thread Jeremy Morse via cfe-commits
jmorse wrote: Hi, We're seeing a crash with this reproducer https://gist.github.com/jmorse/b0248c3c9f9195487ffd7c7431a8d15e llc: llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp:2338: virtual void llvm::DwarfDebug::endFunctionImpl(const llvm::MachineFunction *): Assertion `LScopes.getAbstractScope

[llvm] [clang] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-01-23 Thread Jeremy Morse via cfe-commits
jmorse wrote: Hmmm, that's unexpected -- I reverted the revert (tree here, contains one unrelated commit: https://github.com/jmorse/llvm-project/tree/reapply-localvars-patch) and rebuilt. The assertion-failure occurs just with `llc foobar.ll -o out.o -filetype=obj`, where foobar.ll is the con

[llvm] [clang-tools-extra] [DebugInfo][RemoveDIs] Handle non-instr debug-info in GlobalISel (PR #75228)

2024-01-23 Thread Jeremy Morse via cfe-commits
jmorse wrote: Thanks -- I'm going to land this manually seeing how I don't trust githubs handling of squashing merge commits https://github.com/llvm/llvm-project/pull/75228 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org

[llvm] [clang-tools-extra] [DebugInfo][RemoveDIs] Handle non-instr debug-info in GlobalISel (PR #75228)

2024-01-23 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse closed https://github.com/llvm/llvm-project/pull/75228 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang-tools-extra] [DebugInfo][RemoveDIs] Handle non-instr debug-info in GlobalISel (PR #75228)

2024-01-23 Thread Jeremy Morse via cfe-commits
jmorse wrote: Committed in 087172258a50d5 https://github.com/llvm/llvm-project/pull/75228 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 121a49d - [LiveDebugValues] Add switches for using instr-ref variable locations

2020-08-25 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2020-08-25T14:58:48+01:00 New Revision: 121a49d839d79f5a72be3e22a9d156c9e4b219dc URL: https://github.com/llvm/llvm-project/commit/121a49d839d79f5a72be3e22a9d156c9e4b219dc DIFF: https://github.com/llvm/llvm-project/commit/121a49d839d79f5a72be3e22a9d156c9e4b219dc.diff

Re: [clang] d4934eb - [Syntax] Add iterators over children of syntax trees.

2020-10-28 Thread Jeremy Morse via cfe-commits
Hi Sam, It looks like some Windows buildbots fail to build this, for example: http://lab.llvm.org:8011/#/builders/119/builds/349 In the build step, [Big long cl.exe command line for] C:\buildbot\as-builder-2\x-aarch64\llvm-project\clang\lib\Tooling\Syntax\ComputeReplacements.cpp C:\build

[clang] 651122f - [DebugInfo][InstrRef] Pre-land on-by-default-for-x86 changes

2021-11-30 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2021-11-30T12:40:59Z New Revision: 651122fc4ac92b93f36aab3b194de21065a0c48e URL: https://github.com/llvm/llvm-project/commit/651122fc4ac92b93f36aab3b194de21065a0c48e DIFF: https://github.com/llvm/llvm-project/commit/651122fc4ac92b93f36aab3b194de21065a0c48e.diff LOG:

[clang] 16c6e0f - Quote a python executable path

2020-03-04 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2020-03-04T15:23:48Z New Revision: 16c6e0f387e957d21ab90c8694c11cd269ec7719 URL: https://github.com/llvm/llvm-project/commit/16c6e0f387e957d21ab90c8694c11cd269ec7719 DIFF: https://github.com/llvm/llvm-project/commit/16c6e0f387e957d21ab90c8694c11cd269ec7719.diff LOG:

[clang] d4f9675 - [analyzer] decode() a bytes object to make Python3 happy

2020-03-04 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2020-03-04T17:12:48Z New Revision: d4f9675b5509e26573058318682a9ed5d7aaf320 URL: https://github.com/llvm/llvm-project/commit/d4f9675b5509e26573058318682a9ed5d7aaf320 DIFF: https://github.com/llvm/llvm-project/commit/d4f9675b5509e26573058318682a9ed5d7aaf320.diff LOG:

[clang] 6c0a160 - Rename a flang test case

2019-10-30 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2019-10-30T13:29:47Z New Revision: 6c0a160c2d33e54aecf1538bf7c85d8da92051be URL: https://github.com/llvm/llvm-project/commit/6c0a160c2d33e54aecf1538bf7c85d8da92051be DIFF: https://github.com/llvm/llvm-project/commit/6c0a160c2d33e54aecf1538bf7c85d8da92051be.diff LOG:

Re: [PATCH] D63607: [clang][driver] Add basic --driver-mode=flang support for fortran

2019-10-30 Thread Jeremy Morse via cfe-commits
FYI, in llvmorg-10-init-8612-g6c0a160c2d3 [0] I've renamed one of the two files, Windows too has a case-insensitive filesystem layer and this broke our CI. (I think I've preserved the original intention of the tests). [0] https://github.com/llvm/llvm-project/commit/6c0a160c2d33e54aecf1538bf7c85d8

[clang] 6b45e1b - Revert "[clang] Report sanitizer blacklist as a dependency in cc1"

2019-11-08 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2019-11-08T12:07:42Z New Revision: 6b45e1bc11e91ea7b57a6ab1c19461a86dba33f8 URL: https://github.com/llvm/llvm-project/commit/6b45e1bc11e91ea7b57a6ab1c19461a86dba33f8 DIFF: https://github.com/llvm/llvm-project/commit/6b45e1bc11e91ea7b57a6ab1c19461a86dba33f8.diff LOG:

Re: [clang] 03b84e4 - [clang] Report sanitizer blacklist as a dependency in cc1

2019-11-08 Thread Jeremy Morse via cfe-commits
Hi Jan, As the dfsan tests have been failing for a bit, I've reverted this in 6b45e1bc, and the follow-up patch in d6be9273c, to clear the buildbots. -- Thanks, Jeremy ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bi

Re: [clang] 03b84e4 - [clang] Report sanitizer blacklist as a dependency in cc1

2019-11-08 Thread Jeremy Morse via cfe-commits
Hi Jan, The x86_64 sanitizer was failing: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux/builds/24326 And then immediately after the reverts landed: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux/builds/24327 check-dfsan passes. I don't have any explanation as to wh

[clang] 737394c - Revert "clang: Treat ieee mode as the default for denormal-fp-math"

2020-03-05 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2020-03-05T10:55:24Z New Revision: 737394c490444e968a6f640b99a6614567ca7f28 URL: https://github.com/llvm/llvm-project/commit/737394c490444e968a6f640b99a6614567ca7f28 DIFF: https://github.com/llvm/llvm-project/commit/737394c490444e968a6f640b99a6614567ca7f28.diff LOG:

Re: [clang] c64ca93 - clang: Treat ieee mode as the default for denormal-fp-math

2020-03-05 Thread Jeremy Morse via cfe-commits
Hi Matt, FYI several build bots tripped on this commit: http://lab.llvm.org:8011/builders/clang-x86_64-debian-fast/builds/24703/ http://lab.llvm.org:8011/builders/clang-cmake-x86_64-avx2-linux/builds/13465/ http://lab.llvm.org:8011/builders/clang-with-lto-ubuntu/builds/15994/

[clang] [DebugInfo] Make a test more robust (PR #106463)

2024-09-04 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/106463 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [DebugInfo][RemoveDIs] Use iterator-inserters in clang (PR #102006)

2024-08-09 Thread Jeremy Morse via cfe-commits
jmorse wrote: (I can't replicate the buildkite windows failure locally, will commit and see what actually goes wrong) https://github.com/llvm/llvm-project/pull/102006 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[clang] [DebugInfo][RemoveDIs] Use iterator-inserters in clang (PR #102006)

2024-08-09 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse closed https://github.com/llvm/llvm-project/pull/102006 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] d12250c - [NFC][Clang] clang-format a function declaration

2024-08-12 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2024-08-12T09:49:55+01:00 New Revision: d12250ca7bea22ed12caf44fe80b203d83db75bb URL: https://github.com/llvm/llvm-project/commit/d12250ca7bea22ed12caf44fe80b203d83db75bb DIFF: https://github.com/llvm/llvm-project/commit/d12250ca7bea22ed12caf44fe80b203d83db75bb.diff

[clang] [DebugInfo][RemoveDIs] Use iterator-inserters in clang (PR #102006)

2024-08-12 Thread Jeremy Morse via cfe-commits
jmorse wrote: Clang-formatted the declaration I touched in d12250ca7be, the other matters were already present in the code so I've shied away from addressing them. https://github.com/llvm/llvm-project/pull/102006 ___ cfe-commits mailing list cfe-commi

[clang] [PS4/PS5][Driver] Allow -static in PlayStation drivers (PR #102020)

2024-08-12 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. In lieu of Paul for a bit of time, LGTM. I feel like the check for matching the linker-line could be made even stronger (one wonders how many options end with 'ld"', but it's probably good enough. https://github.com/llvm/llvm-project/pull/1

[clang] [llvm] Add option to generate additional debug info for expression dereferencing pointer to pointers. (PR #94100)

2024-06-10 Thread Jeremy Morse via cfe-commits
jmorse wrote: G'day -- we've got some tests for -O0 that, with this patch applied, generate different code with-and-without the `-g` flag, if `-fdebug-info-for-profiling` is enabled. Example godbolt: https://godbolt.org/z/qooo5Eah1 . It seems the intention of this patch is generating additiona

[clang] [llvm] Add option to generate additional debug info for expression dereferencing pointer to pointers. (PR #94100)

2024-06-10 Thread Jeremy Morse via cfe-commits
jmorse wrote: dblaikie wrote: > I hope that isn't the intent, I thought the intent was just [...] Ah, by which I mean "it's not an accident", > By just specifying -g Even without -fdebug-info-for-profiling it is going to > introduce debug variables as a sequence of alloca-store-load too, so i

[clang] (New) Add option to generate additional debug info for expression dereferencing pointer to pointers (PR #95298)

2024-06-13 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse commented: Looks good in principle, with a couple of nits. https://github.com/llvm/llvm-project/pull/95298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] (New) Add option to generate additional debug info for expression dereferencing pointer to pointers (PR #95298)

2024-06-13 Thread Jeremy Morse via cfe-commits
@@ -5746,6 +5746,57 @@ void CGDebugInfo::EmitExternalVariable(llvm::GlobalVariable *Var, Var->addDebugInfo(GVE); } +void CGDebugInfo::EmitPseudoVariable(CGBuilderTy &Builder, + llvm::Instruction *Value, QualType Ty) { + // Only when -g2

[clang] (New) Add option to generate additional debug info for expression dereferencing pointer to pointers (PR #95298)

2024-06-13 Thread Jeremy Morse via cfe-commits
@@ -5746,6 +5746,57 @@ void CGDebugInfo::EmitExternalVariable(llvm::GlobalVariable *Var, Var->addDebugInfo(GVE); } +void CGDebugInfo::EmitPseudoVariable(CGBuilderTy &Builder, + llvm::Instruction *Value, QualType Ty) { + // Only when -g2

[clang] (New) Add option to generate additional debug info for expression dereferencing pointer to pointers (PR #95298)

2024-06-13 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse edited https://github.com/llvm/llvm-project/pull/95298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] (New) Add option to generate additional debug info for expression dereferencing pointer to pointers (PR #95298)

2024-06-14 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM, thanks for rapidly rewriting this. I think dereferencing the insertion iterator with `&**` will eventually need addressing with the move away from intrinsics and insertion, but that can be a matter for when the DIBuilder APIs get depr

[clang] [Debug Info] Fix debug info ptr to ptr test (PR #95637)

2024-06-15 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/95637 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Debug Info] Fix debug info ptr to ptr test (PR #95637)

2024-06-17 Thread Jeremy Morse via cfe-commits
jmorse wrote: @huangjd Thanks for the fix -- FYI it's acceptable to commit patches like this without review (and leave a comment on the original PR) if you wanted to. Given that it's just the format of the test changing, not any of the meaning, it's an "obvious" fix. https://github.com/llvm/l

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-07-23 Thread Jeremy Morse via cfe-commits
jmorse wrote: I think I've nailed down the source of this problem, and it's the matter to do with `LLVMContext::enableDebugTypeODRUniquing` that aeubanks mentioned on https://reviews.llvm.org/D144006. LLVM will unique DICompositeTypes via their ODR-name, which isn't always safe with function-l

[clang] [PS4,PS5][Driver] Check for absent SDK when -nostdlib/-nodefaultlibs (PR #107112)

2024-09-03 Thread Jeremy Morse via cfe-commits
@@ -36,9 +35,6 @@ // RUN: env SCE_ORBIS_SDK_DIR=.. %clang -Winvalid-or-nonexistent-directory -### -emit-ast -isysroot foo -target x86_64-scei-ps4 %s 2>&1 | FileCheck -check-prefix=WARN-ISYSROOT -check-prefix=NO-WARN %s // RUN: env SCE_ORBIS_SDK_DIR=.. %clang -Winvalid-or-nonex

[clang] [DebugInfo][RemoveDIs] Use iterator-inserters in clang (PR #102006)

2024-08-05 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse created https://github.com/llvm/llvm-project/pull/102006 As part of the LLVM effort to eliminate debug-info intrinsics, we're moving to a world where only iterators should be used to insert instructions. This isn't a problem in clang when instructions get generated be

[clang] [DebugInfo][RemoveDIs] Use iterator-inserters in clang (PR #102006)

2024-08-08 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse updated https://github.com/llvm/llvm-project/pull/102006 >From cf967317327aa3971da62a15f357ee5b29268f14 Mon Sep 17 00:00:00 2001 From: Jeremy Morse Date: Mon, 5 Aug 2024 16:21:53 +0100 Subject: [PATCH 1/2] [DebugInfo][RemoveDIs] Use iterator-inserters in clang As part

[clang] [DebugInfo][RemoveDIs] Use iterator-inserters in clang (PR #102006)

2024-08-08 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse updated https://github.com/llvm/llvm-project/pull/102006 >From cf967317327aa3971da62a15f357ee5b29268f14 Mon Sep 17 00:00:00 2001 From: Jeremy Morse Date: Mon, 5 Aug 2024 16:21:53 +0100 Subject: [PATCH 1/3] [DebugInfo][RemoveDIs] Use iterator-inserters in clang As part

[clang] 3c9bcf0 - [Clang][Coroutine][DebugInfo] Relax test ordering requirement

2021-04-26 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2021-04-26T10:07:22+01:00 New Revision: 3c9bcf0e3549d89b31e19e67a5a16babdee2c72d URL: https://github.com/llvm/llvm-project/commit/3c9bcf0e3549d89b31e19e67a5a16babdee2c72d DIFF: https://github.com/llvm/llvm-project/commit/3c9bcf0e3549d89b31e19e67a5a16babdee2c72d.diff

[clang] ea22fdd - [Clang][DebugInfo] Cease turning instruction-referencing off by default

2021-12-22 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2021-12-22T16:30:05Z New Revision: ea22fdd120aeb1bbb9ea96670d70193dc02b2c5f URL: https://github.com/llvm/llvm-project/commit/ea22fdd120aeb1bbb9ea96670d70193dc02b2c5f DIFF: https://github.com/llvm/llvm-project/commit/ea22fdd120aeb1bbb9ea96670d70193dc02b2c5f.diff LOG:

Re: [clang] ea22fdd - [Clang][DebugInfo] Cease turning instruction-referencing off by default

2021-12-22 Thread Jeremy Morse via cfe-commits
On Wed, Dec 22, 2021 at 4:34 PM David Blaikie via cfe-commits wrote: > Is there a way to turn this off now, if it's broken for some user/use case? I > guess using an -mllvm flag, instead of an -Xclang flag? Yup, that should be achieved by "-mllvm -experimental-debug-variable-locations=false", th

[clang] [llvm] [NFC] Replace more DenseMaps with SmallDenseMaps (PR #111836)

2024-10-10 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse created https://github.com/llvm/llvm-project/pull/111836 These DenseMaps all appear as some of the most frequent sources of memory-allocations that could otherwise be accomodated with an initial stack allocation. For simplicity, I've typedef'd one map-type to be Block

[clang] [llvm] [NFC] Replace more DenseMaps with SmallDenseMaps (PR #111836)

2024-10-10 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse updated https://github.com/llvm/llvm-project/pull/111836 >From d2b935e3a537e065b00f543a1792d1979ba413d9 Mon Sep 17 00:00:00 2001 From: Jeremy Morse Date: Thu, 10 Oct 2024 14:17:34 +0100 Subject: [PATCH 1/2] [NFC] Replace more DenseMaps with SmallDenseMaps These DenseM

[clang] [llvm] [NFC] Replace more DenseMaps with SmallDenseMaps (PR #111836)

2024-10-11 Thread Jeremy Morse via cfe-commits
jmorse wrote: Undid the format-changes in this PR. For context: I've been building profiles of all DenseMap allocations across a build of the CTMark suite to find DenseMaps that a) are frequently used and b) usually have a small number of elements, making them good candidates for initial stack

[clang] [llvm] [NFC] Replace more DenseMaps with SmallDenseMaps (PR #111836)

2024-10-11 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse updated https://github.com/llvm/llvm-project/pull/111836 >From d2b935e3a537e065b00f543a1792d1979ba413d9 Mon Sep 17 00:00:00 2001 From: Jeremy Morse Date: Thu, 10 Oct 2024 14:17:34 +0100 Subject: [PATCH 1/3] [NFC] Replace more DenseMaps with SmallDenseMaps These DenseM

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-10-02 Thread Jeremy Morse via cfe-commits
jmorse wrote: Hadn't realised lambda types will pop up everywhere, the cost might be too high. I'll test with building clang and our internal codebases to see if the fix works and what the cost is. > Surely if we can compute a unique mangled name for this local class, we > should use it as th

[clang] [llvm] [X86] Don't request 0x90 nop filling in p2align directives (PR #110134)

2024-10-02 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse closed https://github.com/llvm/llvm-project/pull/110134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Pass default -z options to PS5 linker (PR #113162)

2024-10-22 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/113162 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Update default linking options when `-r` omitted. (PR #113595)

2024-10-29 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/113595 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Supply default linker scripts (PR #114546)

2024-11-04 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/114546 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Pass `-z rodynamic` to the linker (PR #115009)

2024-11-05 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/115009 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Supply libraries and CRT objects to the linker (PR #115497)

2024-11-11 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. > I don't find its current state especially offensive, but I could have a go at > moving the new stuff to some helper functions, perhaps? If it's manageable then it's manageable, > I have a very slight preference to revert this particular

[clang] [PS5][Driver] Allow `-T` to override `--default-script` (PR #116074)

2024-11-13 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/116074 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Pass a target emulation to the linker (PR #114060)

2024-10-31 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/114060 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Supply libraries and CRT objects to the linker (PR #115497)

2024-11-08 Thread Jeremy Morse via cfe-commits
@@ -97,6 +97,60 @@ // Check the default library name. // CHECK-JMC: "--push-state" "--whole-archive" "-lSceJmc_nosubmission" "--pop-state" +// Test that CRT objects and libraries are supplied to the linker and can be +// omitted with -noxxx options. These switches have some i

[clang] [PS5][Driver] Supply libraries and CRT objects to the linker (PR #115497)

2024-11-08 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse edited https://github.com/llvm/llvm-project/pull/115497 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PS5][Driver] Supply libraries and CRT objects to the linker (PR #115497)

2024-11-08 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse commented: Just to check my understanding, things like CHECK-MAIN-CRT-SAME are going to shift the match-position that FileCheck is looking at forwards, so that we have to match in the correct order, yes? I get the feeling that given how much of the construct-a-job log

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2024-10-01 Thread Jeremy Morse via cfe-commits
jmorse wrote: [This keeps on slipping to the back of my TODO list,] I've been enlightened by the comments on #68929 about ODR rules, and that there isn't a violation in the example; it does at least exercise the code path of interest, my summary of which is that the ODR-uniquing of types is ha

[clang] [PS5][Driver] Restore whole-archive state when `-fjmc` (PR #115181)

2024-11-06 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse approved this pull request. LGTM, although maybe CHECK_JMC instead of CHECK_LIB as it seems very JMC specific? No strong opinion. https://github.com/llvm/llvm-project/pull/115181 ___ cfe-commits mailing list cfe-commits@lists

[clang] [Clang] Enable -fextend-lifetimes at -Og (PR #118026)

2024-11-29 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse commented: Some minor test comments, otherwise looking good, https://github.com/llvm/llvm-project/pull/118026 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Enable -fextend-lifetimes at -Og (PR #118026)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -0,0 +1,30 @@ +/// Check that we generate fake uses only when -fextend-lifetimes is set and we +/// are not setting optnone, or when we have optimizations set to -Og and we have +/// not passed -fno-extend-lifetimes. +// RUN: %clang_cc1 -emit-llvm -disable-llvm-passes -O0 -fex

[clang] [Clang] Enable -fextend-lifetimes at -Og (PR #118026)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -441,6 +441,10 @@ Modified Compiler Flags ``memset`` and similar functions for which it is a documented undefined behavior. It is implied by ``-Wnontrivial-memaccess`` +- The ``-Og`` optimization flag now sets ``-fextend-lifetimes``, a new compiler + flag, resulting in

[clang] [Clang] Enable -fextend-lifetimes at -Og (PR #118026)

2024-11-29 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse edited https://github.com/llvm/llvm-project/pull/118026 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Enable -fextend-lifetimes at -Og (PR #118026)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -1834,6 +1834,14 @@ bool CompilerInvocation::ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args, Opts.setInlining(CodeGenOptions::NormalInlining); } + // If we have specified -Og and have not set any explicit -fextend-lifetimes + // value, then default to -fexten

[clang] [Clang] Add "extend lifetime" flags and release note (PR #110000)

2024-11-29 Thread Jeremy Morse via cfe-commits
jmorse wrote: The additions here look fine; however I think there's generally precedent that anything we add needs to have /some/ kind of test, or be covered by something already existing, otherwise we're vulnerable to: * Patch lands, * Someone refactors clang switch handling, * Other patche

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse commented: Tests are looking better (and github has helpfully thrown away most of my comments). I'll look at the code too now. https://github.com/llvm/llvm-project/pull/110102 ___ cfe-commits mailing list cfe-commits@lists.ll

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse edited https://github.com/llvm/llvm-project/pull/110102 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -0,0 +1,61 @@ +// RUN: %clang_cc1 %s -O0 -disable-O0-optnone -emit-llvm -fextend-lifetimes -fsanitize=null -fsanitize-trap=null -o - | FileCheck --check-prefixes=CHECK,NULL --implicit-check-not=ubsantrap %s +// RUN: %clang_cc1 %s -O0 -disable-O0-optnone -emit-llvm -fextend-li

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -0,0 +1,27 @@ +// RUN: %clang %s -S -emit-llvm -fextend-lifetimes -O2 -o - -fno-discard-value-names | FileCheck %s +// +// Check we can correctly produce fake uses for function-level variables even +// when we have a return in a nested conditional and there is no code at the

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -0,0 +1,50 @@ +// RUN: %clang_cc1 %s -O0 -emit-llvm -fextend-this-ptr -o - | FileCheck %s \ +// RUN: --implicit-check-not="call void (...) @llvm.fake.use" +// RUN: %clang_cc1 %s -O0 -emit-llvm -fextend-lifetimes -o - | FileCheck %s \ +// RUN: --implicit-check-not="ca

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse edited https://github.com/llvm/llvm-project/pull/110102 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -1412,6 +1425,39 @@ void CodeGenFunction::EmitAndRegisterVariableArrayDimensions( } } +/// Return the maximum size of an aggregate for which we generate a fake use +/// intrinsic when -fextend-lifetimes is in effect. +static uint64_t maxFakeUseAggregateSize(const ASTCont

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse commented: Looking good, some comments and questions. Having to fiddle with `findDominatingStoreToReturnValue` to make it skip fake-uses is slightly worrying, but it also says it's a heuristic and thus probably not fundamental for correctness? https://github.com/llvm

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -1664,6 +1710,17 @@ CodeGenFunction::EmitAutoVarAlloca(const VarDecl &D) { emission.getOriginalAllocatedAddress(), emission.getSizeForLifetimeMarkers()); + // Analogous to lifetime markers,

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -1664,6 +1710,17 @@ CodeGenFunction::EmitAutoVarAlloca(const VarDecl &D) { emission.getOriginalAllocatedAddress(), emission.getSizeForLifetimeMarkers()); + // Analogous to lifetime markers,

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -1353,6 +1353,19 @@ void CodeGenFunction::EmitLifetimeEnd(llvm::Value *Size, llvm::Value *Addr) { C->setDoesNotThrow(); } +void CodeGenFunction::EmitFakeUse(Address Addr) { + // We do not emit a fake use if we want to apply optnone to this function, + // even if we mig

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-29 Thread Jeremy Morse via cfe-commits
@@ -112,11 +112,11 @@ void EHScopeStack::deallocate(size_t Size) { StartOfData += llvm::alignTo(Size, ScopeStackAlignment); } -bool EHScopeStack::containsOnlyLifetimeMarkers( +bool EHScopeStack::containsOnlyNoopCleanups( EHScopeStack::stable_iterator Old) const { for

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-20 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse commented: Behold, I've added a bunch of pedantic comments about the tests. I think a significant matter is that they all run an LLVM optimisation pipeline, which I believe means they cover too much of the project to be "clang" tests, they're more end-to-end or cross

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-20 Thread Jeremy Morse via cfe-commits
@@ -0,0 +1,43 @@ +// RUN: %clang_cc1 %s -triple=%itanium_abi_triple -O1 -emit-llvm -fextend-lifetimes -o - | FileCheck %s +// Make sure we don't crash compiling a lambda that is not nested in a function. +// We also check that fake uses are properly issued in lambdas. + +int glo

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2024-11-19 Thread Jeremy Morse via cfe-commits
@@ -0,0 +1,22 @@ +// RUN: %clang_cc1 %s -O2 -emit-llvm -fextend-lifetimes -o - | FileCheck %s +// Make sure we don't generate fake.use for non-scalar variables. +// Make sure we don't generate fake.use for volatile variables +// and parameters even when they are scalar. + +struct

  1   2   >