I'm currently working on a HDD component for PAPI-C but have some trouble with the PAPI_event_name_to_code routine. I've created the component according to the given ACPI and Ethernet components and adapted the PAPI source files accoring to the wiki.

I've configured PAPI-C with --with-acpi=yes, --with-net=yes and --with-hdd=yes (my component) and it compiled without problems.

A call to PAPI_num_components() gives the correct result of 4 and the even the values of the component_info type returned by PAPI_get_component_info() are as expected.However, when I try to create an event set and therefore call PAPI_event_name_to_code(), PAPI does not find the event. With events of the other three components it works fine. Does someone have an idea what the reason might be why the event is not found? Did I miss something?

When you call papi_native_avail, does it also list the new events from the HDD component???If so, try to declare your EventSet with only one of those new HDD events (as shown by papi_native_avail) and then call PAPI_event_name_to_code.-heik

thanks for the tip with papi_native_avail. That segfaulted in a strncpy when it should come to the HDD events and so I eventually discovered that I forgot the commas between the name and the description string of the events in the native event table. It now seems to work.

Thanks, Michael

P.S. Is there a possibility to commit that component to the PAPI-C CVS when finished?

Knobi wrote:P.S. Is there a possibility to commit that component to the PAPI-C CVS when finished?

Apologies for the long delay in responding. We're entering new territory here. We want to encourage people to develop novel, useful and innovative components for PAPI. We also want to provide a mechanism to distribute those components as broadly as possible. However, we're concerned about accepting the burden for testing and maintaining components produced by others as part of the mainline PAPI source tree.

We may be able to set up a separate repository for third party components and we may somehow require components to pass some kind of acceptance testing before being incorporated into the source tree. But this is all new ground to explore.

Maybe this is an opportunity to use something like sourceforge as a clearing house for PAPI Components.

For any of this to work smoothly, we need to develop a mechanism whereby components can be separately compiled and discovered at run-time rather than the clunky inclusion in the build at configure time the way we do things now.