search for: irreader

Displaying 20 results from an estimated 43 matches for "irreader".

Did you mean: bitreader
2013 Feb 28
2
[LLVMdev] Timing the IRReader
...n. 1. Piggybacking on time-passes (like DWARF dumping does) is probably not the "right thing to do", and hard to implement too since some tools like llvm-diff don't even link in the pass infrastructure (which defines the required globals). 2. Creating a separate flag is feasible, but IRReader is currently header-only. So an implementation file has to be created to hold the actual flag. 3. Any other ideas? Eli
2013 Mar 01
0
[LLVMdev] Timing the IRReader
...on time-passes (like DWARF dumping does) is probably > not the "right thing to do", and hard to implement too since some > tools like llvm-diff don't even link in the pass infrastructure (which > defines the required globals). > 2. Creating a separate flag is feasible, but IRReader is currently > header-only. So an implementation file has to be created to hold the > actual flag. > 3. Any other ideas? > > Eli
2017 Nov 16
2
Correctly linking against libLLVM (single shared library build)
...references autoconf). I'll see if I can find time to update it, but the guidance should be to use the `llvm_config` CMake function instead. The proper usage of that in the example there would be to replace the call to `llvm_map_components_to_libnames` with `llvm_config(simple-tool support core irreader)`. > > `llvm_config` should properly handle the LLVM shared library. Actually it does not work at all. It behaves exactly the same as map_components with this CMakeLists.txt: cmake_minimum_required(VERSION 3.4.3) project(SimpleProject) find_package(LLVM REQUIRED CONFIG) message(STATUS &qu...
2016 Nov 20
3
uninitialized values in Attributes.cpp
...lotMapping*) (Parser.cpp:31) ==29299== by 0x1CC5C16: llvm::parseAssembly(llvm::MemoryBufferRef, llvm::SMDiagnostic&, llvm::LLVMContext&, llvm::SlotMapping*) (Parser.cpp:41) ==29299== by 0x158C59E: llvm::parseIR(llvm::MemoryBufferRef, llvm::SMDiagnostic&, llvm::LLVMContext&) (IRReader.cpp:89) ==29299== by 0x158CA61: llvm::parseIRFile(llvm::StringRef, llvm::SMDiagnostic&, llvm::LLVMContext&) (IRReader.cpp:102) ==29299==
2018 Dec 09
2
Parse LLVM IR
...do some instrumentations. However, my problem is that no matter how I tweak my parsing code, it simply cannot print out anything. So here is my C code: int your_fun(int arg2) { int x = arg2; return x+2; } And here is my parsing code: #include <llvm/IR/Module.h> #include <llvm/IRReader/IRReader.h> #include <llvm/IR/LLVMContext.h> #include <llvm/Support/SourceMgr.h> #include <iostream> #include <llvm/Support/raw_ostream.h> using namespace llvm; int main() { LLVMContext context; SMDiagnostic error; Module *m = parseIRFile("t.ll", error,...
2017 Oct 23
2
Correctly linking against libLLVM (single shared library build)
Hi, In SUSE we have recently switched from building LLVM as multiple shared libraries (using BUILD_SHARED_LIBS) to building it as a single shared library (using LLVM_BUILD_LLVM_DYLIB). The multiple shared libraries build was causing issues and apparently it is only meant for LLVM developers. Our guidelines prohibit linking against static libraries unless there is no other option. After this
2019 Sep 18
2
EngineBuilder(std::move(Owner)).create() return null
...UseJIT and run, but the EngineBuilder(std::move(Owner)).create() keeps return null, any idea why? Here's my CMakeList: cmake_minimum_required(VERSION 3.12) project(llvm_test) set(CMAKE_CXX_STANDARD 14) find_package(LLVM REQUIRED CONFIG) llvm_map_components_to_libnames(llvm_libs support core irreader orcjit native) add_executable(llvm_test main.cpp) target_include_directories(llvm_test PUBLIC ${LLVM_INCLUDE_DIRS}) target_compile_definitions(llvm_test PUBLIC ${LLVM_DEFINITIONS}) target_link_libraries(llvm_test ${llvm_libs}) -------------- next part -------------- An HTML attachment was scrubbed...
2018 Feb 24
1
Parsing a bit code file
I am trying to parse LLVM IR from a bit code file. I went through the following steps. hello.cpp #include <iostream> int main() { std::cout << "Hello world!" << "\n"; return 0;} dump.cpp #include <llvm/IR/Module.h>#include <llvm/IRReader/IRReader.h>#include <llvm/IR/LLVMContext.h>#include <llvm/Support/SourceMgr.h> using namespace llvm;int main(){ LLVMContext context; SMDiagnostic error; Module *m = parseIRFile("hello.bc", error, context).get(); if(m) { m->dump(); } return 0;} *$ clan...
2016 Nov 20
3
uninitialized values in Attributes.cpp
...gt; ==29299== by 0x1CC5C16: llvm::parseAssembly(llvm::MemoryBufferRef, >> llvm::SMDiagnostic&, llvm::LLVMContext&, llvm::SlotMapping*) (Parser.cpp:41) >> ==29299== by 0x158C59E: llvm::parseIR(llvm::MemoryBufferRef, >> llvm::SMDiagnostic&, llvm::LLVMContext&) (IRReader.cpp:89) >> ==29299== by 0x158CA61: llvm::parseIRFile(llvm::StringRef, >> llvm::SMDiagnostic&, llvm::LLVMContext&) (IRReader.cpp:102) >> ==29299== >> _______________________________________________ >> LLVM Developers mailing list >> llvm-dev at lists.ll...
2019 Sep 18
2
EngineBuilder(std::move(Owner)).create() return null
...er)).create() keeps return null, any idea > why? > > Here's my CMakeList: > > cmake_minimum_required(VERSION 3.12) > project(llvm_test) > > set(CMAKE_CXX_STANDARD 14) > > find_package(LLVM REQUIRED CONFIG) > llvm_map_components_to_libnames(llvm_libs support core irreader orcjit native) > > add_executable(llvm_test main.cpp) > target_include_directories(llvm_test PUBLIC ${LLVM_INCLUDE_DIRS}) > target_compile_definitions(llvm_test PUBLIC ${LLVM_DEFINITIONS}) > target_link_libraries(llvm_test ${llvm_libs}) > > _____________________________________...
2018 Feb 02
2
Debug info error on bitcode inline modification
...lvm/IR/Module.h" #include "llvm/IR/Function.h" #include "llvm/IR/GlobalValue.h" #include "llvm/IR/InstIterator.h" #include "llvm/IR/Instructions.h" #include "llvm/IR/IRBuilder.h" #include "llvm/Support/SourceMgr.h" #include "llvm/IRReader/IRReader.h" #include "llvm/Support/FileSystem.h" #include "llvm/Bitcode/ReaderWriter.h" #include "llvm/Support/raw_ostream.h" using namespace llvm; int main(int argc, char *argv[]) { SMDiagnostic error; LLVMContext context; Module *M = pa...
2020 May 16
2
Building A Project Against LLVM
...akeLists.txt file I'm using is essentially just taken >>> from: https://llvm.org/docs/CMake.html#embedding-llvm-in-your-project - >>> though originally it would not link. From scouring the internet I made 2 >>> changes to get that working: replaced "support core irreader" with "all", >>> and replaced "${llvm_libs}" with just "LLVM". >>> >>> However as I was starting to play with setting up JIT, I hit more >>> differences between the version of LLVM in Kubuntu and the version the >>> exa...
2016 Feb 12
3
llvm-config error for aarch64
The bot failure can be reproduced with: ./bin/llvm-config "--ldflags" "--libs" "--system-libs" all-targets analysis asmparser asmprinter bitreader bitwriter codegen core debuginfodwarf executionengine instrumentation interpreter ipo irreader linker mc mcjit objcarcopts option profiledata scalaropts support target Looking... -- Mehdi > On Feb 12, 2016, at 10:30 AM, Quentin Colombet <qcolombet at apple.com> wrote: > > Hi, > > This may happen because of r260569. > Now the libAArch64 has a dependency on libG...
2018 Feb 02
0
Debug info error on bitcode inline modification
..."llvm/IR/Function.h" > #include "llvm/IR/GlobalValue.h" > #include "llvm/IR/InstIterator.h" > #include "llvm/IR/Instructions.h" > #include "llvm/IR/IRBuilder.h" > #include "llvm/Support/SourceMgr.h" > #include "llvm/IRReader/IRReader.h" > #include "llvm/Support/FileSystem.h" > #include "llvm/Bitcode/ReaderWriter.h" > #include "llvm/Support/raw_ostream.h" > > using namespace llvm; > > int main(int argc, char *argv[]) > { > SMDiagnostic error; >...
2018 Feb 05
1
Debug info error on bitcode inline modification
...h" >> #include "llvm/IR/GlobalValue.h" >> #include "llvm/IR/InstIterator.h" >> #include "llvm/IR/Instructions.h" >> #include "llvm/IR/IRBuilder.h" >> #include "llvm/Support/SourceMgr.h" >> #include "llvm/IRReader/IRReader.h" >> #include "llvm/Support/FileSystem.h" >> #include "llvm/Bitcode/ReaderWriter.h" >> #include "llvm/Support/raw_ostream.h" >> >> using namespace llvm; >> >> int main(int argc, char *argv[]) >> { >>...
2019 Apr 18
3
Opt plugin linkage
...etName()) << '\n'; return false; } ``` Modified opt's CMakeLists.txt: ``` set(LLVM_LINK_COMPONENTS ${LLVM_TARGETS_TO_BUILD} AggressiveInstCombine Analysis BitWriter CodeGen Core MC MCJIT Object OrcJIT Interpreter RuntimeDyld Coroutines IPO IRReader InstCombine Instrumentation MC ObjCARCOpts ScalarOpts Support Target TransformUtils Vectorize Passes ExecutionEngine ) # Support plugins. set(LLVM_NO_DEAD_STRIP 1) add_llvm_tool(opt AnalysisWrappers.cpp BreakpointPrinter.cpp Debugify.cpp GraphPrinters.cpp NewPMDr...
2019 Apr 16
2
Opt plugin linkage
Hey: I spent sometime debugging this, it seems like editing ``llvm/tools/opt.cpp`` and move ``cl::ParseCommandLineOptions(argc, argv, "llvm .bc -> .bc modular optimizer and analysis printer\n");`` to the beginning of main() solved it for me. I'm not sure if this is a bug on LLVM side Zhang ------------------ Original ------------------ From: "Viktor Was BSc via
2018 Sep 21
2
can't build/run after adding lib to Fibonacci example, even reverting the complete llvm tree does not help
...17 ... loading 273 projects question1: if left click on the solution root and select "build solution" (to check if everyhing is built) two files DummyClangFuzzer.cpp and ClangFuzzer.cpp getting compiled - is that indendet? then i want to add some tests to the Fibonacci example and added IRReader to llvm\examples\Fibonacci\CMakeLists.txt set(LLVM_LINK_COMPONENTS    Core    ExecutionEngine    Interpreter    MC    MCJIT    Support    nativecodegen    IRReader # <-- new    ) and then build the Fibonacci example but the build will fail with this log - even git revert on the llvm...
2012 Dec 27
1
[LLVMdev] Throwing an exception from JITed code, and catching in C++
...predecessors! ret void } declare i8* @__cxa_allocate_exception(i64) declare void @__cxa_throw(i8*, i8*, i8*) $ cat catcher.cpp ################ #include "llvm/LLVMContext.h" #include "llvm/Module.h" #include "llvm/ExecutionEngine/JIT.h" #include "llvm/Support/IRReader.h" #include "llvm/Support/TargetSelect.h" #include using namespace llvm; int main(int, char**) { LLVMContext& context = getGlobalContext(); InitializeNativeTarget(); SMDiagnostic error; Module* m = ParseIRFile("./thrower.s.bc", error, context); if...
2020 May 15
2
Building A Project Against LLVM
...I set up my project using that. The CMakeLists.txt file I'm using is essentially just taken from: https://llvm.org/docs/CMake.html#embedding-llvm-in-your-project - though originally it would not link. From scouring the internet I made 2 changes to get that working: replaced "support core irreader" with "all", and replaced "${llvm_libs}" with just "LLVM". However as I was starting to play with setting up JIT, I hit more differences between the version of LLVM in Kubuntu and the version the examples and documentation were written against. So I decided to t...