added heapCompare flags