jmorse wrote:
Indeed, that's a pattern we've seen elsewhere in the instruction APIs -- you
can select whether you want an instruction inserted into a block or not by
whether you pass an instruction pointer or nullptr in. However, without a
common "no-such-location" instruction iterator (or by
jmorse wrote:
NB, I'm looking less likely to have time for this soon; if you're able to add
some coverage to the unit tests (there'll be somewhere using those DIBuilder
APIs that can duplicated to use iterator insertion instead), it'll speed things
up.
https://github.com/llvm/llvm-project/pul
jmorse wrote:
Prototype here
https://github.com/jmorse/llvm-project/commit/8e68a722e0e2925f042cd6479f8b86578ba3042d
, is that the sort of thing that would be useful? It's lacking unit test
coverage right now.
https://github.com/llvm/llvm-project/pull/124287
___
jmorse wrote:
Ooooff, yeah we missed that. I think (90% confident) that overloading the
relevant DIBuilder methods with iterator-taking versions should work fine, and
we should be able to pick that into llvm20 before rc1, we'll look at it
momentarily.
(In theory downstream compatibility isn't
https://github.com/jmorse closed
https://github.com/llvm/llvm-project/pull/124287
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/jmorse updated
https://github.com/llvm/llvm-project/pull/124287
>From 3d2aa2734d6cb49c43565e3ac8584ba8130fe302 Mon Sep 17 00:00:00 2001
From: Jeremy Morse
Date: Thu, 23 Jan 2025 12:24:14 +
Subject: [PATCH 1/3] [NFC][DebugInfo] Make some block-start-position methods
retur
@@ -448,6 +455,9 @@ BasicBlock::const_iterator
BasicBlock::getFirstNonPHIOrDbgOrAlloca() const {
++InsertPt;
}
}
+
+ // Signal that this comes after any debug records.
+ InsertPt.setHeadBit(false);
jmorse wrote:
The other two call-sites always g
https://github.com/jmorse commented:
Adjusted two call sites, see comments on the others. I've also added an extra
unwrap to CoroSplit.cpp due to it not compiling -- this is going to be reworked
in #124288 anyway.
https://github.com/llvm/llvm-project/pull/124287
___
https://github.com/jmorse edited
https://github.com/llvm/llvm-project/pull/124287
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -1656,7 +1656,8 @@ static Value
*emitSetAndGetSwiftErrorValueAround(Instruction *Call,
Builder.SetInsertPoint(Call->getNextNode());
} else {
auto Invoke = cast(Call);
-Builder.SetInsertPoint(Invoke->getNormalDest()->getFirstNonPHIOrDbg());
+BasicBlock::ite
https://github.com/jmorse updated
https://github.com/llvm/llvm-project/pull/124287
>From 3d2aa2734d6cb49c43565e3ac8584ba8130fe302 Mon Sep 17 00:00:00 2001
From: Jeremy Morse
Date: Thu, 23 Jan 2025 12:24:14 +
Subject: [PATCH 1/2] [NFC][DebugInfo] Make some block-start-position methods
retur
https://github.com/jmorse created
https://github.com/llvm/llvm-project/pull/124287
As part of the "RemoveDIs" work to eliminate debug intrinsics, we're replacing
methods that use Instruction*'s as positions with iterators. A number of these
(such as getFirstNonPHIOrDbg) are sufficiently infreq
@@ -514,7 +513,8 @@ bool
IRForTarget::RewriteObjCConstString(llvm::GlobalVariable *ns_str,
m_CFStringCreateWithBytes, CFSCWB_arguments,
"CFStringCreateWithBytes",
llvm::cast(
- m_entry_instruction_finder.GetValue(function)));
+
@@ -378,8 +378,8 @@ bool IRForTarget::CreateResultVariable(llvm::Function
&llvm_function) {
Constant *initializer = result_global->getInitializer();
-StoreInst *synthesized_store =
-new StoreInst(initializer, new_result_global, first_entry_instruction);
+
https://github.com/jmorse approved this pull request.
LGTM, there are a couple of scenarios here which come close to needing to
store-and-pass-around `BasicBlock::iterator`s to encode a position correctly,
but in all these situations it's correct to just call `getIterator`.
https://github.com/
https://github.com/jmorse edited
https://github.com/llvm/llvm-project/pull/112307
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
16 matches
Mail list logo