Accelerating transitive closure of large-scale sparse graphs