From: "Steven Rostedt (Google)" <rostedt@xxxxxxxxxxx> This patch set is based on top of: https://lore.kernel.org/all/20230808161204.5704-1-stevie.6strings@xxxxxxxxx/ I added a sample program task-eval which is one of the tools that will be using this library. The first patch adds task-eval but that is still using the old API (defined in trace-analysis.c). The next patches modify the new API to fit with the use case of task-eval. One is to use "pointer" as I'm not sure exactly the usecase of the dynamic structure. The cmp and release callbacks are changed to be more generic, and they get called if they simply exist for a given type. I can imagine wanting a release function for event the most mundane types (like number_32). The cmp was also updated to pass in the traceeval descriptor, as I found that I needed access to it while doing a compare (although, I rewrote the code a bit where that use case isn't in the tool anymore). Some fixes were made to the query. The last patch updates the task-eval to use the new API. It added stubs that are needed for the display portion. These can be implemented later. Note, when running the new task-eval, it crashes immediately, so there's lots of bugs to still fix in the existing histogram code. Happy programming! Steven Rostedt (Google) (6): libtraceeval: Add sample task-eval program libtraceeval hist: Add pointer and const string types libtraceeval histogram: Have cmp and release functions be generic libtraceeval histograms: Add traceeval struct to compare function libtraceeval histogram: Fix the return value of traceeval_query() libtraceeval samples: Update task-eval to use the histogram logic Makefile | 3 + include/traceeval-hist.h | 38 +- samples/Makefile | 29 ++ samples/task-eval.c | 948 +++++++++++++++++++++++++++++++++++++++ src/histograms.c | 48 +- 5 files changed, 1026 insertions(+), 40 deletions(-) create mode 100644 samples/Makefile create mode 100644 samples/task-eval.c -- 2.40.1