18 #ifndef LLVM_BITCODE_BITCODES_H
19 #define LLVM_BITCODE_BITCODES_H
23 #include "llvm/Support/DataTypes.h"
133 if (C >=
'a' && C <=
'z')
return true;
134 if (C >=
'A' && C <=
'Z')
return true;
135 if (C >=
'0' && C <=
'9')
return true;
136 if (C ==
'.' || C ==
'_')
return true;
140 if (C >=
'a' && C <=
'z')
return C-
'a';
141 if (C >=
'A' && C <=
'Z')
return C-
'A'+26;
142 if (C >=
'0' && C <=
'9')
return C-
'0'+26+26;
143 if (C ==
'.')
return 62;
144 if (C ==
'_')
return 63;
149 assert((V & ~63) == 0 &&
"Not a Char6 encoded character!");
150 if (V < 26)
return V+
'a';
151 if (V < 26+26)
return V-26+
'A';
152 if (V < 26+26+10)
return V-26-26+
'0';
153 if (V == 62)
return '.';
154 if (V == 63)
return '_';
173 return static_cast<unsigned>(OperandList.size());
176 return OperandList[
N];
180 OperandList.push_back(OpInfo);
BLOCKINFO_BLOCK is used to define metadata about blocks, for example, standard abbrevs that should be...
BitCodeAbbrev - This class represents an abbreviation record.
const BitCodeAbbrevOp & getOperandInfo(unsigned N) const
void Add(const BitCodeAbbrevOp &OpInfo)
static unsigned EncodeChar6(char C)
LLVM_ATTRIBUTE_NORETURN void report_fatal_error(const char *reason, bool gen_crash_diag=true)
Reports a serious error, calling any installed error handler.
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
StandardBlockIDs
StandardBlockIDs - All bitcode files can optionally include a BLOCKINFO block, which contains metadat...
uint64_t getEncodingData() const
RefCountedBase - A generic base class for objects that wish to have their lifetimes managed using ref...
BlockInfoCodes
BlockInfoCodes - The blockinfo block contains metadata about user-defined blocks. ...
bool hasEncodingData() const
BitCodeAbbrevOp(uint64_t V)
BitCodeAbbrevOp - This describes one or more operands in an abbreviation.
uint64_t getLiteralValue() const
isPodLike - This is a type trait that is used to determine whether a given type can be copied around ...
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small...
DEFINE_ABBREV - Defines an abbrev for the current block.
static char DecodeChar6(unsigned V)
static bool isChar6(char C)
isChar6 - Return true if this character is legal in the Char6 encoding.
static bool hasEncodingData(Encoding E)
unsigned getNumOperandInfos() const
BitCodeAbbrevOp(Encoding E, uint64_t Data=0)
Encoding getEncoding() const