{"repo":"christophebedard/instrument-attribute-gcc-plugin","free":true,"listed":false,"github":"https://github.com/christophebedard/instrument-attribute-gcc-plugin","clone":"git clone https://github.com/christophebedard/instrument-attribute-gcc-plugin.git","description":"gcc plugin providing an instrument_function attribute and other flags to allow-list functions to be instrumented","language":"C","stars":32,"topics":["gcc","gcc-plugin","instrumentation","whitelisting","instrument-functions","lttng","babeltrace","tracing","allow-list"],"license":null,"category":"analytics","readme_excerpt":"instrument-attribute-gcc-plugin gcc plugin providing an instrument function attribute and other gcc flags to specify which functions should be instrumented. What it does When enabling function instrumentation ( -finstrument-functions ), the built-in flags ( -finstrument-functions-exclude-file-list=file,file,… , -finstrument-functions-exclude-function-list=sym,sym,… ) and attribute ( no instrument function ) only allow you to exclude functions from being instrumented. This plugin allows you to instrument individual functions, by: adding the instrument function attribute to a function giving a list of paths to files with function definitions ( -fplugin-arg-instrument attribute-include-file-list=file,file,… ) giving a list of function names ( -fplugin-arg-instrument attribute-include-function-list=sym,sym,… ) giving a list of function names for exact matching ( -fplugin-arg-instrument attribute-include-exact-function-list=sym,sym,… ) For example, you might want to use this when you want to instrument only select functions and avoid instrumenting everything , since it adds a measurable overhead. Of course, you will have to keep in mind that not all functions were instrumented when interpreting the data. For example, the self-time of a function may be misleading if only a portion of the functions it calls are instrumented. Build the plugin This has been tested with gcc 7.4.0, 7.5.0, 8.4.0, 9.3.0, and 10.2.0, but it probably works with other versions as well. Download plugin header","default_branch":null,"files":null,"tree":[],"storefront":"/r/christophebedard","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/christophebedard/instrument-attribute-gcc-plugin/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}