diff --git a/gen/abi-x86-64.cpp b/gen/abi-x86-64.cpp index 71939aa3..933df668 100644 --- a/gen/abi-x86-64.cpp +++ b/gen/abi-x86-64.cpp @@ -400,6 +400,15 @@ namespace x86_64_D_cc { bool retStructInRegs(TypeStruct* st) { // 'fastcc' allows returns in up to two registers of each kind: DRegCount state(2, 2, 2); + #if 1 + // TODO: Disable this if and when LLVM PR 3861 gets fixed. + + // LLVM currently doesn't allow a second int to be an i1 or i8. + // (See ) + // Rather than complicating shouldPassStructInRegs(), just disallow + // second integers for now. + state.ints = 1; + #endif return shouldPassStructInRegs(st, state); }