@@ -131,7 +131,7 @@ static std::string computeDataLayout(const Triple &TT) {
131131
132132 Ret += DataLayout::getManglingComponent (TT);
133133 // X86 and x32 have 32 bit pointers.
134- if (! TT.isArch64Bit () || TT.isX32 ())
134+ if (TT.getArch () != Triple::x86_64 || TT.isX32 ())
135135 Ret += " -p:32:32" ;
136136
137137 // Address spaces for 32 bit signed, 32 bit unsigned, and 64 bit pointers.
@@ -140,7 +140,7 @@ static std::string computeDataLayout(const Triple &TT) {
140140 // Some ABIs align 64 bit integers and doubles to 64 bits, others to 32.
141141 // 128 bit integers are not specified in the 32-bit ABIs but are used
142142 // internally for lowering f128, so we match the alignment to that.
143- if (TT.isArch64Bit () || TT.isOSWindows ())
143+ if (TT.getArch () == Triple::x86_64 || TT.isOSWindows ())
144144 Ret += " -i64:64-i128:128" ;
145145 else if (TT.isOSIAMCU ())
146146 Ret += " -i64:32-f64:32" ;
@@ -150,7 +150,8 @@ static std::string computeDataLayout(const Triple &TT) {
150150 // Some ABIs align long double to 128 bits, others to 32.
151151 if (TT.isOSIAMCU ())
152152 ; // No f80
153- else if (TT.isArch64Bit () || TT.isOSDarwin () || TT.isWindowsMSVCEnvironment ())
153+ else if (TT.getArch () == Triple::x86_64 || TT.isOSDarwin () ||
154+ TT.isWindowsMSVCEnvironment ())
154155 Ret += " -f80:128" ;
155156 else
156157 Ret += " -f80:32" ;
@@ -159,13 +160,13 @@ static std::string computeDataLayout(const Triple &TT) {
159160 Ret += " -f128:32" ;
160161
161162 // The registers can hold 8, 16, 32 or, in x86-64, 64 bits.
162- if (TT.isArch64Bit () )
163+ if (TT.getArch () == Triple::x86_64 )
163164 Ret += " -n8:16:32:64" ;
164165 else
165166 Ret += " -n8:16:32" ;
166167
167168 // The stack is aligned to 32 bits on some ABIs and 128 bits on others.
168- if ((! TT.isArch64Bit () && TT.isOSWindows ()) || TT.isOSIAMCU ())
169+ if ((TT.getArch () != Triple::x86_64 && TT.isOSWindows ()) || TT.isOSIAMCU ())
169170 Ret += " -a:0:32-S32" ;
170171 else
171172 Ret += " -S128" ;
0 commit comments