Displaying 20 results from an estimated 700 matches similar to: "Pass and Transformation-level debugging in LLVM"
2018 Jun 08
2
RFC: Pass Execution Instrumentation interface
Care to expand a bit on what you mean by per-optimization level? Preferably with a use case.
To me optbisect is a low level developer tool and it doesn't cope well with a crude user level hammer of optimization level.
F.
On Fri, Jun 8, 2018 at 9:12 AM +0300, "Zhizhou Yang" <zhizhouy at google.com<mailto:zhizhouy at google.com>> wrote:
Hi Fedor,
Thanks for replying
2018 Jun 08
2
RFC: Pass Execution Instrumentation interface
Thanks Craig, that's exactly what I mean, stopping at particular changes
inside a pass.
Would you please refer me the discuss about combining opt-bisect with debug
counters? Is it already under implementation?
On Fri, Jun 8, 2018 at 12:19 AM Craig Topper <craig.topper at gmail.com> wrote:
> I think that "level" was referring to what level of granularity the
>
2018 Sep 26
12
OptBisect implementation for new pass manager
Greetings!
As the generic Pass Instrumentation framework for new pass manager is
finally *in*,
I'm glad to start the discussion on implementation of -opt-bisect
through that framework.
As it has already been discovered while porting other features (namely,
-time-passes)
blindly copying the currently existing legacy implementation is most
likely not a perfect
way forward. Now is a chance
2018 Jun 11
2
RFC: Pass Execution Instrumentation interface
I was going to write something up about fine-grained opt-bisect but
didn't get to it last week.
We've had a -pass-max option here for some time and have hand-added
instrumentation to various passes to honor it. It's saved us man-years
of debug time. I was planning on sending it upstream but saw this
effort with pass execution instrumentation and thought it might fit
there.
2018 Sep 26
2
OptBisect implementation for new pass manager
Philip,
It kinda depends on user expectations.
What do you really expect as a result of your compilation when you set
-opt-bisect-limit=X?
Do you just get a resulting IR and scan for the bad pattern?
Then you dont care about pass sequences and do brute-force bisect.
Do you expect to get a runnable code at the end and check for buggy
run-time behavior?
Then you need to keep the passes that are
2019 Jun 11
2
Bugpoint Redesign
"Finkel, Hal J. via llvm-dev" <llvm-dev at lists.llvm.org> writes:
> One concern that I have is that, from personal experience, the ability
> for bugpoint to reduce the set of optimization passes applied in order
> to reproduce a bug is extremely helpful. I understand your desire to
> decouple the logic somewhat, and maybe there's some way to generalize
> that
2018 Jun 07
5
RFC: Pass Execution Instrumentation interface
TL;DR
====
This RFC suggests an API to enable customizable instrumentation of pass
execution.
The intent is to have a common machinery to implement all the
pass-execution-debugging
features mentioned here.
Prime target of the interface is the new pass manager.
The overall approach and most of the implementation details should be
equially applicable
to the legacy one though.
Background
2018 Jun 06
2
Porting OptBisect to New Pass Manager
Hi Chandler,
I am now working on a bisecting tool to find mis-optimization on LLVM. I
found OptBisect a very useful option and hope to make it work on the new
pass manager. I have several questions about it.
1. Any plans to apply codegen stage with new pass manager?
IIUC, new pass manager only works for opt stage. However the OptBisect
option tries to accumulate pass counts through opt stage
2018 May 06
0
Need guidance to work on NEW PASS managers bugs
Hello all,
After reading OptBisect and DebugCounter related code and playing bit
around it I have following simple design:
- Add a debug counter for opt-bisect. Initilize it against option
-opt-bisect-limit=<limit>.
- DebugCounter is a singleton class so can be accessed by both new and
legacy passmanager.
We may need few more static method like getCounterIdForName(std::string
&Name)
2018 May 07
1
Need guidance to work on NEW PASS managers bugs
Hi Vivek,
can you elaborate why you're looking for a one-size-fits-all solution? What
is the noteworthy benefit over adding a new-pm specific implementation?
Several changes you mention are purely for the benefit of supporting the
legacy PM (which already has a working, tried, and tested solution). E.g.
`getCounterIdForName`, the FIXMEs you mention, and the callbacks. All of
these are
2018 Sep 26
2
OptBisect implementation for new pass manager
But they're deeply connected. I debug codegen problems all the time.
That opt-bisect doesn't work with codegen is really unfortunate.
If opt-bisect should work with codegen then we need to think about how
codegen will work with the new PM.
I agree that whether or not the new PM becomes default is somewhat
orthogonal but eventually it will and at that point I hope we have a
functioning
2018 Sep 26
3
OptBisect implementation for new pass manager
On 9/26/2018 10:47 AM, Philip Pfaffe via llvm-dev wrote:
> Hi Fedor,
>
> can you make an example where a pass actually needs to opt-out?
> Because IMO, bisect should quite literally to DebugCounter-style skip
> every step in every ::run method's loop. Passes should not even be
> concerned with this.
This isn't so much an issue for the optimization pipeline, but code
2018 Sep 26
2
OptBisect implementation for new pass manager
I'm concerned about codegen. If Codegen is not yet ready for the new
PM, should the new PM really become default? I would at least like to
see a plan of how Codegen is going to migrate before the new PM becomes
default. Codegen pass pipelines have been wonky ever since I started
working with LLVM and it would be nice to get that cleaned up.
-David
Philip Pfaffe
2018 Sep 27
4
OptBisect implementation for new pass manager
Hi Andrew,
We absolutely need to be able to generate executable programs using
> opt-bisect, so some mechanism for not skipping required passes is needed.
> It might be nice to have a mode where no passes are skipped and the IR/MIR
> is dumped when the bisect limit is reached, but I don't see that as a
> requirement.
>
At this point it makes no sense to worry about the code
2018 May 02
2
Need guidance to work on NEW PASS managers bugs
As a point of clarification, optnone is already being handled by the pass itself in the legacy implementation. The skip[IR unit] functions are provided by the pass base classes, and the attribute is checked there. This happens any time the legacy wrapper is run, no matter how it is run.
Regarding the opt-bisect design, I’m not particularly fond of the managed static either, but I do want to
2018 Oct 01
4
OptBisect implementation for new pass manager
On 10/01/2018 11:13 PM, David Greene wrote:
> Philip Pfaffe <philip.pfaffe at gmail.com> writes:
>> Sorry, but I strongly oppose to the road you're suggesting here. As I
>> said before the Pass*Manager* is entirely the wrong place to handle
>> OptNone, the absolutely the wrong design. It makes sense for function
>> *only*, and immediately breaks down everywhere
2018 Sep 28
3
OptBisect implementation for new pass manager
On 09/28/2018 12:25 AM, Kaylor, Andrew wrote:
> As I said, that’s really outside the scope of the current discussion
> except to say that the relevant question is what component should make
> the decision about whether or not a pass should be run.
A planned way of implementation for new-pm's OptBisect is for
instrumenting object to control the execution.
Whenever instrumentation
2018 Jun 07
2
RFC: Pass Execution Instrumentation interface
On 06/07/2018 06:11 PM, Chandler Carruth wrote:
> We had already talked about this, so unsurprisingly I'm generally in
> favor of the direction. Some comments below.
>
> On Thu, Jun 7, 2018 at 2:00 AM Fedor Sergeev <fedor.sergeev at azul.com
> <mailto:fedor.sergeev at azul.com>> wrote:
>
> - access through LLVM Context (allows to control life-time and
2018 Mar 29
0
Opt Bisect layering
So... looking at OptBisect, I have a few thoughts:
1) what's the purpose of the virtual interface/OptPassGate? I'm guessing
maybe that worked around the circular referencing in these APIs? hmm, no, I
suppose that wouldn't work/be relevant here.
2) Why is OptBisector a ManagedStatic? That seems pretty antithetical to
the role of LLVMContext. When/why would a user be bisecting over
2018 Mar 22
2
Opt Bisect layering
Andrew,
I would not make the caller pass the description of the IR unit. That is
because it would result in the description generated every time even if
OptBisect is disabled. Description generation is not very chip.
Thinking on the OptBisect extension, I believe passing the units are the
right choice because OptPassGates may use them to make pass skipping
decisions.
-Yevgeny Rouban