Lines Matching refs:Bitcode
22 #include <llvm/Bitcode/ReaderWriter.h>
50 // information about a supplied bitcode input file.
252 static size_t readBitcode(const char **bitcode) {
277 *bitcode = (const char*) calloc(1, bitcodeSize + 1);
278 size_t nread = fread((void*) *bitcode, 1, bitcodeSize, in);
288 static void releaseBitcode(const char **bitcode) {
289 if (bitcode && *bitcode) {
290 free((void*) *bitcode);
291 *bitcode = nullptr;
303 const char *bitcode = nullptr;
304 size_t bitcodeSize = readBitcode(&bitcode);
308 bcinfo::BitcodeWrapper bcWrapper((const char *)bitcode, bitcodeSize);
325 BT.reset(new bcinfo::BitcodeTranslator(bitcode, bitcodeSize, version));
327 fprintf(stderr, "failed to translate bitcode\n");
369 fprintf(stderr, "error: failed to parse bitcode file\n");
390 releaseBitcode(&bitcode);