Bug 474666 - [LTC 5.4 FEAT] Java Support support for OProfile [200979]
[LTC 5.4 FEAT] Java Support support for OProfile [200979]
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: oprofile (Show other bugs)
5.4
ppc64 All
high Severity high
: rc
: 5.4
Assigned To: William Cohen
BaseOS QE
: FutureFeature, OtherQA
Depends On:
Blocks: 445204 483784
  Show dependency treegraph
 
Reported: 2008-12-04 14:50 EST by IBM Bug Proxy
Modified: 2011-01-24 18:35 EST (History)
9 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-09-02 06:03:42 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Patch to change JVMPI agent lib source code to LGPL (1.23 KB, text/plain)
2009-06-22 17:50 EDT, IBM Bug Proxy
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
IBM Linux Technology Center 50372 None None None Never

  None (edit)
Description IBM Bug Proxy 2008-12-04 14:50:36 EST
=Comment: #0=================================================
Emily J. Ratliff <ratliff@austin.ibm.com> - 
1. Feature Overview:
Feature Id:	[200979]
a. Name of Feature:	Java Support support for OProfile
b. Feature Description
Provide infrastructure to profile Java programs running inside a JVM.

2. Feature Details:
Sponsor:	PPC
Architectures:
ppc64

Arch Specificity: Purely Common Code
Delivery Mechanism: Direct from community
Category:	Toolchain
Request Type:	Toolchain - Enhancement from Upstream
d. Upstream Acceptance:	Accepted
Sponsor Priority	1
f. Severity: High
IBM Confidential:	no
Code Contribution:	IBM code
g. Component Version Target:	oProfile 0.9.4 (or later)

3. Business Case
Most IBM Middleware use the IBM JVM. Having good support for profiling Java programs is an important
feature for developing and deploying enterprise server middleware software.

4. Primary contact at Red Hat: 
John Jarvis
jjarvis@redhat.com

5. Primary contacts at Partner:
Project Management Contact:
Michael Hohnbaum, hbaum@us.ibm.com, 503-578-5486

Technical contact(s):
Steven Munroe, sjmunroe@us.ibm.com
Maynard Johnson, mpjohn@us.ibm.com

IBM Manager:
Alexander Johnson, acjohnso@us.ibm.com
Comment 1 IBM Bug Proxy 2008-12-22 15:10:27 EST
Support for profiling Java code with OProfile is now included in OProfile 0.9.4, available at:
http://oprofile.sourceforge.net/download/

Note that special build instructions are required to enable this Java support.  Please see the README_PACKAGERS file in the oprofile root directory for new RPM build instructions.

Also, Will Cohen built an RPM for Fedora and posted a link to it on the
oprofile-list.  Here's the URL to that oprofile-list posting:
http://marc.info/?l=oprofile-list&m=121666815331885&w=2
If you follow the link to the Fedora RPM, you'll see a src rpm that you can
download.  I've done a test rpmbuild of that src rpm and it seems to work correctly on a RHEL 5 system.

NOTE:  I don't think the spec file contained in this src rpm supports the notion of bi-arch -- that is, building both 32-bit and 64-bit libraries.  Since OProfile 0.9.4 includes libraries for the first time (i.e., JIT agent libraries need at runtime for JIT profiling), please be sure to build both 32-bit and 64-bit RPMs.

Also, please build/configure OProfile using a JDK 1.5 in order to build both JVMPI and JVMTI agent libraries.

Thank you for your support.
Comment 2 John Jarvis 2008-12-23 15:38:27 EST
IBM is signed up to test and provide feedback.
Comment 3 IBM Bug Proxy 2009-02-09 17:50:48 EST
Hello, Red Hat,
In today's eSDT call between IBM and Red Hat, I explained that both my ppc64 team and the IBM Cell team had unknowingly opened RHEL 6 feature requests for OProfile.  Both of these requests would be satisfied by shipping OProfile 0.9.4 release in RHEL 6.  But now, the Cell team will no longer be pushing for Cell support in RHEL 6.  They have quit their feature and intend to close their bug.  However, this ppc64 bug (RH474666) will remain open as our feature request is still valid.  I just wanted to clarify the situation to make sure there's no confusion.  Are there any actions needed on the RH side to reflect this situation?  I see that the external target milestone is "alpha", so that's a good sign.

For reference, the Cell team's feature request that was quit was:
"[LTC 6.0 FEAT] 201605:Update of oprofile to 0.9.4 (or later) in RHEL6"
The Red Hat bugzilla opened for that feature was RH462955, and the IBM bugzilla was 48083.
Comment 4 IBM Bug Proxy 2009-02-10 09:30:57 EST
Sigh. . . Please disregard my previous comment since it was made under the mistaken assumption that this is a RHEL 6 feature bugzilla instead of RHEL 5.4  Sorry for the confusion.
Comment 6 John Jarvis 2009-03-24 14:54:53 EDT
This enhancement request was evaluated by the full Red Hat Enterprise Linux 
team for inclusion in a Red Hat Enterprise Linux minor release.   As a 
result of this evaluation, Red Hat has tentatively approved inclusion of 
this feature in the next Red Hat Enterprise Linux Update minor release.   
While it is a goal to include this enhancement in the next minor release 
of Red Hat Enterprise Linux, the enhancement is not yet committed for 
inclusion in the next minor release pending the next phase of actual 
code integration and successful Red Hat and partner testing.
Comment 8 William Cohen 2009-04-21 15:33:41 EDT
java-1.6.0-openjdk is only available for i386 and x86_64 machines. This presents a problem building java enabled oprofile for s390, ia64, and ppc. May need to limit java support to i386 and x86_64.
Comment 9 IBM Bug Proxy 2009-04-21 16:00:31 EDT
------- Comment From sjmunroe@us.ibm.com 2009-04-21 15:57 EDT-------
Why not use the IBM JDK off of extras.
Comment 10 William Cohen 2009-04-21 16:20:20 EDT
I asked about the IBM jdk and it isn't available in the build system's build roots.  java-1.6.0-openjdk was released in RHEL-5.3 and is available in the i386 and x86_64 buildroots. thus, packages dependent on java are only built for i386/x86_64.
Comment 12 IBM Bug Proxy 2009-04-21 18:00:39 EDT
------- Comment From mpjohn@us.ibm.com 2009-04-21 17:57 EDT-------
Will, in fact, the only thing that's needed at build-time for oprofile is the header files -- jvmti.h and jmvpi.h.  So all you need to do is create some dummy <jdk-dir> and an "include" dir underneath it; then copy the two header files from any JDK 1.5 into the include dir.  Then when you invoke oprofile's configure, use '--with-java=<jdk-dir>.  Providing both the jvmpi.h and jvmti.h will result in both JVMPI and JVMTI oprofile libraries being built and installed.  That way, if a user wanted to install their own JDK, we'd be covered with both the older and newer interfaces.
Comment 13 William Cohen 2009-04-22 10:12:58 EDT
I was thinking about this approach also. The question is where to find appropriate jvmti.h and jvmpi.h files. They need to have a compatible license (gpl v2) so they can be included in the oprofile source.
Comment 15 IBM Bug Proxy 2009-04-22 15:20:56 EDT
------- Comment From mpjohn@us.ibm.com 2009-04-22 15:16 EDT-------
The source code for the JVMTI agent library that #includes jvmti.h (agents/jvmti/libjvmti_oprofile.c) states that it's distributed under LGPL, so we should be OK on that one, no matter what JDK you build with.  Unfortunately, the JVMPI agent library source code (agenst/jvmpi/jvmpi_oprofile.cpp) does not have the same LGPL statement.  This was an oversight of mine when I contributed that code.  I will work with the community to change the license for that file.  Then, I think that should resolve your licensing concerns.  Right?
Comment 16 John Jarvis 2009-04-23 16:12:24 EDT
This enhancement request was evaluated by the full Red Hat Enterprise Linux 
team for inclusion in a Red Hat Enterprise Linux minor release.   As a 
result of this evaluation, Red Hat has tentatively approved inclusion of 
this feature in the next Red Hat Enterprise Linux Update minor release.   
While it is a goal to include this enhancement in the next minor release 
of Red Hat Enterprise Linux, the enhancement is not yet committed for 
inclusion in the next minor release pending the next phase of actual 
code integration and successful Red Hat and partner testing.
Comment 17 William Cohen 2009-04-24 15:00:15 EDT
Oprofile 0.9.4-7 has been built to address this bug.
Comment 20 Chris Ward 2009-06-14 19:17:06 EDT
~~ Attention Partners RHEL 5.4 Partner Alpha Released! ~~

RHEL 5.4 Partner Alpha has been released on partners.redhat.com. There should
be a fix present that addresses this particular request. Please test and report back your results here, at your earliest convenience. Our Public Beta release is just around the corner!

If you encounter any issues, please set the bug back to the ASSIGNED state and
describe the issues you encountered. If you have verified the request functions as expected, please set your Partner ID in the Partner field above to indicate successful test results. Do not flip the bug status to VERIFIED. Further questions can be directed to your Red Hat Partner Manager. Thanks!
Comment 21 IBM Bug Proxy 2009-06-22 17:50:30 EDT
------- Comment From mpjohn@us.ibm.com 2009-06-22 17:46 EDT-------
Hello, Will.  I tested the oprofile JIT support on RHEL 5.4.  I installed the IBM 1.5 JRE (java-1.5.0-ibm-1.5.0.9-1jpp.3.el5.ppc.rpm) and successfully profiled a Java app using the -agentlib:jvmti_oprofile option.  Thank you!  However, I found I was unable to do Java profiling when using the 64-bit IBM JRE (java-1.5.0-ibm-1.5.0.9-1jpp.3.el5.ppc64.rpm).  This is due to the fact that the oprofile-jit package was not built for both 32-bit and 64-bit libraries.  Can we get the 64-bit libraries built, too?

Also, we had a conversation back in April (see comments in this bugzilla) about the JVMPI agent library source code (agenst/jvmpi/jvmpi_oprofile.cpp) not
having the LGPL statement.  I fixed that upstream, but neglected to post a patch to this bugzilla so you could go ahead and build the JVMPI oprofile agent library as we discussed.  I've attached that patch now.  Can you integrate that with your oprofile package and build the JVMP library, too?

Thanks.
Comment 22 IBM Bug Proxy 2009-06-22 17:50:35 EDT
Created attachment 349007 [details]
Patch to change JVMPI agent lib source code to LGPL


------- Comment (attachment only) From mpjohn@us.ibm.com 2009-06-22 17:44 EDT-------
Comment 23 Chris Ward 2009-07-03 14:15:16 EDT
~~ Attention - RHEL 5.4 Beta Released! ~~

RHEL 5.4 Beta has been released! There should be a fix present in the Beta release that addresses this particular request. Please test and report back results here, at your earliest convenience. RHEL 5.4 General Availability release is just around the corner!

If you encounter any issues while testing Beta, please describe the issues you have encountered and set the bug into NEED_INFO. If you encounter new issues, please clone this bug to open a new issue and request it be reviewed for inclusion in RHEL 5.4 or a later update, if it is not of urgent severity.

Please do not flip the bug status to VERIFIED. Only post your verification results, and if available, update Verified field with the appropriate value.

Questions can be posted to this bug or your customer or partner representative.
Comment 24 IBM Bug Proxy 2009-07-06 12:01:43 EDT
------- Comment From mpjohn@us.ibm.com 2009-07-06 11:51 EDT-------
Hello, Red Hat.  I posted some comments about the OProfile package back on June 22.  I've not seen a response to those comments yet, so I'm wondering whether or not oprofile got updated (as a result of those comments) in the latest RHEL 5.4 beta.  Thank you.
Comment 27 Chris Ward 2009-07-07 09:29:01 EDT
IBM, this is correct. oprofile was not updated to include the additional change you requested. It should be included though at a later point. At this moment, its hard to say exactly when though. We will update this bugzilla with more information when we get it.
Comment 28 William Cohen 2009-07-07 10:07:55 EDT
For comment #21 As part of the RHEL build, ppc64 versions of the packages are built. There is a ppc64 version of oprofile-jit. However, it is not included in the distribution for ppc in RHEL. It looks like the oprofile-jit for ppc64 will need to be added to the distribution. However, I need to verify that is the complete fix for the problem today.

Will add the appropriate patch to correct the license in #22.
Comment 30 William Cohen 2009-07-07 14:42:41 EDT
In reference to comment #22. Do the additional comments need to be include and the package respun for these comments? None of the binaries rpms include agents/jvmpi/jvmpi_oprofile.cpp.
Comment 31 IBM Bug Proxy 2009-07-07 16:41:09 EDT
------- Comment From mpjohn@us.ibm.com 2009-07-07 16:32 EDT-------
(In reply to comment #27)
> In reference to comment #22. Do the additional comments need to be include and
> the package respun for these comments? None of the binaries rpms include
> agents/jvmpi/jvmpi_oprofile.cpp.
Will,
Our gcc team leader says that comments in source code won't be seen in the binary.  So from a legal standpoint, it's probably not necessary to rebuild the package.  But I would rebuild it anyway, if only so the line numbers match if a user were to ever need to use gdb on that library (assuming debuginfo were made available).   Of course, the patched file should be included in the src rpm.

Thanks.
-Maynard
>
Comment 36 IBM Bug Proxy 2009-07-17 10:01:21 EDT
------- Comment From arobert@us.ibm.com 2009-07-17 09:50 EDT-------
Hi Red Hat - any update on when the code for this feature will be include in a snapshot?
Comment 37 Chris Ward 2009-07-17 10:10:56 EDT
Scheduled for Snapshot 3.
Comment 39 IBM Bug Proxy 2009-07-30 15:00:46 EDT
------- Comment From mpjohn@us.ibm.com 2009-07-30 14:53 EDT-------
Hello, Red Hat.  I examined the oprofile-jit rpms for RHEL 5.4 snap4.  I found that one of the two issues I brought to your attention in my June 22 comment has been fixed -- adding an oprofile-jit.ppc64 rpm with 64-bit JIT agent libraries.  However, the other problem -- no JVMPI agent library -- has not been resolved.  On July 7, Will Cohen indicated that this problem would be addressed, but I'm guessing something was missed in the build.  Can you please resolve this for the next beta?

Thanks for your support.
-Maynard
Comment 40 Chris Ward 2009-07-31 03:52:20 EDT
IBM,

It's getting very late into the release cycle. Chances are lowered daily with
regard to our ability to commit new code into 5.4. Speak with your Partner
Manager for more details about the schedule particulars.

At this phase, we are excepting only release blocker items. Therefore, if you
feel this item must be fixed in RHEL 5.4 as originally planned, it is vital
that you provide a business justification for blocker status as soon as
possible. 

Otherwise, this request will need to be deferred to RHEL 5.5. Please clone this bug and describe the issues encountered in detail.

Thank you for your understanding and expedited response. We are sorry for
any inconvenience this might cause.
Comment 43 William Cohen 2009-07-31 11:20:13 EDT
The way that the Red Hat build system works complicates this a bit. The packages put through the build system need to be buildable with open source packages.  Many of the java packages are not open source. The build system has java openjdk available for only x86 platforms. The work around for this was to include header files from a GPL compatible java in oprofile, then oprofile can be built on the various platforms (ppc, s390, etc).  However, the headers included with the oprofile source were from java-1.6.0-opendjdk-1.6.0. java 1.6.0 only includes support for JVMTI. Need to find similar java 1.5.0 that have support for both JVMTI and JVMPI.
Comment 44 IBM Bug Proxy 2009-07-31 12:00:31 EDT
------- Comment From tpnoonan@us.ibm.com 2009-07-31 11:56 EDT-------
A defect has been opened for this problem: 55195  -  RIT324892- JVMPI agent library missing from oprofile-jit rpm
Comment 45 William Cohen 2009-07-31 15:54:19 EDT
JVMPI has been deprecated for quite some time. The following article from July 1, 2004 and May 2004:

http://java.sun.com/developer/technicalArticles/Programming/jvmpitransition/
http://java.sun.com/developer/technicalArticles/releases/j2se15/

JVMTI is supported on JDK 5 and newer. Are there a significant number of people using JDK 4 (or older) on RHEL5? Is IBM still supporting JDK 4?
Comment 46 IBM Bug Proxy 2009-08-03 14:50:50 EDT
------- Comment From mpjohn@us.ibm.com 2009-08-03 14:40 EDT-------
Closing this bugzilla with the caveat that there is still a missing piece to this feature -- a JVMPI agent library of oprofile.  That problem is being handled via LTC bug # 55195  ( RIT324892 ).
Comment 47 Stephanie Glass 2009-08-04 08:04:04 EDT
> JVMTI is supported on JDK 5 and newer. Are there a significant number of people
> using JDK 4 (or older) on RHEL5? Is IBM still supporting JDK 4?  

From IBM's point of view, the main group of people who still use JDK 4 are the SAP customers.  Our SWG products have all moved away from JDK 4, but the SAP customers have not.  In fact, that is why both Red Hat and IBM are still supporting JDK 4.

Thanks
Stephanie
Comment 48 Eric Bachalo 2009-08-04 11:15:41 EDT
IBM should clone this bug and then request for JDK 4 support for RHEL 5.5

We will not block RHEL 5.4 for this feature request.  We will consider adding JDK 4 support to oprofile in RHEL 5.5

Oprofile in RHEL 5.4 will support JDK 5 and JDK 6.
Comment 50 errata-xmlrpc 2009-09-02 06:03:42 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2009-1322.html
Comment 51 IBM Bug Proxy 2009-09-02 09:41:01 EDT
------- Comment From mpjohn@us.ibm.com 2009-09-02 09:35 EDT-------
(In reply to comment #42)
> An advisory has been issued which should help the problem
> described in this bug report. This report is therefore being
> closed with a resolution of ERRATA. For more information
> on therefore solution and/or where to find the updated files,
> please follow the link below. You may reopen this bug report
> if the solution does not work for you.
>
> http://rhn.redhat.com/errata/RHBA-2009-1322.html
This link is broken.
>
Comment 52 IBM Bug Proxy 2009-09-02 10:42:51 EDT
------- Comment From mpjohn@us.ibm.com 2009-09-02 10:34 EDT-------
(In reply to comment #43)
> (In reply to comment #42)
> > An advisory has been issued which should help the problem
> > described in this bug report. This report is therefore being
> > closed with a resolution of ERRATA. For more information
> > on therefore solution and/or where to find the updated files,
> > please follow the link below. You may reopen this bug report
> > if the solution does not work for you.
> >
> > http://rhn.redhat.com/errata/RHBA-2009-1322.html
> This link is broken.
The link works now.
> >
>

Note You need to log in before you can comment on or make changes to this bug.