LLVM 20.0.0git
Macros | Functions
BitcodeAnalyzer.cpp File Reference
#include "llvm/Bitcode/BitcodeAnalyzer.h"
#include "llvm/Bitcode/BitcodeReader.h"
#include "llvm/Bitcode/LLVMBitCodes.h"
#include "llvm/Bitstream/BitCodes.h"
#include "llvm/Bitstream/BitstreamReader.h"
#include "llvm/Support/Format.h"
#include "llvm/Support/SHA1.h"
#include <optional>

Go to the source code of this file.

Macros

#define STRINGIFY_CODE(PREFIX, CODE)
 

Functions

static Error reportError (StringRef Message)
 
static std::optional< const char * > GetBlockName (unsigned BlockID, const BitstreamBlockInfo &BlockInfo, CurStreamTypeType CurStreamType)
 Return a symbolic block name if known, otherwise return null.
 
static std::optional< const char * > GetCodeName (unsigned CodeID, unsigned BlockID, const BitstreamBlockInfo &BlockInfo, CurStreamTypeType CurStreamType)
 Return a symbolic code name if known, otherwise return null.
 
static void printSize (raw_ostream &OS, double Bits)
 
static void printSize (raw_ostream &OS, uint64_t Bits)
 
static Expected< CurStreamTypeTypeReadSignature (BitstreamCursor &Stream)
 
static Expected< CurStreamTypeTypeanalyzeHeader (std::optional< BCDumpOptions > O, BitstreamCursor &Stream)
 
static bool canDecodeBlob (unsigned Code, unsigned BlockID)
 

Macro Definition Documentation

◆ STRINGIFY_CODE

#define STRINGIFY_CODE (   PREFIX,
  CODE 
)
Value:
case bitc::PREFIX##_##CODE: \
return #CODE;
#define _

Function Documentation

◆ analyzeHeader()

static Expected< CurStreamTypeType > analyzeHeader ( std::optional< BCDumpOptions O,
BitstreamCursor Stream 
)
static

◆ canDecodeBlob()

static bool canDecodeBlob ( unsigned  Code,
unsigned  BlockID 
)
static

◆ GetBlockName()

static std::optional< const char * > GetBlockName ( unsigned  BlockID,
const BitstreamBlockInfo BlockInfo,
CurStreamTypeType  CurStreamType 
)
static

◆ GetCodeName()

static std::optional< const char * > GetCodeName ( unsigned  CodeID,
unsigned  BlockID,
const BitstreamBlockInfo BlockInfo,
CurStreamTypeType  CurStreamType 
)
static

◆ printSize() [1/2]

static void printSize ( raw_ostream OS,
double  Bits 
)
static

Definition at line 425 of file BitcodeAnalyzer.cpp.

References llvm::format(), and OS.

Referenced by llvm::BitcodeAnalyzer::printStats().

◆ printSize() [2/2]

static void printSize ( raw_ostream OS,
uint64_t  Bits 
)
static

Definition at line 428 of file BitcodeAnalyzer.cpp.

References llvm::format(), and OS.

◆ ReadSignature()

static Expected< CurStreamTypeType > ReadSignature ( BitstreamCursor Stream)
static

◆ reportError()

static Error reportError ( StringRef  Message)
static