Home
last modified time | relevance | path

Searched refs:MemoryBuffer (Results 1 – 25 of 315) sorted by relevance

12345678910>>...13

/external/llvm/lib/Support/
DMemoryBuffer.cpp41 MemoryBuffer::~MemoryBuffer() { } in ~MemoryBuffer()
45 void MemoryBuffer::init(const char *BufStart, const char *BufEnd, in init()
83 class MemoryBufferMem : public MemoryBuffer {
104 static ErrorOr<std::unique_ptr<MemoryBuffer>>
108 std::unique_ptr<MemoryBuffer>
109 MemoryBuffer::getMemBuffer(StringRef InputData, StringRef BufferName, in getMemBuffer()
113 return std::unique_ptr<MemoryBuffer>(Ret); in getMemBuffer()
116 std::unique_ptr<MemoryBuffer>
117 MemoryBuffer::getMemBuffer(MemoryBufferRef Ref, bool RequiresNullTerminator) { in getMemBuffer()
118 return std::unique_ptr<MemoryBuffer>(getMemBuffer( in getMemBuffer()
[all …]
/external/llvm/include/llvm/Support/
DMemoryBuffer.h36 class MemoryBuffer {
40 MemoryBuffer(const MemoryBuffer &) = delete;
41 MemoryBuffer &operator=(const MemoryBuffer &) = delete;
43 MemoryBuffer() {} in MemoryBuffer() function
47 virtual ~MemoryBuffer();
71 static ErrorOr<std::unique_ptr<MemoryBuffer>>
78 static ErrorOr<std::unique_ptr<MemoryBuffer>>
88 static ErrorOr<std::unique_ptr<MemoryBuffer>>
94 static std::unique_ptr<MemoryBuffer>
98 static std::unique_ptr<MemoryBuffer>
[all …]
/external/swiftshader/third_party/LLVM/include/llvm/Support/
DMemoryBuffer.h35 class MemoryBuffer {
39 MemoryBuffer(const MemoryBuffer &); // DO NOT IMPLEMENT
40 MemoryBuffer &operator=(const MemoryBuffer &); // DO NOT IMPLEMENT
42 MemoryBuffer() {} in MemoryBuffer() function
46 virtual ~MemoryBuffer();
66 static error_code getFile(StringRef Filename, OwningPtr<MemoryBuffer> &result,
70 OwningPtr<MemoryBuffer> &result,
77 OwningPtr<MemoryBuffer> &result,
85 static MemoryBuffer *getMemBuffer(StringRef InputData,
92 static MemoryBuffer *getMemBufferCopy(StringRef InputData,
[all …]
DIRReader.h35 inline Module *getLazyIRModule(MemoryBuffer *Buffer, in getLazyIRModule()
61 OwningPtr<MemoryBuffer> File; in getLazyIRFileModule()
62 if (error_code ec = MemoryBuffer::getFileOrSTDIN(Filename.c_str(), File)) { in getLazyIRFileModule()
75 inline Module *ParseIR(MemoryBuffer *Buffer, in ParseIR()
98 OwningPtr<MemoryBuffer> File; in ParseIRFile()
99 if (error_code ec = MemoryBuffer::getFileOrSTDIN(Filename.c_str(), File)) { in ParseIRFile()
/external/swiftshader/third_party/LLVM/lib/Support/
DMemoryBuffer.cpp45 MemoryBuffer::~MemoryBuffer() { } in ~MemoryBuffer()
49 void MemoryBuffer::init(const char *BufStart, const char *BufEnd, in init()
79 class MemoryBufferMem : public MemoryBuffer {
98 MemoryBuffer *MemoryBuffer::getMemBuffer(StringRef InputData, in getMemBuffer()
108 MemoryBuffer *MemoryBuffer::getMemBufferCopy(StringRef InputData, in getMemBufferCopy()
110 MemoryBuffer *Buf = getNewUninitMemBuffer(InputData.size(), BufferName); in getMemBufferCopy()
121 MemoryBuffer *MemoryBuffer::getNewUninitMemBuffer(size_t Size, in getNewUninitMemBuffer()
146 MemoryBuffer *MemoryBuffer::getNewMemBuffer(size_t Size, StringRef BufferName) { in getNewMemBuffer()
147 MemoryBuffer *SB = getNewUninitMemBuffer(Size, BufferName); in getNewMemBuffer()
158 error_code MemoryBuffer::getFileOrSTDIN(StringRef Filename, in getFileOrSTDIN()
[all …]
/external/llvm/unittests/Support/
DLineIteratorTest.cpp20 std::unique_ptr<MemoryBuffer> Buffer = MemoryBuffer::getMemBuffer("line 1\n" in TEST()
44 std::unique_ptr<MemoryBuffer> Buffer( in TEST()
45 MemoryBuffer::getMemBuffer("line 1\n" in TEST()
73 std::unique_ptr<MemoryBuffer> Buffer( in TEST()
74 MemoryBuffer::getMemBuffer("line 1\n" in TEST()
110 std::unique_ptr<MemoryBuffer> Buffer = MemoryBuffer::getMemBuffer("\n\n\n" in TEST()
133 std::unique_ptr<MemoryBuffer> Buffer = MemoryBuffer::getMemBuffer("\n\n" in TEST()
170 std::unique_ptr<MemoryBuffer> Buffer = MemoryBuffer::getMemBuffer(""); in TEST()
176 Buffer = MemoryBuffer::getMemBuffer("\n\n\n"); in TEST()
180 Buffer = MemoryBuffer::getMemBuffer("# foo\n" in TEST()
[all …]
DMemoryBufferTest.cpp38 typedef std::unique_ptr<MemoryBuffer> OwningBuffer;
45 OwningBuffer MB1(MemoryBuffer::getMemBuffer(data)); in TEST_F()
49 OwningBuffer MB2(MemoryBuffer::getMemBuffer(data, "one", false)); in TEST_F()
53 OwningBuffer MB3(MemoryBuffer::getMemBuffer(data, "two", true)); in TEST_F()
80 ErrorOr<OwningBuffer> MB = MemoryBuffer::getFile(TestPath.c_str()); in TEST_F()
91 OwningBuffer MBC1(MemoryBuffer::getMemBufferCopy(data)); in TEST_F()
95 OwningBuffer MBC2(MemoryBuffer::getMemBufferCopy(data, "copy")); in TEST_F()
104 OwningBuffer Zero(MemoryBuffer::getNewUninitMemBuffer(0)); in TEST_F()
108 OwningBuffer One(MemoryBuffer::getNewUninitMemBuffer(321)); in TEST_F()
112 OwningBuffer Two(MemoryBuffer::getNewUninitMemBuffer(123, "bla")); in TEST_F()
[all …]
/external/llvm/unittests/ExecutionEngine/MCJIT/
DMCJITObjectCacheTest.cpp36 std::unique_ptr<MemoryBuffer> getObject(const Module *M) override { in getObject()
37 const MemoryBuffer* BufferFound = getObjectInternal(M); in getObject()
43 return MemoryBuffer::getMemBufferCopy(BufferFound->getBuffer()); in getObject()
54 const MemoryBuffer* getObjectInternal(const Module* M) { in getObjectInternal()
57 StringMap<const MemoryBuffer *>::iterator it = ObjMap.find(ModuleID); in getObjectInternal()
64 MemoryBuffer *copyBuffer(MemoryBufferRef Buf) { in copyBuffer()
66 std::unique_ptr<MemoryBuffer> NewBuffer = in copyBuffer()
67 MemoryBuffer::getMemBufferCopy(Buf.getBuffer()); in copyBuffer()
68 MemoryBuffer *Ret = NewBuffer.get(); in copyBuffer()
73 StringMap<const MemoryBuffer *> ObjMap;
[all …]
/external/llvm/lib/AsmParser/
DParser.cpp28 std::unique_ptr<MemoryBuffer> Buf = MemoryBuffer::getMemBuffer(F); in parseAssemblyInto()
51 ErrorOr<std::unique_ptr<MemoryBuffer>> FileOrErr = in parseAssemblyFile()
52 MemoryBuffer::getFileOrSTDIN(Filename); in parseAssemblyFile()
73 std::unique_ptr<MemoryBuffer> Buf = MemoryBuffer::getMemBuffer(Asm); in parseConstantValue()
90 std::unique_ptr<MemoryBuffer> Buf = MemoryBuffer::getMemBuffer(Asm); in parseType()
102 std::unique_ptr<MemoryBuffer> Buf = MemoryBuffer::getMemBuffer(Asm); in parseTypeAtBeginning()
/external/swiftshader/third_party/LLVM/test/Bindings/Ocaml/
Dbitreader.ml24 let mb = Llvm.MemoryBuffer.of_file fn in
29 Llvm.MemoryBuffer.dispose mb;
34 (* MemoryBuffer.of_file *)
36 let mb = Llvm.MemoryBuffer.of_file (fn ^ ".bogus") in
37 Llvm.MemoryBuffer.dispose mb;
45 let mb = Llvm.MemoryBuffer.of_file fn in
49 Llvm.MemoryBuffer.dispose mb;
65 let mb = Llvm.MemoryBuffer.of_file fn in
69 Llvm.MemoryBuffer.dispose mb;
/external/llvm/test/Bindings/OCaml/
Dbitreader.ml31 let mb = Llvm.MemoryBuffer.of_file fn in
36 Llvm.MemoryBuffer.dispose mb;
41 (* MemoryBuffer.of_file *)
43 let mb = Llvm.MemoryBuffer.of_file (fn ^ ".bogus") in
44 Llvm.MemoryBuffer.dispose mb;
52 let mb = Llvm.MemoryBuffer.of_file fn in
56 Llvm.MemoryBuffer.dispose mb;
72 let mb = Llvm.MemoryBuffer.of_file fn in
76 Llvm.MemoryBuffer.dispose mb;
/external/llvm/include/llvm/ProfileData/
DSampleProfReader.h259 SampleProfileReader(std::unique_ptr<MemoryBuffer> B, LLVMContext &C) in SampleProfileReader()
296 create(std::unique_ptr<MemoryBuffer> &B, LLVMContext &C);
313 std::unique_ptr<MemoryBuffer> Buffer;
324 SampleProfileReaderText(std::unique_ptr<MemoryBuffer> B, LLVMContext &C) in SampleProfileReaderText()
334 static bool hasFormat(const MemoryBuffer &Buffer);
339 SampleProfileReaderBinary(std::unique_ptr<MemoryBuffer> B, LLVMContext &C) in SampleProfileReaderBinary()
349 static bool hasFormat(const MemoryBuffer &Buffer);
410 SampleProfileReaderGCC(std::unique_ptr<MemoryBuffer> B, LLVMContext &C) in SampleProfileReaderGCC()
420 static bool hasFormat(const MemoryBuffer &Buffer);
DInstrProfReader.h111 create(std::unique_ptr<MemoryBuffer> Buffer);
125 std::unique_ptr<MemoryBuffer> DataBuffer;
135 TextInstrProfReader(std::unique_ptr<MemoryBuffer> DataBuffer_) in TextInstrProfReader()
140 static bool hasFormat(const MemoryBuffer &Buffer);
166 std::unique_ptr<MemoryBuffer> DataBuffer;
190 RawInstrProfReader(std::unique_ptr<MemoryBuffer> DataBuffer) in RawInstrProfReader()
193 static bool hasFormat(const MemoryBuffer &DataBuffer);
363 std::unique_ptr<MemoryBuffer> DataBuffer;
381 IndexedInstrProfReader(std::unique_ptr<MemoryBuffer> DataBuffer) in IndexedInstrProfReader()
385 static bool hasFormat(const MemoryBuffer &DataBuffer);
[all …]
/external/clang/lib/ARCMigrate/
DFileRemapper.cpp66 llvm::ErrorOr<std::unique_ptr<llvm::MemoryBuffer>> fileBuf = in initFromFile()
67 llvm::MemoryBuffer::getFile(infoFile.c_str()); in initFromFile()
152 llvm::MemoryBuffer *mem = I->second.get<llvm::MemoryBuffer *>(); in flushToFile()
173 assert(I->second.is<llvm::MemoryBuffer *>()); in overwriteOriginal()
183 llvm::MemoryBuffer *mem = I->second.get<llvm::MemoryBuffer *>(); in overwriteOriginal()
198 llvm::MemoryBuffer *mem = I->second.get<llvm::MemoryBuffer *>(); in applyMappings()
207 std::unique_ptr<llvm::MemoryBuffer> memBuf) { in remap()
212 std::unique_ptr<llvm::MemoryBuffer> memBuf) { in remap()
245 if (llvm::MemoryBuffer *oldmem = targ.dyn_cast<llvm::MemoryBuffer *>()) { in resetTarget()
/external/swiftshader/third_party/LLVM/lib/AsmParser/
DParser.cpp25 Module *llvm::ParseAssembly(MemoryBuffer *F, in ParseAssembly()
45 OwningPtr<MemoryBuffer> File; in ParseAssemblyFile()
46 if (error_code ec = MemoryBuffer::getFileOrSTDIN(Filename.c_str(), File)) { in ParseAssemblyFile()
57 MemoryBuffer *F = in ParseAssemblyString()
58 MemoryBuffer::getMemBuffer(StringRef(AsmString, strlen(AsmString)), in ParseAssemblyString()
/external/llvm/bindings/python/llvm/tests/
Dtest_core.py2 from ..core import MemoryBuffer
32 MemoryBuffer(filename=source)
36 MemoryBuffer(filename="/hopefully/this/path/doesnt/exist")
40 m = MemoryBuffer(filename=source)
76 m = parse_bitcode(MemoryBuffer(filename=self.get_test_bc()))
92 m = parse_bitcode(MemoryBuffer(filename=self.get_test_bc()))
114 m = parse_bitcode(MemoryBuffer(filename=self.get_test_bc()))
/external/clang/unittests/Basic/
DSourceManagerTest.cpp75 std::unique_ptr<llvm::MemoryBuffer> Buf = in TEST_F()
76 llvm::MemoryBuffer::getMemBuffer(source); in TEST_F()
129 std::unique_ptr<llvm::MemoryBuffer> Buf = in TEST_F()
130 llvm::MemoryBuffer::getMemBuffer(Source); in TEST_F()
189 std::unique_ptr<llvm::MemoryBuffer> HeaderBuf = in TEST_F()
190 llvm::MemoryBuffer::getMemBuffer(header); in TEST_F()
191 std::unique_ptr<llvm::MemoryBuffer> MainBuf = in TEST_F()
192 llvm::MemoryBuffer::getMemBuffer(main); in TEST_F()
290 std::unique_ptr<llvm::MemoryBuffer> HeaderBuf = in TEST_F()
291 llvm::MemoryBuffer::getMemBuffer(header); in TEST_F()
[all …]
/external/swiftshader/third_party/LLVM/include/llvm/Object/
DBinary.h22 class MemoryBuffer; variable
35 MemoryBuffer *Data;
37 Binary(unsigned int Type, MemoryBuffer *Source);
61 error_code createBinary(MemoryBuffer *Source, OwningPtr<Binary> &Result);
/external/llvm/lib/IRReader/
DIRReader.cpp33 getLazyIRModule(std::unique_ptr<MemoryBuffer> Buffer, SMDiagnostic &Err, in getLazyIRModule()
54 ErrorOr<std::unique_ptr<MemoryBuffer>> FileOrErr = in getLazyIRFileModule()
55 MemoryBuffer::getFileOrSTDIN(Filename); in getLazyIRFileModule()
87 ErrorOr<std::unique_ptr<MemoryBuffer>> FileOrErr = in parseIRFile()
88 MemoryBuffer::getFileOrSTDIN(Filename); in parseIRFile()
107 std::unique_ptr<MemoryBuffer> MB(unwrap(MemBuf)); in LLVMParseIRInContext()
/external/swiftshader/third_party/LLVM/lib/Object/
DBinary.cpp31 Binary::Binary(unsigned int Type, MemoryBuffer *Source) in Binary()
43 error_code object::createBinary(MemoryBuffer *Source, in createBinary()
45 OwningPtr<MemoryBuffer> scopedSource(Source); in createBinary()
99 OwningPtr<MemoryBuffer> File; in createBinary()
100 if (error_code ec = MemoryBuffer::getFileOrSTDIN(Path, File)) in createBinary()
DObjectFile.cpp24 ObjectFile::ObjectFile(unsigned int Type, MemoryBuffer *source, error_code &ec) in ObjectFile()
28 ObjectFile *ObjectFile::createObjectFile(MemoryBuffer *Object) { in createObjectFile()
58 OwningPtr<MemoryBuffer> File; in createObjectFile()
59 if (error_code ec = MemoryBuffer::getFile(ObjectPath, File)) in createObjectFile()
/external/clang/include/clang/Lex/
DHeaderMap.h32 std::unique_ptr<const llvm::MemoryBuffer> FileBuffer;
36 HeaderMapImpl(std::unique_ptr<const llvm::MemoryBuffer> File, bool NeedsBSwap) in HeaderMapImpl()
40 static bool checkHeader(const llvm::MemoryBuffer &File, bool &NeedsByteSwap);
68 HeaderMap(std::unique_ptr<const llvm::MemoryBuffer> File, bool BSwap) in HeaderMap()
/external/swiftshader/third_party/LLVM/tools/llvm-cov/
Dllvm-cov.cpp47 OwningPtr<MemoryBuffer> GCNO_Buff; in main()
48 if (error_code ec = MemoryBuffer::getFileOrSTDIN(InputGCNO, GCNO_Buff)) { in main()
59 OwningPtr<MemoryBuffer> GCDA_Buff; in main()
60 if (error_code ec = MemoryBuffer::getFileOrSTDIN(InputGCDA, GCDA_Buff)) { in main()
/external/swiftshader/third_party/LLVM/lib/ExecutionEngine/RuntimeDyld/
DRuntimeDyldImpl.h73 virtual bool loadObject(MemoryBuffer *InputBuffer) = 0;
94 virtual bool isCompatibleFormat(const MemoryBuffer *InputBuffer) const = 0;
138 bool loadObject(MemoryBuffer *InputBuffer);
142 static bool isKnownFormat(const MemoryBuffer *InputBuffer);
144 bool isCompatibleFormat(const MemoryBuffer *InputBuffer) const { in isCompatibleFormat()
/external/clang/include/clang/ARCMigrate/
DFileRemapper.h20 class MemoryBuffer; variable
35 typedef llvm::PointerUnion<const FileEntry *, llvm::MemoryBuffer *> Target;
55 void remap(StringRef filePath, std::unique_ptr<llvm::MemoryBuffer> memBuf);
62 void remap(const FileEntry *file, std::unique_ptr<llvm::MemoryBuffer> memBuf);

12345678910>>...13