From c36996e5ca4ea047e55778004a99d9f7cad9282f Mon Sep 17 00:00:00 2001 From: Birte Kristina Friesel Date: Tue, 13 May 2025 16:11:44 +0200 Subject: GEMV: Add AspectC++ support --- GEMV/include/dfatool_host.ah | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 GEMV/include/dfatool_host.ah (limited to 'GEMV/include/dfatool_host.ah') diff --git a/GEMV/include/dfatool_host.ah b/GEMV/include/dfatool_host.ah new file mode 100644 index 0000000..bc2d512 --- /dev/null +++ b/GEMV/include/dfatool_host.ah @@ -0,0 +1,27 @@ +#pragma once + +#include +#include "dfatool_host_dpu.ah" + +aspect DfatoolHostTiming : public DfatoolHostDPUTiming { + + uint32_t kernel = 1; + + DfatoolHostTiming() { + element_size = sizeof(T); + } + + advice call("% input_params(...)") : after() { + Params* p = tjp->result(); + input_size = p->n_size * p->m_size; + printf("[>>] GEMV | n_dpus=%u n_elements=%lu\n", NR_DPUS, input_size); + } + + advice call("% gemv_host(...)") : after() { + printf("[--] GEMV | n_dpus=%u n_elements=%lu\n", NR_DPUS, input_size); + } + + advice execution("% main(...)") : after() { + printf("[<<] GEMV | n_dpus=%u n_elements=%lu\n", NR_DPUS, input_size); + } +}; -- cgit v1.2.3