From: Benjamin Kramer Date: Sat, 30 May 2015 13:52:30 +0000 (+0000) Subject: [MC] Reorder MCSymbol members to reduce padding. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=bfe336579508019149f6d264e52e1d013a5b5713;p=oota-llvm.git [MC] Reorder MCSymbol members to reduce padding. sizeof(MCSymbol) goes from 72 to 64 bytes on x86_64. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238655 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/MC/MCSymbol.h b/include/llvm/MC/MCSymbol.h index 33fadbc00f7..f6bb1a7d35f 100644 --- a/include/llvm/MC/MCSymbol.h +++ b/include/llvm/MC/MCSymbol.h @@ -72,11 +72,6 @@ class MCSymbol { /// symbol has no size this field will be NULL. const MCExpr *SymbolSize = nullptr; - /// The alignment of the symbol, if it is 'common', or -1. - // - // FIXME: Pack this in with other fields? - unsigned CommonAlign = -1U; - union { /// The offset to apply to the fragment address to form this symbol's value. uint64_t Offset; @@ -85,6 +80,11 @@ class MCSymbol { uint64_t CommonSize; }; + /// The alignment of the symbol, if it is 'common', or -1. + // + // FIXME: Pack this in with other fields? + unsigned CommonAlign = -1U; + /// The Flags field is used by object file implementations to store /// additional per symbol information which is not easily classified. mutable uint32_t Flags = 0;