From aca1839f02ed75481f08af98c0e0dad054ece158 Mon Sep 17 00:00:00 2001 From: Mike Urbach Date: Thu, 21 Nov 2024 18:52:11 -0800 Subject: [PATCH] Convert a couple handshake cocotb tests to float for comparison. --- .../Dialect/Handshake/multiple_loops/multiple_loops.py | 4 ++-- .../Dialect/Handshake/nested_loops/nested_loops.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/integration_test/Dialect/Handshake/multiple_loops/multiple_loops.py b/integration_test/Dialect/Handshake/multiple_loops/multiple_loops.py index 26fd5fb18332..39c68dcee650 100644 --- a/integration_test/Dialect/Handshake/multiple_loops/multiple_loops.py +++ b/integration_test/Dialect/Handshake/multiple_loops/multiple_loops.py @@ -29,8 +29,8 @@ async def sendMultiple(dut): res0 = [i * (i + 1) / 2 for i in range(N)] res1 = [math.factorial(i) for i in range(N)] - out0Check = cocotb.start_soon(out0.checkOutputs(res0)) - out1Check = cocotb.start_soon(out1.checkOutputs(res1)) + out0Check = cocotb.start_soon(out0.checkOutputs(res0, converter=float)) + out1Check = cocotb.start_soon(out1.checkOutputs(res1, converter=float)) for i in range(N): in0Send = cocotb.start_soon(in0.send(i)) diff --git a/integration_test/Dialect/Handshake/nested_loops/nested_loops.py b/integration_test/Dialect/Handshake/nested_loops/nested_loops.py index a54d380630ac..467daa0aa634 100644 --- a/integration_test/Dialect/Handshake/nested_loops/nested_loops.py +++ b/integration_test/Dialect/Handshake/nested_loops/nested_loops.py @@ -26,7 +26,7 @@ async def sendMultiple(dut): # sum_{i = 0}^n (sum_{j=0}^i i) = 1/6 * (n^3 + 3n^2 + 2n) res = [(1 / 6) * (n**3 + 3 * n**2 + 2 * n) for n in range(N)] - out0Check = cocotb.start_soon(out0.checkOutputs(res)) + out0Check = cocotb.start_soon(out0.checkOutputs(res, converter=float)) for i in range(N): in0Send = cocotb.start_soon(in0.send(i))