summaryrefslogtreecommitdiff
path: root/HST-L/include/dfatool_host.ah
diff options
context:
space:
mode:
authorBirte Kristina Friesel <derf@finalrewind.org>2025-05-15 08:20:02 +0200
committerBirte Kristina Friesel <derf@finalrewind.org>2025-05-15 08:20:02 +0200
commita2931b65cd3ff5a2e77d9564a95aa3368a24533e (patch)
treecb3123bcd67184824909317aa7a3157fdcfba470 /HST-L/include/dfatool_host.ah
parentd8192e05fb13c57fd7ca05af6946093b51aa7d96 (diff)
HST-L: Add AspectC++ support
Diffstat (limited to 'HST-L/include/dfatool_host.ah')
-rw-r--r--HST-L/include/dfatool_host.ah31
1 files changed, 31 insertions, 0 deletions
diff --git a/HST-L/include/dfatool_host.ah b/HST-L/include/dfatool_host.ah
new file mode 100644
index 0000000..db4e441
--- /dev/null
+++ b/HST-L/include/dfatool_host.ah
@@ -0,0 +1,31 @@
+#pragma once
+
+#include <sys/time.h>
+#include "dfatool_host_dpu.ah"
+
+aspect DfatoolHostTiming : public DfatoolHostDPUTiming {
+ unsigned long n_pixels;
+ unsigned int n_bins;
+ unsigned int element_size;
+
+ virtual int getKernel() { return 1; }
+
+ DfatoolHostTiming() {
+ element_size = sizeof(T);
+ }
+
+ advice call("% input_params(...)") : after() {
+ Params* p = tjp->result();
+ n_pixels = p->input_size;
+ n_bins = p->bins;
+ printf("[>>] HST-L | n_dpus=%u n_pixels=%lu n_bins=%u\n", NR_DPUS, n_pixels, n_bins);
+ }
+
+ advice call("% histogram_host(...)") : after() {
+ printf("[--] HST-L | n_dpus=%u n_pixels=%lu n_bins=%u\n", NR_DPUS, n_pixels, n_bins);
+ }
+
+ advice execution("% main(...)") : after() {
+ printf("[<<] HST-L | n_dpus=%u n_pixels=%lu n_bins=%u\n", NR_DPUS, n_pixels, n_bins);
+ }
+};