8141443: jdk/test/java/util/regex/RegExTest.java fails: No match found
authorthartmann
Thu, 05 Nov 2015 15:29:46 +0100
changeset 33636 58b6bcd2ecac
parent 33635 7026b90fb57b
child 33637 f62a5a399b21
8141443: jdk/test/java/util/regex/RegExTest.java fails: No match found Summary: Do not sign extend when converting jbyte to jchar. Reviewed-by: shade, kvn
hotspot/src/share/vm/opto/stringopts.cpp
--- a/hotspot/src/share/vm/opto/stringopts.cpp	Thu Nov 05 15:08:58 2015 +0100
+++ b/hotspot/src/share/vm/opto/stringopts.cpp	Thu Nov 05 15:29:46 2015 +0100
@@ -1520,7 +1520,7 @@
       Node* adr = kit.array_element_address(dst_array, index, T_BYTE);
       jchar val;
       if (src_is_byte) {
-        val = src_array->byte_at(i);
+        val = src_array->byte_at(i) & 0xff;
       } else {
         val = readChar(src_array, i++);
       }