Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
uPython-mirror
Commits
e918fc5e
Commit
e918fc5e
authored
Jun 08, 2016
by
Paul Sokolovsky
Browse files
tests/bench: Add testcase to compare bytes(N) vs b"\0" * N.
Based on python-dev discussion regarding PEP467.
parent
bba77a2d
Changes
2
Hide whitespace changes
Inline
Side-by-side
tests/bench/bytealloc-1-bytes_n.py
0 → 100644
View file @
e918fc5e
import
bench
def
test
(
num
):
for
i
in
iter
(
range
(
num
//
1000
)):
bytes
(
10000
)
bench
.
run
(
test
)
tests/bench/bytealloc-2-repeat.py
0 → 100644
View file @
e918fc5e
import
bench
def
test
(
num
):
for
i
in
iter
(
range
(
num
//
1000
)):
b
"
\0
"
*
10000
bench
.
run
(
test
)
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment