diff --git a/llvm/include/llvm/IR/DebugInfoMetadata.h b/llvm/include/llvm/IR/DebugInfoMetadata.h --- a/llvm/include/llvm/IR/DebugInfoMetadata.h +++ b/llvm/include/llvm/IR/DebugInfoMetadata.h @@ -1643,8 +1643,8 @@ /// written explicitly by the user (e.g. cleanup stuff in C++ put on a closing /// bracket). It's useful for code coverage to not show a counter on "empty" /// lines. - bool isImplicitCode() const { return ImplicitCode; } - void setImplicitCode(bool ImplicitCode) { this->ImplicitCode = ImplicitCode; } + bool isImplicitCode() const { return SubclassData1; } + void setImplicitCode(bool ImplicitCode) { SubclassData1 = ImplicitCode; } DIFile *getFile() const { return getScope()->getFile(); } StringRef getFilename() const { return getScope()->getFilename(); } diff --git a/llvm/include/llvm/IR/Metadata.h b/llvm/include/llvm/IR/Metadata.h --- a/llvm/include/llvm/IR/Metadata.h +++ b/llvm/include/llvm/IR/Metadata.h @@ -67,10 +67,8 @@ /// Storage flag for non-uniqued, otherwise unowned, metadata. unsigned char Storage : 7; - // TODO: expose remaining bits to subclasses. - - unsigned char ImplicitCode : 1; + unsigned char SubclassData1 : 1; unsigned short SubclassData16 = 0; unsigned SubclassData32 = 0; @@ -82,7 +80,7 @@ protected: Metadata(unsigned ID, StorageType Storage) - : SubclassID(ID), Storage(Storage), ImplicitCode(false) { + : SubclassID(ID), Storage(Storage), SubclassData1(false) { static_assert(sizeof(*this) == 8, "Metadata fields poorly packed"); }