As the Title says, this causes crashes if you go
AttributeList::get(getContext(), { AttributeList(),AttributeList() });
It is sensitive to I/O, I have no idea why it is I/O sensitive but it is, at least it disappears when logging is turned on in LDC (the LLVM D Compiler) without fail.
Sometimes the last function in the stacktrace is
_vsnprintf + 586 llvm::AttributeList::get(llvm::LLVMContext&, llvm::ArrayRef<llvm::AttributeList>) + 798
Anyway this appears to fix this and will speed up merges of null AttributeList.
Nicholas