Displaying 20 results from an estimated 20000 matches similar to: "[LLVMdev] LLVM ERROR: Cannot select: intrinsic %llvm.annotation"
2018 May 30
1
llvm.annotation arguments
Hello all,
According to *clang/lib/CodeGen/CodeGenFunction.cpp*, a LLVM annotation
intrinsic call has 4 arguments:
- llvm::Value *AnnotatedVal,
- Builder.CreateBitCast(CGM.EmitAnnotationString(AnnotationStr), Int8PtrTy),
- Builder.CreateBitCast(CGM.EmitAnnotationUnit(Location), Int8PtrTy),
- CGM.EmitAnnotationLineNo(Location)
However, this is what an annotation intrinsic *char
2012 Jan 24
1
[LLVMdev] Possible bug in the dragonegg
Hi Pablo, in fact this is coming from the "ssp" attribute on main, which turns
on LLVM's stack protection logic. I have no idea what that does exactly, but
it seems to be causing the problem. On ubuntu systems it is enabled by default.
You can turn it off by passing -fno-stack-protector to dragonegg. However
please still open a bugreport since stack protection is supposed to work.
2013 Oct 24
0
[LLVMdev] LLVM use chains
On 23 October 2013 22:41, Vassil Vassilev <vvasilev at cern.ch> wrote:
> Hi,
> I have:
> ...
> @.str1 = private unnamed_addr constant [21 x i8] c"Now f is a
> function\0A\00", align 1
> ; Function Attrs: ssp uwtable
> define i32 @_Z1fv() #2 {
> entry:
> %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([21 x
> i8]* @.str1, i32 0,
2013 Oct 24
2
[LLVMdev] LLVM use chains
Hi,
I have:
...
@.str1 = private unnamed_addr constant [21 x i8] c"Now f is a
function\0A\00", align 1
; Function Attrs: ssp uwtable
define i32 @_Z1fv() #2 {
entry:
%call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([21
x i8]* @.str1, i32 0, i32 0))
ret i32 0
}
Then I get after trying to erase the function from the module:
511
2011 Nov 02
0
[LLVMdev] annotations preventing optimizations/cleanup?
> I created a plugin to add simple Annotations to VarDecls and
> FieldDecls, and write this modified AST out to a file. I notice that
> when I use clang to compile this file I get different code then when I
> use the source directly. In both cases I'm compiling with -O4. Can
> anyone explain this?
This is how clang implements annotations on local variables, that's all.
2011 Jul 23
0
[LLVMdev] RFC: Exception Handling Rewrite
Hi Bill,
Thanks for working on this.
Is there a reference for the function attribute uwtable, or is it to be defined as
part of this effort?
Thanks in advance
Garrison
On Jul 23, 2011, at 1:29, Bill Wendling wrote:
> What? Yet another EH proposal?! This one is different from the others in that
> I'm planning to start implementing this shortly. But I want your feedback! I've
2011 Nov 02
2
[LLVMdev] annotations preventing optimizations/cleanup?
I created a plugin to add simple Annotations to VarDecls and
FieldDecls, and write this modified AST out to a file. I notice that
when I use clang to compile this file I get different code then when I
use the source directly. In both cases I'm compiling with -O4. Can
anyone explain this?
Thanks
define i32 @somefunc(i32 (i32)* %ptr) nounwind uwtable {
entry:
%ptr.addr = alloca i32 (i32)*,
2012 Jan 24
0
[LLVMdev] Possible bug in the dragonegg
Hi Pablo, I can reproduce this with the supplied IR. It is related to the use
of __memcpy_chk. As far as I can see it is a bug in lli or the LLVM code
generators. Can you please open a bugreport, attaching the LLVM IR.
Ciao, Duncan.
On 23/01/12 17:00, Pablo Barrio wrote:
> Hi Duncan,
>>> #include<stdio.h>
>>> #include<string.h>
>>>
>>> int
2016 Dec 07
1
Expected constant simplification not happening
Hello
Has there been any progress on this topic ? The 3.9 optimizer output is
still the same as I just looked.
https://llvm.org/bugs/show_bug.cgi?id=24448
Ciao
Nat!
Sanjay Patel schrieb:
> [cc'ing Zia]
>
> We have this transform with -Os for some cases after:
> http://reviews.llvm.org/rL244601
> http://reviews.llvm.org/D11363
>
> but something in this example is
2013 Oct 24
2
[LLVMdev] LLVM use chains
On 10/24/13 2:13 AM, Rafael EspĂndola wrote:
> On 23 October 2013 22:41, Vassil Vassilev <vvasilev at cern.ch> wrote:
>> Hi,
>> I have:
>> ...
>> @.str1 = private unnamed_addr constant [21 x i8] c"Now f is a
>> function\0A\00", align 1
>> ; Function Attrs: ssp uwtable
>> define i32 @_Z1fv() #2 {
>> entry:
>> %call =
2012 Jan 23
2
[LLVMdev] Possible bug in the dragonegg
Hi Duncan,
>> #include<stdio.h>
>> #include<string.h>
>>
>> int main(int argc, char** argv){
>>
>> char a[8] = "aaaaaaa";
>> char b[8] = "bbbbbbb";
>>
>> char *c = (char*) malloc(sizeof(char)*(strlen(a)+strlen(b)+1));
>> memcpy(c, a, strlen(a));
>> memcpy(c + strlen(a), b, strlen(b) + 1);
>>
2018 May 19
2
tbaa error: Access type node must be a valid scalar type
Hi
I am upgrading my clang fork from 5.0 to 6.0 and I am hit by this error:
Access type node must be a valid scalar type
%4 = load %"struct.Foo::p.test1::"*, %"struct.Foo::p.test1::"**
%_param.addr, align 8, !tbaa !16
!16 = !{!15, !15, i64 0}
!15 = !{!"p.test1::", !13, i64 0, !13, i64 8}
It looks like !16 is referencing !15, which is a struct. !13 is
!13 =
2016 Feb 11
3
Expected constant simplification not happening
Hi
the appended IR code does not optimize to my liking :)
this is the interesting part in x86_64, that got produced via clang -Os:
---
movq -16(%r12), %rax
movl -4(%rax), %ecx
andl $2298949, %ecx ## imm = 0x231445
cmpq $2298949, (%rax,%rcx) ## imm = 0x231445
leaq 8(%rax,%rcx), %rax
cmovneq %r15, %rax
movl $2298949, %esi ## imm = 0x231445
movq %r12, %rdi
movq %r14,
2011 Dec 13
0
[LLVMdev] AMD IL Code Generator Backend for OpenCL
Hi Micah, all,
On Dec 13, 2011, at 8:49 AM, Villmow, Micah wrote:
If you look at the test cases, you can infer what needs to be done. Basically since this is targeted
for OpenCL, we annotate OpenCL kernels slightly different than normal functions and that is
what causes the code to be generated. That being said, on my list of things to do is fix this so that
any function will be generated
2013 Feb 27
3
[LLVMdev] llvm get annotations
Hello everyone !
I followed
http://stackoverflow.com/questions/4976298/modern-equivalent-of-llvm-annotationmanagerin
order to get annotations from my target bytecode. All the examples
that
I give in the following is related to the code from that link. I have
`__attribute__((annotate("DS"))) int f=0;` into the target C++ program and
the related IR code:
@.str = private unnamed_addr
2013 Feb 28
0
[LLVMdev] how can I parse a Value* ?
Hello everyone,
I have the following LLVM IR :
@.str = private unnamed_addr constant [3 x i8] c"DS\00", section
"llvm.metadata"
@llvm.global.annotations = appending global [1 x { i8*, i8*, i8*, i32 }] [{
i8*, i8*, i8*, i32 } { i8* bitcast (i32* @f to i8*), i8* getelementptr
inbounds ([3 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([9 x
i8]* @.str1, i32 0, i32 0),
2011 Jul 23
14
[LLVMdev] RFC: Exception Handling Rewrite
What? Yet another EH proposal?! This one is different from the others in that
I'm planning to start implementing this shortly. But I want your feedback! I've
all ready gotten a lot of feedback from Chris, John, Jim, Eric, and many others.
Now is your turn!
Please read this proposal and send me your comments, suggestions, and concerns.
-bw
2012 Dec 25
2
[LLVMdev] [DragonEgg] Strange call to @"\01__isoc99_fscanf"
Dear all,
First of all, Merry Christmas! :)
While testing a File I/O sample program, I've encountered a link failure
due to missing implementation of "\01__isoc99_fscanf" function. I think
this function should be named "__isoc99_fscanf" instead. Please see the
program code and LLVM IR generated by DragonEgg and clang below. It shows
that clang generates
2016 Nov 25
3
Translation of custom attribute (defined for variables) from clang to llvm
Hi Asit,
thanks for the reply.
But I guess I was not clear in my question. Actually, i dont want to use
__ATTRIBUTE__((ANNOTATE("MOVIATTR"))), since in documentation it is
stated that "This intrinsic allows annotation of local variables with
arbitrary strings. This can be useful for special purpose optimizations
that want to look for these annotations. These have no other
2016 Nov 28
2
Translation of custom attribute (defined for variables) from clang to llvm
Hi John,
I have looked into the EmitAutoVarAlloca() in CGDecl.cpp. However, I
could not figure out how to employ my custom attribute for code
generation. For example, my custom attribute is visible in CGDecl.cpp
but how can I generate based on my custom attribute
if (D.hasAttr<myCustomAttri>())
{
//What to do here?
}
What I wan in IR is something like below.
Without Custom Attribute: