Skip to content

Commit

Permalink
improve formatting for unit
Browse files Browse the repository at this point in the history
  • Loading branch information
aktech committed Jul 18, 2024
1 parent b293d84 commit 5b2a3a1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions python_c_extension/c_extension_gil.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ def run_count_in_multiple_threads(count_func=count):


if __name__ == '__main__':
print('Single Thread (C extension): %8f s' % (run_count_in_single_thread(count)))
print('Two Threads (C extension): %8f s' % (run_count_in_multiple_threads(count)))

print('Single Thread (Pure Python): %8f' % (run_count_in_single_thread(count_pure_python)))
print('Two Threads (Pure Python): %8f' % (run_count_in_multiple_threads(count_pure_python)))
print('Single Thread (C extension): %8f (s)' % (run_count_in_single_thread(count)))
print('Two Threads (C extension): %8f (s)' % (run_count_in_multiple_threads(count)))
print("="*100)
print('Single Thread (Pure Python): %8f (s)' % (run_count_in_single_thread(count_pure_python)))
print('Two Threads (Pure Python): %8f (s)' % (run_count_in_multiple_threads(count_pure_python)))

0 comments on commit 5b2a3a1

Please sign in to comment.