Fully featured low overhead profiler for Java EE and Java SE platforms.
Performance monitoring and profiling of Jenkins, TeamCity, Gradle, Maven, Ant, JUnit and TestNG.
Easy to use performance and memory profiler for .NET framework.

Profile JVM on Raspberry Pi B+ 1.2

Moderators: Vladimir Kondratyev, Anton Katilin

Profile JVM on Raspberry Pi B+ 1.2

Postby tjvanderlaan » Tue Dec 24, 2019 4:42 pm

Hi,

I am trying to profile a Java application which is running on my Raspberry Pi B+ 1.2 headlessly. The profiler for linux-arm-x32 returns a segmentation error and does not work. I found out that this board has an ARM1176 processor which makes use of the ARMv6-processor architecture -- which seems not supported anymore by YourKit?

As a result, I could not find a libyjpagent.so-profiler for this architecture. Are there any (old) and (un)supported profilers available? Thanks!
tjvanderlaan
 
Posts: 7
Joined: Tue Dec 24, 2019 4:28 pm

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Wed Dec 25, 2019 8:48 am

Older profiler versions can be found at
https://www.yourkit.com/download/archive.jsp

Please use the agent from "bin/linux-armv5-sf" from version 2019.1, which is the last one supporting ARMv5.
You'll need to use v2019.1 UI with it.
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Fri Dec 27, 2019 4:35 pm

Hi,

Did the old version help?
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby tjvanderlaan » Mon Dec 30, 2019 7:01 pm

Hi Anton,

Thanks for your reply. Unfortunately not, I've received this error while the file *is* available at this location:
Code: Select all
Could not find agent library /home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv5-sf/libyjpagent.so in absolute path, with error: /home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv5-sf/libyjpagent.so: cannot open shared object file: No such file or directory

Should this agent work on an ARMv6 hard float processor architecture? That is used by the Raspberry Pi B+ 1.2 board.
tjvanderlaan
 
Posts: 7
Joined: Tue Dec 24, 2019 4:28 pm

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Mon Dec 30, 2019 7:29 pm

Hi,
Should this agent work on an ARMv6 hard float processor architecture?

As I understand, yes. This agent is compiled as soft-float ("sf" in the name), so it should work on hardware with hard float too. Also, it targets ARMv5, so should run on ARMv6 as well.

What does this command print?
ldd -r /home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv5-sf/libyjpagent.so
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby tjvanderlaan » Mon Dec 30, 2019 7:55 pm

The ldd command prints the following message:
Code: Select all
ldd -r /home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv5-sf/libyjpagent.so
   not a dynamic executable
tjvanderlaan
 
Posts: 7
Joined: Tue Dec 24, 2019 4:28 pm

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Mon Dec 30, 2019 8:00 pm

What does it show for these?
file /home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv5-sf/libyjpagent.so
uname -a
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby tjvanderlaan » Mon Dec 30, 2019 8:38 pm

The response is;
Code: Select all
 [email protected]:~ $ uname -a
Linux Marantz 4.19.66+ #1253 Thu Aug 15 11:37:30 BST 2019 armv6l GNU/Linux
tjvanderlaan
 
Posts: 7
Joined: Tue Dec 24, 2019 4:28 pm

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby tjvanderlaan » Mon Dec 30, 2019 8:49 pm

And;
Code: Select all
[email protected]:~ $ file /home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv5-sf/libyjpagent.so
/home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv5-sf/libyjpagent.so: ELF 32-bit LSB shared object, ARM, EABI5 version 1 (SYSV), dynamically linked, stripped
tjvanderlaan
 
Posts: 7
Joined: Tue Dec 24, 2019 4:28 pm

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Mon Dec 30, 2019 8:56 pm

Did you try the hard float library from the same version 2019.1?
/home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv7-hf/libyjpagent.so

Does it work with "ldd -r"?

Does Java load it?

Although it has "armv7" in its name, perhaps the compiler de-facto generated instructions for older architecture, and it will work for you. The chance is not big, though.
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Mon Dec 30, 2019 10:30 pm

Update:

Apparently the hard float agent linux-armv7-hf from v2019.1 won't work because it was compiled with GCC targeting
Code: Select all
--with-arch=armv7-a --with-fpu=vfpv3-d16 --with-float=hard
whereas your board likely needs
Code: Select all
--with-arch=armv6 --with-fpu=vfp --with-float=hard


Perhaps it makes sense to try even older profiler versions from the archive. For example, I see that v2016.02 was compiled with a much older compiler than v2019.1. Unfortunately, I cannot provide exact target detail for older versions because it's now extremely difficult to recreate the build environment which existed at the build time.

The best approach I can suggest is to actually try older versions in the archive, one-by-one, to check whether a compatible agent exists.
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Mon Dec 30, 2019 10:41 pm

FYI: the oldest version in the archive with ARM agent is v12.0.6.
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby tjvanderlaan » Tue Dec 31, 2019 8:49 am

Did you try the hard float library from the same version 2019.1?
/home/pi/yourkit/YourKit-JavaProfiler-2019.1/bin/linux-armv7-hf/libyjpagent.so

I've tried this version as well, which results in a fatal error:
Code: Select all
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGILL (0x4) at pc=0xb60d7a74, pid=23195, tid=23196


FYI: the oldest version in the archive with ARM agent is v12.0.6.

Thanks for the complete update, I will try all the older versions and give an overview of my results here.
tjvanderlaan
 
Posts: 7
Joined: Tue Dec 24, 2019 4:28 pm

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby tjvanderlaan » Sat Jan 11, 2020 10:18 am

I tried every profiler, but unfortunately none of them work.

You can find the log files of every test I've did here: https://gist.github.com/tjibbevanderlaan/999e00cfd8cde39b56b0b9ec39b99031
tjvanderlaan
 
Posts: 7
Joined: Tue Dec 24, 2019 4:28 pm

Re: Profile JVM on Raspberry Pi B+ 1.2

Postby Anton Katilin » Mon Jan 13, 2020 9:00 am

Apparently, YourKit Java Profiler ARM hard float agent has always been targeting armv7. Hence it's unfortunately impossible to profile Raspberry Pi B+ 1.2 in your configuration. Minimum requirement is Raspberry Pi 2.
Anton Katilin
 
Posts: 5895
Joined: Wed Aug 11, 2004 8:37 am


Return to Java Profiler

Who is online

Users browsing this forum: No registered users and 1 guest

YourKit uses cookies and other tracking technologies to improve your browsing experience on our website, to show you personalized content and targeted ads, to analyze our website traffic, and to understand where our visitors are coming from.

By browsing our website, you consent to our use of cookies and other tracking technologies in accordance with the Privacy Policy.