mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-28 23:17:10 +00:00
For PR761:
The Module::setEndianness and Module::setPointerSize methods have been removed. Instead you can get/set the DataLayout. Adjust thise accordingly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33530 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -189,8 +189,8 @@ void TargetData::init(const std::string &TargetDescription) {
|
||||
}
|
||||
}
|
||||
|
||||
// Unless explicitly specified, the alignments for longs and doubles is capped by
|
||||
// pointer size.
|
||||
// Unless explicitly specified, the alignments for longs and doubles is
|
||||
// capped by pointer size.
|
||||
if (LongABIAlignment == 0)
|
||||
LongABIAlignment = LongPrefAlignment = PointerMemSize;
|
||||
if (DoubleABIAlignment == 0)
|
||||
@@ -198,25 +198,7 @@ void TargetData::init(const std::string &TargetDescription) {
|
||||
}
|
||||
|
||||
TargetData::TargetData(const Module *M) {
|
||||
LittleEndian = M->getEndianness() != Module::BigEndian;
|
||||
PointerMemSize = M->getPointerSize() != Module::Pointer64 ? 4 : 8;
|
||||
PointerABIAlignment = PointerMemSize;
|
||||
DoubleABIAlignment = PointerMemSize;
|
||||
FloatABIAlignment = 4;
|
||||
LongABIAlignment = PointerMemSize;
|
||||
IntABIAlignment = 4;
|
||||
ShortABIAlignment = 2;
|
||||
ByteABIAlignment = 1;
|
||||
BoolABIAlignment = 1;
|
||||
BoolPrefAlignment = BoolABIAlignment;
|
||||
BytePrefAlignment = ByteABIAlignment;
|
||||
ShortPrefAlignment = ShortABIAlignment;
|
||||
IntPrefAlignment = IntABIAlignment;
|
||||
LongPrefAlignment = LongABIAlignment;
|
||||
FloatPrefAlignment = FloatABIAlignment;
|
||||
DoublePrefAlignment = DoubleABIAlignment;
|
||||
PointerPrefAlignment = PointerABIAlignment;
|
||||
AggMinPrefAlignment = 0;
|
||||
init(M->getDataLayout());
|
||||
}
|
||||
|
||||
/// Layouts - The lazy cache of structure layout information maintained by
|
||||
|
Reference in New Issue
Block a user