Browse Source

Change sort for single instanced procedures

gingerBill 2 weeks ago
parent
commit
1fc1d8e451
1 changed files with 7 additions and 0 deletions
  1. 7 0
      src/llvm_backend_utility.cpp

+ 7 - 0
src/llvm_backend_utility.cpp

@@ -2949,6 +2949,13 @@ gb_internal void lb_do_para_poly_diagnostics(lbGenerator *gen) {
 			return +1;
 		}
 
+		if (x->total_code_size > y->total_code_size) {
+			return -1;
+		}
+		if (x->total_code_size < y->total_code_size) {
+			return +1;
+		}
+
 		return string_compare(x->canonical_name, y->canonical_name);
 	});