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
--- 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++);
}