Displaying 20 results from an estimated 9000 matches similar to: "Question about using multiple functions in a Function pass"
2019 Sep 03
2
Get constants of undefined types in IR
Hi Tim,
My mistake not including the llvm-dev, excuse me. affinityElement.__bits[0] worked fine for me, thank you. I am new in using the API for Constants and I am facing the error "incomplete type is not allowed" on the last last of below code: Type * ET = IntegerType::getInt64Ty(I.getContext()); unsigned long size = cpuAffinityVector.size(); ArrayType * AT = ArrayType::get(ET,size);
2017 Jun 05
2
Build problems
Hello,
Could someone please tell me why LLVM and clang downloaded from here:
svn co http://llvm.org/svn/llvm-project/llvm/trunk llvmsvn co http://llvm.org/svn/llvm-project/cfe/trunk clang
and generated using cmake:
cmake -G "Visual Studio 15 2017" ../llvm
does not compile in Visual Studio?
I am using Batch Build in Visual Studio and I have selected only ALL_BUILD project to build as
2017 Jun 06
2
Question
Thank you. So the ABI in llvm will be "gnu" for all Linux distributions?
On Monday, June 5, 2017 11:39 PM, Tim Northover <t.p.northover at gmail.com> wrote:
On 5 June 2017 at 11:54, Iulia Stirb <iulia_s24 at yahoo.com> wrote:
> Can you also please tell me how can I find out the ABI (application binary
> interface)?
Could you send your messages with a smaller
2019 Sep 18
2
How to debug passes
Iulia,
You need to check the contents of the hello.ll (or hello.bc) file rather
than the input *.c file - ultimately that's what opt consumes.
Try compiling without any optimisations:
clang -O0 -emit-llvm -S hello.c -c -o hello.ll
-Andrzej
On 18/09/2019 11:34, iulia_s24 wrote:
> Hi,
>
> Actually I copy-pasted step 5 from the article in which I found the
> solution, in the text
2017 Jun 05
2
Question
Can you also please tell me how can I find out the ABI (application binary interface)?
Thanks,Iulia
On Monday, June 5, 2017 8:58 PM, Bruce Hoult <bruce at hoult.org> wrote:
grep name /proc/cpuinfo
Then look up the model number in
https://en.wikipedia.org/wiki/List_of_Intel_Xeon_microprocessors
On Mon, Jun 5, 2017 at 8:41 PM, Iulia Stirb via llvm-dev <llvm-dev at
2019 Aug 31
3
Get constants of undefined types in IR
Hello all,
I would like to obtain a constant that is initialized with a value of type cpu_set_t, a type which is defined by Pthreads. The problem is that a variable of this type cannot be cast to an int value, even in C source code. I tried get methods from Constant or ConstantInt classes, but with no result.
How can I obtain such constant object in IR?
Thank you,
Iulia
-------------- next
2019 Sep 16
2
How to debug passes
Hi,
Could you please confirm the following steps for debugging a pass?
1. copy your pass into llvm/lib/Transforms/Hello/Hello.cpp
2. name you pass Hello
3. insert debug messages like:
errs() << "Visiting function " << F.getName();
4. get LLVM bitcode: clang -O3 -emit-llvm hello.c -c -o hello.bc5. disassemble the bitcode:
llvm-dis hello.bc
6. run the pass on
2017 Jun 08
2
Question
I want to cross-compile using clang and I have to specify the following triple: <arch><sub>-<vendor>-<sys>-<abi>I know that sub-architectures ("sub" in the triple) for x86_64 Intel Xeon processors could be v2 for ivy bridge or v3 for haswell or v4 etc. Could you please answer: which version of sub-architecture is considered sandy bridge for Intel® Xeon®
2015 Dec 16
2
LLVM and parallelization
Hi,
I know LLVM provides thread-level automatic parallel support using OpenMP (see http://blog.llvm.org/2015/05/openmp-support_22.html), but it is not clear for me which of the following is correct?
1. Clang inserts in the source code OpenMP compiler directives, so, it auto-parallelizes the serial source code provided as input or2. Clang can compile manually written parallel source code that uses
2017 Jun 05
2
Question
Hello,
1. Can you please tell me how can I find the type of my Intel Xeon?I see in LLVM code that Intel Xeon processors can be of type "core2", "penryn", "westmere", "skylake".
2. I also see that "skylake" can be a type and a subtype as well.How can I find out the subtype of my architecture?
Looking forward for you answer. Thank you.Iulia
On
2015 Dec 16
2
Instruction scheduling done before or after register allocation
Hi,
I have read the steps of code generation from here: The LLVM Target-Independent Code Generator — LLVM 3.8 documentation
| |
| | | | | | | |
| The LLVM Target-Independent Code Generator — LLVM 3...Instruction Selection Instruction Selection is the process of translating LLVM code presented to thecode generator into target-specific machine instructions. |
| |
| View on llvm.org
2019 Sep 18
2
How to debug passes
> opt -load libdummypass.so -dummypass hello.ll
Looks like you are loading a shared library different from "LLVMHello.so".
did you change the name of the compilation unit from "Hello.cpp" into
"dummypass.cpp"?
(As asked previously by Andrzej) did you register the dummy pass?
> RegisterPass<DummyPass> X("dummypass",
2017 Jun 04
2
Question
Hello,
Could someone please answer the following question:
Does LLVM support code generation for Intel Processors? Which Intel processors are supported? I am interested especially in Intel Xeon Processor, but you can give me information about the others as well.
Thank you,Iulia
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
2017 May 06
2
LLVM and Pthreads
Hello,
I know clang supports -pthread option (here). Does this mean I can call pthread routines inside llvm code and which pthread library is used, the one for Linux OS or the one for Windows?
Thank you.Iulia
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170506/7a201a40/attachment.html>
2012 Jan 03
2
[LLVMdev] AliasAnalysis and memory dependency
Hi all,
I want to find memory dependency between CallInst instruction and other.
So i used the following code:
* AliasAnalysis &AA=getAnalysis<AliasAnalysis>();*
* if(isa<StoreInst>(inst1)){*
* ** **if(isa<CallInst>(inst2))**{*
* CallInst *call_inst2= dyn_cast<CallInst>(inst2); *
* if(AA.getModRefInfo(inst1,call_inst2)==mod)**{*
*
2004 Nov 18
3
[LLVMdev] A few beginner level questions..
1. If we run a few passes in a sequence ..is the bytecode file
transformed after each pass in sequence i.e
if we have
a) opt -pass1 -pass2 -pass3 < in.bc > out.bc
b)opt -pass1 -pass2 < in.bc > tmp.bc
opt -pass3 < tmp.bc > out.bc
are the above two equivalent ?
what I basically want is to run my pass on an optimised bytecode , so
should i optimize it and get a new bytecode
2012 Apr 09
3
[LLVMdev] How to instrument a this function using insertBefore instruction???
Hi all,
Im trying to instrument this hello function right before the instruction that call the "puts" function(the source code is as follow).
Now I can compile the pass without errors, but when run the pass with opt tool, it broke down. The diagnose is something like
Referencing function in another module!
%CallCheck = call i32 @fib()
Broken module found, compilation aborted!
Does
2011 Sep 16
2
[LLVMdev] How to duplicate a function?
Hi all,
Sorry for the inconvenient about the previous post. The files were not
attached. So I put them here again.
I am a newbie in LLVM and I am trying to replace the function like:
old function || new function
==============================
=========
int haha(int a) { int haha(int a, char* ID) {
===>
}
2012 Apr 07
1
[LLVMdev] How to insert a self-written function to a piece of programme
Hi all,
I wrote a function pass. In the pass, it ran through all the instruction that call to functions. When arriving at the exact function that I m interested in, it would insert a self-made function.
Now I've finished the pass, the compilation is successful. The pass can find the function I like and can insert the CallInst to call my check function. BUT, when running the
2018 Apr 01
2
Custom Binary Format Challenges
Hello,
I hope you are all doing well and thanks in advance. I need to program a
transformation of a set of llvm bitcode to have some various techniques
woven in. In particular, I need to resolve a given computed target address
to one of several in the same way that the function of a dynamic library is
resolved, but I need this resolution to happen in the binary target of my
choice where I tell