search for: getuses

Displaying 20 results from an estimated 72 matches for "getuses".

Did you mean: getuser
2008 Apr 16
0
[LLVMdev] PATCH: Use size reduction -- wave2
On Apr 16, 2008, at 2:50 AM, heisenbug wrote: > > And now here is my educated speculation: > There are 2 things that became slower > 1) Use::getUser() > 2) Use::get/set due to tagging. > > The former is seldom called: > > $ find lib -name "*.cpp" | xargs grep "getUser(" | wc -l > 41 The majority of those aren't actually Use::getUser, but
2008 Apr 16
5
[LLVMdev] PATCH: Use size reduction -- wave2
On Apr 16, 2:13 am, Dan Gohman <goh... at apple.com> wrote: > Hi Gabor, > > Can you provide performance data for this? I'd > like to know what affect these changes have on > compile time. Hi Dan, Unfortunately, no. I can feed you with some speculation, though, see below. The reason why I cannot do measurements (at the moment) is that - I have no experience with
2020 Jan 15
4
Finding callees of a function
I searched the doxygen documentation and could not find a solution to my task: In a ModulePass running at EP_OptimizerLast, if I have a function F like in: bool Foo:runOnModule(Module &M) { LLVMContext &C = M.getContext(); for (auto &F : M) { // magic here if I want to know from which function (callee) each function is called - how can I do this? (so that I e.g. have
2006 Sep 06
0
soapenc:base64 and xsd:base64Binary
Hello guys, I have a little mix in all those webservices and wsdl files and all this things, and I have maybe a strange question. I''m trying to consume webservice from different webservice implementation than ror. And I there is one thing from ror regenerated wsdl file. Method parameter defined by :base64 type is defined in wsdl as ''soapenc:base64''. My question is, why
2015 Jul 27
2
[LLVMdev] a question about pooalloc
Hello, today I download poolalloc from " https://github.com/llvm-mirror/poolalloc". and I compiled it with LLVM3.3. Then when I excute "make",I get the error: AddressTakenAnalysis.cpp:18:30:fatal error:llvm/IR/CallSite.h: No such file or directory. ​I correct the path of callsite.h to "llvm/Support/Callsite.h". there is another error: AddressTakenAnalysis.cpp:In
2018 Apr 20
2
Missed strlen optimizations
Use *last = nullptr; for (Use &U : Src->uses()) last = &U; last->getUser()->dump(); Or any better solution? 2018-04-20 19:19 GMT+02:00 Dávid Bolvanský <david.bolvansky at gmail.com>: > Is: > > > 2018-04-20 18:07 GMT+02:00 Dávid Bolvanský <david.bolvansky at gmail.com>: > >> Hello, >> >> Code: https://godbolt.org/g/EG4Wi6
2011 Jan 06
0
Problem with package twitteR and converting S4 obj to data frame
Hi, I wrote a simple script to retrieve an n number of followers for a given user in Twitter. I used a sample of n=10 to test my script and worked perfectly but once I started to changes n I started to get the following error: Error in list_to_dataframe(res, attr(.data, "split_labels")) : Results do not have equal lengths I have no clue why works fine with n=10 but for higher
2018 Apr 20
0
Missed strlen optimizations
Maybe nicer.. auto i = Src->uses().begin(); std::advance(i, Src->getNumUses() - 1); i->getUser()->dump(); 2018-04-20 19:19 GMT+02:00 Dávid Bolvanský <david.bolvansky at gmail.com>: > Use *last = nullptr; > for (Use &U : Src->uses()) > last = &U; > last->getUser()->dump(); > > > Or any better solution? > > 2018-04-20 19:19
2015 May 09
4
[LLVMdev] [LSR] hoisting loop invariants in reverse order
Hi, I was tracking down a performance regression and noticed that LoopStrengthReduce hoists loop invariants (e.g., the initial formulae of indvars) in the reverse order of how they appear in the loop. This reverse order creates troubles for the StraightLineStrengthReduce pass I recently add. While I understand ultimately SLSR should be able to sort independent candidates in an optimal order,
2018 Aug 07
2
Error Calling eraseFromParent()
Hi. This is part of my code: ... if (auto* op = dyn_cast<BinaryOperator>(&I)) { Value* lhs = op->getOperand(0); Value* rhs = op->getOperand(1); Value* mul = builder.CreateMul(lhs, rhs); for (auto& U : op->uses()) { User* user = U.getUser(); user->setOperand(U.getOperandNo(), mul); } I.eraseFromParent(); } ... This leads to the following
2018 Aug 08
2
Error Calling eraseFromParent()
Hi. Thanks. I changed the code but the problem exists. This is my new code which is again very simple: ... bool runOnFunction(Function &F) override { vector<Instruction *> dels; dels.clear(); for (inst_iterator It = inst_begin(&F), Ie = inst_end(&F); It != Ie;) { Instruction *I = &*(It++); if (auto* op = dyn_cast<BinaryOperator>(I)) { IRBuilder<NoFolder>
2009 Jul 18
3
[LLVMdev] Where does llvm.memcpy.i64 and friends get lowered ?
...mes like 'memcpy' too. It seems a bit of an inconsistancy for the Module not to reference this and have to pick it up from the relocations. Also there is the matter of 'abort' which seems to be defined by most if not all modules even if it is not being used. I am using GlobalValue::getUses() to filter it. Whats going on with 'abort' ? Aaron > > -Chris > > > I get :- > > ---------- Functions ---------- > llvm.memcpy.i64 > Mangled name = llvm.memcpy.i64 > DefaultVisibility > ExternalLinkage - Externally visible. > m...
2013 Jan 02
2
[LLVMdev] Build Failure
I'm getting a build failure with -Werror: [off-dbg] : [llvm] /ptmp/dag/llvm/official/llvm/lib/IR/Use.cpp: In member function 'llvm::User* llvm::Use::getUser() const': [off-dbg] : [llvm] /ptmp/dag/llvm/official/llvm/lib/IR/Use.cpp:142:14: error: cast from type 'const llvm::Use*' to type 'llvm::User*' casts away qualifiers [-Werror=cast-qual]
2014 Aug 09
2
[LLVMdev] difference between replaceAllUsesWith and replaceUsesOfWith?
Why is the first for loop not equivalent to the second? Thanks, Rob =========================== for (GlobalVariable **i = Globals.begin(), **e = Globals.end(); i != e; ++i) { GlobalVariable *GV = *i; Constant *GEP = ConstantExpr::getGetElementPtr(...); GV->replaceAllUsesWith(GEP); } =========================== for (GlobalVariable **i = Globals.begin(), **e = Globals.end(); i != e;
2018 Aug 07
2
Error Calling eraseFromParent()
The code is really simple. But I can not the reason for the segmentation fault. I only know that the eraseFromParent() function leads to it. The whole code is: ... bool runOnFunction(Function &F) override { for (auto &I : instructions(F)) { if (auto* op = dyn_cast<BinaryOperator>(&I)) { IRBuilder<> builder(op); Value* lhs = op->getOperand(0); Value* rhs =
2014 Aug 09
3
[LLVMdev] difference between replaceAllUsesWith and replaceUsesOfWith?
On Sat, Aug 9, 2014 at 6:06 AM, Tim Northover <t.p.northover at gmail.com> wrote: > Hi Rob, > > On 9 August 2014 02:03, Rob Jansen <jansen at cs.umn.edu> wrote: > > Why is the first for loop not equivalent to the second? > > In the second loop, "*ui" is an llvm::Use object. It's owned by a > User, but isn't a subclass of one. To match the
2018 Aug 08
3
Error Calling eraseFromParent()
LLVM is built in Release mode. The version is 6.0.0. I think that a similar code worked on verison 3.9.0. It is probably a null pointer dereference occurring in eraseFromParent(). I checked and reconfirmed that the instruction had no uses. Perhaps I should rebuild LLVM. Thanks. On Wed, Aug 8, 2018 at 9:03 PM, mayuyu.io <admin at mayuyu.io> wrote: > Hmmmm that’s strange. Do you get an
2016 Feb 16
2
Difference between “uses” and “user”
Hi everyone, Instruction and Value classes have "Uses" and "User". What is the difference between them? I think that "Uses" gives all the instructions/values that a particular Value depends on and "User" gives all the instructions/values that depend on that particular value. Is that right? Best, Carlo -------------- next part -------------- An HTML
2018 Aug 07
2
Error Calling eraseFromParent()
Thanks Bjorn! But The problem is still there. On Wed, Aug 8, 2018 at 2:04 AM, Björn Pettersson A < bjorn.a.pettersson at ericsson.com> wrote: > It looks quite dangerous to erase the instruction I inside the loop when > iterating over all instructions in the function. > I guess it depends on how the range based iterator is implemented if that > works or not. > > I think
2017 Jun 09
2
Get segfault with ModulePass
Hi, don't know if this is the right list. Please post a better place, otherwise. I'm currently writing a LLVM ModulePass and ran into strange segfaults or endless loops within LLVM. My main question is, if this is a programming error or API misuse from me or a LLVM bug? Here is some minimal code, that triggers the bug: ---------------- class DebugPass : public ModulePass { public: