similar to: Any significance for m_OneUse in (X / Y) / Z => X / (Y * Z) ??

Displaying 20 results from an estimated 400 matches similar to: "Any significance for m_OneUse in (X / Y) / Z => X / (Y * Z) ??"

2020 Jan 03
3
Any significance for m_OneUse in (X / Y) / Z => X / (Y * Z) ??
A couple more general comments: 1. There shouldn't be any correctness issues removing one-use checks (the transform should be safe independently of use-counts). 2. Ideally, you can remove a m_OneUse() from the code and run 'make check' or similar, and you will see a regression test failure because we have a 'negative' test to cover that pattern. That should make it clear that
2020 Jan 06
2
Any significance for m_OneUse in (X / Y) / Z => X / (Y * Z) ??
Is your case the case mentioned in the subject or a different case? ~Craig On Sun, Jan 5, 2020 at 8:11 PM raghesh <raghesh.a at gmail.com> wrote: > Thanks Sanjay for your comments. > > So, if we want to add a transformation avoiding the one-use check, which > one is the ideal pass? Shall we do it in -aggressive-instcombine? I came > to know that if the pattern search
2019 Sep 24
2
An issue with "lifetime.start" and storing "undef"
Hi All, In order to confine the scope of a local variable allocated using "alloca", we had written a pass named 'undeflocal'. This helps avoid pseudo phi nodes inserted because of the path (carrying an undefined value) starting from the "entry" block. This unwanted phi instruction was preventing some of the optimizations from getting triggered later on. For example,
2017 Jul 13
2
failing to optimize boolean ops on cmps
We have several optimizations in InstCombine for bitwise logic ops (and/or/xor) that fail to handle compare patterns with the equivalent bitwise logic. Example: define i8 @or_and_not(i8 %a, i8 %b) { %nota = xor i8 %a, -1 %and = and i8 %nota, %b %res = or i8 %and, %a ret i8 %res } define i1 @or_and_cmp_not(i32 %a, i32 %b, i1 %c) { %cmp = icmp sgt i32 %a, %b %cmp_inv = icmp sle i32 %a,
2017 Jul 13
2
failing to optimize boolean ops on cmps
This can't be an instsimplify though? The values we want in these cases do not exist already: %res = or i8 %b, %a %res = or i1 %cmp, %c On Thu, Jul 13, 2017 at 5:10 PM, Daniel Berlin <dberlin at dberlin.org> wrote: > > > On Thu, Jul 13, 2017 at 2:12 PM, Sanjay Patel <spatel at rotateright.com> > wrote: > >> We have several optimizations in InstCombine
2017 Sep 04
2
llvm-dev Digest, Vol 159, Issue 2
Hal, Tobias, et al. – I am strongly in favor of seeing a broader range of loop transformations, supported by strong dependence analysis, added to LLVM, and the Polly infrastructure seems to be by far our best bet to make that happen. I have a couple of questions: 1) Integer constraint libraries like ISL (and Omega, which I used extensively in a previous project) are fundamentally solving
2018 Dec 18
2
should we do this time-consuming transform in InstCombine?
Hi, There is an opportunity in instCombine for following instruction pattern: %mul = mul nsw i32 %b, %a %cmp = icmp sgt i32 %mul, -1 %sub = sub i32 0, %a %mul2 = mul nsw i32 %sub, %b %cond = select i1 %cmp, i32 %mul, i32 %mul2 Source code for above pattern: return (a*b) >=0 ? (a*b) : -a*b; Currently, llvm(-O3) can not recognize this as abs(a*b). I initially think we could do this in
2008 May 17
2
[LLVMdev] More info, was Help needed after hiatus
Hi, I know my last question was very vague (i.e. "It stopped working, what went wrong?"), so here is a little more concrete example: If I run the optimizer (opt) on this code snippet with -std-compile-opts the optimizer hangs. ; ModuleID = 'test.ubc' target datalayout =
2018 Dec 18
2
should we do this time-consuming transform in InstCombine?
Hi Roman, Thanks for your good idea. I think it can solve the abs issue very well. I can continue with my work now^-^. But if it is not abs and there is no select, %res = OP i32 %b, %a %sub = sub i32 0, %b %res2 = OP i32 %sub, %a theoretically, we can still do the following transform for the above pattern: %res2 = OP i32 %sub, %a ==> %res2 = sub i32 0, %res Not sure whether we can do it
2008 May 17
0
[LLVMdev] More info, was Help needed after hiatus
On Sat, May 17, 2008 at 11:34 AM, Richard Pennington <rich at pennware.com> wrote: > If I run the optimizer (opt) on this code snippet with -std-compile-opts > the optimizer hangs. > > > ; ModuleID = 'test.ubc' > target datalayout = >
2011 Jun 14
1
[LLVMdev] Adding Polly tester to LLVM buildbot
Hi All, We set up a Polly buildbot tester and would like to add this to LLVM buildbots. We want to commit the buildbot scripts to the LLVM/zorg repository and include buildslave to buildbot.llvm.org Can any one help us to do this? Regards, -- Raghesh
2011 Mar 21
3
[LLVMdev] Contributing to Polly with GSOC 2011
Dear all, I am Raghesh, a student pursuing M.Tech at Indian Institute of Technology, Madras, India. I would like to make contribution to the Polly project (http://wiki.llvm.org/Polyhedral_optimization_framework) as part of GSOC 2011. I have gained some experience working in OpenMP Code generation for Polly. This is almost stable now and planning to test with the polybench benchmarks. Some of
2012 Oct 30
2
[LLVMdev] Any plan to add MIN/MAX isd node?
Hi Duncan, To use select, usually, there is a compare before select. Presence of comparison will disable some opportunities to optimize some code. Select and Compare is not associative neither. Thanks, Yin -----Original Message----- From: llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] On Behalf Of Duncan Sands Sent: Tuesday, October 30, 2012
2008 Nov 09
2
[LLVMdev] m_Not Pattern Question
I have a question about the pattern matching stuff that's used in the Instruction Combiner. If I have code like this: if (match(B, m_Select(m_Value(), m_ConstantInt(0), m_ConstantInt(-1)))) { if (match(C, m_Not(m_Value(B)))) return SelectInst::Create(cast<User>(B)->getOperand(0), D, A); and we match, the program fails during the
2012 Oct 30
0
[LLVMdev] Any plan to add MIN/MAX isd node?
Hi Yin, > To use select, usually, there is a compare before select. > Presence of comparison will disable some opportunities to > optimize some code. Select and Compare is not associative > neither. at the IR level LLVM already has pattern matching helpers for identifying min/max idioms, here is part of a transform using this, from InstructionSimplify.cpp: // Signed variants
2019 Aug 22
2
h265 codec pass through on asterisk
All, I'm using asterisk 16.4.0 with h264 and opus quite well using linphone 4.1 client on android and baresip on linux. I'm exploring use of h265 for improved video quality/lower network bandwidth. I do not see pass through support on asterisk for h265/hvec. All my SIP clients and underlying hardware have hvec/h265 encoding and decoding available. I would have liked vp9 however, vp9
2012 Oct 30
1
[LLVMdev] Any plan to add MIN/MAX isd node?
Hi Duncan, Yes, exactly. However, we need define Opcode MIN/MAX Into ISDOpcodes.h. Do you like to add those two definitions Into the tree? Thanks, Yin -----Original Message----- From: Duncan Sands [mailto:duncan.sands at gmail.com] On Behalf Of Duncan Sands Sent: Tuesday, October 30, 2012 12:10 PM To: Yin Ma Cc: llvmdev at cs.uiuc.edu Subject: Re: [LLVMdev] Any plan to
2005 Oct 05
1
[LLVMdev] Cast instructions
The following situation comes up a lot in what I'm doing. I want to check if a value is a certain kind of instruction. The test also needs to succeed if the value is a *cast* of the instruction (or a cast of a cast, etc.) I.e., I need to "see through" any intervening casts to get to the "real" value. It's trivial to write a function that does this, but does
2010 Dec 22
2
[LLVMdev] Generating target dependent function calls
Hi, raghesh and I are working in Polly on automatically generating OpenMP calls. This works nicely on a 64bit architecture, however the functions we need to generate are slightly different on different platforms. The reason for the difference is that e.g "long" in > bool GOMP_loop_runtime_next(long, long) has a different size on different architectures. Currently we generate
2014 Jul 01
2
[LLVMdev] Probable error in InstCombine
I've found what appears to be a bug in instcombine. Specifically, the transformation of -(X/C) to X/(-C) is invalid if C == INT_MIN. Specifically, if I have > define i32 @foo(i32 %x) #0 { > entry: > %div = sdiv i32 %x, -2147483648 > %sub = sub nsw i32 0, %div > ret i32 %sub > } then opt -instcombine will produce > define i32 @foo(i32 %x) #0 { > entry: > %sub