diff options
author | Julian Taylor <juliantaylor108@gmail.com> | 2018-09-14 21:38:19 +0200 |
---|---|---|
committer | Julian Taylor <juliantaylor108@gmail.com> | 2018-09-20 18:11:18 +0200 |
commit | c6b418fc5bbdeb9c34c3939ee41bf3cd36445c69 (patch) | |
tree | afae7e3559e6a37d239a4ef5b2723067347aa5a8 /benchmarks | |
parent | de4893119139aad52b181324d1c9ce4862b1abc1 (diff) | |
download | numpy-c6b418fc5bbdeb9c34c3939ee41bf3cd36445c69.tar.gz |
BENCH: add out of place memcpy benchmark
Diffstat (limited to 'benchmarks')
-rw-r--r-- | benchmarks/benchmarks/bench_io.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/benchmarks/benchmarks/bench_io.py b/benchmarks/benchmarks/bench_io.py index ce30c4345..879f9b69e 100644 --- a/benchmarks/benchmarks/bench_io.py +++ b/benchmarks/benchmarks/bench_io.py @@ -21,6 +21,10 @@ class Copy(Benchmark): def time_memcpy(self, typename): self.d[...] = self.e_d + def time_memcpy_large_out_of_place(self, typename): + l = np.ones(1024**2, dtype=np.dtype(typename)) + l.copy() + def time_cont_assign(self, typename): self.d[...] = 1 |