Displaying 8 results from an estimated 8 matches for "adddestin".
2013 Jul 23
2
[LLVMdev] Steps to addDestination
Hi,
I need to addDestination to some basic blocks
I used the following code
Value* Address;
IndirectBrInst *IBI = IndirectBrInst::Create(Address,
Result.size(),i->getTerminator() );
IBI->addDestination(i);
The following error was issued
void llvm::IndirectBrInst::init(llvm::Value *, unsigned int): Assertion...
2013 Jul 23
0
[LLVMdev] Steps to addDestination
Hi Rasha,
> I need to addDestination to some basic blocks
Just to make sure there's no confusion here: you really are trying to
create code like:
define i32 @foo(i1 %tst) {
%Address = select i1 %tst, i8* blockaddress(@foo, %true), i8*
blockaddress(@foo, %false)
indirectbr i8* %Address, [label %true, label %false] ; This...
2013 Jul 25
0
[LLVMdev] Steps to addDestination
Hi Rasha,
> for(rit=Result.begin();rit!=Result.end();++rit)
> {
> Value* Address= BlockAddress::get (*rit);
>
> IndirectBrInst *IBI = IndirectBrInst::Create(Address, Result.size(),i->getTerminator() );
> IBI->addDestination((*rit));
> }
This would be creating a block looking something like:
[ Do stuff ]
indirectbr i8* blockaddress(@foo, %result1), [label %result1]
indirectbr i8* blockaddress(@foo, %result2), [label %result2]
[...]
indirectbr i8* blockaddress(@foo, %resultN), [label %resu...
2013 Jul 24
2
[LLVMdev] Steps to addDestination
Hi
1-
for(rit=Result.begin();rit!=Result.end();++rit)
{
Value* Address= BlockAddress::get (*rit);
IndirectBrInst *IBI = IndirectBrInst::Create(Address,
Result.size(),i->getTerminator() );
IBI->addDestination((*rit));
}
I tried this code , but the needed destination wasn't added.
2- About LLVM backend
$ llc -march=cpp example_file.ll -o
I think it will be so helpful for my work
Thanks
On 24 July 2013 08:37, Tim Northover <t.p.northover at gmail.com> wrote:
> Hi Rasha,
>
>...
2013 Jul 23
2
[LLVMdev] Steps to addDestination
..."
from Value.h source code
3- I'm not sure about "select" instruction, you mean that the address is
the new destination (basic block)that will be added
Thanks
On 23 July 2013 16:38, Tim Northover <t.p.northover at gmail.com> wrote:
> Hi Rasha,
>
> > I need to addDestination to some basic blocks
>
> Just to make sure there's no confusion here: you really are trying to
> create code like:
>
> define i32 @foo(i1 %tst) {
> %Address = select i1 %tst, i8* blockaddress(@foo, %true), i8*
> blockaddress(@foo, %false)
> indirectbr i8* %Addre...
2013 Jul 24
0
[LLVMdev] Steps to addDestination
Hi Rasha,
On Wed, Jul 24, 2013 at 12:28 AM, Rasha Omar <rasha.sala7 at gmail.com> wrote:
> 1- I need the first example.
Oh good.
> 2- I set the Address uninitialized according to the documentation
> " Setting the name on the Value automatically updates the module's symbol
> table" from Value.h source code
That's referring to a string name, and is only really
2018 Aug 30
4
crash problem when using IndirectBrInst to replace BranchInst
...alseDestAddr = BlockAddress::get(FalseDest);
Value * ConditionValue = BI->getCondition();
SelectInst * SI = SelectInst::Create(ConditionValue, TrueDestAddr,
FalseDestAddr, "", BI);
IndirectBrInst *indirBr = IndirectBrInst::Create(SI, 2, BI);
indirBr->addDestination(TrueDest);
indirBr->addDestination(FalseDest);
BI->eraseFromParent();
But I met the following crash when using this pass to build the arm target.
The crash log is:
Process: clang [894]
Path: /Users/USER/Library/Android/*/clang
Identifier...
2018 Aug 31
2
crash problem when using IndirectBrInst to replace BranchInst
...Value * ConditionValue = BI->getCondition();
>
>
>
> SelectInst * SI = SelectInst::Create(ConditionValue, TrueDestAddr,
> FalseDestAddr, "", BI);
>
>
>
> IndirectBrInst *indirBr = IndirectBrInst::Create(SI, 2, BI);
>
> indirBr->addDestination(TrueDest);
>
> indirBr->addDestination(FalseDest);
>
> BI->eraseFromParent();
>
>
> But I met the following crash when using this pass to build the arm
> target. The crash log is:
>
>
> Process: clang [894]
>
> Path:...