Jacob Champion <pchamp...@pivotal.io> writes: > ... since the > root cause is that we're not defining a valid ordering, quicksort may > or may not behave consistently for test purposes.
Ah, gotcha. But whether the behavior is sane or not, it'd be reproducible for any specific input dataset on any specific platform (unless you've got a quicksort that actually uses randomized pivots; but ours doesn't, and I think that pg_dump does use src/port/qsort.c). So that partially answers Andrew's question as to why we've not seen instability in the buildfarm's results. It also seems entirely possible that we simply don't have any cases in the existing test data that provoke the indeterminate behavior --- to judge by your concrete example, it might take specifically-chosen object names to get into a situation where the comparator delivers inconsistent results. regards, tom lane