--- old/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotReplacementsImpl.java 2014-11-14 23:17:59.000000000 -0800 +++ new/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotReplacementsImpl.java 2014-11-14 23:17:59.000000000 -0800 @@ -61,7 +61,10 @@ } } else if (substituteMethod.getName().equals("numberOfLeadingZeros")) { if (config.useCountLeadingZerosInstruction) { - // bsr is lzcnt + return null; + } + } else if (substituteMethod.getName().equals("numberOfTrailingZeros")) { + if (config.useCountTrailingZerosInstruction) { return null; } }