search for: bitcoderead

Displaying 20 results from an estimated 221 matches for "bitcoderead".

Did you mean: bitcodereader
2008 Oct 03
0
[LLVMdev] memory leaks in *Type::get() and Constant*::get()
...o common reports by valgrind: 240 (144 direct, 96 indirect) bytes in 3 blocks are definitely lost in loss record 17 of 20 at 0x4023614: operator new(unsigned) (in vgpreload_memcheck.so) by 0x866B4B3: llvm::PointerType::get(llvm::Type const*, unsigned) (Type.cpp:1319) by 0x85E656E: llvm::BitcodeReader::ParseTypeTable() (BitcodeReader.cpp:498) by 0x85EDDB1: llvm::BitcodeReader::ParseModule(std::string const&) (BitcodeReader.cpp:1078) by 0x85EF35F: llvm::BitcodeReader::ParseBitcode() (BitcodeReader.cpp:1367) by 0x85EF40B: llvm::getBitcodeModuleProvider(llvm::MemoryBuffer*, std::...
2020 Jul 20
2
BitcodeReader.cpp bug under LTO
...n resolved yet? We still cannot determine its type then. Is it possible? Regards, Mindong From: Eli Friedman [mailto:efriedma at quicinc.com] Sent: Friday, July 17, 2020 3:06 AM To: chenmindong <chenmindong1 at huawei.com>; llvm-dev <llvm-dev at lists.llvm.org> Subject: RE: [llvm-dev] BitcodeReader.cpp bug under LTO The DelayedShuffles code in BitcodeReader::parseConstants is solving a sort of similar issue; you might be able to borrow the same approach. -Eli From: llvm-dev <llvm-dev-bounces at lists.llvm.org<mailto:llvm-dev-bounces at lists.llvm.org>> On Behalf Of chenmindon...
2020 Jul 16
2
BitcodeReader.cpp bug under LTO
Hi guys, We have found a bug of BitcodeReader.cpp in processing an LTO bitcode file. As LLVM doesn't emit use-list for LTO bitcode files, many forward references will happen when BitcodeReader processes the bitcode file, and LLVM uses placeholders for those forward references and resolve them later. When parseConstants() reads in a CST_...
2011 Jun 11
0
[LLVMdev] Kaleidoscope Build Error
..._empty_rep_storage' > BitReader.cpp:(.text+0x1cc): undefined reference to `std::basic_string<char, > std::char_traits<char>, std::allocator<char> >>::_Rep::_M_destroy(std::allocator<char> const&)' > /homes/malecha/tmp/llvm/lib/ocaml/libLLVMBitReader.a(BitcodeReader.o): In > function `llvm::BitcodeReader::MaterializeModule(llvm::Module*, > std::basic_string<char, std::char_traits<char>, std::allocator<char> >*)': > BitcodeReader.cpp:(.text+0x1eb): undefined reference to `operator > delete(void*)' > /homes/malecha/tmp/...
2011 Jul 25
4
[LLVMdev] Lack of use of LLVMContextImpl::NamedStructTypes
Several people on this list have reported issues with the linker regarding a named StructType instance with the same name in two different modules being resolved into two StructTypes with different names due to StructType:: setName(…) collision behavior. Looking at BitcodeReader::ParseTypeTableBody(…), I don't see use of LLVMContextImpl::NamedStructTypes or of Module::getTypeByName(…). Nor do I see this use anywhere else in BitcodeReader's implementation (.cpp file). Doesn't the context's NamedStructTypes (checking for a previously created StructType wi...
2013 Jan 04
0
[LLVMdev] Help with linking llvm 3.2 into an .so
...a linux application that uses LLVM from version 3.0 to 3.2, and I’m getting a relocation error that I didn’t used to get with the older version of LLVM. I believe that I correctly turned on fPIC, but I’m getting this warning anyway: /usr/bin/ld: /scratch/thirdparty/default/lib/libLLVMBitReader.a(BitcodeReader.o): relocation R_X86_64_PC32 against `llvm::Use::set(llvm::Value*)' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: final link failed: Bad value Does anyone have an idea what the issue might be? // make command line for BitCodeReader.o if g++ -I/home/dami...
2013 Jan 04
0
[LLVMdev] Help with linking llvm 3.2 into an .so
...a linux application that uses LLVM from version 3.0 to 3.2, and I’m getting a relocation error that I didn’t used to get with the older version of LLVM. I believe that I correctly turned on fPIC, but I’m getting this warning anyway: /usr/bin/ld: /scratch/thirdparty/default/lib/libLLVMBitReader.a(BitcodeReader.o): relocation R_X86_64_PC32 against `llvm::Use::set(llvm::Value*)' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: final link failed: Bad value Does anyone have an idea what the issue might be? // make command line for BitCodeReader.o if g++ -I/home/damie...
2012 Sep 26
0
[LLVMdev] [PATCH / PROPOSAL] bitcode encoding that is ~15% smaller for large bitcode files...
...on body block (FUNCTION_BLOCK_ID and FUNCTION_BLOCK_REL_ID) > + // describes function bodies. It can contain a constant block > + // (CONSTANTS_BLOCK_ID). > enum FunctionCodes { > FUNC_CODE_DECLAREBLOCKS = 1, // DECLAREBLOCKS: [n] > > diff --git a/lib/Bitcode/Reader/BitcodeReader.cpp b/lib/Bitcode/Reader/BitcodeReader.cpp > index b69a362..5fd3dfd 100644 > --- a/lib/Bitcode/Reader/BitcodeReader.cpp > +++ b/lib/Bitcode/Reader/BitcodeReader.cpp ... > @@ -1495,6 +1497,12 @@ bool BitcodeReader::ParseModule(bool Resume) { > SeenFirstFunctionBody = true...
2010 Oct 25
5
[LLVMdev] llvm-dis fails to parse bytecode emitted by clang
Hi, I am trying to generate LLVM bytecode using CLANG and I ran into the following problem. If I run clang with the -emit-llvm option and then try to get a textual representation of the output using llvm-dis, the latter crashes because of a failed assertion in BitCodeReader.cpp, mentioning a "Type mismatch in value table" (the exact error message is appended at the end of this email). However, if I generate the bytecode from the same source using llvm-gcc instead of clang, llvm-dis works fine. I am also experiencing another (potentially unrelated problem)...
2009 Jul 10
0
[LLVMdev] void llvm::PATypeHolder::addRef(): Assertion `Ty && "Type Holder has a null type!"' failed.
...190) at Type.cpp:1575 #9 0x0000000001584b8f in llvm::DerivedType::unlockedRefineAbstractTypeTo (this=0x1d77780, NewType=0x1d54190) at Type.cpp:1473 #10 0x0000000001584cba in llvm::DerivedType::refineAbstractTypeTo (this=0x1d77780, NewType=0x1d54190) at Type.cpp:1493 #11 0x0000000000deedda in llvm::BitcodeReader::ParseTypeTable (this=0x1d75530) at BitcodeReader.cpp:580 #12 0x0000000000df230e in llvm::BitcodeReader::ParseModule (this=0x1d75530, ModuleID="receptacle-plug-test.bc") at BitcodeReader.cpp:1142 #13 0x0000000000df39b6 in llvm::BitcodeReader::ParseBitcode (this=0x1d75530) at BitcodeRead...
2007 May 14
2
[LLVMdev] reading a module from a memory string (BitCode)
>> Apparently BitcodeReader.h is only in lib/Bitcode/Reader/ but not in >> include, so a make install does not install it. >I'm not sure what you mean... the header is in include/llvm/Bitcode. >> Is it supposed to be accessible from applications? How exactly? I feel that >> some install rule is mi...
2011 Feb 24
2
[LLVMdev] Valgrind memcheck errors in llvm
...970750E: llvm::StringRef::operator std::string() const (StringRef.h:176) ==24227== by 0x9D22519: llvm::Module::Module(llvm::StringRef, llvm::LLVMContext&) (Module.cpp:61) ==24227== by 0x99FCD1D: llvm::getLazyBitcodeModule(llvm::MemoryBuffer*, llvm::LLVMContext&, std::string*) (BitcodeReader.cpp:2641) ==24227== by 0x99FCDF8: llvm::ParseBitcodeFile(llvm::MemoryBuffer*, llvm::LLVMContext&, std::string*) (BitcodeReader.cpp:2660) ==24227== Mismatched free() / delete / delete [] ==24227== at 0x40257ED: free (vg_replace_malloc.c:366) ==24227== by 0x9D765EF: llvm::ExecutionE...
2009 Oct 31
3
[LLVMdev] Something wrong with my libpthread.so
...0003df28332f5 gsignal + 53 4 libc.so.6 0x0000003df2834b20 abort + 384 5 libc.so.6 0x0000003df282c2fa __assert_fail + 234 6 lli 0x000000000085ece9 llvm::SmallVectorImpl<llvm::Instruction*>::operator[](unsigned int) + 77 7 lli 0x0000000000850ce0 llvm::BitcodeReader::ParseMetadataAttachment() + 448 8 lli 0x0000000000851043 llvm::BitcodeReader::ParseFunctionBody(llvm::Function*) + 677 9 lli 0x0000000000854b29 llvm::BitcodeReader::materializeFunction(llvm::Function*, std::string*) + 323 10 lli 0x0000000000c6a073 llvm::J...
2013 Jul 29
2
[LLVMdev] opt -O3 causes Assertion `New->getType() == getType() && "replaceAllUses of value with new value of different type!"' failed
...60eb10 4 libc.so.6 0x000000332fa30265 gsignal + 53 5 libc.so.6 0x000000332fa31d10 abort + 272 6 libc.so.6 0x000000332fa296e6 __assert_fail + 246 7 llc 0x00000000014702df llvm::Value::replaceAllUsesWith(llvm::Value*) + 173 8 llc 0x00000000006b91e3 llvm::BitcodeReaderValueList::ResolveConstantForwardRefs() + 1127 9 llc 0x00000000006b9d97 llvm::BitcodeReader::ParseConstants() + 339 10 llc 0x00000000006bc634 llvm::BitcodeReader::ParseFunctionBody(llvm::Function*) + 594 11 llc 0x00000000006c2d63 llvm::BitcodeReader::Materializ...
2015 May 15
3
[LLVMdev] RFC: ThinLTO Impementation Plan
...data during the ThinLTO pass finalization (i.e. after all function > >>> importing is complete). This actually applies to all module-level > >>> metadata, not just debug, although it is the largest. This can be > >>> added as a separate set of patches. Changes to BitcodeReader, > >>> ValueMapper, ModuleLinker > >> > >> It sounds like this would work well with the "full" LTO implemented > >> by tools/gold-plugin right now. What exactly did you do to improve > >> this? > > > > I don't think it wil...
2010 Oct 26
0
[LLVMdev] llvm-dis fails to parse bytecode emitted by clang
...: > > Hi, > > I am trying to generate LLVM bytecode using CLANG and I ran into the > following problem. If I run clang with the -emit-llvm option and then > try to get a textual representation of the output using llvm-dis, the > latter crashes because of a failed assertion in BitCodeReader.cpp, > mentioning a "Type mismatch in value table" (the exact error message > is appended at the end of this email). However, if I generate the > bytecode from the same source using llvm-gcc instead of clang, > llvm-dis works fine. > > I am also experiencing another (...
2011 Jul 25
0
[LLVMdev] Lack of use of LLVMContextImpl::NamedStructTypes
...om> wrote: > Several people on this list have reported issues with the linker regarding a > named StructType instance with the same name in two different modules > being resolved into two StructTypes with different names due to StructType:: > setName(…) collision behavior. Looking at BitcodeReader::ParseTypeTableBody(…), > I don't see use of LLVMContextImpl::NamedStructTypes or of Module::getTypeByName(…). > Nor do I see this use anywhere else in BitcodeReader's implementation (.cpp file). The BitcodeReader has nothing to do with the issue in question; the relevant code is i...
2011 Jul 27
0
[LLVMdev] Linking opaque types
...ContainedTys && "Element number out of range!"), function getElementType, file /Users/talin/Projects/llvm/include/llvm/DerivedTypes.h, line 268. 5 0x0000000100158f27 in llvm::StructType::getElementType (this=0x10180f310, N=0) at DerivedTypes.h:268 #6 0x00000001001b8b54 in llvm::BitcodeReader::ParseConstants (this=0x101813800) at /Users/talin/Projects/llvm/lib/Bitcode/Reader/BitcodeReader.cpp:1256 #7 0x00000001001be481 in llvm::BitcodeReader::ParseModule (this=0x101813800) at /Users/talin/Projects/llvm/lib/Bitcode/Reader/BitcodeReader.cpp:1578 #8 0x00000001001bf8fb in llvm::BitcodeR...
2007 Dec 26
2
[LLVMdev] Instantiating modules from .bc files
...to take the output from llvm-gcc and actually use it in another program. I tried to get a module out of a file that I'd read in to it using this code: MemoryBuffer* memBuf = MemoryBuffer::getFile(filename, sizeof filename, &errStr); printf("errStr: %s\n", errStr.c_str()); BitcodeReader::BitcodeReader bcReader(memBuf); Module* Mod = bcReader.materializeModule(&errInfo); printf("errInfo: %s\n", errInfo.c_str()); verifyModule(*Mod, PrintMessageAction); The errStr and the errInfo strings were empty, but I got a crash on the verifyModule call. The filename was pr...
2013 Aug 02
2
[LLVMdev] opt -O3 causes Assertion `New->getType() == getType() && "replaceAllUses of value with new value of different type!"' failed
...53 >> 5 libc.so.6 0x000000332fa31d10 abort + 272 >> 6 libc.so.6 0x000000332fa296e6 __assert_fail + 246 >> 7 llc 0x00000000014702df >> llvm::Value::replaceAllUsesWith(llvm::Value*) + 173 >> 8 llc 0x00000000006b91e3 >> llvm::BitcodeReaderValueList::ResolveConstantForwardRefs() + 1127 >> 9 llc 0x00000000006b9d97 >> llvm::BitcodeReader::ParseConstants() + 339 >> 10 llc 0x00000000006bc634 >> llvm::BitcodeReader::ParseFunctionBody(llvm::Function*) + 594 >> 11 llc 0x000...