Commit 56b3a40e authored by Antoine Pitrou's avatar Antoine Pitrou

Issue #4663: increase the chunk size to improve TextIOWrapper performance on small reads.

Text I/O is still 10x to 100x slower than 2.x!
parent 2674aacb
...@@ -1373,7 +1373,7 @@ class TextIOWrapper(TextIOBase): ...@@ -1373,7 +1373,7 @@ class TextIOWrapper(TextIOBase):
write contains a newline character. write contains a newline character.
""" """
_CHUNK_SIZE = 128 _CHUNK_SIZE = 2048
def __init__(self, buffer, encoding=None, errors=None, newline=None, def __init__(self, buffer, encoding=None, errors=None, newline=None,
line_buffering=False): line_buffering=False):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment