Backport and forward port jdt patch changes for binary code select