From 2debe9805244b5078c0b1e7a48fc2a98b04fe367 Mon Sep 17 00:00:00 2001 From: VakarisZ Date: Tue, 12 May 2020 12:43:41 +0300 Subject: [PATCH] Profiling decorator: added readme and profiler logs added to gitignore --- .gitignore | 3 +++ monkey/monkey_island/cc/testing/README.md | 9 +++++++++ 2 files changed, 12 insertions(+) create mode 100644 monkey/monkey_island/cc/testing/README.md diff --git a/.gitignore b/.gitignore index a10127767..3b602d4aa 100644 --- a/.gitignore +++ b/.gitignore @@ -85,5 +85,8 @@ MonkeyZoo/* # Exported monkey telemetries /monkey/telem_sample/ +# Profiling logs +/monkey/profiler_logs/ + # vim swap files *.swp diff --git a/monkey/monkey_island/cc/testing/README.md b/monkey/monkey_island/cc/testing/README.md new file mode 100644 index 000000000..1c1446b2f --- /dev/null +++ b/monkey/monkey_island/cc/testing/README.md @@ -0,0 +1,9 @@ +# Profiling island + +To profile specific methods on island a `@profile(sort_args=['cumulative'], print_args=[100])` +decorator can be used. +Use it as any other decorator. After decorated method is used, a file will appear in a +directory provided in `profiler_decorator.py`. Filename describes the path of +the method that was profiled. For example if method `monkey_island/cc/resources/netmap.get` +was profiled, then the results of this profiling will appear in +`monkey_island_cc_resources_netmap_get`.