similar to: [LLVMdev] Reg2mem: Identifying introduced memory locations (also, what happens to the phi nodes)

Displaying 20 results from an estimated 2000 matches similar to: "[LLVMdev] Reg2mem: Identifying introduced memory locations (also, what happens to the phi nodes)"

2011 May 17
1
[LLVMdev] eliminate phi nodes, reduce unnecessary loads / stores , reg2mem, mem2reg
Hi, I work on a pass that requires as input LLVM code without any phi nodes. For this, I use the reg2mem pass which produces suitable code, the pass runs correctly, but I obtain a significant performance decrease. I expect that this is because there are more reads / writes to memory after running the reg2mem pass. How can I optimize the code, without inserting any phi nodes? Or is there a
2012 Jul 25
1
[LLVMdev] Inneffiecient code produced by reg2mem?
Is there a pass I can use after reg2mem to get rid of occurances like this?: store i32 %cond, i32* %cond.reg2mem %cond.reload = load i32* %cond.reg2mem store i32 %cond.reload, i32* %cond4.reg2mem Essentially, in this case, reg2mem creates an extra memory space to store and load a value from just here, and never uses the value again; since this isn't efficient code, I'm wondering if
2013 Sep 22
0
[LLVMdev] Why total number of store instructions increased in case of gvn with reg2mem?
Might have to do with GVN's PRE (partial redundancy elimination), which tends to increase code size. H. ----- Original Message ----- From: Abhinash Jain Sent: 09/22/13 01:17 AM To: llvmdev at cs.uiuc.edu Subject: [LLVMdev] Why total number of store instructions increased in case of gvn with reg2mem? Below are the 4 cases out of which for the first 3 cases am able to understand the variation
2013 Sep 22
0
[LLVMdev] Why total number of store instructions increased in case of gvn with reg2mem?
Below are the 4 cases out of which for the first 3 cases am able to understand the variation on total number of store inst. But when -gvn parameters is passed (in case 4) , why does the total number of strore Instruction present on the attached file increases (instead of decrease). Please explain considering that use of -reg2mem pass is mandatory. eg. clang -emit-llvm bzip.c -c -o bzip1.bc
2011 Jun 20
0
[LLVMdev] run -mem2reg and -reg2mem programmably from within a Pass
I guess AU.addRequiredID(DemoteRegisterToMemoryID) would do the trick. - xi On Jun 19, 2011, at 11:03 PM, Chuck Zhao wrote: > I am currently building a BasicBlock pass which requires to run -reg2mem before it, and need to run -mem2reg after it to clean up. > > So, I want to specify -reg2mem as one of the pre-requisite passes to it, as: > > > class MyPass: public
2011 Jun 20
2
[LLVMdev] run -mem2reg and -reg2mem programmably from within a Pass
I am currently building a BasicBlock pass which requires to run -reg2mem before it, and need to run -mem2reg after it to clean up. So, I want to specify -reg2mem as one of the pre-requisite passes to it, as: class MyPass: public BasicBlockPass{ virtual void getAnalysisUsage(AnalysisUsage &AU){ ... AU.addRequired<RegToMem>(); ... } }; I searched all passes under
2007 Aug 10
0
[LLVMdev] Reg2Mem pass
On Fri, 2007-08-10 at 00:51 -0500, Seung Jae Lee wrote: > Hi, guys. > > I'm interested in using reg2mem pass but not sure about the concept of it. > Can you let me know a reference about it, if any? > Forgive my ignorance. -_-; The reg2mem pass undoes SSA form. That is, it turns SSA registers into alloca instructions with loads and stores. > > Thanks, > Seung J.
2012 Dec 31
1
[LLVMdev] reg2mem breaks module
Hello, I'm trying to apply the reg2mem pass on my bc file, but it somehow adds an instruction before a landingpad instruction and so I get a broken module error: The unwind destination does not have a landingpad instruction! %41 = invoke %class.x* @_ZN10xC2Ev(%class.x* %.reload19) to label %.noexc unwind label %88
2008 May 23
0
[LLVMdev] mem2reg & reg2mem
I have a register allocation bug I'm trying to track down. It's caused by a convoluted series of events that results in a massive amount of code, so looking at asm diffs is rather unhelpful. I came up with the bright idea of adding a MaxPromotes flag to limit the number of candidates that mem2reg promotes. But I couldn't figure out how to safely promote some candidates but not
2007 Sep 05
2
[LLVMdev] reg2mem pass
Hello, guys. I just tested -reg2mem pass to see how it changes my bitcode. E.g., for the following simple C code: ------------------------------------------------------------- int foo() { int i,j; int sum = 0; for (i=0; i<10; i++) { sum += i; for (j=0; j<3; j++) sum += 2; } return sum; } ------------------------------------------------------------- I could get the
2015 Apr 22
2
[LLVMdev] Use clang to generate LLVM IR with -O3, how to visit these load operations after -reg2mem
Hi, all I want to instrument load/store operations in LLVM IR. And I find the LLVM IR generated with flag -o3 is much more efficient than -o0, so I try to instrument on these optimized LLVM IR, but, some load operations are changed to Phi loads. Then, I try the -reg2mem flag to remove these phi nodes. The problems are: 1) I use visitLoadInst to collect these load operations, and it seems I
2015 Apr 22
2
[LLVMdev] Use clang to generate LLVM IR with -O3, how to visit these load operations after -reg2mem
Best Regards! Eric Lew On 周三, 4月 22, 2015 at 12:11 下午, David Blaikie < dblaikie at gmail.com [dblaikie at gmail.com] > wrote: On Tue, Apr 21, 2015 at 8:34 PM, Eric Lu <eirc.lew at gmail.com> wrote: > Hi, all > > I want to instrument load/store operations in LLVM IR. And I find the LLVM > IR generated with flag -o3 is much more efficient than -o0, so I try to >
2007 Aug 10
2
[LLVMdev] Reg2Mem pass
Hi, guys. I'm interested in using reg2mem pass but not sure about the concept of it. Can you let me know a reference about it, if any? Forgive my ignorance. -_-; Thanks, Seung J. Lee
2011 Nov 11
2
One step way to create data frame with variable "variable names"?
Suppose plotx <- "someName" modx <- "otherName" plotxRange <- c(10,20) modxVals <- c(1,2,3) It often happens I want to create a dataframe or object with plotx or modx as the variable names. But can't understand syntax to do that. I can get this done in 2 steps, creating the data frame and then assigning names, as in newdf <- data.frame( c(1, 2, 3, 4),
2018 Jan 05
0
Question about reg2mem
Greetings, Lately I have been experimenting on using Obfuscator-llvm on swiftc bitcode file. During the process of applying the Bogus Control Flow function pass I encountered the following error: swifterror value should be the second operand when used by stores %33 = alloca swifterror %swift.error*, align 8 store %swift.error** %33, %swift.error*** %.reg2mem21 swifterror argument should come
2012 Aug 20
2
[LLVMdev] How to eliminate PHI nodes on pointer types?
Somewhere during optimization PHI nodes on pointer types (including alloca instructions) are being introduced, and they persist through the scalar replacement of aggregates pass and others. I can't seem to find a combination of passes or transformations to get rid of them. Has anyone had this problem before, and know a transformation to eliminate it? My optimization passes rely on
2012 Aug 20
0
[LLVMdev] How to eliminate PHI nodes on pointer types?
Hi Andrew, > Somewhere during optimization PHI nodes on pointer types (including > alloca instructions) are being introduced, and they persist through the > scalar replacement of aggregates pass and others. I can't seem to find > a combination of passes or transformations to get rid of them. Has > anyone had this problem before, and know a transformation to eliminate > it?
2011 Aug 31
0
[LLVMdev] Getting rid of phi instructions?
On Wed, Aug 31, 2011 at 2:35 AM, Teemu Rinta-aho <teemu.rinta-aho at nomadiclab.com> wrote: > On 31.8.2011, at 11.41, Eli Friedman wrote: > >> Mmm... reg2mem will transform IR with PHI's into IR without them, but >> it generates a bunch of alloca's, which I would assume are not cheap >> to lower to VHDL.  You might have to write your own pass to get the
2011 Aug 31
2
[LLVMdev] Getting rid of phi instructions?
On 31.8.2011, at 11.41, Eli Friedman wrote: > Mmm... reg2mem will transform IR with PHI's into IR without them, but > it generates a bunch of alloca's, which I would assume are not cheap > to lower to VHDL. You might have to write your own pass to get the > precise transformation you're looking for. Right. Thanks. I need to see the reg2mem source code. Teemu
1998 Nov 18
1
0.63 naming list elements
The following used to work (0.62.1 the latest that I used), and now it doesn't (0.63.0): force <- vector(mode = "list", length = 1) names(force)[1] <- somename It returns the error: Error in "[<-"(NULL, 1) : object is not subsetable You might argue that this approach is unnecessary now that R allows subscripts that are out of range (e.g., force<-list();