Re: [PATCH] Remove Powerpc OProfile events the kernel will reject

William Cohen <[email protected]>
Newsgroups gmane.linux.oprofile
Message-ID <[email protected]>
On 11/17/2015 12:02 PM, Carl E. Love wrote:
> On Mon, 2015-11-16 at 17:38 -0500, William Cohen wrote:
>>
>> Hi Carl,
>>
>> So if I am reading the comment around line 326 the code is allowed to
>> have the msb of cache_sel be 1 so long as the lower 3 bits are zero.
>> Thus, 8 and 0 are allowed in for the cache_sel nibble and the
>> currently proposed patch does exclude the problem pmu events.
>>
> 
> That is the way I read it.  When I tested the events with a cache field
> of 8 were not rejected.  Unfortunately, I can't verify the accuracy of
> the counts.  
> 
> Basically I took the entire events file (events/ppc64/power8/events),
> ran some scripts on it to extract the event names for all of the events
> that are not commented out.  The list of names were then put into a
> script file to run each of the events on a simple workload to verify if
> the events were accepted or rejected.  I claim that after the patch is
> applied, all of the remaining events will be accepted as a valid event
> by the kernel.  
> 
> I don't have the documentation on the HW bug to validate that the
> comment in the code is accurate and the results of events with a cache
> field of 8 really do work.  
> 
> 
>> The libpfm4/lib/events/power8.h has:
>>
>> * Documentation on the PMU events will be published at:
>> *  http://www.power.org/documentation
>>
> Yea, I tried the web site and the site doesn't seem to exist.  I sent
> off an email to the IBM HW team to find out what is going on.  I will
> let you know when I can track down a working link.  Thanks for noticing
> the link is broken.
> 
>               Carl Love

Hi Carl,

The patch for eliminating the problem power 8 pmu events looks reasonable, so I committed it to the oprofile repository.  Thanks for the fix.

When a proper pointer to the power8 pmu counter documentation becomes available there should be a patch to utils/ophelp.c.  It currently has the following in there, but search for "Power ISA 2.07" doesn't turn up anything on the www.power.org website.

	case CPU_PPC64_ARCH_V1:
	case CPU_PPC64_POWER8:
		event_doc =
			"This processor type is fully supported with operf.\n"
			"See Power ISA 2.07 at https://www.power.org/\n\n";
		break;

-Will

------------------------------------------------------------------------------
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.