Building LLVM with -DEXPENSIVE_CHECKS fails with the following error message with libstdc++ in debug mode:
Error: comparison doesn't meet irreflexive requirements, assert(!(a < a)).
The patch fixes the comparison function SizeOrder by returning false when comparing two equal items.