Displaying 20 results from an estimated 117 matches for "insertbefore".
2004 Jun 24
2
[LLVMdev] Instruction ctor: insertBefore
Hi,
the insertBefore parameter, present in all constructors, is declared like
this:
Instruction *InsertBefore=0
any reason there's no "const" before "Instruction"
?
- Volodya
2004 Jun 24
0
[LLVMdev] Instruction ctor: insertBefore
Vladimir,
Instructions are members of a linked list. Consequently if you insert
some Instruction, that instruction gets changed. So, its not const.
Simple enough?
Reid.
On Thu, 2004-06-24 at 01:02, Vladimir Prus wrote:
> Hi,
> the insertBefore parameter, present in all constructors, is declared like
> this:
>
> Instruction *InsertBefore=0
>
> any reason there's no "const" before "Instruction"
>
> ?
>
> - Volodya
>
> _______________________________________________
> LLV...
2016 Aug 25
2
InstList insert depreciated?
Jon,
> You want:
> TaintVar->insertAfter(FirstI);
This worked! Thank you.
On Thu, Aug 25, 2016 at 9:38 AM, Jonathan Roelofs
<jonathan at codesourcery.com> wrote:
>
>
> On 8/25/16 7:01 AM, Shehbaz Jaffer via llvm-dev wrote:
>>
>> I tried an alternative way of adding instruction by first getting the
>> first instruction of the basic block, and then
2004 Jun 24
0
[LLVMdev] Instruction ctor: insertBefore
I'm not opposed to mutable and its probably reasonable in this case.
However, I'd defer to Chris' opinion for anything in VMCore. We try to
limit the number of changes/additions there because the impact can be
quite large if something goes wrong.
Reid.
On Thu, 2004-06-24 at 04:41, Vladimir Prus wrote:
> Hi Reid,
>
> > Instructions are members of a linked list.
2004 Jun 24
2
[LLVMdev] Instruction ctor: insertBefore
Hi Reid,
> Instructions are members of a linked list. Consequently if you insert
> some Instruction, that instruction gets changed. So, its not const.
>
> Simple enough?
Yes, thank you.
I started thinking if "mutable" is right here, but that's long philosophical
issue ;-)
- Volodya
2007 Mar 07
3
[LLVMdev] use of CallInst()
To create a new CallInst I used to call the following constructor:
CallInst(Value *F, const std::vector<Value*> &Par, const std::string
&Name = "", Instruction *InsertBefore = 0);
However, it seems as though that constructor has been removed. I assume
that I'm suppossed to use the following constructor, but I can't figure
out what to pass as the Args parameter (the second parameter).
CallInst (Value *F, Value *const *Args, unsigned NumArgs, const
std::str...
2005 Apr 28
2
[LLVMdev] inserting blocks into a Function
...in places where
the incoming control-edge has changed. Is there anything else that can
be affected when a block is inserted into the CFG?
Also, planning to write a helper function which will take care of such
issues. The general signature is:
void reconnectBlocks(BasicBlock *newBlock, BasicBlock *insertBefore
, std::vector<BasicBlock*> &preds
, bool createBr = true)
The std::vector "preds" is used to provide a list of preds for
insertBefore, which will be reconnected to newBlock. For cases where
all the preds will be reconnected, the function...
2012 Apr 09
0
[LLVMdev] How to instrument a this function using insertBefore instruction???
...nction()->getName()=="puts")
{
errs() <<III->getCalledFunction()->getName()<<" function found!\n";
callcheck->insertBefore(II);
errs() <<"INSERT SUCCEEDED!!!!!!!!\n";
}
else
{...
2009 Jan 08
2
[LLVMdev] insertAfter method Patch
Hi,
I have added an insertAfter method to the ilist and Instruction classes. The methods are implemented as efficiently as the currently existing insert and insertBefore methods. The insertAfter method was created to mirror a similar method in another compiler in order to ease an ongoing port. The patch, which is very small is included as AddInsertBefore.patch. Additionally, I wrote a small test pass which demonstrates the correctness of insertAfter and have attach...
2004 May 26
0
[LLVMdev] Changes in llvm::Instruction and subclasses
...should not affect current code but it may help people who deal with
LLVM instructions. Up till now one could create an llvm::Instruction
(and subclasses) using the following constructor:
Instruction(const Type *Ty, unsigned iType, const std::string &Name ="",
Instruction *InsertBefore = 0);
If InsertBefore was specified the instruction was added to the basic
block InsertBefore was in, right after InsertBefore. While writing my
frontend this was never the case; I always wanted to append to the end
of a basic block. So I introduced this constructor variant:
Instruction(const Typ...
2012 Apr 09
3
[LLVMdev] How to instrument a this function using insertBefore instruction???
...nction()->getName()=="puts")
{
errs() <<III->getCalledFunction()->getName()<<" function found!\n";
callcheck->insertBefore(II);
errs() <<"INSERT SUCCEEDED!!!!!!!!\n";
}
else
{...
2006 Feb 07
1
onHover: can u explain me this function ?
...n, overlap) {
if(overlap>0.5) {
Sortable.mark(dropon, ''before'');
if(dropon.previousSibling != element) {
var oldParentNode = element.parentNode;
element.style.visibility = "hidden"; // fix gecko rendering
dropon.parentNode.insertBefore(element, dropon);
if(dropon.parentNode!=oldParentNode)
Sortable.options(oldParentNode).onChange(element);
Sortable.options(dropon.parentNode).onChange(element);
}
} else {
Sortable.mark(dropon, ''after'');
var nextElement = dro...
2008 Apr 29
0
[LLVMdev] [PATCH] use-diet for review
...// Constructors - These two constructors are convenience methods
because one
/// and two index getelementptr instructions are so common.
static GetElementPtrInst *Create(Value *Ptr, Value *Idx,
const std::string &Name = "",
Instruction *InsertBefore = 0) {
- return new(2/*FIXME*/) GetElementPtrInst(Ptr, Idx, Name,
InsertBefore);
+ return new(2) GetElementPtrInst(Ptr, Idx, Name, InsertBefore);
}
What is the magic "2"?
+GetElementPtrInst::GetElementPtrInst(const GetElementPtrInst &GEPI)
+ : Instruction(reinterpret_ca...
2007 Mar 07
0
[LLVMdev] use of CallInst()
On Tue, 2007-03-06 at 22:44 -0600, Ryan M. Lefever wrote:
> To create a new CallInst I used to call the following constructor:
>
> CallInst(Value *F, const std::vector<Value*> &Par, const std::string
> &Name = "", Instruction *InsertBefore = 0);
>
> However, it seems as though that constructor has been removed. I assume
> that I'm suppossed to use the following constructor, but I can't figure
> out what to pass as the Args parameter (the second parameter).
>
> CallInst (Value *F, Value *const *Args, uns...
2012 Apr 09
0
[LLVMdev] How to instrument a this function using insertBefore instruction???
...nction()->getName()=="puts")
{
errs() <<III->getCalledFunction()->getName()<<" function found!\n";
callcheck->insertBefore(II);
errs() <<"INSERT SUCCEEDED!!!!!!!!\n";
}
else
{...
2017 Oct 13
2
Why does GEP allow src and destination type to have different address spaces?
The GEP constructor does not assert that the source and destination types
match. Of course, this is incorrect and causes random failures somewhere
down the line.
Could I add general sanity checks to the GEP constructor?
In general, is an Instruction allowed to be in an inconsistent state? If
so, is there some well known method to "verify" whether an instruction is
consistent or not?
2012 Apr 09
1
[LLVMdev] How to instrument a this function using insertBefore instruction???
...dFunction()->getName()=="puts")
>> {
>> errs()
>> <<III->getCalledFunction()->getName()<<" function found!\n";
>>
>> callcheck->insertBefore(II);
>> errs() <<"INSERT
>> SUCCEEDED!!!!!!!!\n";
>> }
>> else
>>...
2007 Mar 07
1
[LLVMdev] use of CallInst()
...Spencer wrote:
> On Tue, 2007-03-06 at 22:44 -0600, Ryan M. Lefever wrote:
>> To create a new CallInst I used to call the following constructor:
>>
>> CallInst(Value *F, const std::vector<Value*> &Par, const std::string
>> &Name = "", Instruction *InsertBefore = 0);
>>
>> However, it seems as though that constructor has been removed. I assume
>> that I'm suppossed to use the following constructor, but I can't figure
>> out what to pass as the Args parameter (the second parameter).
>>
>> CallInst (Value *F, V...
2012 Apr 09
2
[LLVMdev] How to instrument a this function using insertBefore instruction???
...amp;III->getCalledFunction()->getName()=="puts")
> {
> errs()
> <<III->getCalledFunction()->getName()<<" function found!\n";
>
> callcheck->insertBefore(II);
> errs() <<"INSERT
> SUCCEEDED!!!!!!!!\n";
> }
> else
> {
>...
2009 Jan 08
0
[LLVMdev] insertAfter method Patch
Thomas B. Jablin wrote:
> Hi,
> I have added an insertAfter method to the ilist and Instruction classes. The methods are implemented as efficiently as the currently existing insert and insertBefore methods. The insertAfter method was created to mirror a similar method in another compiler in order to ease an ongoing port. The patch, which is very small is included as AddInsertBefore.patch. Additionally, I wrote a small test pass which demonstrates the correctness of insertAfter and have attach...