similar to: [LLVMdev] Reading IR from a std::ostream

Displaying 20 results from an estimated 3000 matches similar to: "[LLVMdev] Reading IR from a std::ostream"

2012 Jan 23
3
[LLVMdev] Use printing methods of third-party libraries that use std::ostream
Hi all, I need to use the printing methods from a third-party library. The problem is those methods use std::cout but the use of std::ostream methods seems to be disabled in latest versions of LLVM. I'm aware of raw_os_ostream (http://llvm.org/doxygen/classllvm_1_1raw__os__ostream.html) which takes a std::ostream as input. E.g., I could do something like: #include
2012 Jan 31
0
[LLVMdev] Use printing methods of third-party libraries that use std::ostream
Hi Jorge, > I need to use the printing methods from a third-party library. The > problem is those methods use std::cout but the use of std::ostream > methods seems to be disabled in latest versions of LLVM. > > I'm aware of raw_os_ostream > (http://llvm.org/doxygen/classllvm_1_1raw__os__ostream.html) which > takes a std::ostream as input. E.g., I could do something like:
2010 Nov 06
1
[LLVMdev] Converting raw_ostream to std::ostream
Dear All, I am currently writing an analysis pass that uses a third-party library. I want to write a print() method for my pass (which takes one of the LLVM raw_ostream objects) and have it use a method from this third-party library to print out data. However, the third-party library uses std::ostream. Is there a way to create a std::ostream from a raw_ostream? -- John T.
2009 Aug 25
3
[LLVMdev] std::cout << *MyModule does not work anymore
Daniel Dunbar <daniel at zuster.org> writes: [snip] >> Is all this an unintended change or an intentional one, and if the >> later, could you direct me to something that explains what we gain on >> exchange of this restriction? > > Intentional. std::ostream has long been deprecated in LLVM, each > release has increased the degree of deprecation. The coding
2010 Apr 01
2
[LLVMdev] raw_os_ostream: symbol not found
Hi, I'm writing some code that prints to std::ostream. However, it seems that all of the LLVM objects can only print to llvm::raw_ostream, so I can't do this: void write(std::ostream &out) { ... for (BasicBlock::iterator i = block->begin(), e = block->end(); i ! = e; ++i) { Instruction *instruction = i; out << *instruction << std::endl;
2011 Oct 31
1
Rewrite the ostream output method, to save messages in another directory.
Hi Timo, I Trying to integrate my antispam with dovecot, using the imap folder to do certain actions. I Do almost every thing, but i have some problems saving the message. Explaining this function, i try to use a imap folder like a "collector folder", the user append a message from outside (ie another imap or pop message) to this folder, and i don't want to copy this message, i
2009 Aug 25
0
[LLVMdev] std::cout << *MyModule does not work anymore
On Mon, Aug 24, 2009 at 5:40 PM, Óscar Fuentes<ofv at wanadoo.es> wrote: > It seems that support for dumping text representation of LLVM objects to > standard channels and C++ output streams was removed. My guess is that > now we must use errs() instead of std::cerr, llvm::raw_fd_ostream > instead of std::ofstream, etc. Correct. std::ostream has been purged from LLVM; the only
2014 Feb 11
1
Order of istream and ostream chains
Hi, I'm creating a scrambler plugin, that adds an istream and an ostream to the stream-chain for the mail input/output. It works well until the zlib plugin is added to the configuration. The scrambler should run before the zlib and encrypt the mail before it's compressed. Since, the plugin is named lib18_scrambler_... (and the other lib20_zlib....), that works well when a mail is
2018 Jun 12
2
Proper method to initialize all LLVM Internal Data Structures?
Hi: I'm building a small tool on top of LLVM Core Library. ``` LLVMContext context; SMDiagnostic diag; Module *M = parseIRFile(InputIR, diag, context).get(); if (M == nullptr) { diag.print("LLVM", errs()); exit(-1); } assert(M->isMaterialized() && "Module not materialized!"); PointerType *ArrayPtrTy =
2009 Aug 25
4
[LLVMdev] std::cout << *MyModule does not work anymore
It seems that support for dumping text representation of LLVM objects to standard channels and C++ output streams was removed. My guess is that now we must use errs() instead of std::cerr, llvm::raw_fd_ostream instead of std::ofstream, etc. The changes are not trivial, as for instance llvm::raw_fd_ostream without flags fails if the file exists, but std::ofstream does not. The changes include
2010 Apr 01
0
[LLVMdev] raw_os_ostream: symbol not found
On Apr 1, 2010, at 3:52 PM, Trevor Harmon wrote: > Hi, > > I'm writing some code that prints to std::ostream. However, it seems > that all of the LLVM objects can only print to llvm::raw_ostream, so I > can't do this: > > void write(std::ostream &out) { > ... > for (BasicBlock::iterator i = block->begin(), e = block->end(); i ! > = e;
2016 Nov 20
3
uninitialized values in Attributes.cpp
I did a RelWithDebInfo + asserts build of LLVM just now and, when running "make check" under Valgrind, am seeing a lot of uses of uninitialized memory like the one below. Anyone know offhand what's likely to be the root cause? Unfortunately a Debug build doesn't give these errors. Thanks, John FAIL: LLVM :: Analysis/BasicAA/pr18573.ll (2093 of 18733)
2018 Oct 02
2
2.3.3: Panic: file ostream-zlib.c: line 37 (o_stream_zlib_close): assertion failed
I see this in my logs after 2.3.3: using zlib plugin, ofc. Oct 02 10:01:39 imap(user at example.com)<50643></2k4Sjp3vMqC496W>: Panic: file ostream-zlib.c: line 37 (o_stream_zlib_close): assertion failed: (zstream->ostream.finished || zstream->ostream.ostream.stream_errno != 0 || zstream->ostream.error_handling_disabled) Oct 02 10:01:39 imap(user at
2010 Apr 20
3
zlib Plugin Dovecot 2.0 - ostream
Hello Everyone... In zlib save mail have it: struct ostream *output; There is a way to get the file descriptor from output used in ostream zlib plugin ? to get in istream is i_stream_get_fd, but don't have o_stream_get_fd......
2013 Jul 29
2
[LLVMdev] opt -O3 causes Assertion `New->getType() == getType() && "replaceAllUses of value with new value of different type!"' failed
I am hitting an LLVM assertion from the llc tool iff the bitcode file is optimized at -O3 level by opt). -O1 and -O2 levels of opt do not cause this assert. LLVM version 3.4svn DEBUG build with assertions. Built Jul 14 2013 (15:39:08). Default target: x86_64-unknown-linux-gnu Host CPU: amdfam10 I have attached the input bc file before -O3 optimization :bzip2.del.bc.tgz I have attached
2004 Jul 06
1
[LLVMdev] AsmWriter.cpp:255: error: ambiguous overload for `std::basic_ostream<char,...
Hi guys Is some one able to explain me, why these errors emerge: gmake[2]: Entering directory `/usr/local/src/llvm/lib/VMCore' Compiling AsmWriter.cpp AsmWriter.cpp: In function `void WriteConstantInt(std::ostream&, const llvm::Constant*, bool, std::map<const llvm::Type*, std::string, std::less<const llvm::Type*>, std::allocator<std::pair<const llvm::Type* const,
2012 Sep 19
1
[LLVMdev] Saving code for later execution
I'm using the LLVM C++ API to create code on-the-fly for execution. This works fine. But what if I want to save this code to disk, quit, relaunch my app at some later time, reload the previously generated code off disk, and execute it? How can I do that? Can somebody point me to some documentation or examples? Thanks. - Paul
2006 Dec 07
7
[LLVMdev] #include <iostream>
Hi all, With the newest patches to LLVM, there should be no reason for having "#include <iostream>" in any library source code file, except for lib/ Support/Streams.cpp. Please use the following instead: OLD NEW --- --- std::ostream llvm::OStream std::istream llvm::IStream std::cerr llvm::cerr std::cerr llvm::cout
2016 Nov 20
3
uninitialized values in Attributes.cpp
Well, it looks like almost all of the problems go away when I build using trunk instead of 3.9. So, that was scary but I'm going to forget it ever happened. >8000 test cases failed under Valgrind!! John On 11/20/2016 03:03 AM, Sanjoy Das via llvm-dev wrote: > Hi John, > > This is probably somewhat of a stretch, but since the problem does not > happen with a Debug build,
2013 Aug 02
2
[LLVMdev] opt -O3 causes Assertion `New->getType() == getType() && "replaceAllUses of value with new value of different type!"' failed
Hi Hal, I have filed http://llvm.org/bugs/show_bug.cgi?id=16780 -Milind On Fri, Aug 2, 2013 at 9:15 AM, Hal Finkel <hfinkel at anl.gov> wrote: > Milind, > > Have you filed a bug on this? If not, can you please open a bug report (http://llvm.org/bugs)? > > -Hal > > ----- Original Message ----- >> I am hitting an LLVM assertion from the llc tool iff the bitcode