2
0
mirror of https://github.com/m-labs/artiq.git synced 2024-12-25 03:08:27 +08:00

test/coredevice/primes: keep output list entirely on the host

This commit is contained in:
Sebastien Bourdeauducq 2015-12-31 09:49:37 +08:00
parent 787a1d34fe
commit 17802d3cff

View File

@ -20,6 +20,9 @@ class _Primes(EnvExperiment):
self.setattr_argument("output_list")
self.setattr_argument("maximum")
def _add_output(self, x):
self.output_list.append(x)
@kernel
def run(self):
for x in range(1, self.maximum):
@ -31,7 +34,7 @@ class _Primes(EnvExperiment):
break
d += 1
if prime:
self.output_list.append(x)
self._add_output(x)
class _Misc(EnvExperiment):