MCPcopy Index your code
hub / github.com/python/cpython / _new_buffersize

Function _new_buffersize

Lib/_pyio.py:1486–1494  ·  view source on GitHub ↗
(bytes_read)

Source from the content-addressed store, hash-verified

1484
1485
1486def _new_buffersize(bytes_read):
1487 # Parallels _io/fileio.c new_buffersize
1488 if bytes_read > 65536:
1489 addend = bytes_read >> 3
1490 else:
1491 addend = 256 + bytes_read
1492 if addend < DEFAULT_BUFFER_SIZE:
1493 addend = DEFAULT_BUFFER_SIZE
1494 return bytes_read + addend
1495
1496
1497class FileIO(RawIOBase):

Callers 1

readallMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…