I don't personally have any environment to test this out myself.
I do know the guy who reported the problem he is at Canonical and he maintains the Jenkins package for the official Ubuntu repository, so I just generally trust what he's doing. https://bugs.launchpad.net/ubuntu/+source/jenkins-xstream/+bug/827463 sheds more light into this, and here is how I understand this patch.
JamVM is just a JVM, so it needs to "borrow" class libraries from somewhere else. According to that Wikipedia article, it supports GNU Classpath and OpenJDK, and in case of Ubuntu it uses OpenJDK class libraries (which presumably also includes its native counterparts.) This is the combination that supports sun.misc.Unsafe that the author wanted to make work.
While it is possible to detect JamVM as a JVM vendor, this won't be accurate because whether the enhanced mode is available or not depends on the choice of class libraries JamVM+GNU classpath will presumably not work in this mode. So the author opted to check java.runtime.name.
As you observed, if you are to run Hotspot JVM in OpenJDK (with its associated class libraries), it identifies the vendor to be Oracle/Sun, but it won't if you are to run JamVM + OpenJDK class libraries.
Given your observation about JamVM 1.5.4 on Gentoo, I assume there are some combinations of JamVM + some class libraries that do not have sun.misc.Unsafe (what class libaries do your JamVM uses? GNU Classpath or OpenJDK?), but given that you check the existence of sun.misc.Unsafe anyway, I claim that this patch is the correct fix to the problem.
(Zero VM is probably another JVM that would benefit from this patch, as it probably reports yet separate vendor name.
Patch attached.