summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGRecordLayoutBuilder.h
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/CodeGen/CGRecordLayoutBuilder.h')
-rw-r--r--clang/lib/CodeGen/CGRecordLayoutBuilder.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGRecordLayoutBuilder.h b/clang/lib/CodeGen/CGRecordLayoutBuilder.h
index bca0b5c1429..ff551a4f135 100644
--- a/clang/lib/CodeGen/CGRecordLayoutBuilder.h
+++ b/clang/lib/CodeGen/CGRecordLayoutBuilder.h
@@ -36,6 +36,9 @@ class CGRecordLayoutBuilder {
/// Packed - Whether the resulting LLVM struct will be packed or not.
bool Packed;
+ /// Alignment - Contains the alignment of the RecordDecl.
+ unsigned Alignment;
+
/// AlignmentAsLLVMStruct - Will contain the maximum alignment of all the
/// LLVM types.
unsigned AlignmentAsLLVMStruct;
@@ -69,7 +72,7 @@ class CGRecordLayoutBuilder {
llvm::SmallVector<LLVMBitFieldInfo, 16> LLVMBitFields;
CGRecordLayoutBuilder(CodeGenTypes &Types)
- : Types(Types), Packed(false), AlignmentAsLLVMStruct(1)
+ : Types(Types), Packed(false), Alignment(0), AlignmentAsLLVMStruct(1)
, BitsAvailableInLastField(0), NextFieldOffsetInBytes(0) { }
/// Layout - Will layout a RecordDecl.
OpenPOWER on IntegriCloud