mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-12-20 03:17:48 +00:00
[TableGen] Merge single prefix bit in RecordVal into PointerIntPair with Name to reduce memory usage.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239021 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1113,22 +1113,21 @@ public:
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
class RecordVal {
|
||||
Init *Name;
|
||||
PointerIntPair<Init *, 1, bool> NameAndPrefix;
|
||||
RecTy *Ty;
|
||||
unsigned Prefix;
|
||||
Init *Value;
|
||||
|
||||
public:
|
||||
RecordVal(Init *N, RecTy *T, unsigned P);
|
||||
RecordVal(const std::string &N, RecTy *T, unsigned P);
|
||||
RecordVal(Init *N, RecTy *T, bool P);
|
||||
RecordVal(const std::string &N, RecTy *T, bool P);
|
||||
|
||||
const std::string &getName() const;
|
||||
const Init *getNameInit() const { return Name; }
|
||||
const Init *getNameInit() const { return NameAndPrefix.getPointer(); }
|
||||
std::string getNameInitAsString() const {
|
||||
return getNameInit()->getAsUnquotedString();
|
||||
}
|
||||
|
||||
unsigned getPrefix() const { return Prefix; }
|
||||
bool getPrefix() const { return NameAndPrefix.getInt(); }
|
||||
RecTy *getType() const { return Ty; }
|
||||
Init *getValue() const { return Value; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user