7079626: x64 emits unnecessary REX prefix
authortwisti
Wed, 17 Aug 2011 05:14:43 -0700
changeset 10268 3b789f46f950
parent 10267 8bdeec886dc4
child 10269 8a1ab847ebea
7079626: x64 emits unnecessary REX prefix Reviewed-by: kvn, iveresov, never
hotspot/src/cpu/x86/vm/assembler_x86.cpp
--- a/hotspot/src/cpu/x86/vm/assembler_x86.cpp	Tue Aug 16 16:59:46 2011 -0700
+++ b/hotspot/src/cpu/x86/vm/assembler_x86.cpp	Wed Aug 17 05:14:43 2011 -0700
@@ -3672,7 +3672,7 @@
     } else {
       if (adr.index_needs_rex()) {
         prefix(REX_X);
-      } else if (reg->encoding() >= 4 ) {
+      } else if (byteinst && reg->encoding() >= 4 ) {
         prefix(REX);
       }
     }