Displaying 20 results from an estimated 22 matches for "myintrinsic".
2005 Aug 23
2
[LLVMdev] Marking source locations without interfering with optimization?
...be moved or copied along with the
instruction. I was hoping to find a scheme that'd stay (mostly)
up-to-date through modifications with minimal extra changes.
> I would suggest something like
> this (C syntax for the llvm code):
>
> int foo() {
> %A = alloca int
> llvm.myintrinsic("A", whatever data you want")
> }
Just to clarify, you're suggesting that I use the LLVM value's name to
link up with the source info instead of actually binding to it - so in
a slightly more complicated example I might do this:
C code:
1: a = foo();
2: b = bar();
3: a...
2005 Aug 24
0
[LLVMdev] Marking source locations without interfering with optimization?
...d stay (mostly)
> up-to-date through modifications with minimal extra changes.
I don't really think there is a good way to do that.
>> I would suggest something like
>> this (C syntax for the llvm code):
>>
>> int foo() {
>> %A = alloca int
>> llvm.myintrinsic("A", whatever data you want")
>> }
>
> Just to clarify, you're suggesting that I use the LLVM value's name to
> link up with the source info instead of actually binding to it - so in
> a slightly more complicated example I might do this:
>
> C code:
&g...
2005 Aug 24
1
[LLVMdev] Marking source locations without interfering with optimization?
...or this kind of
'loose' source info.
I'll dig around some more in the code. Thanks for the help.
> >> I would suggest something like
> >> this (C syntax for the llvm code):
> >>
> >> int foo() {
> >> %A = alloca int
> >> llvm.myintrinsic("A", whatever data you want")
> >> }
> >
> > Just to clarify, you're suggesting that I use the LLVM value's name to
> > link up with the source info instead of actually binding to it - so in
> > a slightly more complicated example I might do t...
2007 Mar 31
2
[LLVMdev] About implementing new intrinsic
Hi,
I will try to explain by giving an example.
Let's say that I have an intrinsic: int llvm.myintrinsic(int)
I have a function: int myintrinsic_handler(int)
When
%var = call int %llvm.myintrinsic( int %arg )
is met in the code, I want the code generator put in its place: a call
to function
"myintrinsic_handler" (i.e. %var = call int %myintrinsic_handler( int %arg ) )
or probably in nativ...
2009 Mar 24
2
[LLVMdev] Reducing .td redundancy
...], [IntrNoMem, Commutative]>;
def int_x86_sse2_add_sd : GCCBuiltin<"__builtin_ia32_addsd">,
Intrinsic<[llvm_v2f64_ty, llvm_v2f64_ty,
llvm_v2f64_ty], [IntrNoMem, Commutative]>;
Untested multiclass! Look for SOME_CONCAT.
multiclass myintrinsics<bits<8> opc, string OpcodeStr, Intrinsic Intr> {
// Scalar intrinsics
def SSrr_Int SSI<opc, MRMSrcReg, (outs FR32:$dst), (ins FR32:$src1, FR32:
$src2),
!strconcat(OpcodeStr, "ss\t{$src2, $dst|$dst, $src2}"),
[(set FR32:$dst, (SOME_CON...
2005 Aug 23
0
[LLVMdev] Marking source locations without interfering with optimization?
...re for a value or instruction that
> the pass is doing something interesting to.
Okay... this is tricky. Anything that will bind to variables will
prevent modification to the variable. I would suggest something like
this (C syntax for the llvm code):
int foo() {
%A = alloca int
llvm.myintrinsic("A", whatever data you want")
}
> Because I don't need to support the functionality of a debugger with
> this, it is OK if that best guess contains more than one possibility,
> as long as it isn't a huge number of possibilities. The idea is that
> I'm produci...
2008 Apr 18
0
[LLVMdev] Giving labels to intrinsics and getting the address
...intrinsic with the call
CI->replaceAllUsesWith(callAsm);
Actually, now that I think about it, maybe I shouldn't even bother
using an intrinsic and directly use this inline asm. Assuming that the
following transformation won't cause basic blocks to be considered
dead.
%x = call i1 @llvm.myintrinsic(label %otherPath) ; @myintrinsic always
returns true
br i1 %x, label %mainPath, label %otherPath
Hopefully, even if the CFG optimizer finds that mainPath is always
taken, because there's a use of %otherPath by @myintrinsic, that path
won't be used. Additionally, to the rest of the compiler...
2005 Aug 20
2
[LLVMdev] Marking source locations without interfering with optimization?
I've been thinking of adding an instruction, and I'm following the
advice in the docs to consult the list before doing something rash.
What I want to do is provide a way to identify variable names and
source locations that doesn't affect the effectiveness of
optimizations. This is not the same problem as supporting debug info,
because I don't care about being able to look up
2016 Feb 02
2
creating Intrinsic DAG Node
Matt,
The added intrinsic in DAG looks like:
0xbedb698: i32 = llvm.MyIntrinsic 0xbedb200, 0xbedac18 [ORD=4]
The builtin in DAG looks like:
0xbedb2a8: i32,ch = llvm 0xbedb158:1, 0xbedb200, 0xbedb158 [ORD=7] [ID=16]
The only difference I'm seeing is the extra operand, which is a 'ch'
from a load.
On Tue, Feb 2, 2016 at 3:55 PM, Matt Arsenault <arsenm2 at...
2007 Apr 01
0
[LLVMdev] About implementing new intrinsic
On Sat, 31 Mar 2007, Ferad Zyulkyarov wrote:
> I will try to explain by giving an example.
> Let's say that I have an intrinsic: int llvm.myintrinsic(int)
> I have a function: int myintrinsic_handler(int)
> When
> %var = call int %llvm.myintrinsic( int %arg )
> is met in the code, I want the code generator put in its place: a call
> to function
> "myintrinsic_handler" (i.e. %var = call int %myintrinsic_handler( int %a...
2008 Apr 14
2
[LLVMdev] Branch-like intrinsic
Is there a way to implement an intrinsic that looks like a conditional
branch so that it has 2 edges to 2 basic blocks?
Taking a step back, I'm trying to make a special branch where Passes
treat it just like a regular conditional branch except that it's
condition is opaque to everyone, so it isn't removed by optimizations.
Additionally, the special branch would codegen (to x86) to
2008 Apr 14
0
[LLVMdev] Branch-like intrinsic
...st like a regular conditional branch except that it's
> condition is opaque to everyone, so it isn't removed by optimizations.
> Additionally, the special branch would codegen (to x86) to something
> other than the regular branch instructions.
Why not something like:
%x = llvm.myintrinsic()
br i1 %x, label %T, label %F
?
-Chris
--
http://nondot.org/sabre/
http://llvm.org/
2008 Apr 14
2
[LLVMdev] Branch-like intrinsic
On Mon, Apr 14, 2008 at 5:11 PM, Chris Lattner <sabre at nondot.org> wrote:
> Why not something like:
> %x = llvm.myintrinsic()
> br i1 %x, label %T, label %F
Right. That's exactly what I meant in the last paragraph of the
original message.
The reason for not wanting this is that %x actually always turns out
to be 1 (on architectures that support it), so %T is always taken. But
this unnecessarily adds overheads...
2007 Mar 31
0
[LLVMdev] About implementing new intrinsic
On Sat, 2007-03-31 at 12:38 -0800, Chris Lattner wrote:
> >> 3. Can I introduce an intrinsic that is actually a call to my function
> >> that implements the logic? I suppose it is possible but unfortunately
> >> I couldn't figure it out. For example, in GCC we can write an
> >> intrinsic that translates to a C code.
> >
> > As part of PR1297
2016 Jun 24
2
creating Intrinsic DAG Node
...s this the correct way to add intrinsic dag node?
>
> Thanks.
>
>
> On Tue, Feb 2, 2016 at 5:10 PM, Ryan Taylor <ryta1203 at gmail.com <mailto:ryta1203 at gmail.com>> wrote:
> Matt,
>
> The added intrinsic in DAG looks like:
>
> 0xbedb698: i32 = llvm.MyIntrinsic 0xbedb200, 0xbedac18 [ORD=4]
>
> The builtin in DAG looks like:
>
> 0xbedb2a8: i32,ch = llvm 0xbedb158:1, 0xbedb200, 0xbedb158 [ORD=7] [ID=16]
>
> The only difference I'm seeing is the extra operand, which is a 'ch' from a load.
>
> On Tue, Feb 2, 2016 a...
2009 Mar 24
0
[LLVMdev] Reducing .td redundancy
On Mar 23, 2009, at 5:56 PM, David Greene wrote:
> Is it legal to do something like a !strconcat on a non-string
> entity? That
> is, is there some operation that will let me do this (replace
> SOME_CONCAT with
> an appropriate operator):
I don't get it, can you try a simpler example on me? :)
-Chris
>
>
> (WARNING! Hacked-up tablegen ahead!)
>
>
2016 Jun 24
3
creating Intrinsic DAG Node
...dd intrinsic dag node?
>>
>> Thanks.
>>
>>
>> On Tue, Feb 2, 2016 at 5:10 PM, Ryan Taylor <ryta1203 at gmail.com> wrote:
>>
>>> Matt,
>>>
>>> The added intrinsic in DAG looks like:
>>>
>>> 0xbedb698: i32 = llvm.MyIntrinsic 0xbedb200, 0xbedac18 [ORD=4]
>>>
>>> The builtin in DAG looks like:
>>>
>>> 0xbedb2a8: i32,ch = llvm 0xbedb158:1, 0xbedb200, 0xbedb158 [ORD=7]
>>> [ID=16]
>>>
>>> The only difference I'm seeing is the extra operand, which is a...
2007 Mar 31
4
[LLVMdev] About implementing new intrinsic
>> 3. Can I introduce an intrinsic that is actually a call to my function
>> that implements the logic? I suppose it is possible but unfortunately
>> I couldn't figure it out. For example, in GCC we can write an
>> intrinsic that translates to a C code.
>
> As part of PR1297 (http://llvm.org/PR1297) I am about to make this
> happen. There are certain kinds of
2009 Mar 24
2
[LLVMdev] Reducing .td redundancy
Is it legal to do something like a !strconcat on a non-string entity? That
is, is there some operation that will let me do this (replace SOME_CONCAT with
an appropriate operator):
(WARNING! Hacked-up tablegen ahead!)
multiclass sse_fp_binop_bitwise_rm<bits<8> opc, string OpcodeStr,
SDNode OpNode> {
// Vector operation emulating scalar (fp)
2010 Mar 12
0
[LLVMdev] Question: overloaded intrinsic
I am working on an implementation that needs to add a couple of overloaded intrinsics (based on pointer to different address spaces). I am creating a new myintrinsics.td file and using the iPTRAny for the argument type.
The current interface (i.e. getName() and getTyp() in Intrinsics.h) seems to require the caller to know which arguments are used for overloading, so to set Tys and numTys. This means I need to hardcode the intrinsic property in the caller, whic...