Add HVM detection to E4J

My env was so jumbled, It may look messy but I think everything is clean. Sorry about so many commits with his checkin.