8176841: Additional Unicode Language-Tag Extensions
authornaoto
Tue, 12 Dec 2017 10:21:58 -0800
changeset 48251 57148c79bd75
parent 48250 739aa297c260
child 48252 77b88d8f8380
8176841: Additional Unicode Language-Tag Extensions 8189134: New system properties for the default Locale extensions 8190918: Retrieve the region specific data regardless of language in locale 8191349: Add a new method in j.t.f.DateTimeFormatter to reflect Unicode extensions Reviewed-by: scolebourne, lancea, rriggs, rgoel, nishjain
make/jdk/src/classes/build/tools/cldrconverter/CLDRConverter.java
make/jdk/src/classes/build/tools/cldrconverter/LDMLParseHandler.java
make/jdk/src/classes/build/tools/cldrconverter/NumberingSystemsParseHandler.java
make/jdk/src/classes/build/tools/cldrconverter/ResourceBundleGenerator.java
make/jdk/src/classes/build/tools/cldrconverter/SupplementDataParseHandler.java
make/jdk/src/classes/build/tools/cldrconverter/TimeZoneParseHandler.java
src/java.base/share/classes/java/text/DateFormat.java
src/java.base/share/classes/java/text/DateFormatSymbols.java
src/java.base/share/classes/java/text/DecimalFormatSymbols.java
src/java.base/share/classes/java/text/NumberFormat.java
src/java.base/share/classes/java/text/SimpleDateFormat.java
src/java.base/share/classes/java/time/format/DateTimeFormatter.java
src/java.base/share/classes/java/time/format/DateTimeFormatterBuilder.java
src/java.base/share/classes/java/time/format/DateTimeTextProvider.java
src/java.base/share/classes/java/time/format/DecimalStyle.java
src/java.base/share/classes/java/time/temporal/ChronoField.java
src/java.base/share/classes/java/time/temporal/IsoFields.java
src/java.base/share/classes/java/time/temporal/WeekFields.java
src/java.base/share/classes/java/util/Calendar.java
src/java.base/share/classes/java/util/Currency.java
src/java.base/share/classes/java/util/Locale.java
src/java.base/share/classes/java/util/spi/LocaleNameProvider.java
src/java.base/share/classes/sun/launcher/LauncherHelper.java
src/java.base/share/classes/sun/util/cldr/CLDRCalendarDataProviderImpl.java
src/java.base/share/classes/sun/util/cldr/CLDRLocaleProviderAdapter.java
src/java.base/share/classes/sun/util/locale/provider/CalendarDataProviderImpl.java
src/java.base/share/classes/sun/util/locale/provider/CalendarDataUtility.java
src/java.base/share/classes/sun/util/locale/provider/DateFormatProviderImpl.java
src/java.base/share/classes/sun/util/locale/provider/JRELocaleProviderAdapter.java
src/java.base/share/classes/sun/util/locale/provider/LocaleDataMetaInfo.java
src/java.base/share/classes/sun/util/locale/provider/LocaleNameProviderImpl.java
src/java.base/share/classes/sun/util/locale/provider/LocaleResources.java
src/java.base/share/classes/sun/util/locale/provider/NumberFormatProviderImpl.java
src/java.base/share/classes/sun/util/locale/provider/SPILocaleProviderAdapter.java
src/java.base/share/classes/sun/util/locale/provider/TimeZoneNameUtility.java
src/java.base/share/classes/sun/util/resources/LocaleNames.properties
src/jdk.localedata/share/classes/sun/util/cldr/resources/common/bcp47/timezone.xml
src/jdk.localedata/share/classes/sun/util/cldr/resources/common/dtd/ldmlBCP47.dtd
test/java/util/Calendar/Bug8185841.java
test/jdk/java/time/test/java/time/format/TestUnicodeExtension.java
test/jdk/java/util/Calendar/Bug4302966.java
test/jdk/java/util/Calendar/CalendarDataTest.java
test/jdk/java/util/Locale/bcp47u/CalendarTests.java
test/jdk/java/util/Locale/bcp47u/CurrencyTests.java
test/jdk/java/util/Locale/bcp47u/DefaultLocaleTest.java
test/jdk/java/util/Locale/bcp47u/DisplayNameTests.java
test/jdk/java/util/Locale/bcp47u/FormatTests.java
test/jdk/java/util/Locale/bcp47u/SymbolsTests.java
test/jdk/java/util/Locale/bcp47u/SystemPropertyTests.java
test/jdk/java/util/Locale/bcp47u/spi/LocaleNameProviderTests.java
test/jdk/java/util/Locale/bcp47u/spi/provider/foo/LocaleNameProviderImpl.java
test/jdk/java/util/Locale/bcp47u/spi/provider/module-info.java
test/jdk/sun/text/resources/LocaleData.cldr
test/jdk/sun/text/resources/LocaleDataTest.java
test/jdk/tools/jlink/plugins/IncludeLocalesPluginTest.java
--- a/make/jdk/src/classes/build/tools/cldrconverter/CLDRConverter.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/make/jdk/src/classes/build/tools/cldrconverter/CLDRConverter.java	Tue Dec 12 10:21:58 2017 -0800
@@ -37,6 +37,7 @@
 import java.util.logging.Level;
 import java.util.logging.Logger;
 import java.util.stream.Collectors;
+import java.util.stream.IntStream;
 import javax.xml.parsers.SAXParser;
 import javax.xml.parsers.SAXParserFactory;
 import org.xml.sax.SAXNotRecognizedException;
@@ -52,21 +53,32 @@
 
     static final String LDML_DTD_SYSTEM_ID = "http://www.unicode.org/cldr/dtd/2.0/ldml.dtd";
     static final String SPPL_LDML_DTD_SYSTEM_ID = "http://www.unicode.org/cldr/dtd/2.0/ldmlSupplemental.dtd";
+    static final String BCP47_LDML_DTD_SYSTEM_ID = "http://www.unicode.org/cldr/dtd/2.0/ldmlBCP47.dtd";
+
 
     private static String CLDR_BASE = "../CLDR/21.0.1/";
     static String LOCAL_LDML_DTD;
     static String LOCAL_SPPL_LDML_DTD;
+    static String LOCAL_BCP47_LDML_DTD;
     private static String SOURCE_FILE_DIR;
     private static String SPPL_SOURCE_FILE;
     private static String NUMBERING_SOURCE_FILE;
     private static String METAZONES_SOURCE_FILE;
     private static String LIKELYSUBTAGS_SOURCE_FILE;
+    private static String TIMEZONE_SOURCE_FILE;
     static String DESTINATION_DIR = "build/gensrc";
 
     static final String LOCALE_NAME_PREFIX = "locale.displayname.";
+    static final String LOCALE_SEPARATOR = LOCALE_NAME_PREFIX + "separator";
+    static final String LOCALE_KEYTYPE = LOCALE_NAME_PREFIX + "keytype";
+    static final String LOCALE_KEY_PREFIX = LOCALE_NAME_PREFIX + "key.";
+    static final String LOCALE_TYPE_PREFIX = LOCALE_NAME_PREFIX + "type.";
+    static final String LOCALE_TYPE_PREFIX_CA = LOCALE_TYPE_PREFIX + "ca.";
     static final String CURRENCY_SYMBOL_PREFIX = "currency.symbol.";
     static final String CURRENCY_NAME_PREFIX = "currency.displayname.";
     static final String CALENDAR_NAME_PREFIX = "calendarname.";
+    static final String CALENDAR_FIRSTDAY_PREFIX = "firstDay.";
+    static final String CALENDAR_MINDAYS_PREFIX = "minDays.";
     static final String TIMEZONE_ID_PREFIX = "timezone.id.";
     static final String ZONE_NAME_PREFIX = "timezone.displayname.";
     static final String METAZONE_ID_PREFIX = "metazone.id.";
@@ -76,6 +88,7 @@
     private static LikelySubtagsParseHandler handlerLikelySubtags;
     static NumberingSystemsParseHandler handlerNumbering;
     static MetaZonesParseHandler handlerMetaZones;
+    static TimeZoneParseHandler handlerTimeZone;
     private static BundleGenerator bundleGenerator;
 
     // java.base module related
@@ -201,11 +214,13 @@
         // Set up path names
         LOCAL_LDML_DTD = CLDR_BASE + "/dtd/ldml.dtd";
         LOCAL_SPPL_LDML_DTD = CLDR_BASE + "/dtd/ldmlSupplemental.dtd";
+        LOCAL_BCP47_LDML_DTD = CLDR_BASE + "/dtd/ldmlBCP47.dtd";
         SOURCE_FILE_DIR = CLDR_BASE + "/main";
         SPPL_SOURCE_FILE = CLDR_BASE + "/supplemental/supplementalData.xml";
         LIKELYSUBTAGS_SOURCE_FILE = CLDR_BASE + "/supplemental/likelySubtags.xml";
         NUMBERING_SOURCE_FILE = CLDR_BASE + "/supplemental/numberingSystems.xml";
         METAZONES_SOURCE_FILE = CLDR_BASE + "/supplemental/metaZones.xml";
+        TIMEZONE_SOURCE_FILE = CLDR_BASE + "/bcp47/timezone.xml";
 
         if (BASE_LOCALES.isEmpty()) {
             setupBaseLocales("en-US");
@@ -215,10 +230,10 @@
 
         // Parse data independent of locales
         parseSupplemental();
+        parseBCP47();
 
         List<Bundle> bundles = readBundleList();
         convertBundles(bundles);
-        convertBundles(addedBundles);
     }
 
     private static void usage() {
@@ -314,34 +329,19 @@
     }
 
     private static final Map<String, Map<String, Object>> cldrBundles = new HashMap<>();
-    // this list will contain additional bundles to be generated for Region dependent Data.
-    private static List<Bundle> addedBundles = new ArrayList<>();
 
     private static Map<String, SortedSet<String>> metaInfo = new HashMap<>();
 
     static {
         // For generating information on supported locales.
-        metaInfo.put("LocaleNames", new TreeSet<>());
-        metaInfo.put("CurrencyNames", new TreeSet<>());
-        metaInfo.put("TimeZoneNames", new TreeSet<>());
-        metaInfo.put("CalendarData", new TreeSet<>());
-        metaInfo.put("FormatData", new TreeSet<>());
         metaInfo.put("AvailableLocales", new TreeSet<>());
     }
 
-
-    private static Set<String> calendarDataFields = Set.of("firstDayOfWeek", "minimalDaysInFirstWeek");
-
     static Map<String, Object> getCLDRBundle(String id) throws Exception {
         Map<String, Object> bundle = cldrBundles.get(id);
         if (bundle != null) {
             return bundle;
         }
-        SAXParserFactory factory = SAXParserFactory.newInstance();
-        factory.setValidating(true);
-        SAXParser parser = factory.newSAXParser();
-        enableFileAccess(parser);
-        LDMLParseHandler handler = new LDMLParseHandler(id);
         File file = new File(SOURCE_FILE_DIR + File.separator + id + ".xml");
         if (!file.exists()) {
             // Skip if the file doesn't exist.
@@ -349,14 +349,15 @@
         }
 
         info("..... main directory .....");
-        info("Reading file " + file);
-        parser.parse(file, handler);
+        LDMLParseHandler handler = new LDMLParseHandler(id);
+        parseLDMLFile(file, handler);
 
         bundle = handler.getData();
         cldrBundles.put(id, bundle);
-        String country = getCountryCode(id);
-        if (country != null) {
-            bundle = handlerSuppl.getData(country);
+
+        if (id.equals("root")) {
+            // Calendar data (firstDayOfWeek & minDaysInFirstWeek)
+            bundle = handlerSuppl.getData("root");
             if (bundle != null) {
                 //merge two maps into one map
                 Map<String, Object> temp = cldrBundles.remove(id);
@@ -379,98 +380,44 @@
         // SupplementalData file also provides the "parent" locales which
         // are othrwise not to be fallen back. Process them here as well.
         //
-        info("..... Parsing supplementalData.xml .....");
-        SAXParserFactory factorySuppl = SAXParserFactory.newInstance();
-        factorySuppl.setValidating(true);
-        SAXParser parserSuppl = factorySuppl.newSAXParser();
-        enableFileAccess(parserSuppl);
         handlerSuppl = new SupplementDataParseHandler();
-        File fileSupply = new File(SPPL_SOURCE_FILE);
-        parserSuppl.parse(fileSupply, handlerSuppl);
+        parseLDMLFile(new File(SPPL_SOURCE_FILE), handlerSuppl);
         Map<String, Object> parentData = handlerSuppl.getData("root");
-        parentData.keySet().forEach(key -> {
+        parentData.keySet().stream()
+                .filter(key -> key.startsWith(PARENT_LOCALE_PREFIX))
+                .forEach(key -> {
                 parentLocalesMap.put(key, new TreeSet(
                     Arrays.asList(((String)parentData.get(key)).split(" "))));
             });
 
         // Parse numberingSystems to get digit zero character information.
-        SAXParserFactory numberingParser = SAXParserFactory.newInstance();
-        numberingParser.setValidating(true);
-        SAXParser parserNumbering = numberingParser.newSAXParser();
-        enableFileAccess(parserNumbering);
         handlerNumbering = new NumberingSystemsParseHandler();
-        File fileNumbering = new File(NUMBERING_SOURCE_FILE);
-        parserNumbering.parse(fileNumbering, handlerNumbering);
+        parseLDMLFile(new File(NUMBERING_SOURCE_FILE), handlerNumbering);
 
         // Parse metaZones to create mappings between Olson tzids and CLDR meta zone names
-        info("..... Parsing metaZones.xml .....");
-        SAXParserFactory metazonesParser = SAXParserFactory.newInstance();
-        metazonesParser.setValidating(true);
-        SAXParser parserMetaZones = metazonesParser.newSAXParser();
-        enableFileAccess(parserMetaZones);
         handlerMetaZones = new MetaZonesParseHandler();
-        File fileMetaZones = new File(METAZONES_SOURCE_FILE);
-        parserMetaZones.parse(fileMetaZones, handlerMetaZones);
+        parseLDMLFile(new File(METAZONES_SOURCE_FILE), handlerMetaZones);
 
         // Parse likelySubtags
-        info("..... Parsing likelySubtags.xml .....");
-        SAXParserFactory likelySubtagsParser = SAXParserFactory.newInstance();
-        likelySubtagsParser.setValidating(true);
-        SAXParser parserLikelySubtags = likelySubtagsParser.newSAXParser();
-        enableFileAccess(parserLikelySubtags);
         handlerLikelySubtags = new LikelySubtagsParseHandler();
-        File fileLikelySubtags = new File(LIKELYSUBTAGS_SOURCE_FILE);
-        parserLikelySubtags.parse(fileLikelySubtags, handlerLikelySubtags);
+        parseLDMLFile(new File(LIKELYSUBTAGS_SOURCE_FILE), handlerLikelySubtags);
     }
 
-    /**
-     * This method will check if a new region dependent Bundle needs to be
-     * generated for this Locale id and targetMap. New Bundle will be generated
-     * when Locale id has non empty script and country code and targetMap
-     * contains region dependent data. This method will also remove region
-     * dependent data from this targetMap after candidate locales check. E.g. It
-     * will call genRegionDependentBundle() in case of az_Latn_AZ locale and
-     * remove region dependent data from this targetMap so that az_Latn_AZ
-     * bundle will not be created. For az_Cyrl_AZ, new Bundle will be generated
-     * but region dependent data will not be removed from targetMap as its candidate
-     * locales are [az_Cyrl_AZ, az_Cyrl, root], which does not include az_AZ for
-     * fallback.
-     *
-     */
+    // Parsers for data in "bcp47" directory
+    //
+    private static void parseBCP47() throws Exception {
+        // Parse timezone
+        handlerTimeZone = new TimeZoneParseHandler();
+        parseLDMLFile(new File(TIMEZONE_SOURCE_FILE), handlerTimeZone);
+    }
 
-    private static void checkRegionDependentBundle(Map<String, Object> targetMap, String id) {
-        if ((CLDRConverter.getScript(id) != "")
-                && (CLDRConverter.getCountryCode(id) != "")) {
-            Map<String, Object> regionDepDataMap = targetMap
-                    .keySet()
-                    .stream()
-                    .filter(calendarDataFields::contains)
-                    .collect(Collectors.toMap(k -> k, targetMap::get));
-            if (!regionDepDataMap.isEmpty()) {
-                Locale cldrLoc = new Locale(CLDRConverter.getLanguageCode(id),
-                                            CLDRConverter.getCountryCode(id));
-                genRegionDependentBundle(regionDepDataMap, cldrLoc);
-                if (checkCandidateLocales(id, cldrLoc)) {
-                    // Remove matchedKeys from this targetMap only if checkCandidateLocales() returns true.
-                    regionDepDataMap.keySet().forEach(targetMap::remove);
-                }
-            }
-        }
-    }
-    /**
-     * This method will generate a new Bundle for region dependent data,
-     * minimalDaysInFirstWeek and firstDayOfWeek. Newly generated Bundle will be added
-     * to addedBundles list.
-     */
-    private static void genRegionDependentBundle(Map<String, Object> targetMap, Locale cldrLoc) {
-        String localeId = cldrLoc.toString();
-        StringBuilder sb = getCandLocales(cldrLoc);
-        if (sb.indexOf(localeId) == -1) {
-            sb.append(localeId);
-        }
-        Bundle bundle = new Bundle(localeId, sb.toString(), null, null);
-        cldrBundles.put(localeId, targetMap);
-        addedBundles.add(bundle);
+    private static void parseLDMLFile(File srcfile, AbstractLDMLHandler handler) throws Exception {
+        info("..... Parsing " + srcfile.getName() + " .....");
+        SAXParserFactory pf = SAXParserFactory.newInstance();
+        pf.setValidating(true);
+        SAXParser parser = pf.newSAXParser();
+        enableFileAccess(parser);
+        parser.parse(srcfile, handler);
     }
 
     private static StringBuilder getCandLocales(Locale cldrLoc) {
@@ -491,16 +438,6 @@
         return candList;
     }
 
-    /**
-     * This method will return true, if for a given locale, its language and
-     * country specific locale will exist in runtime lookup path. E.g. it will
-     * return true for bs_Latn_BA.
-     */
-    private static boolean checkCandidateLocales(String id, Locale cldrLoc) {
-        return(getCandidateLocales(Locale.forLanguageTag(id.replaceAll("_", "-")))
-                .contains(cldrLoc));
-    }
-
     private static void convertBundles(List<Bundle> bundles) throws Exception {
         // parent locales map. The mappings are put in base metaInfo file
         // for now.
@@ -514,8 +451,6 @@
 
             Map<String, Object> targetMap = bundle.getTargetMap();
 
-            // check if new region DependentBundle needs to be generated for this Locale.
-            checkRegionDependentBundle(targetMap, bundle.getID());
             EnumSet<Bundle.Type> bundleTypes = bundle.getBundleTypes();
 
             if (bundle.isRoot()) {
@@ -528,40 +463,30 @@
             if (bundleTypes.contains(Bundle.Type.LOCALENAMES)) {
                 Map<String, Object> localeNamesMap = extractLocaleNames(targetMap, bundle.getID());
                 if (!localeNamesMap.isEmpty() || bundle.isRoot()) {
-                    metaInfo.get("LocaleNames").add(toLanguageTag(bundle.getID()));
-                    addLikelySubtags(metaInfo, "LocaleNames", bundle.getID());
                     bundleGenerator.generateBundle("util", "LocaleNames", bundle.getJavaID(), true, localeNamesMap, BundleType.OPEN);
                 }
             }
             if (bundleTypes.contains(Bundle.Type.CURRENCYNAMES)) {
                 Map<String, Object> currencyNamesMap = extractCurrencyNames(targetMap, bundle.getID(), bundle.getCurrencies());
                 if (!currencyNamesMap.isEmpty() || bundle.isRoot()) {
-                    metaInfo.get("CurrencyNames").add(toLanguageTag(bundle.getID()));
-                    addLikelySubtags(metaInfo, "CurrencyNames", bundle.getID());
                     bundleGenerator.generateBundle("util", "CurrencyNames", bundle.getJavaID(), true, currencyNamesMap, BundleType.OPEN);
                 }
             }
             if (bundleTypes.contains(Bundle.Type.TIMEZONENAMES)) {
                 Map<String, Object> zoneNamesMap = extractZoneNames(targetMap, bundle.getID());
                 if (!zoneNamesMap.isEmpty() || bundle.isRoot()) {
-                    metaInfo.get("TimeZoneNames").add(toLanguageTag(bundle.getID()));
-                    addLikelySubtags(metaInfo, "TimeZoneNames", bundle.getID());
                     bundleGenerator.generateBundle("util", "TimeZoneNames", bundle.getJavaID(), true, zoneNamesMap, BundleType.TIMEZONE);
                 }
             }
             if (bundleTypes.contains(Bundle.Type.CALENDARDATA)) {
                 Map<String, Object> calendarDataMap = extractCalendarData(targetMap, bundle.getID());
                 if (!calendarDataMap.isEmpty() || bundle.isRoot()) {
-                    metaInfo.get("CalendarData").add(toLanguageTag(bundle.getID()));
-                    addLikelySubtags(metaInfo, "CalendarData", bundle.getID());
                     bundleGenerator.generateBundle("util", "CalendarData", bundle.getJavaID(), true, calendarDataMap, BundleType.PLAIN);
                 }
             }
             if (bundleTypes.contains(Bundle.Type.FORMATDATA)) {
                 Map<String, Object> formatDataMap = extractFormatData(targetMap, bundle.getID());
                 if (!formatDataMap.isEmpty() || bundle.isRoot()) {
-                    metaInfo.get("FormatData").add(toLanguageTag(bundle.getID()));
-                    addLikelySubtags(metaInfo, "FormatData", bundle.getID());
                     bundleGenerator.generateBundle("text", "FormatData", bundle.getJavaID(), true, formatDataMap, BundleType.PLAIN);
                 }
             }
@@ -570,43 +495,9 @@
             metaInfo.get("AvailableLocales").add(toLanguageTag(bundle.getID()));
             addLikelySubtags(metaInfo, "AvailableLocales", bundle.getID());
         }
-        addCldrImplicitLocales(metaInfo);
         bundleGenerator.generateMetaInfo(metaInfo);
     }
 
-    /**
-     * These are the Locales that are implicitly supported by CLDR.
-     * Adding them explicitly as likelySubtags here, will ensure that
-     * COMPAT locales do not precede them during ResourceBundle search path.
-     */
-    private static void addCldrImplicitLocales(Map<String, SortedSet<String>> metaInfo) {
-        metaInfo.get("LocaleNames").add("zh-Hans-CN");
-        metaInfo.get("LocaleNames").add("zh-Hans-SG");
-        metaInfo.get("LocaleNames").add("zh-Hant-HK");
-        metaInfo.get("LocaleNames").add("zh-Hant-MO");
-        metaInfo.get("LocaleNames").add("zh-Hant-TW");
-        metaInfo.get("CurrencyNames").add("zh-Hans-CN");
-        metaInfo.get("CurrencyNames").add("zh-Hans-SG");
-        metaInfo.get("CurrencyNames").add("zh-Hant-HK");
-        metaInfo.get("CurrencyNames").add("zh-Hant-MO");
-        metaInfo.get("CurrencyNames").add("zh-Hant-TW");
-        metaInfo.get("TimeZoneNames").add("zh-Hans-CN");
-        metaInfo.get("TimeZoneNames").add("zh-Hans-SG");
-        metaInfo.get("TimeZoneNames").add("zh-Hant-HK");
-        metaInfo.get("TimeZoneNames").add("zh-Hant-MO");
-        metaInfo.get("TimeZoneNames").add("zh-Hant-TW");
-        metaInfo.get("TimeZoneNames").add("zh-HK");
-        metaInfo.get("CalendarData").add("zh-Hans-CN");
-        metaInfo.get("CalendarData").add("zh-Hans-SG");
-        metaInfo.get("CalendarData").add("zh-Hant-HK");
-        metaInfo.get("CalendarData").add("zh-Hant-MO");
-        metaInfo.get("CalendarData").add("zh-Hant-TW");
-        metaInfo.get("FormatData").add("zh-Hans-CN");
-        metaInfo.get("FormatData").add("zh-Hans-SG");
-        metaInfo.get("FormatData").add("zh-Hant-HK");
-        metaInfo.get("FormatData").add("zh-Hant-MO");
-        metaInfo.get("FormatData").add("zh-Hant-TW");
-    }
     static final Map<String, String> aliases = new HashMap<>();
 
     /**
@@ -656,14 +547,6 @@
         return Locale.forLanguageTag(id.replaceAll("_", "-")).getCountry();
     }
 
-    /*
-     * Returns the script portion of the given id.
-     * If id is "root", "" is returned.
-     */
-    static String getScript(String id) {
-        return "root".equals(id) ? "" : Locale.forLanguageTag(id.replaceAll("_", "-")).getScript();
-    }
-
     private static class KeyComparator implements Comparator<String> {
         static KeyComparator INSTANCE = new KeyComparator();
 
@@ -695,9 +578,25 @@
         Map<String, Object> localeNames = new TreeMap<>(KeyComparator.INSTANCE);
         for (String key : map.keySet()) {
             if (key.startsWith(LOCALE_NAME_PREFIX)) {
-                localeNames.put(key.substring(LOCALE_NAME_PREFIX.length()), map.get(key));
+                switch (key) {
+                    case LOCALE_SEPARATOR:
+                        localeNames.put("ListCompositionPattern", map.get(key));
+                        break;
+                    case LOCALE_KEYTYPE:
+                        localeNames.put("ListKeyTypePattern", map.get(key));
+                        break;
+                    default:
+                        localeNames.put(key.substring(LOCALE_NAME_PREFIX.length()), map.get(key));
+                        break;
+                }
             }
         }
+
+        if (id.equals("root")) {
+            // Add display name pattern, which is not in CLDR
+            localeNames.put("DisplayNamePattern", "{0,choice,0#|1#{1}|2#{1} ({2})}");
+        }
+
         return localeNames;
     }
 
@@ -778,10 +677,30 @@
         return names;
     }
 
+    /**
+     * Extracts the language independent calendar data. Each of the two keys,
+     * "firstDayOfWeek" and "minimalDaysInFirstWeek" has a string value consists of
+     * one or multiple occurrences of:
+     *  i: rg1 rg2 ... rgn;
+     * where "i" is the data for the following regions (delimited by a space) after
+     * ":", and ends with a ";".
+     */
     private static Map<String, Object> extractCalendarData(Map<String, Object> map, String id) {
         Map<String, Object> calendarData = new LinkedHashMap<>();
-        copyIfPresent(map, "firstDayOfWeek", calendarData);
-        copyIfPresent(map, "minimalDaysInFirstWeek", calendarData);
+        if (id.equals("root")) {
+            calendarData.put("firstDayOfWeek",
+                IntStream.range(1, 8)
+                    .mapToObj(String::valueOf)
+                    .filter(d -> map.keySet().contains(CALENDAR_FIRSTDAY_PREFIX + d))
+                    .map(d -> d + ": " + map.get(CALENDAR_FIRSTDAY_PREFIX + d))
+                    .collect(Collectors.joining(";")));
+            calendarData.put("minimalDaysInFirstWeek",
+                IntStream.range(0, 7)
+                    .mapToObj(String::valueOf)
+                    .filter(d -> map.keySet().contains(CALENDAR_MINDAYS_PREFIX + d))
+                    .map(d -> d + ": " + map.get(CALENDAR_MINDAYS_PREFIX + d))
+                    .collect(Collectors.joining(";")));
+        }
         return calendarData;
     }
 
@@ -844,17 +763,19 @@
 
         for (String key : map.keySet()) {
         // Copy available calendar names
-            if (key.startsWith(CLDRConverter.CALENDAR_NAME_PREFIX)) {
-                String type = key.substring(CLDRConverter.CALENDAR_NAME_PREFIX.length());
+            if (key.startsWith(CLDRConverter.LOCALE_TYPE_PREFIX_CA)) {
+                String type = key.substring(CLDRConverter.LOCALE_TYPE_PREFIX_CA.length());
                 for (CalendarType calendarType : CalendarType.values()) {
                     if (calendarType == CalendarType.GENERIC) {
                         continue;
                     }
                     if (type.equals(calendarType.lname())) {
                         Object value = map.get(key);
-                        formatData.put(key, value);
-                        String ukey = CLDRConverter.CALENDAR_NAME_PREFIX + calendarType.uname();
-                        if (!key.equals(ukey)) {
+                        String dataKey = key.replace(LOCALE_TYPE_PREFIX_CA,
+                                CALENDAR_NAME_PREFIX);
+                        formatData.put(dataKey, value);
+                        String ukey = CALENDAR_NAME_PREFIX + calendarType.uname();
+                        if (!dataKey.equals(ukey)) {
                             formatData.put(ukey, value);
                         }
                     }
@@ -874,6 +795,18 @@
             copyIfPresent(map, "NumberElements", formatData);
         }
         copyIfPresent(map, "NumberPatterns", formatData);
+
+        // put extra number elements for available scripts into formatData, if it is "root"
+        if (id.equals("root")) {
+            handlerNumbering.keySet().stream()
+                .filter(k -> !numberingScripts.contains(k))
+                .forEach(k -> {
+                    String[] ne = (String[])map.get("latn.NumberElements");
+                    String[] neNew = Arrays.copyOf(ne, ne.length);
+                    neNew[4] = handlerNumbering.get(k).substring(0, 1);
+                    formatData.put(k + ".NumberElements", neNew);
+                });
+        }
         return formatData;
     }
 
--- a/make/jdk/src/classes/build/tools/cldrconverter/LDMLParseHandler.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/make/jdk/src/classes/build/tools/cldrconverter/LDMLParseHandler.java	Tue Dec 12 10:21:58 2017 -0800
@@ -76,12 +76,16 @@
             // ignore this element - it has language and territory elements that aren't locale data
             pushIgnoredContainer(qName);
             break;
-        case "type":
-            if ("calendar".equals(attributes.getValue("key"))) {
-                pushStringEntry(qName, attributes, CLDRConverter.CALENDAR_NAME_PREFIX + attributes.getValue("type"));
-            } else {
-                pushIgnoredContainer(qName);
-            }
+
+        // for LocaleNames
+        // copy string
+        case "localeSeparator":
+            pushStringEntry(qName, attributes,
+                CLDRConverter.LOCALE_SEPARATOR);
+            break;
+        case "localeKeyTypePattern":
+            pushStringEntry(qName, attributes,
+                CLDRConverter.LOCALE_KEYTYPE);
             break;
 
         case "language":
@@ -96,6 +100,24 @@
                 attributes.getValue("type"));
             break;
 
+        case "key":
+            // for LocaleNames
+            // copy string
+            pushStringEntry(qName, attributes,
+                CLDRConverter.LOCALE_KEY_PREFIX +
+                convertOldKeyName(attributes.getValue("type")));
+            break;
+
+        case "type":
+            // for LocaleNames/CalendarNames
+            // copy string
+            pushStringEntry(qName, attributes,
+                CLDRConverter.LOCALE_TYPE_PREFIX +
+                convertOldKeyName(attributes.getValue("key")) + "." +
+                attributes.getValue("type"));
+
+            break;
+
         //
         // Currency information
         //
@@ -515,26 +537,10 @@
                 currentNumberingSystem = script + ".";
                 String digits = CLDRConverter.handlerNumbering.get(script);
                 if (digits == null) {
-                    throw new InternalError("null digits for " + script);
-                }
-                if (Character.isSurrogate(digits.charAt(0))) {
-                    // DecimalFormatSymbols doesn't support supplementary characters as digit zero.
                     pushIgnoredContainer(qName);
                     break;
                 }
-                // in case digits are in the reversed order, reverse back the order.
-                if (digits.charAt(0) > digits.charAt(digits.length() - 1)) {
-                    StringBuilder sb = new StringBuilder(digits);
-                    digits = sb.reverse().toString();
-                }
-                // Check if the order is sequential.
-                char c0 = digits.charAt(0);
-                for (int i = 1; i < digits.length(); i++) {
-                    if (digits.charAt(i) != c0 + i) {
-                        pushIgnoredContainer(qName);
-                        break symbols;
-                    }
-                }
+
                 @SuppressWarnings("unchecked")
                 List<String> numberingScripts = (List<String>) get("numberingScripts");
                 if (numberingScripts == null) {
@@ -924,17 +930,35 @@
                 }
             }
         } else if (currentContainer instanceof Entry) {
-                Entry<?> entry = (Entry<?>) currentContainer;
-                Object value = entry.getValue();
-                if (value != null) {
-                    String key = entry.getKey();
-                    // Tweak for MonthNames for the root locale, Needed for
-                    // SimpleDateFormat.format()/parse() roundtrip.
-                    if (id.equals("root") && key.startsWith("MonthNames")) {
-                        value = new DateFormatSymbols(Locale.US).getShortMonths();
-                    }
-                    put(entry.getKey(), value);
+            Entry<?> entry = (Entry<?>) currentContainer;
+            Object value = entry.getValue();
+            if (value != null) {
+                String key = entry.getKey();
+                // Tweak for MonthNames for the root locale, Needed for
+                // SimpleDateFormat.format()/parse() roundtrip.
+                if (id.equals("root") && key.startsWith("MonthNames")) {
+                    value = new DateFormatSymbols(Locale.US).getShortMonths();
                 }
+                put(entry.getKey(), value);
             }
         }
     }
+
+    public String convertOldKeyName(String key) {
+        // Explicitly obtained from "alias" attribute in each "key" element.
+        switch (key) {
+            case "calendar":
+                return "ca";
+            case "currency":
+                return "cu";
+            case "collation":
+                return "co";
+            case "numbers":
+                return "nu";
+            case "timezone":
+                return "tz";
+            default:
+                return key;
+        }
+    }
+}
--- a/make/jdk/src/classes/build/tools/cldrconverter/NumberingSystemsParseHandler.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/make/jdk/src/classes/build/tools/cldrconverter/NumberingSystemsParseHandler.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -54,9 +54,32 @@
     public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException {
         switch (qName) {
         case "numberingSystem":
-            if ("numeric".equals(attributes.getValue("type"))) {
-                // eg, <numberingSystem id="latn" type="numeric" digits="0123456789"/>
-                put(attributes.getValue("id"), attributes.getValue("digits"));
+            numberingSystem: {
+                if ("numeric".equals(attributes.getValue("type"))) {
+                    // eg, <numberingSystem id="latn" type="numeric" digits="0123456789"/>
+                    String script = attributes.getValue("id");
+                    String digits = attributes.getValue("digits");
+
+                    if (Character.isSurrogate(digits.charAt(0))) {
+                        // DecimalFormatSymbols doesn't support supplementary characters as digit zero.
+                        break numberingSystem;
+                    }
+                    // in case digits are in the reversed order, reverse back the order.
+                    if (digits.charAt(0) > digits.charAt(digits.length() - 1)) {
+                        StringBuilder sb = new StringBuilder(digits);
+                        digits = sb.reverse().toString();
+                    }
+                    // Check if the order is sequential.
+                    char c0 = digits.charAt(0);
+                    for (int i = 1; i < digits.length(); i++) {
+                        if (digits.charAt(i) != c0 + i) {
+                            break numberingSystem;
+                        }
+                    }
+
+                    // script/digits are acceptable.
+                    put(script, digits);
+                }
             }
             pushIgnoredContainer(qName);
             break;
--- a/make/jdk/src/classes/build/tools/cldrconverter/ResourceBundleGenerator.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/make/jdk/src/classes/build/tools/cldrconverter/ResourceBundleGenerator.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -256,20 +256,21 @@
         CLDRConverter.info("Generating file " + file);
 
         try (PrintWriter out = new PrintWriter(file, "us-ascii")) {
-            out.println(CopyrightHeaders.getOpenJDKCopyright());
+            out.printf(CopyrightHeaders.getOpenJDKCopyright());
 
-            out.println((CLDRConverter.isBaseModule ? "package sun.util.cldr;\n\n" :
+            out.printf((CLDRConverter.isBaseModule ? "package sun.util.cldr;\n\n" :
                                   "package sun.util.resources.cldr.provider;\n\n")
                       + "import java.util.HashMap;\n"
                       + "import java.util.Locale;\n"
                       + "import java.util.Map;\n"
-                      + "import sun.util.locale.provider.LocaleProviderAdapter;\n"
-                      + "import sun.util.locale.provider.LocaleDataMetaInfo;\n");
+                      + "import sun.util.locale.provider.LocaleDataMetaInfo;\n"
+                      + "import sun.util.locale.provider.LocaleProviderAdapter;\n\n");
             out.printf("public class %s implements LocaleDataMetaInfo {\n", className);
-            out.println("    private static final Map<String, String> resourceNameToLocales = new HashMap<>();\n" +
-                        (CLDRConverter.isBaseModule ?
-                        "    private static final Map<Locale, String[]> parentLocalesMap = new HashMap<>();\n\n" : "\n") +
-                        "    static {\n");
+            out.printf("    private static final Map<String, String> resourceNameToLocales = new HashMap<>();\n" +
+                       (CLDRConverter.isBaseModule ?
+                       "    private static final Map<Locale, String[]> parentLocalesMap = new HashMap<>();\n\n" :
+                       "\n") +
+                       "    static {\n");
 
             for (String key : metaInfo.keySet()) {
                 if (key.startsWith(CLDRConverter.PARENT_LOCALE_PREFIX)) {
@@ -296,30 +297,50 @@
                     }
                     out.printf("\n             });\n");
                 } else {
-                    out.printf("        resourceNameToLocales.put(\"%s\",\n", key);
-                    out.printf("              \"%s\");\n",
-                    toLocaleList(key.equals("FormatData") ? metaInfo.get("AvailableLocales") :
-                                            metaInfo.get(key), false));
+                    if ("AvailableLocales".equals(key)) {
+                        out.printf("        resourceNameToLocales.put(\"%s\",\n", key);
+                        out.printf("              \"%s\");\n", toLocaleList(metaInfo.get(key), false));
+                    }
                 }
             }
-            out.println("    }\n\n");
+
+            out.printf("    }\n\n");
+
+            // end of static initializer block.
 
-            out.println("    @Override\n" +
+            // Short TZ names for delayed initialization
+            if (CLDRConverter.isBaseModule) {
+                out.printf("    private static class TZShortIDMapHolder {\n");
+                out.printf("        static final Map<String, String> tzShortIDMap = new HashMap<>();\n");
+                out.printf("        static {\n");
+                CLDRConverter.handlerTimeZone.getData().entrySet().stream()
+                    .forEach(e -> {
+                        out.printf("            tzShortIDMap.put(\"%s\", \"%s\");\n", e.getKey(),
+                                ((String)e.getValue()));
+                    });
+                out.printf("        }\n    }\n\n");
+            }
+
+            out.printf("    @Override\n" +
                         "    public LocaleProviderAdapter.Type getType() {\n" +
                         "        return LocaleProviderAdapter.Type.CLDR;\n" +
                         "    }\n\n");
 
-            out.println("    @Override\n" +
+            out.printf("    @Override\n" +
                         "    public String availableLanguageTags(String category) {\n" +
                         "        return resourceNameToLocales.getOrDefault(category, \"\");\n" +
                         "    }\n\n");
 
             if (CLDRConverter.isBaseModule) {
+                out.printf("    @Override\n" +
+                           "    public Map<String, String> tzShortIDs() {\n" +
+                           "        return TZShortIDMapHolder.tzShortIDMap;\n" +
+                           "    }\n\n");
                 out.printf("    public Map<Locale, String[]> parentLocales() {\n" +
                            "        return parentLocalesMap;\n" +
                            "    }\n}");
             } else {
-                out.println("}");
+                out.printf("}");
             }
         }
     }
--- a/make/jdk/src/classes/build/tools/cldrconverter/SupplementDataParseHandler.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/make/jdk/src/classes/build/tools/cldrconverter/SupplementDataParseHandler.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -84,53 +84,18 @@
             values.put(CLDRConverter.PARENT_LOCALE_PREFIX+key,
                 parentLocalesMap.get(key));
             });
-        } else {
-            String countryData = getWeekData(id, JAVA_FIRSTDAY, firstDayMap);
-        if (countryData != null) {
-            values.put(JAVA_FIRSTDAY, countryData);
-        }
-            String minDaysData = getWeekData(id, JAVA_MINDAY, minDaysMap);
-        if (minDaysData != null) {
-            values.put(JAVA_MINDAY, minDaysData);
-        }
+            firstDayMap.keySet().forEach(key -> {
+            values.put(CLDRConverter.CALENDAR_FIRSTDAY_PREFIX+firstDayMap.get(key),
+                key);
+            });
+            minDaysMap.keySet().forEach(key -> {
+            values.put(CLDRConverter.CALENDAR_MINDAYS_PREFIX+minDaysMap.get(key),
+                key);
+            });
         }
         return values.isEmpty() ? null : values;
     }
 
-    /**
-     * It returns either firstDay or minDays in the JRE format for the country.
-     *
-     * @param country       territory code of the requested data
-     * @param jreDataName   JAVA_FIRSTDAY or JAVA_MINDAY
-     * @param dataMap       firstDayMap or minDaysMap
-     * @return the value for the given jreDataName, or null if requested value
-     *         (firstDay/minDays) is not available although that is highly unlikely
-     *         because of the default value for the world (001).
-     */
-    String getWeekData(String country, final String jreDataName, final Map<String, Object> dataMap) {
-        String countryValue = null;
-        String defaultWorldValue = null;
-        for (String key : dataMap.keySet()) {
-            if (key.contains(country)) {
-                if (jreDataName.equals(JAVA_FIRSTDAY)) {
-                    countryValue = DAY_OF_WEEK_MAP.get((String) dataMap.get(key));
-                } else if (jreDataName.equals(JAVA_MINDAY)) {
-                    countryValue = (String) dataMap.get(key);
-                }
-                if (countryValue != null) {
-                    return countryValue;
-                }
-            } else if (key.contains(WORLD)) {
-                if (jreDataName.equals(JAVA_FIRSTDAY)) {
-                    defaultWorldValue = DAY_OF_WEEK_MAP.get((String) dataMap.get(key));
-                } else if (jreDataName.equals(JAVA_MINDAY)) {
-                    defaultWorldValue = (String) dataMap.get(key);
-                }
-            }
-        }
-        return defaultWorldValue;
-    }
-
     @Override
     public InputSource resolveEntity(String publicID, String systemID) throws IOException, SAXException {
         // avoid HTTP traffic to unicode.org
@@ -152,7 +117,33 @@
         switch (qName) {
         case "firstDay":
             if (!isIgnored(attributes)) {
-                firstDayMap.put(attributes.getValue("territories"), attributes.getValue("day"));
+                String fd;
+
+                switch (attributes.getValue("day")) {
+                    case "sun":
+                        fd = "1";
+                        break;
+                    default:
+                    case "mon":
+                        fd = "2";
+                        break;
+                    case "tue":
+                        fd = "3";
+                        break;
+                    case "wed":
+                        fd = "4";
+                        break;
+                    case "thu":
+                        fd = "5";
+                        break;
+                    case "fri":
+                        fd = "6";
+                        break;
+                    case "sat":
+                        fd = "7";
+                        break;
+                }
+                firstDayMap.put(attributes.getValue("territories"), fd);
             }
             break;
         case "minDays":
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/jdk/src/classes/build/tools/cldrconverter/TimeZoneParseHandler.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,64 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package build.tools.cldrconverter;
+
+import java.io.File;
+import java.io.IOException;
+import org.xml.sax.Attributes;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * Handles parsing of timezone.xml and produces a map from short timezone IDs to
+ * tz database IDs.
+ */
+
+class TimeZoneParseHandler extends AbstractLDMLHandler<Object> {
+
+    @Override
+    public InputSource resolveEntity(String publicID, String systemID) throws IOException, SAXException {
+        // avoid HTTP traffic to unicode.org
+        if (systemID.startsWith(CLDRConverter.BCP47_LDML_DTD_SYSTEM_ID)) {
+            return new InputSource((new File(CLDRConverter.LOCAL_BCP47_LDML_DTD)).toURI().toString());
+        }
+        return null;
+    }
+
+    @Override
+    public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException {
+        switch (qName) {
+        case "type":
+            if (!isIgnored(attributes) && !attributes.getValue("deprecated").equals("true")) {
+                put(attributes.getValue("name"), attributes.getValue("alias"));
+            }
+            break;
+        default:
+            // treat anything else as a container
+            pushContainer(qName, attributes);
+            break;
+        }
+    }
+}
--- a/src/java.base/share/classes/java/text/DateFormat.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/text/DateFormat.java	Tue Dec 12 10:21:58 2017 -0800
@@ -97,6 +97,13 @@
  * DateFormat df = DateFormat.getDateInstance(DateFormat.LONG, Locale.FRANCE);
  * }</pre>
  * </blockquote>
+ *
+ * <p>If the specified locale contains "ca" (calendar), "rg" (region override),
+ * and/or "tz" (timezone) <a href="../util/Locale.html#def_locale_extension">Unicode
+ * extensions</a>, the calendar, the country and/or the time zone for formatting
+ * are overridden. If both "ca" and "rg" are specified, the calendar from the "ca"
+ * extension supersedes the implicit one from the "rg" extension.
+ *
  * <p>You can use a DateFormat to parse also.
  * <blockquote>
  * <pre>{@code
--- a/src/java.base/share/classes/java/text/DateFormatSymbols.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/text/DateFormatSymbols.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -49,6 +49,7 @@
 import java.util.ResourceBundle;
 import java.util.concurrent.ConcurrentHashMap;
 import java.util.concurrent.ConcurrentMap;
+import sun.util.locale.provider.CalendarDataUtility;
 import sun.util.locale.provider.LocaleProviderAdapter;
 import sun.util.locale.provider.LocaleServiceProviderPool;
 import sun.util.locale.provider.ResourceBundleBasedAdapter;
@@ -82,6 +83,10 @@
  * </pre>
  * </blockquote>
  *
+ * <p>If the locale contains "rg" (region override)
+ * <a href="../util/Locale.html#def_locale_extension">Unicode extension</a>,
+ * the symbols are overridden for the designated region.
+ *
  * <p>
  * <code>DateFormatSymbols</code> objects are cloneable. When you obtain
  * a <code>DateFormatSymbols</code> object, feel free to modify the
@@ -716,15 +721,18 @@
             }
             dfs = new DateFormatSymbols(false);
 
+            // check for region override
+            Locale override = CalendarDataUtility.findRegionOverride(locale);
+
             // Initialize the fields from the ResourceBundle for locale.
             LocaleProviderAdapter adapter
-                = LocaleProviderAdapter.getAdapter(DateFormatSymbolsProvider.class, locale);
+                = LocaleProviderAdapter.getAdapter(DateFormatSymbolsProvider.class, override);
             // Avoid any potential recursions
             if (!(adapter instanceof ResourceBundleBasedAdapter)) {
                 adapter = LocaleProviderAdapter.getResourceBundleBased();
             }
             ResourceBundle resource
-                = ((ResourceBundleBasedAdapter)adapter).getLocaleData().getDateFormatData(locale);
+                = ((ResourceBundleBasedAdapter)adapter).getLocaleData().getDateFormatData(override);
 
             dfs.locale = locale;
             // JRE and CLDR use different keys
--- a/src/java.base/share/classes/java/text/DecimalFormatSymbols.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/text/DecimalFormatSymbols.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -44,6 +44,7 @@
 import java.text.spi.DecimalFormatSymbolsProvider;
 import java.util.Currency;
 import java.util.Locale;
+import sun.util.locale.provider.CalendarDataUtility;
 import sun.util.locale.provider.LocaleProviderAdapter;
 import sun.util.locale.provider.LocaleServiceProviderPool;
 import sun.util.locale.provider.ResourceBundleBasedAdapter;
@@ -56,6 +57,10 @@
  * of these symbols, you can get the <code>DecimalFormatSymbols</code> object from
  * your <code>DecimalFormat</code> and modify it.
  *
+ * <p>If the locale contains "rg" (region override)
+ * <a href="../util/Locale.html#def_locale_extension">Unicode extension</a>,
+ * the symbols are overridden for the designated region.
+ *
  * @see          java.util.Locale
  * @see          DecimalFormat
  * @author       Mark Davis
@@ -609,13 +614,18 @@
     private void initialize( Locale locale ) {
         this.locale = locale;
 
+        // check for region override
+        Locale override = locale.getUnicodeLocaleType("nu") == null ?
+            CalendarDataUtility.findRegionOverride(locale) :
+            locale;
+
         // get resource bundle data
-        LocaleProviderAdapter adapter = LocaleProviderAdapter.getAdapter(DecimalFormatSymbolsProvider.class, locale);
+        LocaleProviderAdapter adapter = LocaleProviderAdapter.getAdapter(DecimalFormatSymbolsProvider.class, override);
         // Avoid potential recursions
         if (!(adapter instanceof ResourceBundleBasedAdapter)) {
             adapter = LocaleProviderAdapter.getResourceBundleBased();
         }
-        Object[] data = adapter.getLocaleResources(locale).getDecimalFormatSymbolsData();
+        Object[] data = adapter.getLocaleResources(override).getDecimalFormatSymbolsData();
         String[] numberElements = (String[]) data[0];
 
         decimalSeparator = numberElements[0].charAt(0);
--- a/src/java.base/share/classes/java/text/NumberFormat.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/text/NumberFormat.java	Tue Dec 12 10:21:58 2017 -0800
@@ -96,7 +96,14 @@
  * NumberFormat nf = NumberFormat.getInstance(Locale.FRENCH);
  * }</pre>
  * </blockquote>
- * You can also use a <code>NumberFormat</code> to parse numbers:
+ *
+ * <p>If the locale contains "nu" (numbers) and/or "rg" (region override)
+ * <a href="../util/Locale.html#def_locale_extension">Unicode extensions</a>,
+ * the decimal digits, and/or the country used for formatting are overridden.
+ * If both "nu" and "rg" are specified, the decimal digits from the "nu"
+ * extension supersedes the implicit one from the "rg" extension.
+ *
+ * <p>You can also use a {@code NumberFormat} to parse numbers:
  * <blockquote>
  * <pre>{@code
  * myNumber = nf.parse(myString);
--- a/src/java.base/share/classes/java/text/SimpleDateFormat.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/text/SimpleDateFormat.java	Tue Dec 12 10:21:58 2017 -0800
@@ -672,7 +672,7 @@
             // However, the calendar should use the current default TimeZone.
             // If this is not contained in the locale zone strings, then the zone
             // will be formatted using generic GMT+/-H:MM nomenclature.
-            calendar = Calendar.getInstance(TimeZone.getDefault(), loc);
+            calendar = Calendar.getInstance(loc);
         }
     }
 
--- a/src/java.base/share/classes/java/time/format/DateTimeFormatter.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/time/format/DateTimeFormatter.java	Tue Dec 12 10:21:58 2017 -0800
@@ -97,6 +97,7 @@
 import java.util.Map;
 import java.util.Objects;
 import java.util.Set;
+import sun.util.locale.provider.TimeZoneNameUtility;
 
 /**
  * Formatter for printing and parsing date-time objects.
@@ -548,7 +549,7 @@
      * For example, {@code d MMM uuuu} will format 2011-12-03 as '3 Dec 2011'.
      * <p>
      * The formatter will use the {@link Locale#getDefault(Locale.Category) default FORMAT locale}.
-     * This can be changed using {@link DateTimeFormatter#withLocale(Locale)} on the returned formatter
+     * This can be changed using {@link DateTimeFormatter#withLocale(Locale)} on the returned formatter.
      * Alternatively use the {@link #ofPattern(String, Locale)} variant of this method.
      * <p>
      * The returned formatter has no override chronology or zone.
@@ -572,7 +573,7 @@
      * For example, {@code d MMM uuuu} will format 2011-12-03 as '3 Dec 2011'.
      * <p>
      * The formatter will use the specified locale.
-     * This can be changed using {@link DateTimeFormatter#withLocale(Locale)} on the returned formatter
+     * This can be changed using {@link DateTimeFormatter#withLocale(Locale)} on the returned formatter.
      * <p>
      * The returned formatter has no override chronology or zone.
      * It uses {@link ResolverStyle#SMART SMART} resolver style.
@@ -1443,10 +1444,17 @@
      * This is used to lookup any part of the formatter needing specific
      * localization, such as the text or localized pattern.
      * <p>
+     * The locale is stored as passed in, without further processing.
+     * If the locale has <a href="../../util/Locale.html#def_locale_extension">
+     * Unicode extensions</a>, they may be used later in text
+     * processing. To set the chronology, time-zone and decimal style from
+     * unicode extensions, see {@link #localizedBy localizedBy()}.
+     * <p>
      * This instance is immutable and unaffected by this method call.
      *
      * @param locale  the new locale, not null
      * @return a formatter based on this formatter with the requested locale, not null
+     * @see #localizedBy(Locale)
      */
     public DateTimeFormatter withLocale(Locale locale) {
         if (this.locale.equals(locale)) {
@@ -1455,6 +1463,52 @@
         return new DateTimeFormatter(printerParser, locale, decimalStyle, resolverStyle, resolverFields, chrono, zone);
     }
 
+    /**
+     * Returns a copy of this formatter with localized values of the locale,
+     * calendar, region, decimal style and/or timezone, that supercede values in
+     * this formatter.
+     * <p>
+     * This is used to lookup any part of the formatter needing specific
+     * localization, such as the text or localized pattern. If the locale contains the
+     * "ca" (calendar), "nu" (numbering system), "rg" (region override), and/or
+     * "tz" (timezone)
+     * <a href="../../util/Locale.html#def_locale_extension">Unicode extensions</a>,
+     * the chronology, numbering system and/or the zone are overridden. If both "ca"
+     * and "rg" are specified, the chronology from the "ca" extension supersedes the
+     * implicit one from the "rg" extension. Same is true for the "nu" extension.
+     * <p>
+     * Unlike the {@link #withLocale withLocale} method, the call to this method may
+     * produce a different formatter depending on the order of method chaining with
+     * other withXXXX() methods.
+     * <p>
+     * This instance is immutable and unaffected by this method call.
+     *
+     * @param locale  the locale, not null
+     * @return a formatter based on this formatter with localized values of
+     *      the calendar, decimal style and/or timezone, that supercede values in this
+     *      formatter.
+     * @see #withLocale(Locale)
+     * @since 10
+     */
+    public DateTimeFormatter localizedBy(Locale locale) {
+        if (this.locale.equals(locale)) {
+            return this;
+        }
+
+        // Check for decimalStyle/chronology/timezone in locale object
+        Chronology c = locale.getUnicodeLocaleType("ca") != null ?
+                       Chronology.ofLocale(locale) : chrono;
+        DecimalStyle ds = locale.getUnicodeLocaleType("nu") != null ?
+                       DecimalStyle.of(locale) : decimalStyle;
+        String tzType = locale.getUnicodeLocaleType("tz");
+        ZoneId z  = tzType != null ?
+                    TimeZoneNameUtility.convertLDMLShortID(tzType)
+                        .map(ZoneId::of)
+                        .orElse(zone) :
+                    zone;
+        return new DateTimeFormatter(printerParser, locale, ds, resolverStyle, resolverFields, c, z);
+    }
+
     //-----------------------------------------------------------------------
     /**
      * Gets the DecimalStyle to be used during formatting.
--- a/src/java.base/share/classes/java/time/format/DateTimeFormatterBuilder.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/time/format/DateTimeFormatterBuilder.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -120,6 +120,7 @@
 import java.util.concurrent.ConcurrentMap;
 
 import sun.text.spi.JavaTimeDateTimePatternProvider;
+import sun.util.locale.provider.CalendarDataUtility;
 import sun.util.locale.provider.LocaleProviderAdapter;
 import sun.util.locale.provider.LocaleResources;
 import sun.util.locale.provider.TimeZoneNameUtility;
@@ -198,6 +199,10 @@
      * Gets the formatting pattern for date and time styles for a locale and chronology.
      * The locale and chronology are used to lookup the locale specific format
      * for the requested dateStyle and/or timeStyle.
+     * <p>
+     * If the locale contains the "rg" (region override)
+     * <a href="../../util/Locale.html#def_locale_extension">Unicode extensions</a>,
+     * the formatting pattern is overridden with the one appropriate for the region.
      *
      * @param dateStyle  the FormatStyle for the date, null for time-only pattern
      * @param timeStyle  the FormatStyle for the time, null for date-only pattern
@@ -216,7 +221,8 @@
         LocaleProviderAdapter adapter = LocaleProviderAdapter.getAdapter(JavaTimeDateTimePatternProvider.class, locale);
         JavaTimeDateTimePatternProvider provider = adapter.getJavaTimeDateTimePatternProvider();
         String pattern = provider.getJavaTimeDateTimePattern(convertStyle(timeStyle),
-                         convertStyle(dateStyle), chrono.getCalendarType(), locale);
+                         convertStyle(dateStyle), chrono.getCalendarType(),
+                         CalendarDataUtility.findRegionOverride(locale));
         return pattern;
     }
 
--- a/src/java.base/share/classes/java/time/format/DateTimeTextProvider.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/time/format/DateTimeTextProvider.java	Tue Dec 12 10:21:58 2017 -0800
@@ -510,7 +510,8 @@
     @SuppressWarnings("unchecked")
     static <T> T getLocalizedResource(String key, Locale locale) {
         LocaleResources lr = LocaleProviderAdapter.getResourceBundleBased()
-                                    .getLocaleResources(locale);
+                                    .getLocaleResources(
+                                        CalendarDataUtility.findRegionOverride(locale));
         ResourceBundle rb = lr.getJavaTimeFormatData();
         return rb.containsKey(key) ? (T) rb.getObject(key) : null;
     }
--- a/src/java.base/share/classes/java/time/format/DecimalStyle.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/time/format/DecimalStyle.java	Tue Dec 12 10:21:58 2017 -0800
@@ -147,6 +147,11 @@
      * Obtains the DecimalStyle for the specified locale.
      * <p>
      * This method provides access to locale sensitive decimal style symbols.
+     * If the locale contains "nu" (Numbering System) and/or "rg"
+     * (Region Override) <a href="../../util/Locale.html#def_locale_extension">
+     * Unicode extensions</a>, returned instance will reflect the values specified with
+     * those extensions. If both "nu" and "rg" are specified, the value from
+     * the "nu" extension supersedes the implicit one from the "rg" extension.
      *
      * @param locale  the locale, not null
      * @return the decimal style, not null
--- a/src/java.base/share/classes/java/time/temporal/ChronoField.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/time/temporal/ChronoField.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -79,6 +79,7 @@
 import java.util.Locale;
 import java.util.Objects;
 import java.util.ResourceBundle;
+import sun.util.locale.provider.CalendarDataUtility;
 import sun.util.locale.provider.LocaleProviderAdapter;
 import sun.util.locale.provider.LocaleResources;
 
@@ -632,7 +633,9 @@
         }
 
         LocaleResources lr = LocaleProviderAdapter.getResourceBundleBased()
-                                    .getLocaleResources(locale);
+                                    .getLocaleResources(
+                                        CalendarDataUtility
+                                            .findRegionOverride(locale));
         ResourceBundle rb = lr.getJavaTimeFormatData();
         String key = "field." + displayNameKey;
         return rb.containsKey(key) ? rb.getString(key) : name;
--- a/src/java.base/share/classes/java/time/temporal/IsoFields.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/time/temporal/IsoFields.java	Tue Dec 12 10:21:58 2017 -0800
@@ -81,6 +81,7 @@
 import java.util.Objects;
 import java.util.ResourceBundle;
 
+import sun.util.locale.provider.CalendarDataUtility;
 import sun.util.locale.provider.LocaleProviderAdapter;
 import sun.util.locale.provider.LocaleResources;
 
@@ -430,7 +431,9 @@
             public String getDisplayName(Locale locale) {
                 Objects.requireNonNull(locale, "locale");
                 LocaleResources lr = LocaleProviderAdapter.getResourceBundleBased()
-                                            .getLocaleResources(locale);
+                                            .getLocaleResources(
+                                                CalendarDataUtility
+                                                    .findRegionOverride(locale));
                 ResourceBundle rb = lr.getJavaTimeFormatData();
                 return rb.containsKey("field.week") ? rb.getString("field.week") : toString();
             }
--- a/src/java.base/share/classes/java/time/temporal/WeekFields.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/time/temporal/WeekFields.java	Tue Dec 12 10:21:58 2017 -0800
@@ -286,13 +286,17 @@
      * Obtains an instance of {@code WeekFields} appropriate for a locale.
      * <p>
      * This will look up appropriate values from the provider of localization data.
+     * If the locale contains "fw" (First day of week) and/or "rg"
+     * (Region Override) <a href="../../util/Locale.html#def_locale_extension">
+     * Unicode extensions</a>, returned instance will reflect the values specified with
+     * those extensions. If both "fw" and "rg" are specified, the value from
+     * the "fw" extension supersedes the implicit one from the "rg" extension.
      *
      * @param locale  the locale to use, not null
      * @return the week-definition, not null
      */
     public static WeekFields of(Locale locale) {
         Objects.requireNonNull(locale, "locale");
-        locale = new Locale(locale.getLanguage(), locale.getCountry());  // elminate variants
 
         int calDow = CalendarDataUtility.retrieveFirstDayOfWeek(locale);
         DayOfWeek dow = DayOfWeek.SUNDAY.plus(calDow - 1);
@@ -1041,7 +1045,8 @@
             Objects.requireNonNull(locale, "locale");
             if (rangeUnit == YEARS) {  // only have values for week-of-year
                 LocaleResources lr = LocaleProviderAdapter.getResourceBundleBased()
-                        .getLocaleResources(locale);
+                        .getLocaleResources(
+                            CalendarDataUtility.findRegionOverride(locale));
                 ResourceBundle rb = lr.getJavaTimeFormatData();
                 return rb.containsKey("field.week") ? rb.getString("field.week") : name;
             }
--- a/src/java.base/share/classes/java/util/Calendar.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/util/Calendar.java	Tue Dec 12 10:21:58 2017 -0800
@@ -58,6 +58,7 @@
 import sun.util.calendar.ZoneInfo;
 import sun.util.locale.provider.CalendarDataUtility;
 import sun.util.locale.provider.LocaleProviderAdapter;
+import sun.util.locale.provider.TimeZoneNameUtility;
 import sun.util.spi.CalendarProvider;
 
 /**
@@ -128,9 +129,14 @@
  *
  * <code>Calendar</code> defines a locale-specific seven day week using two
  * parameters: the first day of the week and the minimal days in first week
- * (from 1 to 7).  These numbers are taken from the locale resource data when a
- * <code>Calendar</code> is constructed.  They may also be specified explicitly
- * through the methods for setting their values.
+ * (from 1 to 7).  These numbers are taken from the locale resource data or the
+ * locale itself when a {@code Calendar} is constructed. If the designated
+ * locale contains "fw" and/or "rg" <a href="./Locale.html#def_locale_extension">
+ * Unicode extensions</a>, the first day of the week will be obtained according to
+ * those extensions. If both "fw" and "rg" are specified, the value from the "fw"
+ * extension supersedes the implicit one from the "rg" extension.
+ * They may also be specified explicitly through the methods for setting their
+ * values.
  *
  * <p>When setting or getting the <code>WEEK_OF_MONTH</code> or
  * <code>WEEK_OF_YEAR</code> fields, <code>Calendar</code> must determine the
@@ -1444,6 +1450,11 @@
          *
          * <p>The default values are used for locale and time zone if these
          * parameters haven't been given explicitly.
+         * <p>
+         * If the locale contains the time zone with "tz"
+         * <a href="Locale.html#def_locale_extension">Unicode extension</a>,
+         * and time zone hasn't been given explicitly, time zone in the locale
+         * is used.
          *
          * <p>Any out of range field values are either normalized in lenient
          * mode or detected as an invalid value in non-lenient mode.
@@ -1463,7 +1474,7 @@
                 locale = Locale.getDefault();
             }
             if (zone == null) {
-                zone = TimeZone.getDefault();
+                zone = defaultTimeZone(locale);
             }
             Calendar cal;
             if (type == null) {
@@ -1605,12 +1616,17 @@
      * <code>Calendar</code> returned is based on the current time
      * in the default time zone with the default
      * {@link Locale.Category#FORMAT FORMAT} locale.
+     * <p>
+     * If the locale contains the time zone with "tz"
+     * <a href="Locale.html#def_locale_extension">Unicode extension</a>,
+     * that time zone is used instead.
      *
      * @return a Calendar.
      */
     public static Calendar getInstance()
     {
-        return createCalendar(TimeZone.getDefault(), Locale.getDefault(Locale.Category.FORMAT));
+        Locale aLocale = Locale.getDefault(Locale.Category.FORMAT);
+        return createCalendar(defaultTimeZone(aLocale), aLocale);
     }
 
     /**
@@ -1631,13 +1647,17 @@
      * Gets a calendar using the default time zone and specified locale.
      * The <code>Calendar</code> returned is based on the current time
      * in the default time zone with the given locale.
+     * <p>
+     * If the locale contains the time zone with "tz"
+     * <a href="Locale.html#def_locale_extension">Unicode extension</a>,
+     * that time zone is used instead.
      *
      * @param aLocale the locale for the week data
      * @return a Calendar.
      */
     public static Calendar getInstance(Locale aLocale)
     {
-        return createCalendar(TimeZone.getDefault(), aLocale);
+        return createCalendar(defaultTimeZone(aLocale), aLocale);
     }
 
     /**
@@ -1655,6 +1675,16 @@
         return createCalendar(zone, aLocale);
     }
 
+    private static TimeZone defaultTimeZone(Locale l) {
+        TimeZone defaultTZ = TimeZone.getDefault();
+        String shortTZID = l.getUnicodeLocaleType("tz");
+        return shortTZID != null ?
+            TimeZoneNameUtility.convertLDMLShortID(shortTZID)
+                .map(TimeZone::getTimeZone)
+                .orElse(defaultTZ) :
+            defaultTZ;
+    }
+
     private static Calendar createCalendar(TimeZone zone,
                                            Locale aLocale)
     {
--- a/src/java.base/share/classes/java/util/Currency.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/util/Currency.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -28,7 +28,6 @@
 import java.io.BufferedInputStream;
 import java.io.DataInputStream;
 import java.io.File;
-import java.io.FileInputStream;
 import java.io.FileReader;
 import java.io.InputStream;
 import java.io.IOException;
@@ -42,6 +41,7 @@
 import java.util.regex.Pattern;
 import java.util.regex.Matcher;
 import java.util.spi.CurrencyNameProvider;
+import sun.util.locale.provider.CalendarDataUtility;
 import sun.util.locale.provider.LocaleServiceProviderPool;
 import sun.util.logging.PlatformLogger;
 
@@ -348,6 +348,13 @@
      * until December 31, 2001, and the Euro from January 1, 2002, local time
      * of the respective countries.
      * <p>
+     * If the specified {@code locale} contains "cu" and/or "rg"
+     * <a href="./Locale.html#def_locale_extension">Unicode extensions</a>,
+     * the instance returned from this method reflects
+     * the values specified with those extensions. If both "cu" and "rg" are
+     * specified, the currency from the "cu" extension supersedes the implicit one
+     * from the "rg" extension.
+     * <p>
      * The method returns <code>null</code> for territories that don't
      * have a currency, such as Antarctica.
      *
@@ -361,12 +368,19 @@
      * is not a supported ISO 3166 country code.
      */
     public static Currency getInstance(Locale locale) {
-        String country = locale.getCountry();
-        if (country == null) {
-            throw new NullPointerException();
+        // check for locale overrides
+        String override = locale.getUnicodeLocaleType("cu");
+        if (override != null) {
+            try {
+                return getInstance(override.toUpperCase(Locale.ROOT));
+            } catch (IllegalArgumentException iae) {
+                // override currency is invalid. Fall through.
+            }
         }
 
-        if (country.length() != 2) {
+        String country = CalendarDataUtility.findRegionOverride(locale).getCountry();
+
+        if (country == null || !country.matches("^[a-zA-Z]{2}$")) {
             throw new IllegalArgumentException();
         }
 
@@ -482,6 +496,12 @@
      * locale is the US, while for other locales it may be "US$". If no
      * symbol can be determined, the ISO 4217 currency code is returned.
      * <p>
+     * If the default {@link Locale.Category#DISPLAY DISPLAY} locale
+     * contains "rg" (region override)
+     * <a href="./Locale.html#def_locale_extension">Unicode extension</a>,
+     * the symbol returned from this method reflects
+     * the value specified with that extension.
+     * <p>
      * This is equivalent to calling
      * {@link #getSymbol(Locale)
      *     getSymbol(Locale.getDefault(Locale.Category.DISPLAY))}.
@@ -498,6 +518,11 @@
      * For example, for the US Dollar, the symbol is "$" if the specified
      * locale is the US, while for other locales it may be "US$". If no
      * symbol can be determined, the ISO 4217 currency code is returned.
+     * <p>
+     * If the specified {@code locale} contains "rg" (region override)
+     * <a href="./Locale.html#def_locale_extension">Unicode extension</a>,
+     * the symbol returned from this method reflects
+     * the value specified with that extension.
      *
      * @param locale the locale for which a display name for this currency is
      * needed
@@ -507,6 +532,7 @@
     public String getSymbol(Locale locale) {
         LocaleServiceProviderPool pool =
             LocaleServiceProviderPool.getPool(CurrencyNameProvider.class);
+        locale = CalendarDataUtility.findRegionOverride(locale);
         String symbol = pool.getLocalizedObject(
                                 CurrencyNameGetter.INSTANCE,
                                 locale, currencyCode, SYMBOL);
--- a/src/java.base/share/classes/java/util/Locale.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/util/Locale.java	Tue Dec 12 10:21:58 2017 -0800
@@ -48,6 +48,7 @@
 import java.text.MessageFormat;
 import java.util.concurrent.ConcurrentHashMap;
 import java.util.spi.LocaleNameProvider;
+import java.util.stream.Collectors;
 
 import sun.security.action.GetPropertyAction;
 import sun.util.locale.BaseLocale;
@@ -62,6 +63,7 @@
 import sun.util.locale.provider.LocaleProviderAdapter;
 import sun.util.locale.provider.LocaleResources;
 import sun.util.locale.provider.LocaleServiceProviderPool;
+import sun.util.locale.provider.TimeZoneNameUtility;
 
 /**
  * A <code>Locale</code> object represents a specific geographical, political,
@@ -665,10 +667,12 @@
     /**
      * Display types for retrieving localized names from the name providers.
      */
-    private static final int DISPLAY_LANGUAGE = 0;
-    private static final int DISPLAY_COUNTRY  = 1;
-    private static final int DISPLAY_VARIANT  = 2;
-    private static final int DISPLAY_SCRIPT   = 3;
+    private static final int DISPLAY_LANGUAGE  = 0;
+    private static final int DISPLAY_COUNTRY   = 1;
+    private static final int DISPLAY_VARIANT   = 2;
+    private static final int DISPLAY_SCRIPT    = 3;
+    private static final int DISPLAY_UEXT_KEY  = 4;
+    private static final int DISPLAY_UEXT_TYPE = 5;
 
     /**
      * Private constructor used by getInstance method
@@ -942,11 +946,14 @@
             variant = props.getProperty("user.variant", "");
         }
 
-        return getInstance(language, script, country, variant, null);
+        return getInstance(language, script, country, variant,
+                getDefaultExtensions(props.getProperty("user.extensions", ""))
+                    .orElse(null));
     }
 
     private static Locale initDefault(Locale.Category category) {
         Properties props = GetPropertyAction.privilegedGetProperties();
+
         return getInstance(
             props.getProperty(category.languageKey,
                     defaultLocale.getLanguage()),
@@ -956,7 +963,22 @@
                     defaultLocale.getCountry()),
             props.getProperty(category.variantKey,
                     defaultLocale.getVariant()),
-            null);
+            getDefaultExtensions(props.getProperty(category.extensionsKey, ""))
+                .orElse(defaultLocale.getLocaleExtensions()));
+    }
+
+    private static Optional<LocaleExtensions> getDefaultExtensions(String extensionsProp) {
+        LocaleExtensions exts = null;
+
+        try {
+            exts = new InternalLocaleBuilder()
+                .setExtensions(extensionsProp)
+                .getLocaleExtensions();
+        } catch (LocaleSyntaxException e) {
+            // just ignore this incorrect property
+        }
+
+        return Optional.ofNullable(exts);
     }
 
     /**
@@ -1771,7 +1793,7 @@
      * @exception NullPointerException if <code>inLocale</code> is <code>null</code>
      */
     public String getDisplayLanguage(Locale inLocale) {
-        return getDisplayString(baseLocale.getLanguage(), inLocale, DISPLAY_LANGUAGE);
+        return getDisplayString(baseLocale.getLanguage(), null, inLocale, DISPLAY_LANGUAGE);
     }
 
     /**
@@ -1801,7 +1823,7 @@
      * @since 1.7
      */
     public String getDisplayScript(Locale inLocale) {
-        return getDisplayString(baseLocale.getScript(), inLocale, DISPLAY_SCRIPT);
+        return getDisplayString(baseLocale.getScript(), null, inLocale, DISPLAY_SCRIPT);
     }
 
     /**
@@ -1844,29 +1866,24 @@
      * @exception NullPointerException if <code>inLocale</code> is <code>null</code>
      */
     public String getDisplayCountry(Locale inLocale) {
-        return getDisplayString(baseLocale.getRegion(), inLocale, DISPLAY_COUNTRY);
+        return getDisplayString(baseLocale.getRegion(), null, inLocale, DISPLAY_COUNTRY);
     }
 
-    private String getDisplayString(String code, Locale inLocale, int type) {
-        if (code.length() == 0) {
+    private String getDisplayString(String code, String cat, Locale inLocale, int type) {
+        Objects.requireNonNull(inLocale);
+        Objects.requireNonNull(code);
+
+        if (code.isEmpty()) {
             return "";
         }
 
-        if (inLocale == null) {
-            throw new NullPointerException();
-        }
-
         LocaleServiceProviderPool pool =
             LocaleServiceProviderPool.getPool(LocaleNameProvider.class);
-        String key = (type == DISPLAY_VARIANT ? "%%"+code : code);
+        String rbKey = (type == DISPLAY_VARIANT ? "%%"+code : code);
         String result = pool.getLocalizedObject(
                                 LocaleNameGetter.INSTANCE,
-                                inLocale, key, type, code);
-            if (result != null) {
-                return result;
-            }
-
-        return code;
+                                inLocale, rbKey, type, code, cat);
+        return result != null ? result : code;
     }
 
     /**
@@ -1894,29 +1911,31 @@
         if (baseLocale.getVariant().length() == 0)
             return "";
 
-        LocaleResources lr = LocaleProviderAdapter.forJRE().getLocaleResources(inLocale);
+        LocaleResources lr = LocaleProviderAdapter
+            .getResourceBundleBased()
+            .getLocaleResources(inLocale);
 
         String names[] = getDisplayVariantArray(inLocale);
 
         // Get the localized patterns for formatting a list, and use
         // them to format the list.
         return formatList(names,
-                          lr.getLocaleName("ListPattern"),
                           lr.getLocaleName("ListCompositionPattern"));
     }
 
     /**
      * Returns a name for the locale that is appropriate for display to the
      * user. This will be the values returned by getDisplayLanguage(),
-     * getDisplayScript(), getDisplayCountry(), and getDisplayVariant() assembled
-     * into a single string. The non-empty values are used in order,
-     * with the second and subsequent names in parentheses.  For example:
+     * getDisplayScript(), getDisplayCountry(), getDisplayVariant() and
+     * optional <a href="./Locale.html#def_locale_extension">Unicode extensions</a>
+     * assembled into a single string. The non-empty values are used in order, with
+     * the second and subsequent names in parentheses.  For example:
      * <blockquote>
-     * language (script, country, variant)<br>
-     * language (country)<br>
-     * language (variant)<br>
-     * script (country)<br>
-     * country<br>
+     * language (script, country, variant(, extension)*)<br>
+     * language (country(, extension)*)<br>
+     * language (variant(, extension)*)<br>
+     * script (country(, extension)*)<br>
+     * country (extension)*<br>
      * </blockquote>
      * depending on which fields are specified in the locale.  If the
      * language, script, country, and variant fields are all empty,
@@ -1931,16 +1950,17 @@
     /**
      * Returns a name for the locale that is appropriate for display
      * to the user.  This will be the values returned by
-     * getDisplayLanguage(), getDisplayScript(),getDisplayCountry(),
-     * and getDisplayVariant() assembled into a single string.
-     * The non-empty values are used in order,
-     * with the second and subsequent names in parentheses.  For example:
+     * getDisplayLanguage(), getDisplayScript(),getDisplayCountry()
+     * getDisplayVariant(), and optional <a href="./Locale.html#def_locale_extension">
+     * Unicode extensions</a> assembled into a single string. The non-empty
+     * values are used in order, with the second and subsequent names in
+     * parentheses.  For example:
      * <blockquote>
-     * language (script, country, variant)<br>
-     * language (country)<br>
-     * language (variant)<br>
-     * script (country)<br>
-     * country<br>
+     * language (script, country, variant(, extension)*)<br>
+     * language (country(, extension)*)<br>
+     * language (variant(, extension)*)<br>
+     * script (country(, extension)*)<br>
+     * country (extension)*<br>
      * </blockquote>
      * depending on which fields are specified in the locale.  If the
      * language, script, country, and variant fields are all empty,
@@ -1951,7 +1971,9 @@
      * @throws NullPointerException if <code>inLocale</code> is <code>null</code>
      */
     public String getDisplayName(Locale inLocale) {
-        LocaleResources lr =  LocaleProviderAdapter.forJRE().getLocaleResources(inLocale);
+        LocaleResources lr =  LocaleProviderAdapter
+            .getResourceBundleBased()
+            .getLocaleResources(inLocale);
 
         String languageName = getDisplayLanguage(inLocale);
         String scriptName = getDisplayScript(inLocale);
@@ -1960,7 +1982,6 @@
 
         // Get the localized patterns for formatting a display name.
         String displayNamePattern = lr.getLocaleName("DisplayNamePattern");
-        String listPattern = lr.getLocaleName("ListPattern");
         String listCompositionPattern = lr.getLocaleName("ListCompositionPattern");
 
         // The display name consists of a main name, followed by qualifiers.
@@ -1977,7 +1998,7 @@
             if (variantNames.length == 0) {
                 return "";
             } else {
-                return formatList(variantNames, listPattern, listCompositionPattern);
+                return formatList(variantNames, listCompositionPattern);
             }
         }
         ArrayList<String> names = new ArrayList<>(4);
@@ -1994,6 +2015,16 @@
             names.addAll(Arrays.asList(variantNames));
         }
 
+        // add Unicode extensions
+        if (localeExtensions != null) {
+            localeExtensions.getUnicodeLocaleAttributes().stream()
+                .map(key -> getDisplayString(key, null, inLocale, DISPLAY_UEXT_KEY))
+                .forEach(names::add);
+            localeExtensions.getUnicodeLocaleKeys().stream()
+                .map(key -> getDisplayKeyTypeExtensionString(key, lr, inLocale))
+                .forEach(names::add);
+        }
+
         // The first one in the main name
         mainName = names.get(0);
 
@@ -2014,7 +2045,7 @@
             // list case, but this is more efficient, and we want it to be
             // efficient since all the language-only locales will not have any
             // qualifiers.
-            qualifierNames.length != 0 ? formatList(qualifierNames, listPattern, listCompositionPattern) : null
+            qualifierNames.length != 0 ? formatList(qualifierNames, listCompositionPattern) : null
         };
 
         if (displayNamePattern != null) {
@@ -2121,74 +2152,78 @@
         // For each variant token, lookup the display name.  If
         // not found, use the variant name itself.
         for (int i=0; i<names.length; ++i) {
-            names[i] = getDisplayString(tokenizer.nextToken(),
+            names[i] = getDisplayString(tokenizer.nextToken(), null,
                                 inLocale, DISPLAY_VARIANT);
         }
 
         return names;
     }
 
+    private String getDisplayKeyTypeExtensionString(String key, LocaleResources lr, Locale inLocale) {
+        String type = localeExtensions.getUnicodeLocaleType(key);
+        String ret = getDisplayString(type, key, inLocale, DISPLAY_UEXT_TYPE);
+
+        if (ret == null || ret.equals(type)) {
+            // no localization for this type. try combining key/type separately
+            String displayType = type;
+            switch (key) {
+            case "cu":
+                displayType = lr.getCurrencyName(type.toLowerCase(Locale.ROOT));
+                break;
+            case "rg":
+                if (type != null &&
+                    // UN M.49 code should not be allowed here
+                    type.matches("^[a-zA-Z]{2}[zZ]{4}$")) {
+                        displayType = lr.getLocaleName(type.substring(0, 2).toUpperCase(Locale.ROOT));
+                }
+                break;
+            case "tz":
+                displayType = TimeZoneNameUtility.retrieveGenericDisplayName(
+                    TimeZoneNameUtility.convertLDMLShortID(type).orElse(type),
+                    TimeZone.LONG, inLocale);
+                break;
+            }
+            ret = MessageFormat.format(lr.getLocaleName("ListKeyTypePattern"),
+                getDisplayString(key, null, inLocale, DISPLAY_UEXT_KEY),
+                Optional.ofNullable(displayType).orElse(type));
+        }
+
+        return ret;
+    }
+
     /**
      * Format a list using given pattern strings.
      * If either of the patterns is null, then a the list is
      * formatted by concatenation with the delimiter ','.
      * @param stringList the list of strings to be formatted.
-     * @param listPattern should create a MessageFormat taking 0-3 arguments
      * and formatting them into a list.
-     * @param listCompositionPattern should take 2 arguments
-     * and is used by composeList.
+     * @param pattern should take 2 arguments for reduction
      * @return a string representing the list.
      */
-    private static String formatList(String[] stringList, String listPattern, String listCompositionPattern) {
+    private static String formatList(String[] stringList, String pattern) {
         // If we have no list patterns, compose the list in a simple,
         // non-localized way.
-        if (listPattern == null || listCompositionPattern == null) {
-            StringJoiner sj = new StringJoiner(",");
-            for (int i = 0; i < stringList.length; ++i) {
-                sj.add(stringList[i]);
-            }
-            return sj.toString();
-        }
-
-        // Compose the list down to three elements if necessary
-        if (stringList.length > 3) {
-            MessageFormat format = new MessageFormat(listCompositionPattern);
-            stringList = composeList(format, stringList);
+        if (pattern == null) {
+            return Arrays.stream(stringList).collect(Collectors.joining(","));
         }
 
-        // Rebuild the argument list with the list length as the first element
-        Object[] args = new Object[stringList.length + 1];
-        System.arraycopy(stringList, 0, args, 1, stringList.length);
-        args[0] = stringList.length;
-
-        // Format it using the pattern in the resource
-        MessageFormat format = new MessageFormat(listPattern);
-        return format.format(args);
-    }
-
-    /**
-     * Given a list of strings, return a list shortened to three elements.
-     * Shorten it by applying the given format to the first two elements
-     * recursively.
-     * @param format a format which takes two arguments
-     * @param list a list of strings
-     * @return if the list is three elements or shorter, the same list;
-     * otherwise, a new list of three elements.
-     */
-    private static String[] composeList(MessageFormat format, String[] list) {
-        if (list.length <= 3) return list;
-
-        // Use the given format to compose the first two elements into one
-        String[] listItems = { list[0], list[1] };
-        String newItem = format.format(listItems);
-
-        // Form a new list one element shorter
-        String[] newList = new String[list.length-1];
-        System.arraycopy(list, 2, newList, 1, newList.length-1);
-        newList[0] = newItem;
-
-        // Recurse
-        return composeList(format, newList);
+        switch (stringList.length) {
+            case 0:
+                return "";
+            case 1:
+                return stringList[0];
+            default:
+                return Arrays.stream(stringList).reduce("",
+                    (s1, s2) -> {
+                        if (s1.equals("")) {
+                            return s2;
+                        }
+                        if (s2.equals("")) {
+                            return s1;
+                        }
+                        return MessageFormat.format(pattern, s1, s2);
+                    });
+        }
     }
 
     // Duplicate of sun.util.locale.UnicodeLocaleExtension.isKey in order to
@@ -2345,9 +2380,10 @@
                                 Locale locale,
                                 String key,
                                 Object... params) {
-            assert params.length == 2;
+            assert params.length == 3;
             int type = (Integer)params[0];
             String code = (String)params[1];
+            String cat = (String)params[2];
 
             switch(type) {
             case DISPLAY_LANGUAGE:
@@ -2358,6 +2394,10 @@
                 return localeNameProvider.getDisplayVariant(code, locale);
             case DISPLAY_SCRIPT:
                 return localeNameProvider.getDisplayScript(code, locale);
+            case DISPLAY_UEXT_KEY:
+                return localeNameProvider.getDisplayUnicodeExtensionKey(code, locale);
+            case DISPLAY_UEXT_TYPE:
+                return localeNameProvider.getDisplayUnicodeExtensionType(code, cat, locale);
             default:
                 assert false; // shouldn't happen
             }
@@ -2384,7 +2424,8 @@
         DISPLAY("user.language.display",
                 "user.script.display",
                 "user.country.display",
-                "user.variant.display"),
+                "user.variant.display",
+                "user.extensions.display"),
 
         /**
          * Category used to represent the default locale for
@@ -2393,19 +2434,23 @@
         FORMAT("user.language.format",
                "user.script.format",
                "user.country.format",
-               "user.variant.format");
+               "user.variant.format",
+               "user.extensions.format");
 
-        Category(String languageKey, String scriptKey, String countryKey, String variantKey) {
+        Category(String languageKey, String scriptKey, String countryKey,
+                String variantKey, String extensionsKey) {
             this.languageKey = languageKey;
             this.scriptKey = scriptKey;
             this.countryKey = countryKey;
             this.variantKey = variantKey;
+            this.extensionsKey = extensionsKey;
         }
 
         final String languageKey;
         final String scriptKey;
         final String countryKey;
         final String variantKey;
+        final String extensionsKey;
     }
 
     /**
--- a/src/java.base/share/classes/java/util/spi/LocaleNameProvider.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/java/util/spi/LocaleNameProvider.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,6 +26,7 @@
 package java.util.spi;
 
 import java.util.Locale;
+import java.util.Objects;
 
 /**
  * An abstract class for service providers that
@@ -141,4 +142,54 @@
      * @see java.util.Locale#getDisplayVariant(java.util.Locale)
      */
     public abstract String getDisplayVariant(String variant, Locale locale);
+
+    /**
+     * Returns a localized name for the given
+     * <a href="../Locale.html#def_locale_extension">Unicode extension</a> key,
+     * and the given locale that is appropriate for display to the user.
+     * If the name returned cannot be localized according to {@code locale},
+     * this method returns null.
+     * @implSpec the default implementation returns {@code null}.
+     * @param key the Unicode Extension key, not null.
+     * @param locale the desired locale, not null.
+     * @return the name of the given key string for the specified locale,
+     *  or null if it's not available.
+     * @exception NullPointerException if {@code key} or {@code locale} is null
+     * @exception IllegalArgumentException if {@code locale} isn't
+     *     one of the locales returned from
+     *     {@link java.util.spi.LocaleServiceProvider#getAvailableLocales()
+     *     getAvailableLocales()}.
+     * @since 10
+     */
+    public String getDisplayUnicodeExtensionKey(String key, Locale locale) {
+        Objects.requireNonNull(key);
+        Objects.requireNonNull(locale);
+        return null;
+    }
+
+    /**
+     * Returns a localized name for the given
+     * <a href="../Locale.html#def_locale_extension">Unicode extension</a> type,
+     * and the given locale that is appropriate for display to the user.
+     * If the name returned cannot be localized according to {@code locale},
+     * this method returns null.
+     * @implSpec the default implementation returns {@code null}.
+     * @param type the Unicode Extension type, not null.
+     * @param key the Unicode Extension key for this {@code type}, not null.
+     * @param locale the desired locale, not null.
+     * @return the name of the given type string for the specified locale,
+     *  or null if it's not available.
+     * @exception NullPointerException if {@code key}, {@code type} or {@code locale} is null
+     * @exception IllegalArgumentException if {@code locale} isn't
+     *     one of the locales returned from
+     *     {@link java.util.spi.LocaleServiceProvider#getAvailableLocales()
+     *     getAvailableLocales()}.
+     * @since 10
+     */
+    public String getDisplayUnicodeExtensionType(String type, String key, Locale locale) {
+        Objects.requireNonNull(type);
+        Objects.requireNonNull(key);
+        Objects.requireNonNull(locale);
+        return null;
+    }
 }
--- a/src/java.base/share/classes/sun/launcher/LauncherHelper.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/launcher/LauncherHelper.java	Tue Dec 12 10:21:58 2017 -0800
@@ -268,7 +268,7 @@
         Locale locale = Locale.getDefault();
         ostream.println(LOCALE_SETTINGS);
         ostream.println(INDENT + "default locale = " +
-                locale.getDisplayLanguage());
+                locale.getDisplayName());
         ostream.println(INDENT + "default display locale = " +
                 Locale.getDefault(Category.DISPLAY).getDisplayName());
         ostream.println(INDENT + "default format locale = " +
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/sun/util/cldr/CLDRCalendarDataProviderImpl.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,106 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package sun.util.cldr;
+
+import static sun.util.locale.provider.LocaleProviderAdapter.Type;
+
+import java.util.Arrays;
+import java.util.Map;
+import java.util.Locale;
+import java.util.Set;
+import java.util.Optional;
+import java.util.concurrent.ConcurrentHashMap;
+import sun.util.locale.provider.LocaleProviderAdapter;
+import sun.util.locale.provider.LocaleResources;
+import sun.util.locale.provider.CalendarDataProviderImpl;
+import sun.util.locale.provider.CalendarDataUtility;
+
+/**
+ * Concrete implementation of the
+ * {@link java.util.spi.CalendarDataProvider CalendarDataProvider} class
+ * for the CLDR LocaleProviderAdapter.
+ *
+ * @author Naoto Sato
+ */
+public class CLDRCalendarDataProviderImpl extends CalendarDataProviderImpl {
+
+    private static Map<String, Integer> firstDay = new ConcurrentHashMap<>();
+    private static Map<String, Integer> minDays = new ConcurrentHashMap<>();
+
+    public CLDRCalendarDataProviderImpl(Type type, Set<String> langtags) {
+        super(type, langtags);
+    }
+
+    @Override
+    public int getFirstDayOfWeek(Locale locale) {
+        return findValue(CalendarDataUtility.FIRST_DAY_OF_WEEK, locale);
+    }
+
+    @Override
+    public int getMinimalDaysInFirstWeek(Locale locale) {
+        return findValue(CalendarDataUtility.MINIMAL_DAYS_IN_FIRST_WEEK, locale);
+    }
+
+    /**
+     * Finds the requested integer value for the locale.
+     * Each resource consists of the following:
+     *
+     *    (n: cc1 cc2 ... ccx;)*
+     *
+     * where 'n' is the integer for the following region codes, terminated by
+     * a ';'.
+     *
+     */
+    private static int findValue(String key, Locale locale) {
+        Map<String, Integer> map = CalendarDataUtility.FIRST_DAY_OF_WEEK.equals(key) ?
+            firstDay : minDays;
+        String region = locale.getCountry();
+
+        if (region.isEmpty()) {
+            return 0;
+        }
+
+        Integer val = map.get(region);
+        if (val == null) {
+            String valStr =
+                LocaleProviderAdapter.forType(Type.CLDR).getLocaleResources(Locale.ROOT)
+                   .getCalendarData(key);
+            val = retrieveInteger(valStr, region)
+                .orElse(retrieveInteger(valStr, "001").orElse(0));
+            map.putIfAbsent(region, val);
+        }
+
+        return val;
+    }
+
+    private static Optional<Integer> retrieveInteger(String src, String region) {
+        return Arrays.stream(src.split(";"))
+            .filter(entry -> entry.contains(region))
+            .map(entry -> entry.substring(0, entry.indexOf(":")))
+            .findAny()
+            .map(Integer::parseInt);
+    }
+}
--- a/src/java.base/share/classes/sun/util/cldr/CLDRLocaleProviderAdapter.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/cldr/CLDRLocaleProviderAdapter.java	Tue Dec 12 10:21:58 2017 -0800
@@ -27,6 +27,7 @@
 
 import java.security.AccessController;
 import java.security.AccessControlException;
+import java.security.PrivilegedAction;
 import java.security.PrivilegedActionException;
 import java.security.PrivilegedExceptionAction;
 import java.text.spi.BreakIteratorProvider;
@@ -37,15 +38,16 @@
 import java.util.List;
 import java.util.Locale;
 import java.util.Map;
-import java.util.Objects;
+import java.util.Optional;
 import java.util.ServiceLoader;
 import java.util.ServiceConfigurationError;
 import java.util.Set;
 import java.util.StringTokenizer;
 import java.util.concurrent.ConcurrentHashMap;
+import java.util.spi.CalendarDataProvider;
 import sun.util.locale.provider.JRELocaleProviderAdapter;
+import sun.util.locale.provider.LocaleDataMetaInfo;
 import sun.util.locale.provider.LocaleProviderAdapter;
-import sun.util.locale.provider.LocaleDataMetaInfo;
 
 /**
  * LocaleProviderAdapter implementation for the CLDR locale data.
@@ -106,6 +108,24 @@
     }
 
     @Override
+    public CalendarDataProvider getCalendarDataProvider() {
+        if (calendarDataProvider == null) {
+            CalendarDataProvider provider = AccessController.doPrivileged(
+                (PrivilegedAction<CalendarDataProvider>) () ->
+                    new CLDRCalendarDataProviderImpl(
+                        getAdapterType(),
+                        getLanguageTagSet("CalendarData")));
+
+            synchronized (this) {
+                if (calendarDataProvider == null) {
+                    calendarDataProvider = provider;
+                }
+            }
+        }
+        return calendarDataProvider;
+    }
+
+    @Override
     public CollatorProvider getCollatorProvider() {
         return null;
     }
@@ -123,6 +143,10 @@
 
     @Override
     protected Set<String> createLanguageTagSet(String category) {
+        // Assume all categories support the same set as AvailableLocales
+        // in CLDR adapter.
+        category = "AvailableLocales";
+
         // Directly call Base tags, as we know it's in the base module.
         String supportedLocaleString = baseMetaInfo.availableLanguageTags(category);
         String nonBaseTags = null;
@@ -220,4 +244,11 @@
                 || langtags.contains(locale.stripExtensions().toLanguageTag())
                 || langtags.contains(getEquivalentLoc(locale).toLanguageTag());
     }
+
+    /**
+     * Returns the time zone ID from an LDML's short ID
+     */
+    public Optional<String> getTimeZoneID(String shortID) {
+        return Optional.ofNullable(baseMetaInfo.tzShortIDs().get(shortID));
+    }
 }
--- a/src/java.base/share/classes/sun/util/locale/provider/CalendarDataProviderImpl.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/CalendarDataProviderImpl.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -46,14 +46,16 @@
 
     @Override
     public int getFirstDayOfWeek(Locale locale) {
-        return LocaleProviderAdapter.forType(type).getLocaleResources(locale)
+        String fw = LocaleProviderAdapter.forType(type).getLocaleResources(locale)
                    .getCalendarData(CalendarDataUtility.FIRST_DAY_OF_WEEK);
+        return convertToCalendarData(fw);
     }
 
     @Override
     public int getMinimalDaysInFirstWeek(Locale locale) {
-        return LocaleProviderAdapter.forType(type).getLocaleResources(locale)
+        String md = LocaleProviderAdapter.forType(type).getLocaleResources(locale)
                    .getCalendarData(CalendarDataUtility.MINIMAL_DAYS_IN_FIRST_WEEK);
+        return convertToCalendarData(md);
     }
 
     @Override
@@ -65,4 +67,9 @@
     public Set<String> getAvailableLanguageTags() {
         return langtags;
     }
+
+    private int convertToCalendarData(String src) {
+        int val = Integer.parseInt(src);
+        return (src.isEmpty() || val <= 0 || val > 7) ? 0 : val;
+    }
 }
--- a/src/java.base/share/classes/sun/util/locale/provider/CalendarDataUtility.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/CalendarDataUtility.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -47,10 +47,34 @@
     }
 
     public static int retrieveFirstDayOfWeek(Locale locale) {
+        // Look for the Unicode Extension in the locale parameter
+        if (locale.hasExtensions()) {
+            String fw = locale.getUnicodeLocaleType("fw");
+            if (fw != null) {
+                switch (fw.toLowerCase(Locale.ROOT)) {
+                    case "mon":
+                        return MONDAY;
+                    case "tue":
+                        return TUESDAY;
+                    case "wed":
+                        return WEDNESDAY;
+                    case "thu":
+                        return THURSDAY;
+                    case "fri":
+                        return FRIDAY;
+                    case "sat":
+                        return SATURDAY;
+                    case "sun":
+                        return SUNDAY;
+                }
+            }
+        }
+
         LocaleServiceProviderPool pool =
                 LocaleServiceProviderPool.getPool(CalendarDataProvider.class);
         Integer value = pool.getLocalizedObject(CalendarWeekParameterGetter.INSTANCE,
-                                                locale, true, FIRST_DAY_OF_WEEK);
+                                                findRegionOverride(locale),
+                                                true, FIRST_DAY_OF_WEEK);
         return (value != null && (value >= SUNDAY && value <= SATURDAY)) ? value : SUNDAY;
     }
 
@@ -58,7 +82,8 @@
         LocaleServiceProviderPool pool =
                 LocaleServiceProviderPool.getPool(CalendarDataProvider.class);
         Integer value = pool.getLocalizedObject(CalendarWeekParameterGetter.INSTANCE,
-                                                locale, true, MINIMAL_DAYS_IN_FIRST_WEEK);
+                                                findRegionOverride(locale),
+                                                true, MINIMAL_DAYS_IN_FIRST_WEEK);
         return (value != null && (value >= 1 && value <= 7)) ? value : 1;
     }
 
@@ -102,6 +127,32 @@
         return map;
     }
 
+    /**
+     * Utility to look for a region override extension.
+     * If no region override is found, returns the original locale.
+     */
+    public static Locale findRegionOverride(Locale l) {
+        String rg = l.getUnicodeLocaleType("rg");
+        Locale override = l;
+
+        if (rg != null && rg.length() == 6) {
+            // UN M.49 code should not be allowed here
+            // cannot use regex here, as it could be a recursive call
+            rg = rg.toUpperCase(Locale.ROOT);
+            if (rg.charAt(0) >= 0x0041 &&
+                rg.charAt(0) <= 0x005A &&
+                rg.charAt(1) >= 0x0041 &&
+                rg.charAt(1) <= 0x005A &&
+                rg.substring(2).equals("ZZZZ")) {
+                override = new Locale.Builder().setLocale(l)
+                    .setRegion(rg.substring(0, 2))
+                    .build();
+            }
+        }
+
+        return override;
+    }
+
     static String normalizeCalendarType(String requestID) {
         String type;
         if (requestID.equals("gregorian") || requestID.equals("iso8601")) {
@@ -179,7 +230,7 @@
         }
     }
 
-     private static class CalendarWeekParameterGetter
+    private static class CalendarWeekParameterGetter
         implements LocaleServiceProviderPool.LocalizedObjectGetter<CalendarDataProvider,
                                                                    Integer> {
         private static final CalendarWeekParameterGetter INSTANCE =
--- a/src/java.base/share/classes/sun/util/locale/provider/DateFormatProviderImpl.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/DateFormatProviderImpl.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -32,6 +32,7 @@
 import java.util.Locale;
 import java.util.MissingResourceException;
 import java.util.Set;
+import java.util.TimeZone;
 
 /**
  * Concrete implementation of the  {@link java.text.spi.DateFormatProvider
@@ -147,11 +148,14 @@
             throw new NullPointerException();
         }
 
-        SimpleDateFormat sdf = new SimpleDateFormat("", locale);
+        // Check for region override
+        Locale rg = CalendarDataUtility.findRegionOverride(locale);
+
+        SimpleDateFormat sdf = new SimpleDateFormat("", rg);
         Calendar cal = sdf.getCalendar();
         try {
             String pattern = LocaleProviderAdapter.forType(type)
-                .getLocaleResources(locale).getDateTimePattern(timeStyle, dateStyle,
+                .getLocaleResources(rg).getDateTimePattern(timeStyle, dateStyle,
                                                                cal);
             sdf.applyPattern(pattern);
         } catch (MissingResourceException mre) {
@@ -159,6 +163,15 @@
             sdf.applyPattern("M/d/yy h:mm a");
         }
 
+        // Check for timezone override
+        String tz = locale.getUnicodeLocaleType("tz");
+        if (tz != null) {
+            sdf.setTimeZone(
+                TimeZoneNameUtility.convertLDMLShortID(tz)
+                    .map(TimeZone::getTimeZone)
+                    .orElseGet(sdf::getTimeZone));
+        }
+
         return sdf;
     }
 
--- a/src/java.base/share/classes/sun/util/locale/provider/JRELocaleProviderAdapter.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/JRELocaleProviderAdapter.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -130,7 +130,7 @@
     private volatile CurrencyNameProvider currencyNameProvider;
     private volatile LocaleNameProvider localeNameProvider;
     private volatile TimeZoneNameProvider timeZoneNameProvider;
-    private volatile CalendarDataProvider calendarDataProvider;
+    protected volatile CalendarDataProvider calendarDataProvider;
     private volatile CalendarNameProvider calendarNameProvider;
 
     private volatile CalendarProvider calendarProvider;
--- a/src/java.base/share/classes/sun/util/locale/provider/LocaleDataMetaInfo.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/LocaleDataMetaInfo.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -25,6 +25,8 @@
 
 package sun.util.locale.provider;
 
+import java.util.Map;
+
 /**
  * LocaleData meta info SPI
  *
@@ -46,4 +48,13 @@
      * @return concatenated language tags, separated by a space.
      */
     public String availableLanguageTags(String category);
+
+    /**
+     * Returns a map for short time zone ids in BCP47 Unicode extension and
+     * the long time zone ids.
+     * @return map of short id to long ids, separated by a space.
+     */
+    default public Map<String, String>  tzShortIDs() {
+        return null;
+    }
 }
--- a/src/java.base/share/classes/sun/util/locale/provider/LocaleNameProviderImpl.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/LocaleNameProviderImpl.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -168,6 +168,28 @@
         return getDisplayString("%%"+vrnt, locale);
     }
 
+    /**
+     * @inheritDoc
+     */
+    @Override
+    public String getDisplayUnicodeExtensionKey(String key, Locale locale) {
+        super.getDisplayUnicodeExtensionKey(key, locale); // null check
+        String rbKey = "key." + key;
+        String name = getDisplayString(rbKey, locale);
+        return rbKey.equals(name) ? key : name;
+    }
+
+    /**
+     * @inheritDoc
+     */
+    @Override
+    public String getDisplayUnicodeExtensionType(String extType, String key, Locale locale) {
+        super.getDisplayUnicodeExtensionType(extType, key, locale); // null check
+        String rbKey = "type." + key + "." + extType;
+        String name = getDisplayString(rbKey, locale);
+        return rbKey.equals(name) ? extType : name;
+    }
+
     private String getDisplayString(String key, Locale locale) {
         if (key == null || locale == null) {
             throw new NullPointerException();
--- a/src/java.base/share/classes/sun/util/locale/provider/LocaleResources.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/LocaleResources.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -122,23 +122,21 @@
         return (byte[]) localeData.getBreakIteratorResources(locale).getObject(key);
     }
 
-    int getCalendarData(String key) {
-        Integer caldata;
+    public String getCalendarData(String key) {
+        String caldata = "";
         String cacheKey = CALENDAR_DATA  + key;
 
         removeEmptyReferences();
 
         ResourceReference data = cache.get(cacheKey);
-        if (data == null || ((caldata = (Integer) data.get()) == null)) {
+        if (data == null || ((caldata = (String) data.get()) == null)) {
             ResourceBundle rb = localeData.getCalendarData(locale);
             if (rb.containsKey(key)) {
-                caldata = Integer.parseInt(rb.getString(key));
-            } else {
-                caldata = 0;
+                caldata = rb.getString(key);
             }
 
             cache.put(cacheKey,
-                      new ResourceReference(cacheKey, (Object) caldata, referenceQueue));
+                      new ResourceReference(cacheKey, caldata, referenceQueue));
         }
 
         return caldata;
--- a/src/java.base/share/classes/sun/util/locale/provider/NumberFormatProviderImpl.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/NumberFormatProviderImpl.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -173,9 +173,14 @@
             throw new NullPointerException();
         }
 
+        // Check for region override
+        Locale override = locale.getUnicodeLocaleType("nu") == null ?
+            CalendarDataUtility.findRegionOverride(locale) :
+            locale;
+
         LocaleProviderAdapter adapter = LocaleProviderAdapter.forType(type);
-        String[] numberPatterns = adapter.getLocaleResources(locale).getNumberPatterns();
-        DecimalFormatSymbols symbols = DecimalFormatSymbols.getInstance(locale);
+        String[] numberPatterns = adapter.getLocaleResources(override).getNumberPatterns();
+        DecimalFormatSymbols symbols = DecimalFormatSymbols.getInstance(override);
         int entry = (choice == INTEGERSTYLE) ? NUMBERSTYLE : choice;
         DecimalFormat format = new DecimalFormat(numberPatterns[entry], symbols);
 
--- a/src/java.base/share/classes/sun/util/locale/provider/SPILocaleProviderAdapter.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/SPILocaleProviderAdapter.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -160,28 +160,24 @@
         @Override
         public BreakIterator getWordInstance(Locale locale) {
             BreakIteratorProvider bip = getImpl(locale);
-            assert bip != null;
             return bip.getWordInstance(locale);
         }
 
         @Override
         public BreakIterator getLineInstance(Locale locale) {
             BreakIteratorProvider bip = getImpl(locale);
-            assert bip != null;
             return bip.getLineInstance(locale);
         }
 
         @Override
         public BreakIterator getCharacterInstance(Locale locale) {
             BreakIteratorProvider bip = getImpl(locale);
-            assert bip != null;
             return bip.getCharacterInstance(locale);
         }
 
         @Override
         public BreakIterator getSentenceInstance(Locale locale) {
             BreakIteratorProvider bip = getImpl(locale);
-            assert bip != null;
             return bip.getSentenceInstance(locale);
         }
 
@@ -215,7 +211,6 @@
         @Override
         public Collator getInstance(Locale locale) {
             CollatorProvider cp = getImpl(locale);
-            assert cp != null;
             return cp.getInstance(locale);
         }
     }
@@ -249,21 +244,18 @@
         @Override
         public DateFormat getTimeInstance(int style, Locale locale) {
             DateFormatProvider dfp = getImpl(locale);
-            assert dfp != null;
             return dfp.getTimeInstance(style, locale);
         }
 
         @Override
         public DateFormat getDateInstance(int style, Locale locale) {
             DateFormatProvider dfp = getImpl(locale);
-            assert dfp != null;
             return dfp.getDateInstance(style, locale);
         }
 
         @Override
         public DateFormat getDateTimeInstance(int dateStyle, int timeStyle, Locale locale) {
             DateFormatProvider dfp = getImpl(locale);
-            assert dfp != null;
             return dfp.getDateTimeInstance(dateStyle, timeStyle, locale);
         }
     }
@@ -297,7 +289,6 @@
         @Override
         public DateFormatSymbols getInstance(Locale locale) {
             DateFormatSymbolsProvider dfsp = getImpl(locale);
-            assert dfsp != null;
             return dfsp.getInstance(locale);
         }
     }
@@ -331,7 +322,6 @@
         @Override
         public DecimalFormatSymbols getInstance(Locale locale) {
             DecimalFormatSymbolsProvider dfsp = getImpl(locale);
-            assert dfsp != null;
             return dfsp.getInstance(locale);
         }
     }
@@ -365,28 +355,24 @@
         @Override
         public NumberFormat getCurrencyInstance(Locale locale) {
             NumberFormatProvider nfp = getImpl(locale);
-            assert nfp != null;
             return nfp.getCurrencyInstance(locale);
         }
 
         @Override
         public NumberFormat getIntegerInstance(Locale locale) {
             NumberFormatProvider nfp = getImpl(locale);
-            assert nfp != null;
             return nfp.getIntegerInstance(locale);
         }
 
         @Override
         public NumberFormat getNumberInstance(Locale locale) {
             NumberFormatProvider nfp = getImpl(locale);
-            assert nfp != null;
             return nfp.getNumberInstance(locale);
         }
 
         @Override
         public NumberFormat getPercentInstance(Locale locale) {
             NumberFormatProvider nfp = getImpl(locale);
-            assert nfp != null;
             return nfp.getPercentInstance(locale);
         }
     }
@@ -420,14 +406,12 @@
         @Override
         public int getFirstDayOfWeek(Locale locale) {
             CalendarDataProvider cdp = getImpl(locale);
-            assert cdp != null;
             return cdp.getFirstDayOfWeek(locale);
         }
 
         @Override
         public int getMinimalDaysInFirstWeek(Locale locale) {
             CalendarDataProvider cdp = getImpl(locale);
-            assert cdp != null;
             return cdp.getMinimalDaysInFirstWeek(locale);
         }
     }
@@ -463,7 +447,6 @@
                                               int field, int value,
                                               int style, Locale locale) {
             CalendarNameProvider cdp = getImpl(locale);
-            assert cdp != null;
             return cdp.getDisplayName(calendarType, field, value, style, locale);
         }
 
@@ -472,7 +455,6 @@
                                                              int field, int style,
                                                              Locale locale) {
             CalendarNameProvider cdp = getImpl(locale);
-            assert cdp != null;
             return cdp.getDisplayNames(calendarType, field, style, locale);
         }
     }
@@ -506,14 +488,12 @@
         @Override
         public String getSymbol(String currencyCode, Locale locale) {
             CurrencyNameProvider cnp = getImpl(locale);
-            assert cnp != null;
             return cnp.getSymbol(currencyCode, locale);
         }
 
         @Override
         public String getDisplayName(String currencyCode, Locale locale) {
             CurrencyNameProvider cnp = getImpl(locale);
-            assert cnp != null;
             return cnp.getDisplayName(currencyCode, locale);
         }
     }
@@ -547,30 +527,38 @@
         @Override
         public String getDisplayLanguage(String languageCode, Locale locale) {
             LocaleNameProvider lnp = getImpl(locale);
-            assert lnp != null;
             return lnp.getDisplayLanguage(languageCode, locale);
         }
 
         @Override
         public String getDisplayScript(String scriptCode, Locale locale) {
             LocaleNameProvider lnp = getImpl(locale);
-            assert lnp != null;
             return lnp.getDisplayScript(scriptCode, locale);
         }
 
         @Override
         public String getDisplayCountry(String countryCode, Locale locale) {
             LocaleNameProvider lnp = getImpl(locale);
-            assert lnp != null;
             return lnp.getDisplayCountry(countryCode, locale);
         }
 
         @Override
         public String getDisplayVariant(String variant, Locale locale) {
             LocaleNameProvider lnp = getImpl(locale);
-            assert lnp != null;
             return lnp.getDisplayVariant(variant, locale);
         }
+
+        @Override
+        public String getDisplayUnicodeExtensionKey(String key, Locale locale) {
+            LocaleNameProvider lnp = getImpl(locale);
+            return lnp.getDisplayUnicodeExtensionKey(key, locale);
+        }
+
+        @Override
+        public String getDisplayUnicodeExtensionType(String extType, String key, Locale locale) {
+            LocaleNameProvider lnp = getImpl(locale);
+            return lnp.getDisplayUnicodeExtensionType(extType, key, locale);
+        }
     }
 
     static class TimeZoneNameProviderDelegate extends TimeZoneNameProvider
@@ -602,14 +590,12 @@
         @Override
         public String getDisplayName(String ID, boolean daylight, int style, Locale locale) {
             TimeZoneNameProvider tznp = getImpl(locale);
-            assert tznp != null;
             return tznp.getDisplayName(ID, daylight, style, locale);
         }
 
         @Override
         public String getGenericDisplayName(String ID, int style, Locale locale) {
             TimeZoneNameProvider tznp = getImpl(locale);
-            assert tznp != null;
             return tznp.getGenericDisplayName(ID, style, locale);
         }
     }
--- a/src/java.base/share/classes/sun/util/locale/provider/TimeZoneNameUtility.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/locale/provider/TimeZoneNameUtility.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -31,10 +31,13 @@
 import java.util.Locale;
 import java.util.Map;
 import java.util.Objects;
+import java.util.Optional;
 import java.util.Set;
 import java.util.concurrent.ConcurrentHashMap;
 import java.util.spi.TimeZoneNameProvider;
 import sun.util.calendar.ZoneInfo;
+import sun.util.cldr.CLDRLocaleProviderAdapter;
+import static sun.util.locale.provider.LocaleProviderAdapter.Type;
 
 /**
  * Utility class that deals with the localized time zone names
@@ -152,6 +155,18 @@
         }
     }
 
+    /**
+     * Converts the time zone id from LDML's 5-letter id to tzdb's id
+     *
+     * @param shortID       time zone short ID defined in LDML
+     * @return the tzdb's time zone ID
+     */
+    public static Optional<String> convertLDMLShortID(String shortID) {
+        return ((CLDRLocaleProviderAdapter)LocaleProviderAdapter.forType(Type.CLDR))
+                    .getTimeZoneID(shortID)
+                    .map(id -> id.replaceAll("\\s.*", ""));
+    }
+
     private static String[] retrieveDisplayNamesImpl(String id, Locale locale) {
         LocaleServiceProviderPool pool =
             LocaleServiceProviderPool.getPool(TimeZoneNameProvider.class);
--- a/src/java.base/share/classes/sun/util/resources/LocaleNames.properties	Tue Dec 12 09:33:37 2017 -0800
+++ b/src/java.base/share/classes/sun/util/resources/LocaleNames.properties	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 #
 # This code is free software; you can redistribute it and/or modify it
@@ -1164,8 +1164,7 @@
 
 
 # locale name patterns
-# rarely localized
 
 DisplayNamePattern={0,choice,0#|1#{1}|2#{1} ({2})}
-ListPattern={0,choice,0#|1#{1}|2#{1},{2}|3#{1},{2},{3}}
+ListKeyTypePattern={0}:{1}
 ListCompositionPattern={0},{1}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/jdk.localedata/share/classes/sun/util/cldr/resources/common/bcp47/timezone.xml	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,470 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE ldmlBCP47 SYSTEM "../../common/dtd/ldmlBCP47.dtd">
+<!--
+Copyright © 1991-2013 Unicode, Inc.
+CLDR data files are interpreted according to the LDML specification (http://unicode.org/reports/tr35/)
+For terms of use, see http://www.unicode.org/copyright.html
+-->
+
+<ldmlBCP47>
+    <version number="$Revision: 12146 $"/>
+    <keyword>
+        <key name="tz" description="Time zone key" alias="timezone">
+            <type name="adalv" description="Andorra" alias="Europe/Andorra"/>
+            <type name="aedxb" description="Dubai, United Arab Emirates" alias="Asia/Dubai"/>
+            <type name="afkbl" description="Kabul, Afghanistan" alias="Asia/Kabul"/>
+            <type name="aganu" description="Antigua" alias="America/Antigua"/>
+            <type name="aiaxa" description="Anguilla" alias="America/Anguilla"/>
+            <type name="altia" description="Tirane, Albania" alias="Europe/Tirane"/>
+            <type name="amevn" description="Yerevan, Armenia" alias="Asia/Yerevan"/>
+            <type name="ancur" description="Curaçao" alias="America/Curacao"/>
+            <type name="aolad" description="Luanda, Angola" alias="Africa/Luanda"/>
+            <type name="aqams" description="Amundsen-Scott Station, South Pole" deprecated="true" preferred="nzakl"/>
+            <type name="aqcas" description="Casey Station, Bailey Peninsula" alias="Antarctica/Casey"/>
+            <type name="aqdav" description="Davis Station, Vestfold Hills" alias="Antarctica/Davis"/>
+            <type name="aqddu" description="Dumont d'Urville Station, Terre Adélie" alias="Antarctica/DumontDUrville"/>
+            <type name="aqmaw" description="Mawson Station, Holme Bay" alias="Antarctica/Mawson"/>
+            <type name="aqmcm" description="McMurdo Station, Ross Island" alias="Antarctica/McMurdo"/>
+            <type name="aqplm" description="Palmer Station, Anvers Island" alias="Antarctica/Palmer"/>
+            <type name="aqrot" description="Rothera Station, Adelaide Island" alias="Antarctica/Rothera"/>
+            <type name="aqsyw" description="Syowa Station, East Ongul Island" alias="Antarctica/Syowa"/>
+            <type name="aqtrl" description="Troll Station, Queen Maud Land" alias="Antarctica/Troll" since="26"/>
+            <type name="aqvos" description="Vostok Station, Lake Vostok" alias="Antarctica/Vostok"/>
+            <type name="arbue" description="Buenos Aires, Argentina" alias="America/Buenos_Aires America/Argentina/Buenos_Aires"/>
+            <type name="arcor" description="Córdoba, Argentina" alias="America/Cordoba America/Argentina/Cordoba America/Rosario"/>
+            <type name="arctc" description="Catamarca, Argentina" alias="America/Catamarca America/Argentina/Catamarca America/Argentina/ComodRivadavia"/>
+            <type name="arirj" description="La Rioja, Argentina" alias="America/Argentina/La_Rioja"/>
+            <type name="arjuj" description="Jujuy, Argentina" alias="America/Jujuy America/Argentina/Jujuy"/>
+            <type name="arluq" description="San Luis, Argentina" alias="America/Argentina/San_Luis"/>
+            <type name="armdz" description="Mendoza, Argentina" alias="America/Mendoza America/Argentina/Mendoza"/>
+            <type name="arrgl" description="Río Gallegos, Argentina" alias="America/Argentina/Rio_Gallegos"/>
+            <type name="arsla" description="Salta, Argentina" alias="America/Argentina/Salta"/>
+            <type name="artuc" description="Tucumán, Argentina" alias="America/Argentina/Tucuman"/>
+            <type name="aruaq" description="San Juan, Argentina" alias="America/Argentina/San_Juan"/>
+            <type name="arush" description="Ushuaia, Argentina" alias="America/Argentina/Ushuaia"/>
+            <type name="asppg" description="Pago Pago, American Samoa" alias="Pacific/Pago_Pago Pacific/Samoa US/Samoa"/>
+            <type name="atvie" description="Vienna, Austria" alias="Europe/Vienna"/>
+            <type name="auadl" description="Adelaide, Australia" alias="Australia/Adelaide Australia/South"/>
+            <type name="aubhq" description="Broken Hill, Australia" alias="Australia/Broken_Hill Australia/Yancowinna"/>
+            <type name="aubne" description="Brisbane, Australia" alias="Australia/Brisbane Australia/Queensland"/>
+            <type name="audrw" description="Darwin, Australia" alias="Australia/Darwin Australia/North"/>
+            <type name="aueuc" description="Eucla, Australia" alias="Australia/Eucla"/>
+            <type name="auhba" description="Hobart, Australia" alias="Australia/Hobart Australia/Tasmania"/>
+            <type name="aukns" description="Currie, Australia" alias="Australia/Currie"/>
+            <type name="auldc" description="Lindeman Island, Australia" alias="Australia/Lindeman"/>
+            <type name="auldh" description="Lord Howe Island, Australia" alias="Australia/Lord_Howe Australia/LHI"/>
+            <type name="aumel" description="Melbourne, Australia" alias="Australia/Melbourne Australia/Victoria"/>
+            <type name="aumqi" description="Macquarie Island Station, Macquarie Island" alias="Antarctica/Macquarie" since="1.8.1"/>
+            <type name="auper" description="Perth, Australia" alias="Australia/Perth Australia/West"/>
+            <type name="ausyd" description="Sydney, Australia" alias="Australia/Sydney Australia/ACT Australia/Canberra Australia/NSW"/>
+            <type name="awaua" description="Aruba" alias="America/Aruba"/>
+            <type name="azbak" description="Baku, Azerbaijan" alias="Asia/Baku"/>
+            <type name="basjj" description="Sarajevo, Bosnia and Herzegovina" alias="Europe/Sarajevo"/>
+            <type name="bbbgi" description="Barbados" alias="America/Barbados"/>
+            <type name="bddac" description="Dhaka, Bangladesh" alias="Asia/Dhaka Asia/Dacca"/>
+            <type name="bebru" description="Brussels, Belgium" alias="Europe/Brussels"/>
+            <type name="bfoua" description="Ouagadougou, Burkina Faso" alias="Africa/Ouagadougou"/>
+            <type name="bgsof" description="Sofia, Bulgaria" alias="Europe/Sofia"/>
+            <type name="bhbah" description="Bahrain" alias="Asia/Bahrain"/>
+            <type name="bibjm" description="Bujumbura, Burundi" alias="Africa/Bujumbura"/>
+            <type name="bjptn" description="Porto-Novo, Benin" alias="Africa/Porto-Novo"/>
+            <type name="bmbda" description="Bermuda" alias="Atlantic/Bermuda"/>
+            <type name="bnbwn" description="Brunei" alias="Asia/Brunei"/>
+            <type name="bolpb" description="La Paz, Bolivia" alias="America/La_Paz"/>
+            <type name="bqkra" description="Bonaire, Sint Estatius and Saba" alias="America/Kralendijk" since="21"/>
+            <type name="braux" description="Araguaína, Brazil" alias="America/Araguaina"/>
+            <type name="brbel" description="Belém, Brazil" alias="America/Belem"/>
+            <type name="brbvb" description="Boa Vista, Brazil" alias="America/Boa_Vista"/>
+            <type name="brcgb" description="Cuiabá, Brazil" alias="America/Cuiaba"/>
+            <type name="brcgr" description="Campo Grande, Brazil" alias="America/Campo_Grande"/>
+            <type name="brern" description="Eirunepé, Brazil" alias="America/Eirunepe"/>
+            <type name="brfen" description="Fernando de Noronha, Brazil" alias="America/Noronha Brazil/DeNoronha"/>
+            <type name="brfor" description="Fortaleza, Brazil" alias="America/Fortaleza"/>
+            <type name="brmao" description="Manaus, Brazil" alias="America/Manaus Brazil/West"/>
+            <type name="brmcz" description="Maceió, Brazil" alias="America/Maceio"/>
+            <type name="brpvh" description="Porto Velho, Brazil" alias="America/Porto_Velho"/>
+            <type name="brrbr" description="Rio Branco, Brazil" alias="America/Rio_Branco America/Porto_Acre Brazil/Acre"/>
+            <type name="brrec" description="Recife, Brazil" alias="America/Recife"/>
+            <type name="brsao" description="São Paulo, Brazil" alias="America/Sao_Paulo Brazil/East"/>
+            <type name="brssa" description="Bahia, Brazil" alias="America/Bahia"/>
+            <type name="brstm" description="Santarém, Brazil" alias="America/Santarem"/>
+            <type name="bsnas" description="Nassau, Bahamas" alias="America/Nassau"/>
+            <type name="btthi" description="Thimphu, Bhutan" alias="Asia/Thimphu Asia/Thimbu"/>
+            <type name="bwgbe" description="Gaborone, Botswana" alias="Africa/Gaborone"/>
+            <type name="bymsq" description="Minsk, Belarus" alias="Europe/Minsk"/>
+            <type name="bzbze" description="Belize" alias="America/Belize"/>
+            <type name="cacfq" description="Creston, Canada" alias="America/Creston" since="21.0.1"/>
+            <type name="caedm" description="Edmonton, Canada" alias="America/Edmonton Canada/Mountain"/>
+            <type name="caffs" description="Rainy River, Canada" alias="America/Rainy_River"/>
+            <type name="cafne" description="Fort Nelson, Canada" alias="America/Fort_Nelson"/>
+            <type name="caglb" description="Glace Bay, Canada" alias="America/Glace_Bay"/>
+            <type name="cagoo" description="Goose Bay, Canada" alias="America/Goose_Bay"/>
+            <type name="cahal" description="Halifax, Canada" alias="America/Halifax Canada/Atlantic"/>
+            <type name="caiql" description="Iqaluit, Canada" alias="America/Iqaluit"/>
+            <type name="camon" description="Moncton, Canada" alias="America/Moncton"/>
+            <type name="camtr" description="Montreal, Canada" deprecated="true" alias="America/Montreal"/>
+            <type name="capnt" description="Pangnirtung, Canada" alias="America/Pangnirtung"/>
+            <type name="careb" description="Resolute, Canada" alias="America/Resolute"/>
+            <type name="careg" description="Regina, Canada" alias="America/Regina Canada/East-Saskatchewan Canada/Saskatchewan"/>
+            <type name="casjf" description="St. John's, Canada" alias="America/St_Johns Canada/Newfoundland"/>
+            <type name="canpg" description="Nipigon, Canada" alias="America/Nipigon"/>
+            <type name="cathu" description="Thunder Bay, Canada" alias="America/Thunder_Bay"/>
+            <type name="cator" description="Toronto, Canada" alias="America/Toronto Canada/Eastern"/>
+            <type name="cavan" description="Vancouver, Canada" alias="America/Vancouver Canada/Pacific"/>
+            <type name="cawnp" description="Winnipeg, Canada" alias="America/Winnipeg Canada/Central"/>
+            <type name="caybx" description="Blanc-Sablon, Canada" alias="America/Blanc-Sablon"/>
+            <type name="caycb" description="Cambridge Bay, Canada" alias="America/Cambridge_Bay"/>
+            <type name="cayda" description="Dawson, Canada" alias="America/Dawson"/>
+            <type name="caydq" description="Dawson Creek, Canada" alias="America/Dawson_Creek"/>
+            <type name="cayek" description="Rankin Inlet, Canada" alias="America/Rankin_Inlet"/>
+            <type name="cayev" description="Inuvik, Canada" alias="America/Inuvik"/>
+            <type name="cayxy" description="Whitehorse, Canada" alias="America/Whitehorse Canada/Yukon"/>
+            <type name="cayyn" description="Swift Current, Canada" alias="America/Swift_Current"/>
+            <type name="cayzf" description="Yellowknife, Canada" alias="America/Yellowknife"/>
+            <type name="cayzs" description="Atikokan, Canada" alias="America/Coral_Harbour America/Atikokan"/>
+            <type name="cccck" description="Cocos (Keeling) Islands" alias="Indian/Cocos"/>
+            <type name="cdfbm" description="Lubumbashi, Democratic Republic of the Congo" alias="Africa/Lubumbashi"/>
+            <type name="cdfih" description="Kinshasa, Democratic Republic of the Congo" alias="Africa/Kinshasa"/>
+            <type name="cfbgf" description="Bangui, Central African Republic" alias="Africa/Bangui"/>
+            <type name="cgbzv" description="Brazzaville, Republic of the Congo" alias="Africa/Brazzaville"/>
+            <type name="chzrh" description="Zurich, Switzerland" alias="Europe/Zurich"/>
+            <type name="ciabj" description="Abidjan, Côte d'Ivoire" alias="Africa/Abidjan"/>
+            <type name="ckrar" description="Rarotonga, Cook Islands" alias="Pacific/Rarotonga"/>
+            <type name="clipc" description="Easter Island, Chile" alias="Pacific/Easter Chile/EasterIsland"/>
+            <type name="clscl" description="Santiago, Chile" alias="America/Santiago Chile/Continental"/>
+            <type name="cmdla" description="Douala, Cameroon" alias="Africa/Douala"/>
+            <type name="cnckg" description="Chongqing, China" deprecated="true" preferred="cnsha"/>
+            <type name="cnhrb" description="Harbin, China" deprecated="true" preferred="cnsha"/>
+            <type name="cnkhg" description="Kashgar, China" deprecated="true" preferred="cnurc"/>
+            <type name="cnsha" description="Shanghai, China" alias="Asia/Shanghai Asia/Chongqing Asia/Chungking Asia/Harbin PRC"/>
+            <type name="cnurc" description="Ürümqi, China" alias="Asia/Urumqi Asia/Kashgar"/>
+            <type name="cobog" description="Bogotá, Colombia" alias="America/Bogota"/>
+            <type name="crsjo" description="Costa Rica" alias="America/Costa_Rica"/>
+            <type name="cst6cdt" description="POSIX style time zone for US Central Time" alias="CST6CDT" since="1.8"/>
+            <type name="cuhav" description="Havana, Cuba" alias="America/Havana Cuba"/>
+            <type name="cvrai" description="Cape Verde" alias="Atlantic/Cape_Verde"/>
+            <type name="cxxch" description="Christmas Island" alias="Indian/Christmas"/>
+            <type name="cynic" description="Nicosia, Cyprus" alias="Asia/Nicosia Europe/Nicosia"/>
+            <type name="czprg" description="Prague, Czech Republic" alias="Europe/Prague"/>
+            <type name="deber" description="Berlin, Germany" alias="Europe/Berlin"/>
+            <type name="debsngn" description="Busingen, Germany" alias="Europe/Busingen" since="23"/>
+            <type name="djjib" description="Djibouti" alias="Africa/Djibouti"/>
+            <type name="dkcph" description="Copenhagen, Denmark" alias="Europe/Copenhagen"/>
+            <type name="dmdom" description="Dominica" alias="America/Dominica"/>
+            <type name="dosdq" description="Santo Domingo, Dominican Republic" alias="America/Santo_Domingo"/>
+            <type name="dzalg" description="Algiers, Algeria" alias="Africa/Algiers"/>
+            <type name="ecgps" description="Galápagos Islands, Ecuador" alias="Pacific/Galapagos"/>
+            <type name="ecgye" description="Guayaquil, Ecuador" alias="America/Guayaquil"/>
+            <type name="eetll" description="Tallinn, Estonia" alias="Europe/Tallinn"/>
+            <type name="egcai" description="Cairo, Egypt" alias="Africa/Cairo Egypt"/>
+            <type name="eheai" description="El Aaiún, Western Sahara" alias="Africa/El_Aaiun"/>
+            <type name="erasm" description="Asmara, Eritrea" alias="Africa/Asmera Africa/Asmara"/>
+            <type name="esceu" description="Ceuta, Spain" alias="Africa/Ceuta"/>
+            <type name="eslpa" description="Canary Islands, Spain" alias="Atlantic/Canary"/>
+            <type name="esmad" description="Madrid, Spain" alias="Europe/Madrid"/>
+            <type name="est5edt" description="POSIX style time zone for US Eastern Time" alias="EST5EDT" since="1.8"/>
+            <type name="etadd" description="Addis Ababa, Ethiopia" alias="Africa/Addis_Ababa"/>
+            <type name="fihel" description="Helsinki, Finland" alias="Europe/Helsinki"/>
+            <type name="fimhq" description="Mariehamn, Ã…land, Finland" alias="Europe/Mariehamn"/>
+            <type name="fjsuv" description="Fiji" alias="Pacific/Fiji"/>
+            <type name="fkpsy" description="Stanley, Falkland Islands" alias="Atlantic/Stanley"/>
+            <type name="fmksa" description="Kosrae, Micronesia" alias="Pacific/Kosrae"/>
+            <type name="fmpni" description="Pohnpei, Micronesia" alias="Pacific/Ponape Pacific/Pohnpei"/>
+            <type name="fmtkk" description="Chuuk, Micronesia" alias="Pacific/Truk Pacific/Chuuk Pacific/Yap"/>
+            <type name="fotho" description="Faroe Islands" alias="Atlantic/Faeroe Atlantic/Faroe"/>
+            <type name="frpar" description="Paris, France" alias="Europe/Paris"/>
+            <type name="galbv" description="Libreville, Gabon" alias="Africa/Libreville"/>
+            <type name="gaza" description="Gaza Strip, Palestinian Territories" alias="Asia/Gaza"/>
+            <type name="gblon" description="London, United Kingdom" alias="Europe/London Europe/Belfast GB GB-Eire"/>
+            <type name="gdgnd" description="Grenada" alias="America/Grenada"/>
+            <type name="getbs" description="Tbilisi, Georgia" alias="Asia/Tbilisi"/>
+            <type name="gfcay" description="Cayenne, French Guiana" alias="America/Cayenne"/>
+            <type name="gggci" description="Guernsey" alias="Europe/Guernsey"/>
+            <type name="ghacc" description="Accra, Ghana" alias="Africa/Accra"/>
+            <type name="gigib" description="Gibraltar" alias="Europe/Gibraltar"/>
+            <type name="gldkshvn" description="Danmarkshavn, Greenland" alias="America/Danmarkshavn"/>
+            <type name="glgoh" description="Nuuk (Godthåb), Greenland" alias="America/Godthab"/>
+            <type name="globy" description="Ittoqqortoormiit (Scoresbysund), Greenland" alias="America/Scoresbysund"/>
+            <type name="glthu" description="Qaanaaq (Thule), Greenland" alias="America/Thule"/>
+            <type name="gmbjl" description="Banjul, Gambia" alias="Africa/Banjul"/>
+            <type name="gncky" description="Conakry, Guinea" alias="Africa/Conakry"/>
+            <type name="gpbbr" description="Guadeloupe" alias="America/Guadeloupe"/>
+            <type name="gpmsb" description="Marigot, Saint Martin" alias="America/Marigot"/>
+            <type name="gpsbh" description="Saint Barthélemy" alias="America/St_Barthelemy"/>
+            <type name="gqssg" description="Malabo, Equatorial Guinea" alias="Africa/Malabo"/>
+            <type name="grath" description="Athens, Greece" alias="Europe/Athens"/>
+            <type name="gsgrv" description="South Georgia and the South Sandwich Islands" alias="Atlantic/South_Georgia"/>
+            <type name="gtgua" description="Guatemala" alias="America/Guatemala"/>
+            <type name="gugum" description="Guam" alias="Pacific/Guam"/>
+            <type name="gwoxb" description="Bissau, Guinea-Bissau" alias="Africa/Bissau"/>
+            <type name="gygeo" description="Guyana" alias="America/Guyana"/>
+            <type name="hebron" description="West Bank, Palestinian Territories" alias="Asia/Hebron" since="21"/>
+            <type name="hkhkg" description="Hong Kong SAR China" alias="Asia/Hong_Kong Hongkong"/>
+            <type name="hntgu" description="Tegucigalpa, Honduras" alias="America/Tegucigalpa"/>
+            <type name="hrzag" description="Zagreb, Croatia" alias="Europe/Zagreb"/>
+            <type name="htpap" description="Port-au-Prince, Haiti" alias="America/Port-au-Prince"/>
+            <type name="hubud" description="Budapest, Hungary" alias="Europe/Budapest"/>
+            <type name="iddjj" description="Jayapura, Indonesia" alias="Asia/Jayapura"/>
+            <type name="idjkt" description="Jakarta, Indonesia" alias="Asia/Jakarta"/>
+            <type name="idmak" description="Makassar, Indonesia" alias="Asia/Makassar Asia/Ujung_Pandang"/>
+            <type name="idpnk" description="Pontianak, Indonesia" alias="Asia/Pontianak"/>
+            <type name="iedub" description="Dublin, Ireland" alias="Europe/Dublin Eire"/>
+            <type name="imdgs" description="Isle of Man" alias="Europe/Isle_of_Man"/>
+            <type name="inccu" description="Kolkata, India" alias="Asia/Calcutta Asia/Kolkata"/>
+            <type name="iodga" description="Chagos Archipelago" alias="Indian/Chagos"/>
+            <type name="iqbgw" description="Baghdad, Iraq" alias="Asia/Baghdad"/>
+            <type name="irthr" description="Tehran, Iran" alias="Asia/Tehran Iran"/>
+            <type name="isrey" description="Reykjavik, Iceland" alias="Atlantic/Reykjavik Iceland"/>
+            <type name="itrom" description="Rome, Italy" alias="Europe/Rome"/>
+            <type name="jeruslm" description="Jerusalem" alias="Asia/Jerusalem Asia/Tel_Aviv Israel"/>
+            <type name="jesth" description="Jersey" alias="Europe/Jersey"/>
+            <type name="jmkin" description="Jamaica" alias="America/Jamaica Jamaica"/>
+            <type name="joamm" description="Amman, Jordan" alias="Asia/Amman"/>
+            <type name="jptyo" description="Tokyo, Japan" alias="Asia/Tokyo Japan"/>
+            <type name="kenbo" description="Nairobi, Kenya" alias="Africa/Nairobi"/>
+            <type name="kgfru" description="Bishkek, Kyrgyzstan" alias="Asia/Bishkek"/>
+            <type name="khpnh" description="Phnom Penh, Cambodia" alias="Asia/Phnom_Penh"/>
+            <type name="kicxi" description="Kiritimati, Kiribati" alias="Pacific/Kiritimati"/>
+            <type name="kipho" description="Enderbury Island, Kiribati" alias="Pacific/Enderbury"/>
+            <type name="kitrw" description="Tarawa, Kiribati" alias="Pacific/Tarawa"/>
+            <type name="kmyva" description="Comoros" alias="Indian/Comoro"/>
+            <type name="knbas" description="Saint Kitts" alias="America/St_Kitts"/>
+            <type name="kpfnj" description="Pyongyang, North Korea" alias="Asia/Pyongyang"/>
+            <type name="krsel" description="Seoul, South Korea" alias="Asia/Seoul ROK"/>
+            <type name="kwkwi" description="Kuwait" alias="Asia/Kuwait"/>
+            <type name="kygec" description="Cayman Islands" alias="America/Cayman"/>
+            <type name="kzaau" description="Aqtau, Kazakhstan" alias="Asia/Aqtau"/>
+            <type name="kzakx" description="Aqtobe, Kazakhstan" alias="Asia/Aqtobe"/>
+            <type name="kzala" description="Almaty, Kazakhstan" alias="Asia/Almaty"/>
+            <type name="kzkzo" description="Kyzylorda, Kazakhstan" alias="Asia/Qyzylorda"/>
+            <type name="kzura" description="Oral, Kazakhstan" alias="Asia/Oral"/>
+            <type name="lavte" description="Vientiane, Laos" alias="Asia/Vientiane"/>
+            <type name="lbbey" description="Beirut, Lebanon" alias="Asia/Beirut"/>
+            <type name="lccas" description="Saint Lucia" alias="America/St_Lucia"/>
+            <type name="livdz" description="Vaduz, Liechtenstein" alias="Europe/Vaduz"/>
+            <type name="lkcmb" description="Colombo, Sri Lanka" alias="Asia/Colombo"/>
+            <type name="lrmlw" description="Monrovia, Liberia" alias="Africa/Monrovia"/>
+            <type name="lsmsu" description="Maseru, Lesotho" alias="Africa/Maseru"/>
+            <type name="ltvno" description="Vilnius, Lithuania" alias="Europe/Vilnius"/>
+            <type name="lulux" description="Luxembourg" alias="Europe/Luxembourg"/>
+            <type name="lvrix" description="Riga, Latvia" alias="Europe/Riga"/>
+            <type name="lytip" description="Tripoli, Libya" alias="Africa/Tripoli Libya"/>
+            <type name="macas" description="Casablanca, Morocco" alias="Africa/Casablanca"/>
+            <type name="mcmon" description="Monaco" alias="Europe/Monaco"/>
+            <type name="mdkiv" description="Chişinău, Moldova" alias="Europe/Chisinau Europe/Tiraspol"/>
+            <type name="metgd" description="Podgorica, Montenegro" alias="Europe/Podgorica"/>
+            <type name="mgtnr" description="Antananarivo, Madagascar" alias="Indian/Antananarivo"/>
+            <type name="mhkwa" description="Kwajalein, Marshall Islands" alias="Pacific/Kwajalein Kwajalein"/>
+            <type name="mhmaj" description="Majuro, Marshall Islands" alias="Pacific/Majuro"/>
+            <type name="mkskp" description="Skopje, Macedonia" alias="Europe/Skopje"/>
+            <type name="mlbko" description="Bamako, Mali" alias="Africa/Bamako Africa/Timbuktu"/>
+            <type name="mmrgn" description="Yangon (Rangoon), Burma" alias="Asia/Rangoon"/>
+            <type name="mncoq" description="Choibalsan, Mongolia" alias="Asia/Choibalsan"/>
+            <type name="mnhvd" description="Khovd (Hovd), Mongolia" alias="Asia/Hovd"/>
+            <type name="mnuln" description="Ulaanbaatar (Ulan Bator), Mongolia" alias="Asia/Ulaanbaatar Asia/Ulan_Bator"/>
+            <type name="momfm" description="Macau SAR China" alias="Asia/Macau Asia/Macao"/>
+            <type name="mpspn" description="Saipan, Northern Mariana Islands" alias="Pacific/Saipan"/>
+            <type name="mqfdf" description="Martinique" alias="America/Martinique"/>
+            <type name="mrnkc" description="Nouakchott, Mauritania" alias="Africa/Nouakchott"/>
+            <type name="msmni" description="Montserrat" alias="America/Montserrat"/>
+            <type name="mst7mdt" description="POSIX style time zone for US Mountain Time" alias="MST7MDT" since="1.8"/>
+            <type name="mtmla" description="Malta" alias="Europe/Malta"/>
+            <type name="muplu" description="Mauritius" alias="Indian/Mauritius"/>
+            <type name="mvmle" description="Maldives" alias="Indian/Maldives"/>
+            <type name="mwblz" description="Blantyre, Malawi" alias="Africa/Blantyre"/>
+            <type name="mxchi" description="Chihuahua, Mexico" alias="America/Chihuahua"/>
+            <type name="mxcun" description="Cancún, Mexico" alias="America/Cancun"/>
+            <type name="mxhmo" description="Hermosillo, Mexico" alias="America/Hermosillo"/>
+            <type name="mxmam" description="Matamoros, Mexico" alias="America/Matamoros"/>
+            <type name="mxmex" description="Mexico City, Mexico" alias="America/Mexico_City Mexico/General"/>
+            <type name="mxmid" description="Mérida, Mexico" alias="America/Merida"/>
+            <type name="mxmty" description="Monterrey, Mexico" alias="America/Monterrey"/>
+            <type name="mxmzt" description="Mazatlán, Mexico" alias="America/Mazatlan Mexico/BajaSur"/>
+            <type name="mxoji" description="Ojinaga, Mexico" alias="America/Ojinaga"/>
+            <type name="mxpvr" description="Bahía de Banderas, Mexico" alias="America/Bahia_Banderas" since="1.9"/>
+            <type name="mxstis" description="Santa Isabel (Baja California), Mexico" alias="America/Santa_Isabel"/>
+            <type name="mxtij" description="Tijuana, Mexico" alias="America/Tijuana America/Ensenada Mexico/BajaNorte"/>
+            <type name="mykch" description="Kuching, Malaysia" alias="Asia/Kuching"/>
+            <type name="mykul" description="Kuala Lumpur, Malaysia" alias="Asia/Kuala_Lumpur"/>
+            <type name="mzmpm" description="Maputo, Mozambique" alias="Africa/Maputo"/>
+            <type name="nawdh" description="Windhoek, Namibia" alias="Africa/Windhoek"/>
+            <type name="ncnou" description="Noumea, New Caledonia" alias="Pacific/Noumea"/>
+            <type name="nenim" description="Niamey, Niger" alias="Africa/Niamey"/>
+            <type name="nfnlk" description="Norfolk Island" alias="Pacific/Norfolk"/>
+            <type name="nglos" description="Lagos, Nigeria" alias="Africa/Lagos"/>
+            <type name="nimga" description="Managua, Nicaragua" alias="America/Managua"/>
+            <type name="nlams" description="Amsterdam, Netherlands" alias="Europe/Amsterdam"/>
+            <type name="noosl" description="Oslo, Norway" alias="Europe/Oslo"/>
+            <type name="npktm" description="Kathmandu, Nepal" alias="Asia/Katmandu Asia/Kathmandu"/>
+            <type name="nrinu" description="Nauru" alias="Pacific/Nauru"/>
+            <type name="nuiue" description="Niue" alias="Pacific/Niue"/>
+            <type name="nzakl" description="Auckland, New Zealand" alias="Pacific/Auckland Antarctica/South_Pole NZ"/>
+            <type name="nzcht" description="Chatham Islands, New Zealand" alias="Pacific/Chatham NZ-CHAT"/>
+            <type name="ommct" description="Muscat, Oman" alias="Asia/Muscat"/>
+            <type name="papty" description="Panama" alias="America/Panama"/>
+            <type name="pelim" description="Lima, Peru" alias="America/Lima"/>
+            <type name="pfgmr" description="Gambiera Islands, French Polynesia" alias="Pacific/Gambier"/>
+            <type name="pfnhv" description="Marquesas Islands, French Polynesia" alias="Pacific/Marquesas"/>
+            <type name="pfppt" description="Tahiti, French Polynesia" alias="Pacific/Tahiti"/>
+            <type name="pgpom" description="Port Moresby, Papua New Guinea" alias="Pacific/Port_Moresby"/>
+            <type name="pgraw" description="Bougainville, Papua New Guinea" alias="Pacific/Bougainville" since="27"/>
+            <type name="phmnl" description="Manila, Philippines" alias="Asia/Manila"/>
+            <type name="pkkhi" description="Karachi, Pakistan" alias="Asia/Karachi"/>
+            <type name="plwaw" description="Warsaw, Poland" alias="Europe/Warsaw Poland"/>
+            <type name="pmmqc" description="Saint Pierre and Miquelon" alias="America/Miquelon"/>
+            <type name="pnpcn" description="Pitcairn Islands" alias="Pacific/Pitcairn"/>
+            <type name="prsju" description="Puerto Rico" alias="America/Puerto_Rico"/>
+            <type name="pst8pdt" description="POSIX style time zone for US Pacific Time" alias="PST8PDT" since="1.8"/>
+            <type name="ptfnc" description="Madeira, Portugal" alias="Atlantic/Madeira"/>
+            <type name="ptlis" description="Lisbon, Portugal" alias="Europe/Lisbon Portugal"/>
+            <type name="ptpdl" description="Azores, Portugal" alias="Atlantic/Azores"/>
+            <type name="pwror" description="Palau" alias="Pacific/Palau"/>
+            <type name="pyasu" description="Asunción, Paraguay" alias="America/Asuncion"/>
+            <type name="qadoh" description="Qatar" alias="Asia/Qatar"/>
+            <type name="rereu" description="Réunion" alias="Indian/Reunion"/>
+            <type name="robuh" description="Bucharest, Romania" alias="Europe/Bucharest"/>
+            <type name="rsbeg" description="Belgrade, Serbia" alias="Europe/Belgrade"/>
+            <type name="ruchita" description="Chita Zabaykalsky, Russia" alias="Asia/Chita" since="26"/>
+            <type name="rudyr" description="Anadyr, Russia" alias="Asia/Anadyr"/>
+            <type name="rugdx" description="Magadan, Russia" alias="Asia/Magadan"/>
+            <type name="ruikt" description="Irkutsk, Russia" alias="Asia/Irkutsk"/>
+            <type name="rukgd" description="Kaliningrad, Russia" alias="Europe/Kaliningrad"/>
+            <type name="rukhndg" description="Khandyga Tomponsky, Russia" alias="Asia/Khandyga" since="23"/>
+            <type name="rukra" description="Krasnoyarsk, Russia" alias="Asia/Krasnoyarsk"/>
+            <type name="rukuf" description="Samara, Russia" alias="Europe/Samara"/>
+            <type name="rumow" description="Moscow, Russia" alias="Europe/Moscow W-SU"/>
+            <type name="runoz" description="Novokuznetsk, Russia" alias="Asia/Novokuznetsk"/>
+            <type name="ruoms" description="Omsk, Russia" alias="Asia/Omsk"/>
+            <type name="ruovb" description="Novosibirsk, Russia" alias="Asia/Novosibirsk"/>
+            <type name="rupkc" description="Kamchatka Peninsula, Russia" alias="Asia/Kamchatka"/>
+            <type name="rusred" description="Srednekolymsk, Russia" alias="Asia/Srednekolymsk" since="26"/>
+            <type name="ruunera" description="Ust-Nera Oymyakonsky, Russia" alias="Asia/Ust-Nera" since="23"/>
+            <type name="ruuus" description="Sakhalin, Russia" alias="Asia/Sakhalin"/>
+            <type name="ruvog" description="Volgograd, Russia" alias="Europe/Volgograd"/>
+            <type name="ruvvo" description="Vladivostok, Russia" alias="Asia/Vladivostok"/>
+            <type name="ruyek" description="Yekaterinburg, Russia" alias="Asia/Yekaterinburg"/>
+            <type name="ruyks" description="Yakutsk, Russia" alias="Asia/Yakutsk"/>
+            <type name="rwkgl" description="Kigali, Rwanda" alias="Africa/Kigali"/>
+            <type name="saruh" description="Riyadh, Saudi Arabia" alias="Asia/Riyadh"/>
+            <type name="sbhir" description="Guadalcanal, Solomon Islands" alias="Pacific/Guadalcanal"/>
+            <type name="scmaw" description="Mahé, Seychelles" alias="Indian/Mahe"/>
+            <type name="sdkrt" description="Khartoum, Sudan" alias="Africa/Khartoum"/>
+            <type name="sesto" description="Stockholm, Sweden" alias="Europe/Stockholm"/>
+            <type name="sgsin" description="Singapore" alias="Asia/Singapore Singapore"/>
+            <type name="shshn" description="Saint Helena" alias="Atlantic/St_Helena"/>
+            <type name="silju" description="Ljubljana, Slovenia" alias="Europe/Ljubljana"/>
+            <type name="sjlyr" description="Longyearbyen, Svalbard" alias="Arctic/Longyearbyen Atlantic/Jan_Mayen"/>
+            <type name="skbts" description="Bratislava, Slovakia" alias="Europe/Bratislava"/>
+            <type name="slfna" description="Freetown, Sierra Leone" alias="Africa/Freetown"/>
+            <type name="smsai" description="San Marino" alias="Europe/San_Marino"/>
+            <type name="sndkr" description="Dakar, Senegal" alias="Africa/Dakar"/>
+            <type name="somgq" description="Mogadishu, Somalia" alias="Africa/Mogadishu"/>
+            <type name="srpbm" description="Paramaribo, Suriname" alias="America/Paramaribo"/>
+            <type name="ssjub" description="Juba, South Sudan" alias="Africa/Juba" since="21"/>
+            <type name="sttms" description="São Tomé, São Tomé and Príncipe" alias="Africa/Sao_Tome"/>
+            <type name="svsal" description="El Salvador" alias="America/El_Salvador"/>
+            <type name="sxphi" description="Sint Maarten" alias="America/Lower_Princes" since="21"/>
+            <type name="sydam" description="Damascus, Syria" alias="Asia/Damascus"/>
+            <type name="szqmn" description="Mbabane, Swaziland" alias="Africa/Mbabane"/>
+            <type name="tcgdt" description="Grand Turk, Turks and Caicos Islands" alias="America/Grand_Turk"/>
+            <type name="tdndj" description="N'Djamena, Chad" alias="Africa/Ndjamena"/>
+            <type name="tfpfr" description="Kerguelen Islands, French Southern Territories" alias="Indian/Kerguelen"/>
+            <type name="tglfw" description="Lomé, Togo" alias="Africa/Lome"/>
+            <type name="thbkk" description="Bangkok, Thailand" alias="Asia/Bangkok"/>
+            <type name="tjdyu" description="Dushanbe, Tajikistan" alias="Asia/Dushanbe"/>
+            <type name="tkfko" description="Fakaofo, Tokelau" alias="Pacific/Fakaofo"/>
+            <type name="tldil" description="Dili, East Timor" alias="Asia/Dili"/>
+            <type name="tmasb" description="Ashgabat, Turkmenistan" alias="Asia/Ashgabat Asia/Ashkhabad"/>
+            <type name="tntun" description="Tunis, Tunisia" alias="Africa/Tunis"/>
+            <type name="totbu" description="Tongatapu, Tonga" alias="Pacific/Tongatapu"/>
+            <type name="trist" description="Istanbul, Turkey" alias="Europe/Istanbul Asia/Istanbul Turkey"/>
+            <type name="ttpos" description="Port of Spain, Trinidad and Tobago" alias="America/Port_of_Spain"/>
+            <type name="tvfun" description="Funafuti, Tuvalu" alias="Pacific/Funafuti"/>
+            <type name="twtpe" description="Taipei, Taiwan" alias="Asia/Taipei ROC"/>
+            <type name="tzdar" description="Dar es Salaam, Tanzania" alias="Africa/Dar_es_Salaam"/>
+            <type name="uaiev" description="Kiev, Ukraine" alias="Europe/Kiev"/>
+            <type name="uaozh" description="Zaporizhia (Zaporozhye), Ukraine" alias="Europe/Zaporozhye"/>
+            <type name="uasip" description="Simferopol, Ukraine" alias="Europe/Simferopol"/>
+            <type name="uauzh" description="Uzhhorod (Uzhgorod), Ukraine" alias="Europe/Uzhgorod"/>
+            <type name="ugkla" description="Kampala, Uganda" alias="Africa/Kampala"/>
+            <type name="umawk" description="Wake Island, U.S. Minor Outlying Islands" alias="Pacific/Wake"/>
+            <type name="umjon" description="Johnston Atoll, U.S. Minor Outlying Islands" alias="Pacific/Johnston"/>
+            <type name="ummdy" description="Midway Islands, U.S. Minor Outlying Islands" alias="Pacific/Midway"/>
+            <type name="unk" description="Unknown time zone" alias="Etc/Unknown"/>
+            <type name="usadk" description="Adak (Alaska), United States" alias="America/Adak America/Atka US/Aleutian"/>
+            <type name="usaeg" description="Marengo (Indiana), United States" alias="America/Indiana/Marengo"/>
+            <type name="usanc" description="Anchorage, United States" alias="America/Anchorage US/Alaska"/>
+            <type name="usboi" description="Boise (Idaho), United States" alias="America/Boise"/>
+            <type name="uschi" description="Chicago, United States" alias="America/Chicago US/Central"/>
+            <type name="usden" description="Denver, United States" alias="America/Denver America/Shiprock Navajo US/Mountain"/>
+            <type name="usdet" description="Detroit, United States" alias="America/Detroit US/Michigan"/>
+            <type name="ushnl" description="Honolulu, United States" alias="Pacific/Honolulu US/Hawaii"/>
+            <type name="usind" description="Indianapolis, United States" alias="America/Indianapolis America/Fort_Wayne America/Indiana/Indianapolis US/East-Indiana"/>
+            <type name="usinvev" description="Vevay (Indiana), United States" alias="America/Indiana/Vevay"/>
+            <type name="usjnu" description="Juneau (Alaska), United States" alias="America/Juneau"/>
+            <type name="usknx" description="Knox (Indiana), United States" alias="America/Indiana/Knox America/Knox_IN US/Indiana-Starke"/>
+            <type name="uslax" description="Los Angeles, United States" alias="America/Los_Angeles US/Pacific US/Pacific-New"/>
+            <type name="uslui" description="Louisville (Kentucky), United States" alias="America/Louisville America/Kentucky/Louisville"/>
+            <type name="usmnm" description="Menominee (Michigan), United States" alias="America/Menominee"/>
+            <type name="usmtm" description="Metlakatla (Alaska), United States" alias="America/Metlakatla" since="1.9.1"/>
+            <type name="usmoc" description="Monticello (Kentucky), United States" alias="America/Kentucky/Monticello"/>
+            <type name="usnavajo" description="Shiprock (Navajo), United States" deprecated="true" preferred="usden"/>
+            <type name="usndcnt" description="Center (North Dakota), United States" alias="America/North_Dakota/Center"/>
+            <type name="usndnsl" description="New Salem (North Dakota), United States" alias="America/North_Dakota/New_Salem"/>
+            <type name="usnyc" description="New York, United States" alias="America/New_York US/Eastern"/>
+            <type name="usoea" description="Vincennes (Indiana), United States" alias="America/Indiana/Vincennes"/>
+            <type name="usome" description="Nome (Alaska), United States" alias="America/Nome"/>
+            <type name="usphx" description="Phoenix, United States" alias="America/Phoenix US/Arizona"/>
+            <type name="ussit" description="Sitka (Alaska), United States" alias="America/Sitka" since="1.9.1"/>
+            <type name="ustel" description="Tell City (Indiana), United States" alias="America/Indiana/Tell_City"/>
+            <type name="uswlz" description="Winamac (Indiana), United States" alias="America/Indiana/Winamac"/>
+            <type name="uswsq" description="Petersburg (Indiana), United States" alias="America/Indiana/Petersburg"/>
+            <type name="usxul" description="Beulah (North Dakota), United States" alias="America/North_Dakota/Beulah" since="1.9.1"/>
+            <type name="usyak" description="Yakutat (Alaska), United States" alias="America/Yakutat"/>
+            <type name="utc" description="UTC (Coordinated Universal Time)" alias="Etc/GMT Etc/GMT+0 Etc/GMT-0 Etc/GMT0 Etc/Greenwich Etc/UCT Etc/UTC Etc/Universal Etc/Zulu GMT GMT+0 GMT-0 GMT0 Greenwich UCT UTC Universal Zulu"/>
+            <type name="utce01" description="1 hour ahead of UTC" alias="Etc/GMT-1"/>
+            <type name="utce02" description="2 hours ahead of UTC" alias="Etc/GMT-2"/>
+            <type name="utce03" description="3 hours ahead of UTC" alias="Etc/GMT-3"/>
+            <type name="utce04" description="4 hours ahead of UTC" alias="Etc/GMT-4"/>
+            <type name="utce05" description="5 hours ahead of UTC" alias="Etc/GMT-5"/>
+            <type name="utce06" description="6 hours ahead of UTC" alias="Etc/GMT-6"/>
+            <type name="utce07" description="7 hours ahead of UTC" alias="Etc/GMT-7"/>
+            <type name="utce08" description="8 hours ahead of UTC" alias="Etc/GMT-8"/>
+            <type name="utce09" description="9 hours ahead of UTC" alias="Etc/GMT-9"/>
+            <type name="utce10" description="10 hours ahead of UTC" alias="Etc/GMT-10"/>
+            <type name="utce11" description="11 hours ahead of UTC" alias="Etc/GMT-11"/>
+            <type name="utce12" description="12 hours ahead of UTC" alias="Etc/GMT-12"/>
+            <type name="utce13" description="13hours ahead of UTC" alias="Etc/GMT-13"/>
+            <type name="utce14" description="14 hours ahead of UTC" alias="Etc/GMT-14"/>
+            <type name="utcw01" description="1 hour behind UTC" alias="Etc/GMT+1"/>
+            <type name="utcw02" description="2 hours behind UTC" alias="Etc/GMT+2"/>
+            <type name="utcw03" description="3 hours behind UTC" alias="Etc/GMT+3"/>
+            <type name="utcw04" description="4 hours behind UTC" alias="Etc/GMT+4"/>
+            <type name="utcw05" description="5 hours behind UTC" alias="Etc/GMT+5 EST"/>
+            <type name="utcw06" description="6 hours behind UTC" alias="Etc/GMT+6"/>
+            <type name="utcw07" description="7 hours behind UTC" alias="Etc/GMT+7 MST"/>
+            <type name="utcw08" description="8 hours behind UTC" alias="Etc/GMT+8"/>
+            <type name="utcw09" description="9 hours behind UTC" alias="Etc/GMT+9"/>
+            <type name="utcw10" description="10 hours behind UTC" alias="Etc/GMT+10 HST"/>
+            <type name="utcw11" description="11 hours behind UTC" alias="Etc/GMT+11"/>
+            <type name="utcw12" description="12 hours behind UTC" alias="Etc/GMT+12"/>
+            <type name="uymvd" description="Montevideo, Uruguay" alias="America/Montevideo"/>
+            <type name="uzskd" description="Samarkand, Uzbekistan" alias="Asia/Samarkand"/>
+            <type name="uztas" description="Tashkent, Uzbekistan" alias="Asia/Tashkent"/>
+            <type name="vavat" description="Vatican City" alias="Europe/Vatican"/>
+            <type name="vcsvd" description="Saint Vincent, Saint Vincent and the Grenadines" alias="America/St_Vincent"/>
+            <type name="veccs" description="Caracas, Venezuela" alias="America/Caracas"/>
+            <type name="vgtov" description="Tortola, British Virgin Islands" alias="America/Tortola"/>
+            <type name="vistt" description="Saint Thomas, U.S. Virgin Islands" alias="America/St_Thomas America/Virgin"/>
+            <type name="vnsgn" description="Ho Chi Minh City, Vietnam" alias="Asia/Saigon Asia/Ho_Chi_Minh"/>
+            <type name="vuvli" description="Efate, Vanuatu" alias="Pacific/Efate"/>
+            <type name="wfmau" description="Wallis Islands, Wallis and Futuna" alias="Pacific/Wallis"/>
+            <type name="wsapw" description="Apia, Samoa" alias="Pacific/Apia"/>
+            <type name="yeade" description="Aden, Yemen" alias="Asia/Aden"/>
+            <type name="ytmam" description="Mayotte" alias="Indian/Mayotte"/>
+            <type name="zajnb" description="Johannesburg, South Africa" alias="Africa/Johannesburg"/>
+            <type name="zmlun" description="Lusaka, Zambia" alias="Africa/Lusaka"/>
+            <type name="zwhre" description="Harare, Zimbabwe" alias="Africa/Harare"/>
+        </key>
+    </keyword>
+</ldmlBCP47>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/jdk.localedata/share/classes/sun/util/cldr/resources/common/dtd/ldmlBCP47.dtd	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,74 @@
+<!--
+Copyright © 2003-2015 Unicode, Inc. and others. All rights reserved. Distributed under the Terms of Use in http://www.unicode.org/copyright.html.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of the Unicode data files and any associated documentation (the "Data Files") or Unicode software and any associated documentation (the "Software") to deal in the Data Files or Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, and/or sell copies of the Data Files or Software, and to permit persons to whom the Data Files or Software are furnished to do so, provided that (a) the above copyright notice(s) and this permission notice appear with all copies of the Data Files or Software, (b) both the above copyright notice(s) and this permission notice appear in associated documentation, and (c) there is clear notice in each modified Data File or in the Software as well as in the documentation associated with the Data File(s) or Software that the data or software has been modified.
+
+THE DATA FILES AND SOFTWARE ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THE DATA FILES OR SOFTWARE.
+
+Except as contained in this notice, the name of a copyright holder shall not be used in advertising or otherwise to promote the sale, use or other dealings in these Data Files or Software without prior written authorization of the copyright holder.
+$Revision: 12433 $
+-->
+
+<!ELEMENT ldmlBCP47 ( version, generation?, cldrVersion?, keyword*, attribute* ) >
+
+<!ELEMENT version EMPTY >
+    <!--@METADATA-->
+<!ATTLIST version number CDATA #REQUIRED >
+    <!--@METADATA-->
+<!ATTLIST version cldrVersion CDATA #FIXED "29" >
+    <!--@VALUE-->
+
+<!ELEMENT generation EMPTY >
+    <!--@METADATA-->
+    <!--@DEPRECATED-->
+<!ATTLIST generation date CDATA #REQUIRED >
+    <!--@METADATA-->
+    <!--@DEPRECATED-->
+
+<!ELEMENT cldrVersion EMPTY >
+    <!--@DEPRECATED-->
+<!ATTLIST cldrVersion version CDATA #REQUIRED >
+    <!--@METADATA-->
+    <!--@DEPRECATED-->
+
+<!ELEMENT keyword ( key* ) >
+
+<!ELEMENT key ( type* ) >
+<!ATTLIST key extension NMTOKEN #IMPLIED >
+<!ATTLIST key name NMTOKEN #REQUIRED >
+<!ATTLIST key description CDATA #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST key deprecated (true | false) "false" >
+    <!--@METADATA-->
+<!ATTLIST key preferred NMTOKEN #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST key alias NMTOKEN #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST key valueType (single | multiple | incremental | any) #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST key since CDATA #IMPLIED >
+    <!--@METADATA-->
+
+<!ELEMENT type EMPTY >
+<!ATTLIST type name NMTOKEN #REQUIRED >
+<!ATTLIST type description CDATA #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST type deprecated (true | false) "false" >
+    <!--@METADATA-->
+<!ATTLIST type preferred NMTOKEN #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST type alias CDATA #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST type since CDATA #IMPLIED >
+    <!--@METADATA-->
+
+<!ELEMENT attribute EMPTY >
+<!ATTLIST attribute name NMTOKEN #REQUIRED >
+<!ATTLIST attribute description CDATA #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST attribute deprecated (true | false) "false" >
+    <!--@METADATA-->
+<!ATTLIST attribute preferred NMTOKEN #IMPLIED >
+    <!--@VALUE-->
+<!ATTLIST attribute since CDATA #IMPLIED >
+    <!--@METADATA-->
--- a/test/java/util/Calendar/Bug8185841.java	Tue Dec 12 09:33:37 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,278 +0,0 @@
-/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
- /*
- * @test
- * @bug 8185841
- * @summary Test that Region dependent Bundles are added/removed correctly.
- * @modules jdk.localedata
- */
-
- /*
-This test is dependent on a particular version of CLDR.
- */
-import java.net.URI;
-import java.nio.file.FileSystem;
-import java.nio.file.FileSystems;
-import java.nio.file.Files;
-import java.nio.file.Path;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Set;
-import java.util.stream.Collectors;
-
-public class Bug8185841 {
-    // Golden data for Region dependent Bundles in CLDR29.
-
-    private static final Set<String> expectedBundles
-            = Set.of("CalendarData_af_NA.class", "CalendarData_af_ZA.class", "CalendarData_agq_CM.class",
-                    "CalendarData_ak_GH.class", "CalendarData_am_ET.class", "CalendarData_ar_AE.class",
-                    "CalendarData_ar_BH.class", "CalendarData_ar_DJ.class", "CalendarData_ar_DZ.class",
-                    "CalendarData_ar_EG.class", "CalendarData_ar_EH.class", "CalendarData_ar_ER.class",
-                    "CalendarData_ar_IL.class", "CalendarData_ar_IQ.class", "CalendarData_ar_JO.class",
-                    "CalendarData_ar_KM.class", "CalendarData_ar_KW.class", "CalendarData_ar_LB.class",
-                    "CalendarData_ar_LY.class", "CalendarData_ar_MA.class", "CalendarData_ar_MR.class",
-                    "CalendarData_ar_OM.class", "CalendarData_ar_PS.class", "CalendarData_ar_QA.class",
-                    "CalendarData_ar_SA.class", "CalendarData_ar_SD.class", "CalendarData_ar_SO.class",
-                    "CalendarData_ar_SS.class", "CalendarData_ar_SY.class", "CalendarData_ar_TD.class",
-                    "CalendarData_ar_TN.class", "CalendarData_ar_YE.class", "CalendarData_as_IN.class",
-                    "CalendarData_asa_TZ.class", "CalendarData_ast_ES.class", "CalendarData_az_AZ.class",
-                    "CalendarData_az_Cyrl_AZ.class", "CalendarData_bas_CM.class", "CalendarData_be_BY.class",
-                    "CalendarData_bem_ZM.class", "CalendarData_bez_TZ.class", "CalendarData_bg_BG.class",
-                    "CalendarData_bm_ML.class", "CalendarData_bn_BD.class", "CalendarData_bn_IN.class",
-                    "CalendarData_bo_CN.class", "CalendarData_bo_IN.class", "CalendarData_br_FR.class",
-                    "CalendarData_brx_IN.class", "CalendarData_bs_BA.class", "CalendarData_bs_Cyrl_BA.class",
-                    "CalendarData_ca_AD.class", "CalendarData_ca_ES.class", "CalendarData_ca_FR.class",
-                    "CalendarData_ca_IT.class", "CalendarData_ce_RU.class", "CalendarData_cgg_UG.class",
-                    "CalendarData_chr_US.class", "CalendarData_ckb_IQ.class", "CalendarData_ckb_IR.class",
-                    "CalendarData_cs_CZ.class", "CalendarData_cu_RU.class", "CalendarData_cy_GB.class",
-                    "CalendarData_da_DK.class", "CalendarData_da_GL.class", "CalendarData_dav_KE.class",
-                    "CalendarData_de_AT.class", "CalendarData_de_BE.class", "CalendarData_de_CH.class",
-                    "CalendarData_de_DE.class", "CalendarData_de_LI.class", "CalendarData_de_LU.class",
-                    "CalendarData_dje_NE.class", "CalendarData_dsb_DE.class", "CalendarData_dua_CM.class",
-                    "CalendarData_dyo_SN.class", "CalendarData_dz_BT.class", "CalendarData_ebu_KE.class",
-                    "CalendarData_ee_GH.class", "CalendarData_ee_TG.class", "CalendarData_el_CY.class",
-                    "CalendarData_el_GR.class", "CalendarData_en_AG.class", "CalendarData_en_AI.class",
-                    "CalendarData_en_AS.class", "CalendarData_en_AT.class", "CalendarData_en_AU.class",
-                    "CalendarData_en_BB.class", "CalendarData_en_BE.class", "CalendarData_en_BI.class",
-                    "CalendarData_en_BM.class", "CalendarData_en_BS.class", "CalendarData_en_BW.class",
-                    "CalendarData_en_BZ.class", "CalendarData_en_CA.class", "CalendarData_en_CC.class",
-                    "CalendarData_en_CH.class", "CalendarData_en_CK.class", "CalendarData_en_CM.class",
-                    "CalendarData_en_CX.class", "CalendarData_en_CY.class", "CalendarData_en_DE.class",
-                    "CalendarData_en_DG.class", "CalendarData_en_DK.class", "CalendarData_en_DM.class",
-                    "CalendarData_en_ER.class", "CalendarData_en_FI.class", "CalendarData_en_FJ.class",
-                    "CalendarData_en_FK.class", "CalendarData_en_FM.class", "CalendarData_en_GB.class",
-                    "CalendarData_en_GD.class", "CalendarData_en_GG.class", "CalendarData_en_GH.class",
-                    "CalendarData_en_GI.class", "CalendarData_en_GM.class", "CalendarData_en_GU.class",
-                    "CalendarData_en_GY.class", "CalendarData_en_HK.class", "CalendarData_en_IE.class",
-                    "CalendarData_en_IL.class", "CalendarData_en_IM.class", "CalendarData_en_IN.class",
-                    "CalendarData_en_IO.class", "CalendarData_en_JE.class", "CalendarData_en_JM.class",
-                    "CalendarData_en_KE.class", "CalendarData_en_KI.class", "CalendarData_en_KN.class",
-                    "CalendarData_en_KY.class", "CalendarData_en_LC.class", "CalendarData_en_LR.class",
-                    "CalendarData_en_LS.class", "CalendarData_en_MG.class", "CalendarData_en_MH.class",
-                    "CalendarData_en_MO.class", "CalendarData_en_MP.class", "CalendarData_en_MS.class",
-                    "CalendarData_en_MT.class", "CalendarData_en_MU.class", "CalendarData_en_MW.class",
-                    "CalendarData_en_MY.class", "CalendarData_en_NA.class", "CalendarData_en_NF.class",
-                    "CalendarData_en_NG.class", "CalendarData_en_NL.class", "CalendarData_en_NR.class",
-                    "CalendarData_en_NU.class", "CalendarData_en_NZ.class", "CalendarData_en_PG.class",
-                    "CalendarData_en_PH.class", "CalendarData_en_PK.class", "CalendarData_en_PN.class",
-                    "CalendarData_en_PR.class", "CalendarData_en_PW.class", "CalendarData_en_RW.class",
-                    "CalendarData_en_SB.class", "CalendarData_en_SC.class", "CalendarData_en_SD.class",
-                    "CalendarData_en_SE.class", "CalendarData_en_SG.class", "CalendarData_en_SH.class",
-                    "CalendarData_en_SI.class", "CalendarData_en_SL.class", "CalendarData_en_SS.class",
-                    "CalendarData_en_SX.class", "CalendarData_en_SZ.class", "CalendarData_en_TC.class",
-                    "CalendarData_en_TK.class", "CalendarData_en_TO.class", "CalendarData_en_TT.class",
-                    "CalendarData_en_TV.class", "CalendarData_en_TZ.class", "CalendarData_en_UG.class",
-                    "CalendarData_en_UM.class", "CalendarData_en_VC.class", "CalendarData_en_VG.class",
-                    "CalendarData_en_VI.class", "CalendarData_en_VU.class", "CalendarData_en_WS.class",
-                    "CalendarData_en_ZA.class", "CalendarData_en_ZM.class", "CalendarData_en_ZW.class",
-                    "CalendarData_es_AR.class", "CalendarData_es_BO.class", "CalendarData_es_BR.class",
-                    "CalendarData_es_CL.class", "CalendarData_es_CO.class", "CalendarData_es_CR.class",
-                    "CalendarData_es_CU.class", "CalendarData_es_DO.class", "CalendarData_es_EA.class",
-                    "CalendarData_es_EC.class", "CalendarData_es_ES.class", "CalendarData_es_GQ.class",
-                    "CalendarData_es_GT.class", "CalendarData_es_HN.class", "CalendarData_es_IC.class",
-                    "CalendarData_es_MX.class", "CalendarData_es_NI.class", "CalendarData_es_PA.class",
-                    "CalendarData_es_PE.class", "CalendarData_es_PH.class", "CalendarData_es_PR.class",
-                    "CalendarData_es_PY.class", "CalendarData_es_SV.class", "CalendarData_es_US.class",
-                    "CalendarData_es_UY.class", "CalendarData_es_VE.class", "CalendarData_et_EE.class",
-                    "CalendarData_eu_ES.class", "CalendarData_ewo_CM.class", "CalendarData_fa_AF.class",
-                    "CalendarData_fa_IR.class", "CalendarData_ff_CM.class", "CalendarData_ff_GN.class",
-                    "CalendarData_ff_MR.class", "CalendarData_ff_SN.class", "CalendarData_fi_FI.class",
-                    "CalendarData_fil_PH.class", "CalendarData_fo_DK.class", "CalendarData_fo_FO.class",
-                    "CalendarData_fr_BE.class", "CalendarData_fr_BF.class", "CalendarData_fr_BI.class",
-                    "CalendarData_fr_BJ.class", "CalendarData_fr_BL.class", "CalendarData_fr_CA.class",
-                    "CalendarData_fr_CD.class", "CalendarData_fr_CF.class", "CalendarData_fr_CG.class",
-                    "CalendarData_fr_CH.class", "CalendarData_fr_CI.class", "CalendarData_fr_CM.class",
-                    "CalendarData_fr_DJ.class", "CalendarData_fr_DZ.class", "CalendarData_fr_FR.class",
-                    "CalendarData_fr_GA.class", "CalendarData_fr_GF.class", "CalendarData_fr_GN.class",
-                    "CalendarData_fr_GP.class", "CalendarData_fr_GQ.class", "CalendarData_fr_HT.class",
-                    "CalendarData_fr_KM.class", "CalendarData_fr_LU.class", "CalendarData_fr_MA.class",
-                    "CalendarData_fr_MC.class", "CalendarData_fr_MF.class", "CalendarData_fr_MG.class",
-                    "CalendarData_fr_ML.class", "CalendarData_fr_MQ.class", "CalendarData_fr_MR.class",
-                    "CalendarData_fr_MU.class", "CalendarData_fr_NC.class", "CalendarData_fr_NE.class",
-                    "CalendarData_fr_PF.class", "CalendarData_fr_PM.class", "CalendarData_fr_RE.class",
-                    "CalendarData_fr_RW.class", "CalendarData_fr_SC.class", "CalendarData_fr_SN.class",
-                    "CalendarData_fr_SY.class", "CalendarData_fr_TD.class", "CalendarData_fr_TG.class",
-                    "CalendarData_fr_TN.class", "CalendarData_fr_VU.class", "CalendarData_fr_WF.class",
-                    "CalendarData_fr_YT.class", "CalendarData_fur_IT.class", "CalendarData_fy_NL.class",
-                    "CalendarData_ga_IE.class", "CalendarData_gd_GB.class", "CalendarData_gl_ES.class",
-                    "CalendarData_gsw_CH.class", "CalendarData_gsw_FR.class", "CalendarData_gsw_LI.class",
-                    "CalendarData_gu_IN.class", "CalendarData_guz_KE.class", "CalendarData_gv_IM.class",
-                    "CalendarData_ha_GH.class", "CalendarData_ha_NE.class", "CalendarData_ha_NG.class",
-                    "CalendarData_haw_US.class", "CalendarData_hi_IN.class", "CalendarData_hr_BA.class",
-                    "CalendarData_hr_HR.class", "CalendarData_hsb_DE.class", "CalendarData_hu_HU.class",
-                    "CalendarData_hy_AM.class", "CalendarData_ig_NG.class", "CalendarData_ii_CN.class",
-                    "CalendarData_in_ID.class", "CalendarData_is_IS.class", "CalendarData_it_CH.class",
-                    "CalendarData_it_IT.class", "CalendarData_it_SM.class", "CalendarData_iw_IL.class",
-                    "CalendarData_ja_JP.class", "CalendarData_jgo_CM.class", "CalendarData_jmc_TZ.class",
-                    "CalendarData_ka_GE.class", "CalendarData_kab_DZ.class", "CalendarData_kam_KE.class",
-                    "CalendarData_kde_TZ.class", "CalendarData_kea_CV.class", "CalendarData_khq_ML.class",
-                    "CalendarData_ki_KE.class", "CalendarData_kk_KZ.class", "CalendarData_kkj_CM.class",
-                    "CalendarData_kl_GL.class", "CalendarData_kln_KE.class", "CalendarData_km_KH.class",
-                    "CalendarData_kn_IN.class", "CalendarData_ko_KP.class", "CalendarData_ko_KR.class",
-                    "CalendarData_kok_IN.class", "CalendarData_ks_IN.class", "CalendarData_ksb_TZ.class",
-                    "CalendarData_ksf_CM.class", "CalendarData_ksh_DE.class", "CalendarData_kw_GB.class",
-                    "CalendarData_ky_KG.class", "CalendarData_lag_TZ.class", "CalendarData_lb_LU.class",
-                    "CalendarData_lg_UG.class", "CalendarData_lkt_US.class", "CalendarData_ln_AO.class",
-                    "CalendarData_ln_CD.class", "CalendarData_ln_CF.class", "CalendarData_ln_CG.class",
-                    "CalendarData_lo_LA.class", "CalendarData_lrc_IQ.class", "CalendarData_lrc_IR.class",
-                    "CalendarData_lt_LT.class", "CalendarData_lu_CD.class", "CalendarData_luo_KE.class",
-                    "CalendarData_luy_KE.class", "CalendarData_lv_LV.class", "CalendarData_mas_KE.class",
-                    "CalendarData_mas_TZ.class", "CalendarData_mer_KE.class", "CalendarData_mfe_MU.class",
-                    "CalendarData_mg_MG.class", "CalendarData_mgh_MZ.class", "CalendarData_mgo_CM.class",
-                    "CalendarData_mk_MK.class", "CalendarData_ml_IN.class", "CalendarData_mn_MN.class",
-                    "CalendarData_mr_IN.class", "CalendarData_ms_BN.class", "CalendarData_ms_MY.class",
-                    "CalendarData_ms_SG.class", "CalendarData_mt_MT.class", "CalendarData_mua_CM.class",
-                    "CalendarData_my_MM.class", "CalendarData_mzn_IR.class", "CalendarData_naq_NA.class",
-                    "CalendarData_nb_NO.class", "CalendarData_nb_SJ.class", "CalendarData_nd_ZW.class",
-                    "CalendarData_ne_IN.class", "CalendarData_ne_NP.class", "CalendarData_nl_AW.class",
-                    "CalendarData_nl_BE.class", "CalendarData_nl_BQ.class", "CalendarData_nl_CW.class",
-                    "CalendarData_nl_NL.class", "CalendarData_nl_SR.class", "CalendarData_nl_SX.class",
-                    "CalendarData_nmg_CM.class", "CalendarData_nnh_CM.class", "CalendarData_nus_SS.class",
-                    "CalendarData_nyn_UG.class", "CalendarData_om_ET.class", "CalendarData_om_KE.class",
-                    "CalendarData_or_IN.class", "CalendarData_os_GE.class", "CalendarData_os_RU.class",
-                    "CalendarData_pa_Arab_PK.class", "CalendarData_pa_IN.class", "CalendarData_pa_PK.class",
-                    "CalendarData_pl_PL.class", "CalendarData_ps_AF.class", "CalendarData_pt_AO.class",
-                    "CalendarData_pt_BR.class", "CalendarData_pt_CV.class", "CalendarData_pt_GQ.class",
-                    "CalendarData_pt_GW.class", "CalendarData_pt_MO.class", "CalendarData_pt_MZ.class",
-                    "CalendarData_pt_PT.class", "CalendarData_pt_ST.class", "CalendarData_pt_TL.class",
-                    "CalendarData_qu_BO.class", "CalendarData_qu_EC.class", "CalendarData_qu_PE.class",
-                    "CalendarData_rm_CH.class", "CalendarData_rn_BI.class", "CalendarData_ro_MD.class",
-                    "CalendarData_ro_RO.class", "CalendarData_rof_TZ.class", "CalendarData_ru_BY.class",
-                    "CalendarData_ru_KG.class", "CalendarData_ru_KZ.class", "CalendarData_ru_MD.class",
-                    "CalendarData_ru_RU.class", "CalendarData_ru_UA.class", "CalendarData_rw_RW.class",
-                    "CalendarData_rwk_TZ.class", "CalendarData_sah_RU.class", "CalendarData_saq_KE.class",
-                    "CalendarData_sbp_TZ.class", "CalendarData_se_FI.class", "CalendarData_se_NO.class",
-                    "CalendarData_se_SE.class", "CalendarData_seh_MZ.class", "CalendarData_ses_ML.class",
-                    "CalendarData_sg_CF.class", "CalendarData_shi_Latn_MA.class", "CalendarData_shi_MA.class",
-                    "CalendarData_si_LK.class", "CalendarData_sk_SK.class", "CalendarData_sl_SI.class",
-                    "CalendarData_smn_FI.class", "CalendarData_sn_ZW.class", "CalendarData_so_DJ.class",
-                    "CalendarData_so_ET.class", "CalendarData_so_KE.class", "CalendarData_so_SO.class",
-                    "CalendarData_sq_AL.class", "CalendarData_sq_MK.class", "CalendarData_sq_XK.class",
-                    "CalendarData_sr_BA.class", "CalendarData_sr_Latn_BA.class", "CalendarData_sr_Latn_ME.class",
-                    "CalendarData_sr_Latn_RS.class", "CalendarData_sr_Latn_XK.class", "CalendarData_sr_ME.class",
-                    "CalendarData_sr_RS.class", "CalendarData_sr_XK.class", "CalendarData_sv_AX.class",
-                    "CalendarData_sv_FI.class", "CalendarData_sv_SE.class", "CalendarData_sw_CD.class",
-                    "CalendarData_sw_KE.class", "CalendarData_sw_TZ.class", "CalendarData_sw_UG.class",
-                    "CalendarData_ta_IN.class", "CalendarData_ta_LK.class", "CalendarData_ta_MY.class",
-                    "CalendarData_ta_SG.class", "CalendarData_te_IN.class", "CalendarData_teo_KE.class",
-                    "CalendarData_teo_UG.class", "CalendarData_th_TH.class", "CalendarData_ti_ER.class",
-                    "CalendarData_ti_ET.class", "CalendarData_tk_TM.class", "CalendarData_to_TO.class",
-                    "CalendarData_tr_CY.class", "CalendarData_tr_TR.class", "CalendarData_twq_NE.class",
-                    "CalendarData_tzm_MA.class", "CalendarData_ug_CN.class", "CalendarData_uk_UA.class",
-                    "CalendarData_ur_IN.class", "CalendarData_ur_PK.class", "CalendarData_uz_AF.class",
-                    "CalendarData_uz_Arab_AF.class", "CalendarData_uz_Cyrl_UZ.class", "CalendarData_uz_UZ.class",
-                    "CalendarData_vai_LR.class", "CalendarData_vai_Latn_LR.class", "CalendarData_vi_VN.class",
-                    "CalendarData_vun_TZ.class", "CalendarData_wae_CH.class", "CalendarData_xog_UG.class",
-                    "CalendarData_yav_CM.class", "CalendarData_yo_BJ.class", "CalendarData_yo_NG.class",
-                    "CalendarData_yue_HK.class", "CalendarData_zgh_MA.class", "CalendarData_zh_CN.class",
-                    "CalendarData_zh_HK.class", "CalendarData_zh_Hant_HK.class", "CalendarData_zh_Hant_TW.class",
-                    "CalendarData_zh_MO.class", "CalendarData_zh_SG.class", "CalendarData_zh_TW.class", "CalendarData_zu_ZA.class");
-
-    private static Set<String> removedBundles = Set.of(
-            "CalendarData_az_Latn_AZ.class", "CalendarData_bs_Latn_BA.class",
-            "CalendarData_pa_Guru_IN.class", "CalendarData_shi_Tfng_MA.class",
-            "CalendarData_sr_Cyrl_BA.class", "CalendarData_sr_Cyrl_ME.class",
-            "CalendarData_sr_Cyrl_RS.class", "CalendarData_sr_Cyrl_XK.class",
-            "CalendarData_uz_Latn_UZ.class", "CalendarData_vai_Vaii_LR.class",
-            "CalendarData_zh_Hans_CN.class", "CalendarData_zh_Hans_HK.class",
-            "CalendarData_zh_Hans_MO.class", "CalendarData_zh_Hans_SG.class");
-
-    private static Set<String> addedBundles = Set.of(
-            "CalendarData_az_AZ.class", "CalendarData_bs_BA.class",
-            "CalendarData_pa_IN.class", "CalendarData_pa_PK.class",
-            "CalendarData_shi_MA.class", "CalendarData_sr_BA.class",
-            "CalendarData_sr_ME.class", "CalendarData_sr_RS.class",
-            "CalendarData_sr_XK.class", "CalendarData_uz_UZ.class",
-            "CalendarData_uz_AF.class", "CalendarData_vai_LR.class",
-            "CalendarData_zh_CN.class", "CalendarData_zh_HK.class",
-            "CalendarData_zh_MO.class", "CalendarData_zh_SG.class", "CalendarData_zh_TW.class");
-
-    private static Set<String> retrievedBundles = Collections.EMPTY_SET;
-
-    public static void main(String[] args) throws Exception {
-        FileSystem fs = FileSystems.newFileSystem(URI.create("jrt:/"),
-                Collections.emptyMap());
-        Path path = fs.getPath("/", "modules", "jdk.localedata", "sun/util/resources/cldr/ext");
-        retrievedBundles = Files.walk(path)
-                                .map(p -> p.getFileName().toString())
-                                .filter(p -> p.startsWith("CalendarData_"))
-                                .collect(Collectors.toSet());
-        if (!retrievedBundles.equals(expectedBundles)) {
-            checkAddedBundles();
-            checkRemovedBundles();
-            Set<String> retrievedBundlesSet = new HashSet<>(retrievedBundles);
-            retrievedBundlesSet.removeAll(expectedBundles);
-            throw new RuntimeException("Unexpected "
-                    + " bundles " + retrievedBundlesSet + " are present in jdk.localedata module ");
-
-        }
-    }
-
-    /**
-     * This method checks that bundles which have been additionally generated
-     * are present in jdk.localedata module.
-     */
-    private static void checkAddedBundles() {
-        Set<String> addedBundlesSet = new HashSet<>(addedBundles);
-        addedBundlesSet.removeAll(retrievedBundles);
-        if (!addedBundlesSet.isEmpty()) {
-            throw new RuntimeException("expected CalendarData"
-                    + " bundles " + addedBundlesSet + " are not present in jdk.localedata module ");
-        }
-
-    }
-
-    /**
-     * This method checks that bundles which have been removed are not present
-     * in jdk.localedata module.
-     */
-    private static void checkRemovedBundles() {
-        Set<String> unexpectedBundles = removedBundles.stream().
-                filter(retrievedBundles::contains).collect(Collectors.toSet());
-        if (!unexpectedBundles.isEmpty()) {
-            throw new RuntimeException("Unexpected CalendarData"
-                    + " bundles " + unexpectedBundles + " are present in jdk.localedata module ");
-        }
-    }
-}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/time/test/java/time/format/TestUnicodeExtension.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,852 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8176841
+ * @summary Tests java.time classes deals with Unicode extensions
+ *      correctly.
+ * @modules jdk.localedata
+ */
+package test.java.time.format;
+
+import static org.testng.Assert.assertEquals;
+
+import java.time.DayOfWeek;
+import java.time.ZonedDateTime;
+import java.time.ZoneId;
+import java.time.chrono.Chronology;
+import java.time.chrono.HijrahChronology;
+import java.time.chrono.IsoChronology;
+import java.time.chrono.JapaneseChronology;
+import java.time.format.DateTimeFormatter;
+import java.time.format.DateTimeFormatterBuilder;
+import java.time.format.FormatStyle;
+import java.time.temporal.ChronoField;
+import java.time.temporal.TemporalField;
+import java.time.temporal.WeekFields;
+import java.util.Locale;
+import java.util.TimeZone;
+
+import org.testng.annotations.AfterTest;
+import org.testng.annotations.BeforeTest;
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+/**
+ * Test JavaTime with BCP47 U extensions
+ */
+@Test
+public class TestUnicodeExtension {
+    private static TimeZone defaultTZ;
+
+    private static final Chronology JAPANESE = JapaneseChronology.INSTANCE;
+    private static final Chronology HIJRAH = HijrahChronology.INSTANCE;
+
+    private static final ZoneId ASIATOKYO = ZoneId.of("Asia/Tokyo");
+    private static final ZoneId AMLA = ZoneId.of("America/Los_Angeles");
+
+    private static final Locale JPTYO = Locale.forLanguageTag("en-u-tz-jptyo");
+    private static final Locale JCAL = Locale.forLanguageTag("en-u-ca-japanese");
+    private static final Locale HCAL = Locale.forLanguageTag("en-u-ca-islamic-umalqura");
+
+    private static final Locale FW_SUN = Locale.forLanguageTag("en-US-u-fw-sun");
+    private static final Locale FW_MON = Locale.forLanguageTag("en-US-u-fw-mon");
+    private static final Locale FW_TUE = Locale.forLanguageTag("en-US-u-fw-tue");
+    private static final Locale FW_WED = Locale.forLanguageTag("en-US-u-fw-wed");
+    private static final Locale FW_THU = Locale.forLanguageTag("en-US-u-fw-thu");
+    private static final Locale FW_FRI = Locale.forLanguageTag("en-US-u-fw-fri");
+    private static final Locale FW_SAT = Locale.forLanguageTag("en-US-u-fw-sat");
+
+    private static final Locale RG_GB = Locale.forLanguageTag("en-US-u-rg-gbzzzz");
+
+    private static final ZonedDateTime ZDT = ZonedDateTime.of(2017, 8, 10, 15, 15, 0, 0, AMLA);
+
+    private static final String PATTERN = "GGGG MMMM-dd-uu HH:mm:ss zzzz";
+
+    @BeforeTest
+    public void beforeTest() {
+        defaultTZ = TimeZone.getDefault();
+        TimeZone.setDefault(TimeZone.getTimeZone(AMLA));
+    }
+
+    @AfterTest
+    public void afterTest() {
+        TimeZone.setDefault(defaultTZ);
+    }
+
+    @DataProvider(name="localizedBy")
+    Object[][] localizedBy() {
+        return new Object[][] {
+            // Locale, Chrono override, Zone override, Expected Chrono, Expected Zone,
+            // Expected formatted string
+            {Locale.JAPAN, null, null, null, null,
+            "2017\u5e748\u670810\u65e5\u6728\u66dc\u65e5 15\u664215\u520600\u79d2 \u30a2\u30e1\u30ea\u30ab\u592a\u5e73\u6d0b\u590f\u6642\u9593"
+            },
+            {Locale.JAPAN, JAPANESE, null, JAPANESE, null,
+            "\u5e73\u621029\u5e748\u670810\u65e5\u6728\u66dc\u65e5 15\u664215\u520600\u79d2 \u30a2\u30e1\u30ea\u30ab\u592a\u5e73\u6d0b\u590f\u6642\u9593"
+            },
+            {Locale.JAPAN, JAPANESE, ASIATOKYO, JAPANESE, ASIATOKYO,
+            "\u5e73\u621029\u5e748\u670811\u65e5\u91d1\u66dc\u65e5 7\u664215\u520600\u79d2 \u65e5\u672c\u6a19\u6e96\u6642"
+            },
+
+            {JCAL, null, null, JAPANESE, null,
+            "Thursday, August 10, 29 Heisei at 3:15:00 PM Pacific Daylight Time"
+            },
+            {JCAL, HIJRAH, null, JAPANESE, null,
+            "Thursday, August 10, 29 Heisei at 3:15:00 PM Pacific Daylight Time"
+            },
+            {HCAL, JAPANESE, null, HIJRAH, null,
+            "Thursday, Dhu\u02bbl-Qi\u02bbdah 18, 1438 AH at 3:15:00 PM Pacific Daylight Time"
+            },
+
+
+            {JPTYO, null, null, null, ASIATOKYO,
+            "Friday, August 11, 2017 at 7:15:00 AM Japan Standard Time"
+            },
+            {JPTYO, null, AMLA, null, ASIATOKYO,
+            "Friday, August 11, 2017 at 7:15:00 AM Japan Standard Time"
+            },
+            // invalid tz
+            {Locale.forLanguageTag("en-US-u-tz-jpzzz"), null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+            {Locale.forLanguageTag("en-US-u-tz-jpzzz"), null, AMLA, null, AMLA,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+
+            {RG_GB, null, null, null, null,
+            "Thursday, 10 August 2017 at 15:15:00 Pacific Daylight Time"
+            },
+
+            // DecimalStyle
+            {Locale.forLanguageTag("en-US-u-nu-thai"), null, null, null, null,
+            "Thursday, August \u0e51\u0e50, \u0e52\u0e50\u0e51\u0e57 at \u0e53:\u0e51\u0e55:\u0e50\u0e50 PM Pacific Daylight Time"
+            },
+            // DecimalStyle, "nu" vs "rg"
+            {Locale.forLanguageTag("en-US-u-nu-thai-rg-uszzzz"), null, null, null, null,
+            "Thursday, August \u0e51\u0e50, \u0e52\u0e50\u0e51\u0e57 at \u0e53:\u0e51\u0e55:\u0e50\u0e50 PM Pacific Daylight Time"
+            },
+            // DecimalStyle, invalid
+            {Locale.forLanguageTag("en-US-u-nu-foo"), null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+        };
+    }
+
+    @DataProvider(name="withLocale")
+    Object[][] withLocale() {
+        return new Object[][] {
+            // Locale, Chrono override, Zone override, Expected Chrono, Expected Zone,
+            // Expected formatted string
+            {Locale.JAPAN, null, null, null, null,
+            "2017\u5e748\u670810\u65e5\u6728\u66dc\u65e5 15\u664215\u520600\u79d2 \u30a2\u30e1\u30ea\u30ab\u592a\u5e73\u6d0b\u590f\u6642\u9593"
+            },
+            {Locale.JAPAN, JAPANESE, null, JAPANESE, null,
+            "\u5e73\u621029\u5e748\u670810\u65e5\u6728\u66dc\u65e5 15\u664215\u520600\u79d2 \u30a2\u30e1\u30ea\u30ab\u592a\u5e73\u6d0b\u590f\u6642\u9593"
+            },
+            {Locale.JAPAN, JAPANESE, ASIATOKYO, JAPANESE, ASIATOKYO,
+            "\u5e73\u621029\u5e748\u670811\u65e5\u91d1\u66dc\u65e5 7\u664215\u520600\u79d2 \u65e5\u672c\u6a19\u6e96\u6642"
+            },
+
+            {JCAL, null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+            {JCAL, HIJRAH, null, HIJRAH, null,
+            "Thursday, Dhu\u02bbl-Qi\u02bbdah 18, 1438 AH at 3:15:00 PM Pacific Daylight Time"
+            },
+            {HCAL, JAPANESE, null, JAPANESE, null,
+            "Thursday, August 10, 29 Heisei at 3:15:00 PM Pacific Daylight Time"
+            },
+
+
+            {JPTYO, null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+            {JPTYO, null, AMLA, null, AMLA,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+            // invalid tz
+            {Locale.forLanguageTag("en-US-u-tz-jpzzz"), null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+            {Locale.forLanguageTag("en-US-u-tz-jpzzz"), null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+
+            {RG_GB, null, null, null, null,
+            "Thursday, 10 August 2017 at 15:15:00 Pacific Daylight Time"
+            },
+
+            // DecimalStyle
+            {Locale.forLanguageTag("en-US-u-nu-thai"), null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+            // DecimalStyle, "nu" vs "rg"
+            {Locale.forLanguageTag("en-US-u-nu-thai-rg-uszzzz"), null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+            // DecimalStyle, invalid
+            {Locale.forLanguageTag("en-US-u-nu-foo"), null, null, null, null,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+        };
+    }
+
+    @DataProvider(name="firstDayOfWeek")
+    Object[][] firstDayOfWeek () {
+        return new Object[][] {
+            // Locale, Expected DayOfWeek,
+            {Locale.US, DayOfWeek.SUNDAY},
+            {FW_SUN, DayOfWeek.SUNDAY},
+            {FW_MON, DayOfWeek.MONDAY},
+            {FW_TUE, DayOfWeek.TUESDAY},
+            {FW_WED, DayOfWeek.WEDNESDAY},
+            {FW_THU, DayOfWeek.THURSDAY},
+            {FW_FRI, DayOfWeek.FRIDAY},
+            {FW_SAT, DayOfWeek.SATURDAY},
+
+            // invalid case
+            {Locale.forLanguageTag("en-US-u-fw-xxx"), DayOfWeek.SUNDAY},
+
+            // region override
+            {RG_GB, DayOfWeek.MONDAY},
+            {Locale.forLanguageTag("zh-CN-u-rg-eszzzz"), DayOfWeek.MONDAY},
+
+            // "fw" and "rg".
+            {Locale.forLanguageTag("en-US-u-fw-wed-rg-gbzzzz"), DayOfWeek.WEDNESDAY},
+            {Locale.forLanguageTag("en-US-u-fw-xxx-rg-gbzzzz"), DayOfWeek.MONDAY},
+            {Locale.forLanguageTag("en-US-u-fw-xxx-rg-zzzz"), DayOfWeek.SUNDAY},
+        };
+    }
+
+    @DataProvider(name="minDaysInFirstWeek")
+    Object[][] minDaysInFrstWeek () {
+        return new Object[][] {
+            // Locale, Expected minDay,
+            {Locale.US, 1},
+
+            // region override
+            {RG_GB, 4},
+            {Locale.forLanguageTag("zh-CN-u-rg-eszzzz"), 4},
+        };
+    }
+
+    @DataProvider(name="ofPattern")
+    Object[][] ofPattern() {
+        return new Object[][] {
+            // Locale, Expected Chrono, Expected Zone,
+            // Expected formatted string
+            {JCAL, null, null,
+            "Anno Domini August-10-17 15:15:00 Pacific Daylight Time"
+            },
+            {HCAL, null, null,
+            "Anno Domini August-10-17 15:15:00 Pacific Daylight Time"
+            },
+
+            {JPTYO, null, null,
+            "Anno Domini August-10-17 15:15:00 Pacific Daylight Time"
+            },
+            {Locale.forLanguageTag("en-US-u-tz-jpzzz"), null, null,
+            "Anno Domini August-10-17 15:15:00 Pacific Daylight Time"
+            },
+
+            {RG_GB, null, null,
+            "Anno Domini August-10-17 15:15:00 Pacific Daylight Time"
+            },
+
+        };
+    }
+
+    @DataProvider(name="shortTZID")
+    Object[][] shortTZID() {
+        return new Object[][] {
+            // LDML's short ID, Expected Zone,
+            {"adalv", "Europe/Andorra"},
+            {"aedxb", "Asia/Dubai"},
+            {"afkbl", "Asia/Kabul"},
+            {"aganu", "America/Antigua"},
+            {"aiaxa", "America/Anguilla"},
+            {"altia", "Europe/Tirane"},
+            {"amevn", "Asia/Yerevan"},
+            {"ancur", "America/Curacao"},
+            {"aolad", "Africa/Luanda"},
+            {"aqcas", "Antarctica/Casey"},
+            {"aqdav", "Antarctica/Davis"},
+            {"aqddu", "Antarctica/DumontDUrville"},
+            {"aqmaw", "Antarctica/Mawson"},
+            {"aqmcm", "Antarctica/McMurdo"},
+            {"aqplm", "Antarctica/Palmer"},
+            {"aqrot", "Antarctica/Rothera"},
+            {"aqsyw", "Antarctica/Syowa"},
+            {"aqtrl", "Antarctica/Troll"},
+            {"aqvos", "Antarctica/Vostok"},
+            {"arbue", "America/Buenos_Aires"},
+            {"arcor", "America/Cordoba"},
+            {"arctc", "America/Catamarca"},
+            {"arirj", "America/Argentina/La_Rioja"},
+            {"arjuj", "America/Jujuy"},
+            {"arluq", "America/Argentina/San_Luis"},
+            {"armdz", "America/Mendoza"},
+            {"arrgl", "America/Argentina/Rio_Gallegos"},
+            {"arsla", "America/Argentina/Salta"},
+            {"artuc", "America/Argentina/Tucuman"},
+            {"aruaq", "America/Argentina/San_Juan"},
+            {"arush", "America/Argentina/Ushuaia"},
+            {"asppg", "Pacific/Pago_Pago"},
+            {"atvie", "Europe/Vienna"},
+            {"auadl", "Australia/Adelaide"},
+            {"aubhq", "Australia/Broken_Hill"},
+            {"aubne", "Australia/Brisbane"},
+            {"audrw", "Australia/Darwin"},
+            {"aueuc", "Australia/Eucla"},
+            {"auhba", "Australia/Hobart"},
+            {"aukns", "Australia/Currie"},
+            {"auldc", "Australia/Lindeman"},
+            {"auldh", "Australia/Lord_Howe"},
+            {"aumel", "Australia/Melbourne"},
+            {"aumqi", "Antarctica/Macquarie"},
+            {"auper", "Australia/Perth"},
+            {"ausyd", "Australia/Sydney"},
+            {"awaua", "America/Aruba"},
+            {"azbak", "Asia/Baku"},
+            {"basjj", "Europe/Sarajevo"},
+            {"bbbgi", "America/Barbados"},
+            {"bddac", "Asia/Dhaka"},
+            {"bebru", "Europe/Brussels"},
+            {"bfoua", "Africa/Ouagadougou"},
+            {"bgsof", "Europe/Sofia"},
+            {"bhbah", "Asia/Bahrain"},
+            {"bibjm", "Africa/Bujumbura"},
+            {"bjptn", "Africa/Porto-Novo"},
+            {"bmbda", "Atlantic/Bermuda"},
+            {"bnbwn", "Asia/Brunei"},
+            {"bolpb", "America/La_Paz"},
+            {"bqkra", "America/Kralendijk"},
+            {"braux", "America/Araguaina"},
+            {"brbel", "America/Belem"},
+            {"brbvb", "America/Boa_Vista"},
+            {"brcgb", "America/Cuiaba"},
+            {"brcgr", "America/Campo_Grande"},
+            {"brern", "America/Eirunepe"},
+            {"brfen", "America/Noronha"},
+            {"brfor", "America/Fortaleza"},
+            {"brmao", "America/Manaus"},
+            {"brmcz", "America/Maceio"},
+            {"brpvh", "America/Porto_Velho"},
+            {"brrbr", "America/Rio_Branco"},
+            {"brrec", "America/Recife"},
+            {"brsao", "America/Sao_Paulo"},
+            {"brssa", "America/Bahia"},
+            {"brstm", "America/Santarem"},
+            {"bsnas", "America/Nassau"},
+            {"btthi", "Asia/Thimphu"},
+            {"bwgbe", "Africa/Gaborone"},
+            {"bymsq", "Europe/Minsk"},
+            {"bzbze", "America/Belize"},
+            {"cacfq", "America/Creston"},
+            {"caedm", "America/Edmonton"},
+            {"caffs", "America/Rainy_River"},
+            {"cafne", "America/Fort_Nelson"},
+            {"caglb", "America/Glace_Bay"},
+            {"cagoo", "America/Goose_Bay"},
+            {"cahal", "America/Halifax"},
+            {"caiql", "America/Iqaluit"},
+            {"camon", "America/Moncton"},
+            {"capnt", "America/Pangnirtung"},
+            {"careb", "America/Resolute"},
+            {"careg", "America/Regina"},
+            {"casjf", "America/St_Johns"},
+            {"canpg", "America/Nipigon"},
+            {"cathu", "America/Thunder_Bay"},
+            {"cator", "America/Toronto"},
+            {"cavan", "America/Vancouver"},
+            {"cawnp", "America/Winnipeg"},
+            {"caybx", "America/Blanc-Sablon"},
+            {"caycb", "America/Cambridge_Bay"},
+            {"cayda", "America/Dawson"},
+            {"caydq", "America/Dawson_Creek"},
+            {"cayek", "America/Rankin_Inlet"},
+            {"cayev", "America/Inuvik"},
+            {"cayxy", "America/Whitehorse"},
+            {"cayyn", "America/Swift_Current"},
+            {"cayzf", "America/Yellowknife"},
+            {"cayzs", "America/Coral_Harbour"},
+            {"cccck", "Indian/Cocos"},
+            {"cdfbm", "Africa/Lubumbashi"},
+            {"cdfih", "Africa/Kinshasa"},
+            {"cfbgf", "Africa/Bangui"},
+            {"cgbzv", "Africa/Brazzaville"},
+            {"chzrh", "Europe/Zurich"},
+            {"ciabj", "Africa/Abidjan"},
+            {"ckrar", "Pacific/Rarotonga"},
+            {"clipc", "Pacific/Easter"},
+            {"clscl", "America/Santiago"},
+            {"cmdla", "Africa/Douala"},
+            {"cnsha", "Asia/Shanghai"},
+            {"cnurc", "Asia/Urumqi"},
+            {"cobog", "America/Bogota"},
+            {"crsjo", "America/Costa_Rica"},
+            {"cst6cdt", "CST6CDT"},
+            {"cuhav", "America/Havana"},
+            {"cvrai", "Atlantic/Cape_Verde"},
+            {"cxxch", "Indian/Christmas"},
+            {"cynic", "Asia/Nicosia"},
+            {"czprg", "Europe/Prague"},
+            {"deber", "Europe/Berlin"},
+            {"debsngn", "Europe/Busingen"},
+            {"djjib", "Africa/Djibouti"},
+            {"dkcph", "Europe/Copenhagen"},
+            {"dmdom", "America/Dominica"},
+            {"dosdq", "America/Santo_Domingo"},
+            {"dzalg", "Africa/Algiers"},
+            {"ecgps", "Pacific/Galapagos"},
+            {"ecgye", "America/Guayaquil"},
+            {"eetll", "Europe/Tallinn"},
+            {"egcai", "Africa/Cairo"},
+            {"eheai", "Africa/El_Aaiun"},
+            {"erasm", "Africa/Asmera"},
+            {"esceu", "Africa/Ceuta"},
+            {"eslpa", "Atlantic/Canary"},
+            {"esmad", "Europe/Madrid"},
+            {"est5edt", "EST5EDT"},
+            {"etadd", "Africa/Addis_Ababa"},
+            {"fihel", "Europe/Helsinki"},
+            {"fimhq", "Europe/Mariehamn"},
+            {"fjsuv", "Pacific/Fiji"},
+            {"fkpsy", "Atlantic/Stanley"},
+            {"fmksa", "Pacific/Kosrae"},
+            {"fmpni", "Pacific/Ponape"},
+            {"fmtkk", "Pacific/Truk"},
+            {"fotho", "Atlantic/Faeroe"},
+            {"frpar", "Europe/Paris"},
+            {"galbv", "Africa/Libreville"},
+            {"gaza", "Asia/Gaza"},
+            {"gblon", "Europe/London"},
+            {"gdgnd", "America/Grenada"},
+            {"getbs", "Asia/Tbilisi"},
+            {"gfcay", "America/Cayenne"},
+            {"gggci", "Europe/Guernsey"},
+            {"ghacc", "Africa/Accra"},
+            {"gigib", "Europe/Gibraltar"},
+            {"gldkshvn", "America/Danmarkshavn"},
+            {"glgoh", "America/Godthab"},
+            {"globy", "America/Scoresbysund"},
+            {"glthu", "America/Thule"},
+            {"gmbjl", "Africa/Banjul"},
+            {"gncky", "Africa/Conakry"},
+            {"gpbbr", "America/Guadeloupe"},
+            {"gpmsb", "America/Marigot"},
+            {"gpsbh", "America/St_Barthelemy"},
+            {"gqssg", "Africa/Malabo"},
+            {"grath", "Europe/Athens"},
+            {"gsgrv", "Atlantic/South_Georgia"},
+            {"gtgua", "America/Guatemala"},
+            {"gugum", "Pacific/Guam"},
+            {"gwoxb", "Africa/Bissau"},
+            {"gygeo", "America/Guyana"},
+            {"hebron", "Asia/Hebron"},
+            {"hkhkg", "Asia/Hong_Kong"},
+            {"hntgu", "America/Tegucigalpa"},
+            {"hrzag", "Europe/Zagreb"},
+            {"htpap", "America/Port-au-Prince"},
+            {"hubud", "Europe/Budapest"},
+            {"iddjj", "Asia/Jayapura"},
+            {"idjkt", "Asia/Jakarta"},
+            {"idmak", "Asia/Makassar"},
+            {"idpnk", "Asia/Pontianak"},
+            {"iedub", "Europe/Dublin"},
+            {"imdgs", "Europe/Isle_of_Man"},
+            {"inccu", "Asia/Calcutta"},
+            {"iodga", "Indian/Chagos"},
+            {"iqbgw", "Asia/Baghdad"},
+            {"irthr", "Asia/Tehran"},
+            {"isrey", "Atlantic/Reykjavik"},
+            {"itrom", "Europe/Rome"},
+            {"jeruslm", "Asia/Jerusalem"},
+            {"jesth", "Europe/Jersey"},
+            {"jmkin", "America/Jamaica"},
+            {"joamm", "Asia/Amman"},
+            {"jptyo", "Asia/Tokyo"},
+            {"kenbo", "Africa/Nairobi"},
+            {"kgfru", "Asia/Bishkek"},
+            {"khpnh", "Asia/Phnom_Penh"},
+            {"kicxi", "Pacific/Kiritimati"},
+            {"kipho", "Pacific/Enderbury"},
+            {"kitrw", "Pacific/Tarawa"},
+            {"kmyva", "Indian/Comoro"},
+            {"knbas", "America/St_Kitts"},
+            {"kpfnj", "Asia/Pyongyang"},
+            {"krsel", "Asia/Seoul"},
+            {"kwkwi", "Asia/Kuwait"},
+            {"kygec", "America/Cayman"},
+            {"kzaau", "Asia/Aqtau"},
+            {"kzakx", "Asia/Aqtobe"},
+            {"kzala", "Asia/Almaty"},
+            {"kzkzo", "Asia/Qyzylorda"},
+            {"kzura", "Asia/Oral"},
+            {"lavte", "Asia/Vientiane"},
+            {"lbbey", "Asia/Beirut"},
+            {"lccas", "America/St_Lucia"},
+            {"livdz", "Europe/Vaduz"},
+            {"lkcmb", "Asia/Colombo"},
+            {"lrmlw", "Africa/Monrovia"},
+            {"lsmsu", "Africa/Maseru"},
+            {"ltvno", "Europe/Vilnius"},
+            {"lulux", "Europe/Luxembourg"},
+            {"lvrix", "Europe/Riga"},
+            {"lytip", "Africa/Tripoli"},
+            {"macas", "Africa/Casablanca"},
+            {"mcmon", "Europe/Monaco"},
+            {"mdkiv", "Europe/Chisinau"},
+            {"metgd", "Europe/Podgorica"},
+            {"mgtnr", "Indian/Antananarivo"},
+            {"mhkwa", "Pacific/Kwajalein"},
+            {"mhmaj", "Pacific/Majuro"},
+            {"mkskp", "Europe/Skopje"},
+            {"mlbko", "Africa/Bamako"},
+            {"mmrgn", "Asia/Rangoon"},
+            {"mncoq", "Asia/Choibalsan"},
+            {"mnhvd", "Asia/Hovd"},
+            {"mnuln", "Asia/Ulaanbaatar"},
+            {"momfm", "Asia/Macau"},
+            {"mpspn", "Pacific/Saipan"},
+            {"mqfdf", "America/Martinique"},
+            {"mrnkc", "Africa/Nouakchott"},
+            {"msmni", "America/Montserrat"},
+            {"mst7mdt", "MST7MDT"},
+            {"mtmla", "Europe/Malta"},
+            {"muplu", "Indian/Mauritius"},
+            {"mvmle", "Indian/Maldives"},
+            {"mwblz", "Africa/Blantyre"},
+            {"mxchi", "America/Chihuahua"},
+            {"mxcun", "America/Cancun"},
+            {"mxhmo", "America/Hermosillo"},
+            {"mxmam", "America/Matamoros"},
+            {"mxmex", "America/Mexico_City"},
+            {"mxmid", "America/Merida"},
+            {"mxmty", "America/Monterrey"},
+            {"mxmzt", "America/Mazatlan"},
+            {"mxoji", "America/Ojinaga"},
+            {"mxpvr", "America/Bahia_Banderas"},
+            {"mxstis", "America/Santa_Isabel"},
+            {"mxtij", "America/Tijuana"},
+            {"mykch", "Asia/Kuching"},
+            {"mykul", "Asia/Kuala_Lumpur"},
+            {"mzmpm", "Africa/Maputo"},
+            {"nawdh", "Africa/Windhoek"},
+            {"ncnou", "Pacific/Noumea"},
+            {"nenim", "Africa/Niamey"},
+            {"nfnlk", "Pacific/Norfolk"},
+            {"nglos", "Africa/Lagos"},
+            {"nimga", "America/Managua"},
+            {"nlams", "Europe/Amsterdam"},
+            {"noosl", "Europe/Oslo"},
+            {"npktm", "Asia/Katmandu"},
+            {"nrinu", "Pacific/Nauru"},
+            {"nuiue", "Pacific/Niue"},
+            {"nzakl", "Pacific/Auckland"},
+            {"nzcht", "Pacific/Chatham"},
+            {"ommct", "Asia/Muscat"},
+            {"papty", "America/Panama"},
+            {"pelim", "America/Lima"},
+            {"pfgmr", "Pacific/Gambier"},
+            {"pfnhv", "Pacific/Marquesas"},
+            {"pfppt", "Pacific/Tahiti"},
+            {"pgpom", "Pacific/Port_Moresby"},
+            {"pgraw", "Pacific/Bougainville"},
+            {"phmnl", "Asia/Manila"},
+            {"pkkhi", "Asia/Karachi"},
+            {"plwaw", "Europe/Warsaw"},
+            {"pmmqc", "America/Miquelon"},
+            {"pnpcn", "Pacific/Pitcairn"},
+            {"prsju", "America/Puerto_Rico"},
+            {"pst8pdt", "PST8PDT"},
+            {"ptfnc", "Atlantic/Madeira"},
+            {"ptlis", "Europe/Lisbon"},
+            {"ptpdl", "Atlantic/Azores"},
+            {"pwror", "Pacific/Palau"},
+            {"pyasu", "America/Asuncion"},
+            {"qadoh", "Asia/Qatar"},
+            {"rereu", "Indian/Reunion"},
+            {"robuh", "Europe/Bucharest"},
+            {"rsbeg", "Europe/Belgrade"},
+            {"ruchita", "Asia/Chita"},
+            {"rudyr", "Asia/Anadyr"},
+            {"rugdx", "Asia/Magadan"},
+            {"ruikt", "Asia/Irkutsk"},
+            {"rukgd", "Europe/Kaliningrad"},
+            {"rukhndg", "Asia/Khandyga"},
+            {"rukra", "Asia/Krasnoyarsk"},
+            {"rukuf", "Europe/Samara"},
+            {"rumow", "Europe/Moscow"},
+            {"runoz", "Asia/Novokuznetsk"},
+            {"ruoms", "Asia/Omsk"},
+            {"ruovb", "Asia/Novosibirsk"},
+            {"rupkc", "Asia/Kamchatka"},
+            {"rusred", "Asia/Srednekolymsk"},
+            {"ruunera", "Asia/Ust-Nera"},
+            {"ruuus", "Asia/Sakhalin"},
+            {"ruvog", "Europe/Volgograd"},
+            {"ruvvo", "Asia/Vladivostok"},
+            {"ruyek", "Asia/Yekaterinburg"},
+            {"ruyks", "Asia/Yakutsk"},
+            {"rwkgl", "Africa/Kigali"},
+            {"saruh", "Asia/Riyadh"},
+            {"sbhir", "Pacific/Guadalcanal"},
+            {"scmaw", "Indian/Mahe"},
+            {"sdkrt", "Africa/Khartoum"},
+            {"sesto", "Europe/Stockholm"},
+            {"sgsin", "Asia/Singapore"},
+            {"shshn", "Atlantic/St_Helena"},
+            {"silju", "Europe/Ljubljana"},
+            {"sjlyr", "Arctic/Longyearbyen"},
+            {"skbts", "Europe/Bratislava"},
+            {"slfna", "Africa/Freetown"},
+            {"smsai", "Europe/San_Marino"},
+            {"sndkr", "Africa/Dakar"},
+            {"somgq", "Africa/Mogadishu"},
+            {"srpbm", "America/Paramaribo"},
+            {"ssjub", "Africa/Juba"},
+            {"sttms", "Africa/Sao_Tome"},
+            {"svsal", "America/El_Salvador"},
+            {"sxphi", "America/Lower_Princes"},
+            {"sydam", "Asia/Damascus"},
+            {"szqmn", "Africa/Mbabane"},
+            {"tcgdt", "America/Grand_Turk"},
+            {"tdndj", "Africa/Ndjamena"},
+            {"tfpfr", "Indian/Kerguelen"},
+            {"tglfw", "Africa/Lome"},
+            {"thbkk", "Asia/Bangkok"},
+            {"tjdyu", "Asia/Dushanbe"},
+            {"tkfko", "Pacific/Fakaofo"},
+            {"tldil", "Asia/Dili"},
+            {"tmasb", "Asia/Ashgabat"},
+            {"tntun", "Africa/Tunis"},
+            {"totbu", "Pacific/Tongatapu"},
+            {"trist", "Europe/Istanbul"},
+            {"ttpos", "America/Port_of_Spain"},
+            {"tvfun", "Pacific/Funafuti"},
+            {"twtpe", "Asia/Taipei"},
+            {"tzdar", "Africa/Dar_es_Salaam"},
+            {"uaiev", "Europe/Kiev"},
+            {"uaozh", "Europe/Zaporozhye"},
+            {"uasip", "Europe/Simferopol"},
+            {"uauzh", "Europe/Uzhgorod"},
+            {"ugkla", "Africa/Kampala"},
+            {"umawk", "Pacific/Wake"},
+            {"umjon", "Pacific/Johnston"},
+            {"ummdy", "Pacific/Midway"},
+//            {"unk", "Etc/Unknown"},
+            {"usadk", "America/Adak"},
+            {"usaeg", "America/Indiana/Marengo"},
+            {"usanc", "America/Anchorage"},
+            {"usboi", "America/Boise"},
+            {"uschi", "America/Chicago"},
+            {"usden", "America/Denver"},
+            {"usdet", "America/Detroit"},
+            {"ushnl", "Pacific/Honolulu"},
+            {"usind", "America/Indianapolis"},
+            {"usinvev", "America/Indiana/Vevay"},
+            {"usjnu", "America/Juneau"},
+            {"usknx", "America/Indiana/Knox"},
+            {"uslax", "America/Los_Angeles"},
+            {"uslui", "America/Louisville"},
+            {"usmnm", "America/Menominee"},
+            {"usmtm", "America/Metlakatla"},
+            {"usmoc", "America/Kentucky/Monticello"},
+            {"usndcnt", "America/North_Dakota/Center"},
+            {"usndnsl", "America/North_Dakota/New_Salem"},
+            {"usnyc", "America/New_York"},
+            {"usoea", "America/Indiana/Vincennes"},
+            {"usome", "America/Nome"},
+            {"usphx", "America/Phoenix"},
+            {"ussit", "America/Sitka"},
+            {"ustel", "America/Indiana/Tell_City"},
+            {"uswlz", "America/Indiana/Winamac"},
+            {"uswsq", "America/Indiana/Petersburg"},
+            {"usxul", "America/North_Dakota/Beulah"},
+            {"usyak", "America/Yakutat"},
+            {"utc", "Etc/GMT"},
+            {"utce01", "Etc/GMT-1"},
+            {"utce02", "Etc/GMT-2"},
+            {"utce03", "Etc/GMT-3"},
+            {"utce04", "Etc/GMT-4"},
+            {"utce05", "Etc/GMT-5"},
+            {"utce06", "Etc/GMT-6"},
+            {"utce07", "Etc/GMT-7"},
+            {"utce08", "Etc/GMT-8"},
+            {"utce09", "Etc/GMT-9"},
+            {"utce10", "Etc/GMT-10"},
+            {"utce11", "Etc/GMT-11"},
+            {"utce12", "Etc/GMT-12"},
+            {"utce13", "Etc/GMT-13"},
+            {"utce14", "Etc/GMT-14"},
+            {"utcw01", "Etc/GMT+1"},
+            {"utcw02", "Etc/GMT+2"},
+            {"utcw03", "Etc/GMT+3"},
+            {"utcw04", "Etc/GMT+4"},
+            {"utcw05", "Etc/GMT+5"},
+            {"utcw06", "Etc/GMT+6"},
+            {"utcw07", "Etc/GMT+7"},
+            {"utcw08", "Etc/GMT+8"},
+            {"utcw09", "Etc/GMT+9"},
+            {"utcw10", "Etc/GMT+10"},
+            {"utcw11", "Etc/GMT+11"},
+            {"utcw12", "Etc/GMT+12"},
+            {"uymvd", "America/Montevideo"},
+            {"uzskd", "Asia/Samarkand"},
+            {"uztas", "Asia/Tashkent"},
+            {"vavat", "Europe/Vatican"},
+            {"vcsvd", "America/St_Vincent"},
+            {"veccs", "America/Caracas"},
+            {"vgtov", "America/Tortola"},
+            {"vistt", "America/St_Thomas"},
+            {"vnsgn", "Asia/Saigon"},
+            {"vuvli", "Pacific/Efate"},
+            {"wfmau", "Pacific/Wallis"},
+            {"wsapw", "Pacific/Apia"},
+            {"yeade", "Asia/Aden"},
+            {"ytmam", "Indian/Mayotte"},
+            {"zajnb", "Africa/Johannesburg"},
+            {"zmlun", "Africa/Lusaka"},
+            {"zwhre", "Africa/Harare"},
+
+        };
+    }
+
+    @DataProvider(name="getLocalizedDateTimePattern")
+    Object[][] getLocalizedDateTimePattern() {
+        return new Object[][] {
+            // Locale, Expected pattern,
+            {Locale.US, FormatStyle.FULL, "EEEE, MMMM d, y 'at' h:mm:ss a zzzz"},
+            {Locale.US, FormatStyle.LONG, "MMMM d, y 'at' h:mm:ss a z"},
+            {Locale.US, FormatStyle.MEDIUM, "MMM d, y, h:mm:ss a"},
+            {Locale.US, FormatStyle.SHORT, "M/d/yy, h:mm a"},
+            {RG_GB, FormatStyle.FULL, "EEEE, d MMMM y 'at' HH:mm:ss zzzz"},
+            {RG_GB, FormatStyle.LONG, "d MMMM y 'at' HH:mm:ss z"},
+            {RG_GB, FormatStyle.MEDIUM, "d MMM y, HH:mm:ss"},
+            {RG_GB, FormatStyle.SHORT, "dd/MM/y, HH:mm"},
+        };
+    }
+
+    @DataProvider(name="getDisplayName")
+    Object[][] getDisplayName() {
+        return new Object[][] {
+            // Locale, field, Expected name,
+            {Locale.US, ChronoField.AMPM_OF_DAY, "AM/PM"},
+            {RG_GB, ChronoField.AMPM_OF_DAY, "am/pm"},
+        };
+    }
+
+    @Test(dataProvider="localizedBy")
+    public void test_localizedBy(Locale locale, Chronology chrono, ZoneId zone,
+                                Chronology chronoExpected, ZoneId zoneExpected,
+                                String formatExpected) {
+        DateTimeFormatter dtf =
+            DateTimeFormatter.ofLocalizedDateTime(FormatStyle.FULL, FormatStyle.FULL)
+                .withChronology(chrono).withZone(zone).localizedBy(locale);
+        assertEquals(dtf.getChronology(), chronoExpected);
+        assertEquals(dtf.getZone(), zoneExpected);
+        String formatted = dtf.format(ZDT);
+        assertEquals(formatted, formatExpected);
+        assertEquals(dtf.parse(formatted, ZonedDateTime::from),
+            zoneExpected != null ? ZDT.withZoneSameInstant(zoneExpected) : ZDT);
+    }
+
+    @Test(dataProvider="withLocale")
+    public void test_withLocale(Locale locale, Chronology chrono, ZoneId zone,
+                                Chronology chronoExpected, ZoneId zoneExpected,
+                                String formatExpected) {
+        DateTimeFormatter dtf =
+            DateTimeFormatter.ofLocalizedDateTime(FormatStyle.FULL, FormatStyle.FULL)
+                .withChronology(chrono).withZone(zone).withLocale(locale);
+        assertEquals(dtf.getChronology(), chronoExpected);
+        assertEquals(dtf.getZone(), zoneExpected);
+        String formatted = dtf.format(ZDT);
+        assertEquals(formatted, formatExpected);
+        assertEquals(dtf.parse(formatted, ZonedDateTime::from),
+            zoneExpected != null ? ZDT.withZoneSameInstant(zoneExpected) : ZDT);
+    }
+
+    @Test(dataProvider="firstDayOfWeek")
+    public void test_firstDayOfWeek(Locale locale, DayOfWeek dowExpected) {
+        DayOfWeek dow = WeekFields.of(locale).getFirstDayOfWeek();
+        assertEquals(dow, dowExpected);
+    }
+
+    @Test(dataProvider="minDaysInFirstWeek")
+    public void test_minDaysInFirstWeek(Locale locale, int minDaysExpected) {
+        int minDays = WeekFields.of(locale).getMinimalDaysInFirstWeek();
+        assertEquals(minDays, minDaysExpected);
+    }
+
+    @Test(dataProvider="ofPattern")
+    public void test_ofPattern(Locale locale,
+                                Chronology chronoExpected, ZoneId zoneExpected,
+                                String formatExpected) {
+        DateTimeFormatter dtf =
+            DateTimeFormatter.ofPattern(PATTERN, locale);
+        assertEquals(dtf.getChronology(), chronoExpected);
+        assertEquals(dtf.getZone(), zoneExpected);
+        String formatted = dtf.format(ZDT);
+        assertEquals(formatted, formatExpected);
+        assertEquals(dtf.parse(formatted, ZonedDateTime::from),
+            zoneExpected != null ? ZDT.withZoneSameInstant(zoneExpected) : ZDT);
+    }
+
+    @Test(dataProvider="ofPattern")
+    public void test_toFormatter(Locale locale,
+                                Chronology chronoExpected, ZoneId zoneExpected,
+                                String formatExpected) {
+        DateTimeFormatter dtf =
+            new DateTimeFormatterBuilder().appendPattern(PATTERN).toFormatter(locale);
+        assertEquals(dtf.getChronology(), chronoExpected);
+        assertEquals(dtf.getZone(), zoneExpected);
+        String formatted = dtf.format(ZDT);
+        assertEquals(formatted, formatExpected);
+        assertEquals(dtf.parse(formatted, ZonedDateTime::from),
+            zoneExpected != null ? ZDT.withZoneSameInstant(zoneExpected) : ZDT);
+    }
+
+    @Test(dataProvider="shortTZID")
+    public void test_shortTZID(String shortID, String expectedZone) {
+        Locale l = Locale.forLanguageTag("en-US-u-tz-" + shortID);
+        DateTimeFormatter dtf =
+            DateTimeFormatter.ofLocalizedDateTime(FormatStyle.FULL, FormatStyle.FULL)
+                .localizedBy(l);
+        assertEquals(dtf.getZone(), ZoneId.of(expectedZone));
+    }
+
+    @Test(dataProvider="getLocalizedDateTimePattern")
+    public void test_getLocalizedDateTimePattern(Locale l, FormatStyle s, String expectedPattern) {
+        DateTimeFormatterBuilder dtfb = new DateTimeFormatterBuilder();
+        assertEquals(dtfb.getLocalizedDateTimePattern(s, s, IsoChronology.INSTANCE, l),
+            expectedPattern);
+    }
+
+    @Test(dataProvider="getDisplayName")
+    public void test_getDisplayName(Locale l, TemporalField f, String expectedName) {
+        assertEquals(f.getDisplayName(l), expectedName);
+    }
+}
--- a/test/jdk/java/util/Calendar/Bug4302966.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/test/jdk/java/util/Calendar/Bug4302966.java	Tue Dec 12 10:21:58 2017 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug 4302966
+ * @bug 4302966 8176841
  * @modules jdk.localedata
  * @summary In Czech Republic first day of week is Monday not Sunday
  */
@@ -34,7 +34,7 @@
 public class Bug4302966 {
 
     public static void main(String[] args) {
-        Calendar czechCalendar = Calendar.getInstance(new Locale("cs"));
+        Calendar czechCalendar = Calendar.getInstance(new Locale("cs", "CZ"));
         int firstDayOfWeek = czechCalendar.getFirstDayOfWeek();
         if (firstDayOfWeek != Calendar.MONDAY) {
             throw new RuntimeException();
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Calendar/CalendarDataTest.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,108 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/**
+ * @test
+ * @bug 8190918
+ * @summary Tests for region dependent calendar data, i.e.,
+ *      firstDayOfWeek and minimalDaysInFirstWeek.
+ * @modules jdk.localedata
+ * @run main CalendarDataTest
+ */
+
+import java.util.Calendar;
+import java.util.List;
+import java.util.Locale;
+import java.util.Optional;
+import java.util.stream.IntStream;
+
+public class CalendarDataTest {
+
+    // golden data from CLDR
+    private static final List<List<String>> FIRSTDAYDATA = List.of(
+        List.of("1", "AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT " +
+            "GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ " +
+            "NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE " +
+            "VI WS YE ZA ZW"),
+        List.of("2",   "001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY " +
+            "CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP " +
+            "GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ " +
+            "MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ " +
+            "VA VN XK"),
+        List.of("6", "BD MV"),
+        List.of("7", "AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY"));
+
+    private static final List<List<String>> MINDAYSDATA = List.of(
+        List.of("1", "001 GU UM US VI"),
+        List.of("4", "AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR " +
+            "GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO " +
+            "PL PT RE SE SJ SK SM VA"));
+
+    public static void main(String... args) throws Exception {
+        // world
+        Calendar cal = Calendar.getInstance(new Locale("", "001"));
+        checkResult("001",
+            cal.getFirstDayOfWeek(),
+            cal.getMinimalDaysInFirstWeek());
+
+        // two letter country codes
+        IntStream.range(0x41, 0x5b)
+            .forEach(c1 -> {
+                IntStream.range(0x41, 0x5b)
+                    .mapToObj(c2 -> String.valueOf((char)c1) + String.valueOf((char)c2))
+                    .forEach(region -> {
+                        Calendar c = Calendar.getInstance(new Locale("", region));
+                        checkResult(region,
+                                c.getFirstDayOfWeek(),
+                                c.getMinimalDaysInFirstWeek());
+                    });
+            });
+    }
+
+    private static void checkResult(String region, int firstDay, int minDays) {
+        // first day of week
+        int expected = Integer.parseInt(findEntry(region, FIRSTDAYDATA)
+            .orElse(findEntry("001", FIRSTDAYDATA).orElse(List.of("1")))
+            .get(0));
+        if (firstDay != expected) {
+            throw new RuntimeException("firstDayOfWeek is incorrect for the region: " +
+                    region + ". Returned: " + firstDay + ", Expected: " + expected);
+        }
+
+        // minimal days in first week
+        expected = Integer.parseInt(findEntry(region, MINDAYSDATA)
+            .orElse(findEntry("001", MINDAYSDATA).orElse(List.of("1")))
+            .get(0));
+        if (minDays != expected) {
+            throw new RuntimeException("minimalDaysInFirstWeek is incorrect for the region: " +
+                    region + ". Returned: " + firstDay + ", Expected: " + expected);
+        }
+    }
+
+    private static Optional<List<String>> findEntry(String region, List<List<String>> data) {
+        return data.stream()
+            .filter(l -> l.get(1).contains(region))
+            .findAny();
+    }
+}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/CalendarTests.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,158 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ *
+ * @test
+ * @bug 8176841
+ * @summary Tests Calendar class deals with Unicode extensions
+ *      correctly.
+ * @modules jdk.localedata
+ * @run testng/othervm CalendarTests
+ */
+
+import static org.testng.Assert.assertEquals;
+
+import java.text.DateFormat;
+import java.util.Calendar;
+import java.util.Locale;
+import java.util.TimeZone;
+
+import org.testng.annotations.AfterTest;
+import org.testng.annotations.BeforeTest;
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+/**
+ * Test Calendar with BCP47 U extensions
+ */
+@Test
+public class CalendarTests {
+    private static TimeZone defaultTZ;
+
+    private static final TimeZone ASIATOKYO = TimeZone.getTimeZone("Asia/Tokyo");
+    private static final TimeZone AMLA = TimeZone.getTimeZone("America/Los_Angeles");
+
+    private static final Locale JPTYO = Locale.forLanguageTag("en-u-tz-jptyo");
+    private static final Locale USLAX = Locale.forLanguageTag("en-u-tz-uslax");
+
+    private static final Locale FW_SUN = Locale.forLanguageTag("en-US-u-fw-sun");
+    private static final Locale FW_MON = Locale.forLanguageTag("en-US-u-fw-mon");
+    private static final Locale FW_TUE = Locale.forLanguageTag("en-US-u-fw-tue");
+    private static final Locale FW_WED = Locale.forLanguageTag("en-US-u-fw-wed");
+    private static final Locale FW_THU = Locale.forLanguageTag("en-US-u-fw-thu");
+    private static final Locale FW_FRI = Locale.forLanguageTag("en-US-u-fw-fri");
+    private static final Locale FW_SAT = Locale.forLanguageTag("en-US-u-fw-sat");
+
+    @BeforeTest
+    public void beforeTest() {
+        defaultTZ = TimeZone.getDefault();
+        TimeZone.setDefault(AMLA);
+    }
+
+    @AfterTest
+    public void afterTest() {
+        TimeZone.setDefault(defaultTZ);
+    }
+
+    @DataProvider(name="tz")
+    Object[][] tz() {
+        return new Object[][] {
+            // Locale, Expected Zone,
+            {JPTYO, ASIATOKYO},
+            {USLAX, AMLA},
+
+            // invalid
+            {Locale.forLanguageTag("en-US-u-tz-jpzzz"), AMLA}
+        };
+    }
+
+    @DataProvider(name="firstDayOfWeek")
+    Object[][] firstDayOfWeek () {
+        return new Object[][] {
+            // Locale, Expected DayOfWeek,
+            {Locale.US, Calendar.SUNDAY},
+            {FW_SUN, Calendar.SUNDAY},
+            {FW_MON, Calendar.MONDAY},
+            {FW_TUE, Calendar.TUESDAY},
+            {FW_WED, Calendar.WEDNESDAY},
+            {FW_THU, Calendar.THURSDAY},
+            {FW_FRI, Calendar.FRIDAY},
+            {FW_SAT, Calendar.SATURDAY},
+
+            // invalid case
+            {Locale.forLanguageTag("en-US-u-fw-xxx"), Calendar.SUNDAY},
+
+            // region override
+            {Locale.forLanguageTag("en-US-u-rg-gbzzzz"), Calendar.MONDAY},
+            {Locale.forLanguageTag("zh-CN-u-rg-eszzzz"), Calendar.MONDAY},
+
+            // "fw" and "rg".
+            {Locale.forLanguageTag("en-US-u-fw-wed-rg-gbzzzz"), Calendar.WEDNESDAY},
+            {Locale.forLanguageTag("en-US-u-fw-xxx-rg-gbzzzz"), Calendar.MONDAY},
+            {Locale.forLanguageTag("en-US-u-fw-xxx-rg-zzzz"), Calendar.SUNDAY},
+        };
+    }
+
+    @DataProvider(name="minDaysInFirstWeek")
+    Object[][] minDaysInFrstWeek () {
+        return new Object[][] {
+            // Locale, Expected minDay,
+            {Locale.US, 1},
+
+            // region override
+            {Locale.forLanguageTag("en-US-u-rg-gbzzzz"), 4},
+            {Locale.forLanguageTag("zh-CN-u-rg-eszzzz"), 4},
+        };
+    }
+
+    @Test(dataProvider="tz")
+    public void test_tz(Locale locale, TimeZone zoneExpected) {
+        DateFormat df = DateFormat.getTimeInstance(DateFormat.FULL, locale);
+        assertEquals(df.getTimeZone(), zoneExpected);
+
+        Calendar c = Calendar.getInstance(locale);
+        assertEquals(c.getTimeZone(), zoneExpected);
+
+        c = new Calendar.Builder().setLocale(locale).build();
+        assertEquals(c.getTimeZone(), zoneExpected);
+    }
+
+    @Test(dataProvider="firstDayOfWeek")
+    public void test_firstDayOfWeek(Locale locale, int dowExpected) {
+        Calendar c = Calendar.getInstance(locale);
+        assertEquals(c.getFirstDayOfWeek(), dowExpected);
+
+        c = new Calendar.Builder().setLocale(locale).build();
+        assertEquals(c.getFirstDayOfWeek(), dowExpected);
+    }
+
+    @Test(dataProvider="minDaysInFirstWeek")
+    public void test_minDaysInFirstWeek(Locale locale, int minDaysExpected) {
+        Calendar c = Calendar.getInstance(locale);
+        assertEquals(c.getMinimalDaysInFirstWeek(), minDaysExpected);
+
+        c = new Calendar.Builder().setLocale(locale).build();
+        assertEquals(c.getMinimalDaysInFirstWeek(), minDaysExpected);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/CurrencyTests.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,106 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ *
+ * @test
+ * @bug 8176841
+ * @summary Tests Currency class instantiates correctly with Unicode
+ *      extensions
+ * @modules jdk.localedata
+ * @run testng/othervm CurrencyTests
+ */
+
+import static org.testng.Assert.assertEquals;
+
+import java.util.Currency;
+import java.util.Locale;
+
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+/**
+ * Test Currency with BCP47 U extensions
+ */
+@Test
+public class CurrencyTests {
+    private static final Currency USD = Currency.getInstance("USD");
+    private static final Currency CAD = Currency.getInstance("CAD");
+    private static final Currency JPY = Currency.getInstance("JPY");
+
+    @DataProvider(name="getInstanceData")
+    Object[][] getInstanceData() {
+        return new Object[][] {
+            // Locale, Expected Currency
+            // "cu"
+            {Locale.forLanguageTag("en-US-u-cu-jpy"), JPY},
+            {Locale.forLanguageTag("ja-JP-u-cu-usd"), USD},
+            {Locale.forLanguageTag("en-US-u-cu-foobar"), USD},
+            {Locale.forLanguageTag("en-US-u-cu-zzz"), USD},
+
+            // "rg"
+            {Locale.forLanguageTag("en-US-u-rg-jpzzzz"), JPY},
+            {Locale.forLanguageTag("ja-JP-u-rg-uszzzz"), USD},
+            {Locale.forLanguageTag("ja-JP-u-rg-001zzzz"), JPY},
+            {Locale.forLanguageTag("en-US-u-rg-jpz"), USD},
+
+            // "cu" and "rg". "cu" should win
+            {Locale.forLanguageTag("en-CA-u-cu-jpy-rg-uszzzz"), JPY},
+
+            // invaid "cu" and valid "rg". "rg" should win
+            {Locale.forLanguageTag("en-CA-u-cu-jpyy-rg-uszzzz"), USD},
+            {Locale.forLanguageTag("en-CA-u-cu-zzz-rg-uszzzz"), USD},
+
+            // invaid "cu" and invalid "rg". both should be ignored
+            {Locale.forLanguageTag("en-CA-u-cu-jpyy-rg-jpzz"), CAD},
+        };
+    }
+
+    @DataProvider(name="getSymbolData")
+    Object[][] getSymbolData() {
+        return new Object[][] {
+            // Currency, DisplayLocale, expected Symbol
+            {USD, Locale.forLanguageTag("en-US-u-rg-jpzzzz"), "$"},
+            {USD, Locale.forLanguageTag("en-US-u-rg-cazzzz"), "US$"},
+            {USD, Locale.forLanguageTag("en-CA-u-rg-uszzzz"), "$"},
+
+            {CAD, Locale.forLanguageTag("en-US-u-rg-jpzzzz"), "CA$"},
+            {CAD, Locale.forLanguageTag("en-US-u-rg-cazzzz"), "$"},
+            {CAD, Locale.forLanguageTag("en-CA-u-rg-uszzzz"), "CA$"},
+
+            {JPY, Locale.forLanguageTag("ja-JP-u-rg-uszzzz"), "\uffe5"},
+            {JPY, Locale.forLanguageTag("en-US-u-rg-jpzzzz"), "\u00a5"},
+            {JPY, Locale.forLanguageTag("ko-KR-u-rg-jpzzzz"), "JP\u00a5"},
+        };
+    }
+
+    @Test(dataProvider="getInstanceData")
+    public void test_getInstance(Locale locale, Currency currencyExpected) {
+        assertEquals(Currency.getInstance(locale), currencyExpected);
+    }
+
+    @Test(dataProvider="getSymbolData")
+    public void test_getSymbol(Currency c, Locale locale, String expected) {
+        assertEquals(c.getSymbol(locale), expected);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/DefaultLocaleTest.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,46 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+import java.util.Locale;
+
+/*
+ * Test application that verifies default locales. Invoked from
+ * SystemPropertyTests
+ */
+public class DefaultLocaleTest {
+    public static void main(String... args) {
+        String defLoc = Locale.getDefault().toString();
+        String defFmtLoc = Locale.getDefault(Locale.Category.FORMAT).toString();
+        String defDspLoc = Locale.getDefault(Locale.Category.DISPLAY).toString();
+
+        if (!defLoc.equals(args[0]) ||
+            !defFmtLoc.equals(args[1]) ||
+            !defDspLoc.equals(args[2])) {
+            System.err.println("Some default locale(s) don't match.\n" +
+                "Default Locale expected: " + args[0] + ", result: " + defLoc + "\n" +
+                "Default Format Locale expected: " + args[1] + ", result: " + defFmtLoc + "\n" +
+                "Default Display Locale expected: " + args[2] + ", result: " + defDspLoc);
+            System.exit(-1);
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/DisplayNameTests.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,109 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ *
+ * @test
+ * @bug 8176841
+ * @summary Tests the display names for BCP 47 U extensions
+ * @modules jdk.localedata
+ * @run testng/othervm -Djava.locale.providers=CLDR DisplayNameTests
+ */
+
+import static org.testng.Assert.assertEquals;
+
+import java.util.Locale;
+
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+/**
+ * Test Locale.getDisplayName() with BCP47 U extensions. Note that the
+ * result may change depending on the CLDR releases.
+ */
+@Test
+public class DisplayNameTests {
+    private static final Locale loc1 = Locale.forLanguageTag("en-Latn-US-u" +
+                                                             "-ca-japanese" +
+                                                             "-cf-account" +
+                                                             "-co-pinyin" +
+                                                             "-cu-jpy" +
+                                                             "-em-emoji" +
+                                                             "-fw-wed" +
+                                                             "-hc-h23" +
+                                                             "-lb-loose" +
+                                                             "-lw-breakall" +
+                                                             "-ms-uksystem" +
+                                                             "-nu-roman" +
+                                                             "-rg-gbzzzz" +
+                                                             "-sd-gbsct" +
+                                                             "-ss-standard" +
+                                                             "-tz-jptyo" +
+                                                             "-va-posix");
+    private static final Locale loc2 = new Locale("ja", "JP", "JP");
+    private static final Locale loc3 = new Locale.Builder()
+                                            .setRegion("US")
+                                            .setScript("Latn")
+                                            .setUnicodeLocaleKeyword("ca", "japanese")
+                                            .build();
+    private static final Locale loc4 = new Locale.Builder()
+                                            .setRegion("US")
+                                            .setUnicodeLocaleKeyword("ca", "japanese")
+                                            .build();
+    private static final Locale loc5 = new Locale.Builder()
+                                            .setUnicodeLocaleKeyword("ca", "japanese")
+                                            .build();
+    private static final Locale loc6 = Locale.forLanguageTag( "zh-CN-u-ca-dddd-nu-ddd-cu-ddd-fw-moq-tz-unknown-rg-twzz");
+
+    @DataProvider(name="locales")
+    Object[][] tz() {
+        return new Object[][] {
+            // Locale for display, Test Locale, Expected output,
+            {Locale.US, loc1,
+            "English (Latin, United States, Japanese Calendar, Accounting Currency Format, Pinyin Sort Order, Currency: Japanese Yen, Prefer Emoji Presentation For Emoji Characters, First Day of Week Is Wednesday, 24 Hour System (0\u201323), Loose Line Break Style, Allow Line Breaks In All Words, Imperial Measurement System, Roman Numerals, Region For Supplemental Data: United Kingdom, Region Subdivision: gbsct, Suppress Sentence Breaks After Standard Abbreviations, Time Zone: Japan Time, POSIX Compliant Locale)"},
+            {Locale.JAPAN, loc1,
+            "\u82f1\u8a9e (\u30e9\u30c6\u30f3\u6587\u5b57\u3001\u30a2\u30e1\u30ea\u30ab\u5408\u8846\u56fd\u3001\u548c\u66a6\u3001cf: account\u3001\u30d4\u30f3\u30a4\u30f3\u9806\u3001\u901a\u8ca8: \u65e5\u672c\u5186\u3001em: emoji\u3001fw: wed\u300124\u6642\u9593\u5236(0\u301c23)\u3001\u7981\u5247\u51e6\u7406(\u5f31)\u3001lw: breakall\u3001\u30e4\u30fc\u30c9\u30fb\u30dd\u30f3\u30c9\u6cd5\u3001\u30ed\u30fc\u30de\u6570\u5b57\u3001rg: \u30a4\u30ae\u30ea\u30b9\u3001sd: gbsct\u3001ss: standard\u3001\u30bf\u30a4\u30e0\u30be\u30fc\u30f3: \u65e5\u672c\u6642\u9593\u3001\u30ed\u30b1\u30fc\u30eb\u306e\u30d0\u30ea\u30a2\u30f3\u30c8: posix)"},
+            {Locale.forLanguageTag("hi-IN"), loc1,
+            "\u0905\u0902\u0917\u094d\u0930\u0947\u091c\u093c\u0940 (\u0932\u0948\u091f\u093f\u0928, \u0938\u0902\u092f\u0941\u0915\u094d\u0924 \u0930\u093e\u091c\u094d\u092f, \u091c\u093e\u092a\u093e\u0928\u0940 \u092a\u0902\u091a\u093e\u0902\u0917, cf: account, \u092a\u093f\u0928\u092f\u0940\u0928 \u0935\u0930\u094d\u0917\u0940\u0915\u0930\u0923, \u092e\u0941\u0926\u094d\u0930\u093e: \u091c\u093e\u092a\u093e\u0928\u0940 \u092f\u0947\u0928, em: emoji, fw: wed, 24 \u0918\u0902\u091f\u094b\u0902 \u0915\u0940 \u092a\u094d\u0930\u0923\u093e\u0932\u0940 (0\u201323), \u0922\u0940\u0932\u0940 \u092a\u0902\u0915\u094d\u0924\u093f \u0935\u093f\u091a\u094d\u091b\u0947\u0926 \u0936\u0948\u0932\u0940, lw: breakall, \u0907\u092e\u094d\u092a\u0940\u0930\u093f\u092f\u0932 \u092e\u093e\u092a\u0928 \u092a\u094d\u0930\u0923\u093e\u0932\u0940, \u0930\u094b\u092e\u0928 \u0938\u0902\u0916\u094d\u092f\u093e\u090f\u0901, rg: \u092f\u0942\u0928\u093e\u0907\u091f\u0947\u0921 \u0915\u093f\u0902\u0917\u0921\u092e, sd: gbsct, ss: standard, \u0938\u092e\u092f \u0915\u094d\u0937\u0947\u0924\u094d\u0930: \u091c\u093e\u092a\u093e\u0928 \u0938\u092e\u092f, \u0938\u094d\u0925\u093e\u0928\u0940\u092f \u092a\u094d\u0930\u0915\u093e\u0930: posix)"},
+
+            // cases where no localized types are available. fall back to "key: type"
+            {Locale.US, Locale.forLanguageTag("en-u-ca-unknown"), "English (Calendar: unknown)"},
+
+            // cases with variant, w/o language, script
+            {Locale.US, loc2, "Japanese (Japan, JP, Japanese Calendar)"},
+            {Locale.US, loc3, "Latin (United States, Japanese Calendar)"},
+            {Locale.US, loc4, "United States (Japanese Calendar)"},
+            {Locale.US, loc5, ""},
+
+            // invalid cases
+            {loc6, loc6, "\u4e2d\u6587 (\u4e2d\u56fd\u3001\u65e5\u5386\uff1adddd\u3001\u8d27\u5e01\uff1addd\u3001fw\uff1amoq\u3001\u6570\u5b57\uff1addd\u3001rg\uff1atwzz\u3001\u65f6\u533a\uff1aunknown)"},
+            {Locale.US, loc6, "Chinese (China, Calendar: dddd, Currency: ddd, First day of week: moq, Numbers: ddd, Region For Supplemental Data: twzz, Time Zone: unknown)"},
+        };
+    }
+
+    @Test(dataProvider="locales")
+    public void test_locales(Locale inLocale, Locale testLocale, String expected) {
+        String result = testLocale.getDisplayName(inLocale);
+        assertEquals(result, expected);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/FormatTests.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,167 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ *
+ * @test
+ * @bug 8176841
+ * @summary Tests *Format class deals with Unicode extensions
+ *      correctly.
+ * @modules jdk.localedata
+ * @run testng/othervm -Djava.locale.providers=CLDR FormatTests
+ */
+
+import static org.testng.Assert.assertEquals;
+
+import java.text.DateFormat;
+import java.text.NumberFormat;
+import java.util.Calendar;
+import java.util.Date;
+import java.util.Locale;
+import java.util.TimeZone;
+
+import org.testng.annotations.AfterTest;
+import org.testng.annotations.BeforeTest;
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+/**
+ * Test *Format classes with BCP47 U extensions
+ */
+@Test
+public class FormatTests {
+    private static TimeZone defaultTZ;
+
+    private static final TimeZone ASIATOKYO = TimeZone.getTimeZone("Asia/Tokyo");
+    private static final TimeZone AMLA = TimeZone.getTimeZone("America/Los_Angeles");
+
+    private static final Locale JPTYO = Locale.forLanguageTag("en-u-tz-jptyo");
+    private static final Locale JCAL = Locale.forLanguageTag("en-u-ca-japanese");
+    private static final Locale USLAX = Locale.forLanguageTag("en-u-tz-uslax");
+
+    private static final Locale RG_GB = Locale.forLanguageTag("en-US-u-rg-gbzzzz");
+    private static final Locale RG_DE = Locale.forLanguageTag("en-US-u-rg-dezzzz");
+
+    private static final Locale NU_DEVA = Locale.forLanguageTag("en-US-u-nu-deva");
+    private static final Locale NU_SINH = Locale.forLanguageTag("en-US-u-nu-sinh");
+    private static final Locale NU_ZZZZ = Locale.forLanguageTag("en-US-u-nu-zzzz");
+
+    private static final double testNum = 12345.6789;
+    private static final String NUM_US = "12,345.6789";
+    private static final String NUM_DE = "12.345,6789";
+    private static final String NUM_DEVA = "\u0967\u0968,\u0969\u096a\u096b.\u096c\u096d\u096e\u096f";
+    private static final String NUM_SINH = "\u0de7\u0de8,\u0de9\u0dea\u0deb.\u0dec\u0ded\u0dee\u0def";
+
+    private static final Date testDate = new Calendar.Builder()
+                                        .setDate(2017, 7, 10)
+                                        .setTimeOfDay(15, 15, 0)
+                                        .setTimeZone(AMLA)
+                                        .build()
+                                        .getTime();
+
+    @BeforeTest
+    public void beforeTest() {
+        defaultTZ = TimeZone.getDefault();
+        TimeZone.setDefault(AMLA);
+    }
+
+    @AfterTest
+    public void afterTest() {
+        TimeZone.setDefault(defaultTZ);
+    }
+
+    @DataProvider(name="dateFormatData")
+    Object[][] dateFormatData() {
+        return new Object[][] {
+            // Locale, Expected calendar, Expected timezone, Expected formatted string
+
+            // -ca
+            {JCAL, "java.util.JapaneseImperialCalendar", null,
+            "Thursday, August 10, 29 Heisei at 3:15:00 PM Pacific Daylight Time"
+            },
+
+            // -tz
+            {JPTYO, null, ASIATOKYO,
+            "Friday, August 11, 2017 at 7:15:00 AM Japan Standard Time"
+            },
+            {USLAX, null, AMLA,
+            "Thursday, August 10, 2017 at 3:15:00 PM Pacific Daylight Time"
+            },
+
+            // -rg
+            {RG_GB, null, null,
+            "Thursday, 10 August 2017 at 15:15:00 Pacific Daylight Time"
+            },
+        };
+    }
+
+    @DataProvider(name="numberFormatData")
+    Object[][] numberFormatData() {
+        return new Object[][] {
+            // Locale, number, expected format
+
+            // -nu
+            {NU_DEVA, testNum, NUM_DEVA},
+            {NU_SINH, testNum, NUM_SINH},
+            {NU_ZZZZ, testNum, NUM_US},
+
+            // -rg
+            {RG_DE, testNum, NUM_DE},
+
+            // -nu & -rg, valid & invalid
+            {Locale.forLanguageTag("en-US-u-nu-deva-rg-dezzzz"), testNum, NUM_DEVA},
+            {Locale.forLanguageTag("en-US-u-nu-zzzz-rg-dezzzz"), testNum, NUM_US},
+            {Locale.forLanguageTag("en-US-u-nu-zzzz-rg-zzzz"), testNum, NUM_US},
+        };
+    }
+
+    @Test(dataProvider="dateFormatData")
+    public void test_DateFormat(Locale locale, String calClass, TimeZone tz,
+                                String formatExpected) throws Exception {
+        DateFormat df = DateFormat.getDateTimeInstance(DateFormat.FULL, DateFormat.FULL, locale);
+        if (calClass != null) {
+            try {
+                Class expected = Class.forName(calClass);
+            assertEquals(df.getCalendar().getClass(), expected);
+            } catch (Exception e) {
+                throw e;
+            }
+        }
+        if (tz != null) {
+            assertEquals(df.getTimeZone(), tz);
+        }
+        String formatted = df.format(testDate);
+        assertEquals(formatted, formatExpected);
+        assertEquals(df.parse(formatted), testDate);
+    }
+
+    @Test(dataProvider="numberFormatData")
+    public void test_NumberFormat(Locale locale, double num,
+                                String formatExpected) throws Exception {
+        NumberFormat nf = NumberFormat.getNumberInstance(locale);
+        nf.setMaximumFractionDigits(4);
+        String formatted = nf.format(num);
+        assertEquals(nf.format(num), formatExpected);
+        assertEquals(nf.parse(formatted), num);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/SymbolsTests.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,91 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ *
+ * @test
+ * @bug 8176841
+ * @summary Tests *FormatSymbols class deals with Unicode extensions
+ *      correctly.
+ * @modules jdk.localedata
+ * @run testng/othervm -Djava.locale.providers=CLDR FormatTests
+ */
+
+import static org.testng.Assert.assertEquals;
+
+import java.text.DateFormatSymbols;
+import java.text.DecimalFormatSymbols;
+import java.util.Locale;
+
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+/**
+ * Test *FormatSymbols classes with BCP47 U extensions
+ */
+@Test
+public class SymbolsTests {
+
+    private static final Locale RG_GB = Locale.forLanguageTag("en-US-u-rg-gbzzzz");
+    private static final Locale RG_IE = Locale.forLanguageTag("en-US-u-rg-iezzzz");
+    private static final Locale RG_AT = Locale.forLanguageTag("en-US-u-rg-atzzzz");
+
+    @DataProvider(name="dateFormatSymbolsData")
+    Object[][] dateFormatSymbolsData() {
+        return new Object[][] {
+            // Locale, expected AM string, expected PM string
+
+            {RG_GB, "am", "pm"},
+            {RG_IE, "a.m.", "p.m."},
+            {Locale.US, "AM", "PM"},
+        };
+    }
+
+    @DataProvider(name="decimalFormatSymbolsData")
+    Object[][] decimalFormatSymbolsData() {
+        return new Object[][] {
+            // Locale, expected decimal separator, expected grouping separator
+
+            {RG_AT, ",", "."},
+            {Locale.US, ".", ","},
+
+            // -nu & -rg mixed. -nu should win
+            {Locale.forLanguageTag("ar-EG-u-nu-latn-rg-mazzzz"), ".", ","},
+        };
+    }
+
+    @Test(dataProvider="dateFormatSymbolsData")
+    public void test_DateFormatSymbols(Locale locale, String amExpected, String pmExpected) {
+        DateFormatSymbols dfs = DateFormatSymbols.getInstance(locale);
+        String[] ampm = dfs.getAmPmStrings();
+        assertEquals(ampm[0], amExpected);
+        assertEquals(ampm[1], pmExpected);
+    }
+
+    @Test(dataProvider="decimalFormatSymbolsData")
+    public void test_DecimalFormatSymbols(Locale locale, char decimal, char grouping) {
+        DecimalFormatSymbols dfs = DecimalFormatSymbols.getInstance(locale);
+        assertEquals(dfs.getDecimalSeparator(), decimal);
+        assertEquals(dfs.getGroupingSeparator(), grouping);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/SystemPropertyTests.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,99 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @library /lib/testlibrary
+ * @bug 8189134
+ * @summary Tests the system properties
+ * @modules jdk.localedata
+ * @build DefaultLocaleTest jdk.testlibrary.*
+ * @run testng/othervm SystemPropertyTests
+ */
+
+import static jdk.testlibrary.ProcessTools.executeTestJava;
+import static org.testng.Assert.assertTrue;
+
+import java.util.Locale;
+
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+/**
+ * Test Locale.getDefault() reflects the system property. Note that the
+ * result may change depending on the CLDR releases.
+ */
+@Test
+public class SystemPropertyTests {
+
+    private static String LANGPROP = "-Duser.language=en";
+    private static String CTRYPROP = "-Duser.country=US";
+
+    @DataProvider(name="data")
+    Object[][] data() {
+        return new Object[][] {
+            // system property, expected default, expected format, expected display
+            {"-Duser.extensions=u-ca-japanese",
+             "en_US_#u-ca-japanese",
+             "en_US_#u-ca-japanese",
+             "en_US_#u-ca-japanese",
+            },
+
+            {"-Duser.extensions=u-ca-japanese-nu-thai",
+             "en_US_#u-ca-japanese-nu-thai",
+             "en_US_#u-ca-japanese-nu-thai",
+             "en_US_#u-ca-japanese-nu-thai",
+            },
+
+            {"-Duser.extensions=foo",
+             "en_US",
+             "en_US",
+             "en_US",
+            },
+
+            {"-Duser.extensions.format=u-ca-japanese",
+             "en_US",
+             "en_US_#u-ca-japanese",
+             "en_US",
+            },
+
+            {"-Duser.extensions.display=u-ca-japanese",
+             "en_US",
+             "en_US",
+             "en_US_#u-ca-japanese",
+            },
+        };
+    }
+
+    @Test(dataProvider="data")
+    public void runTest(String extprop, String defLoc,
+                        String defFmtLoc, String defDspLoc) throws Exception {
+        int exitValue = executeTestJava(LANGPROP, CTRYPROP,
+                                    extprop, "DefaultLocaleTest", defLoc, defFmtLoc, defDspLoc)
+                            .outputTo(System.out)
+                            .errorTo(System.out)
+                            .getExitValue();
+
+        assertTrue(exitValue == 0);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/spi/LocaleNameProviderTests.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,52 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ *
+ * @test
+ * @bug 8176841
+ * @summary Tests LocaleNameProvider SPIs
+ * @library provider
+ * @build provider/module-info provider/foo.LocaleNameProviderImpl
+ * @run main/othervm -Djava.locale.providers=SPI LocaleNameProviderTests
+ */
+
+import java.util.Locale;
+
+/**
+ * Test LocaleNameProvider SPI with BCP47 U extensions
+ *
+ * Verifies getUnicodeExtensionKey() and getUnicodeExtensionType() methods in
+ * LocaleNameProvider works.
+ */
+public class LocaleNameProviderTests {
+    private static final String expected = "foo (foo_ca:foo_japanese)";
+
+    public static void main(String... args) {
+        String name = Locale.forLanguageTag("foo-u-ca-japanese").getDisplayName(new Locale("foo"));
+        if (!name.equals(expected)) {
+            throw new RuntimeException("Unicode extension key and/or type name(s) is incorrect. " +
+                "Expected: \"" + expected + "\", got: \"" + name + "\"");
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/spi/provider/foo/LocaleNameProviderImpl.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package foo;
+
+import java.util.Locale;
+import java.util.spi.LocaleNameProvider;
+
+/*
+ * Implements LocaleNameProvider SPI, augmenting the default
+ * values for Unicode Locale Extension key/type names.
+ */
+public class LocaleNameProviderImpl extends LocaleNameProvider {
+    private static final Locale[] avail = {new Locale("foo")};
+
+    @Override
+    public Locale[] getAvailableLocales() {
+        return avail;
+    }
+
+    @Override
+    public String getDisplayLanguage(String lang, Locale target) {
+        return null;
+    }
+
+    @Override
+    public String getDisplayCountry(String ctry, Locale target) {
+        return null;
+    }
+
+    @Override
+    public String getDisplayVariant(String vrnt, Locale target) {
+        return null;
+    }
+
+    @Override
+    public String getDisplayUnicodeExtensionKey(String key, Locale target) {
+        return "foo_" + key;
+    }
+
+    @Override
+    public String getDisplayUnicodeExtensionType(String extType, String key, Locale target) {
+        return "foo_" + key + ":foo_" + extType;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/jdk/java/util/Locale/bcp47u/spi/provider/module-info.java	Tue Dec 12 10:21:58 2017 -0800
@@ -0,0 +1,27 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+module provider {
+    exports foo;
+    provides java.util.spi.LocaleNameProvider with foo.LocaleNameProviderImpl;
+}
--- a/test/jdk/sun/text/resources/LocaleData.cldr	Tue Dec 12 09:33:37 2017 -0800
+++ b/test/jdk/sun/text/resources/LocaleData.cldr	Tue Dec 12 10:21:58 2017 -0800
@@ -34,8 +34,8 @@
 FormatData/pt_BR/DayNames/0=domingo
 FormatData/pt_BR/DayNames/1=segunda-feira
 FormatData/pt_BR/DayNames/2=ter\u00e7a-feira
-CalendarData/pt_BR/firstDayOfWeek=1
-CalendarData/pt_BR/minimalDaysInFirstWeek=1
+CalendarData/pt_BR/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/pt_BR/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/pt_BR/MonthNames/0=janeiro
 FormatData/pt_BR/MonthNames/1=fevereiro
 FormatData/pt_BR/MonthNames/2=mar\u00e7o
@@ -189,8 +189,8 @@
 FormatData/pl_PL/MonthAbbreviations/10=lis
 FormatData/pl_PL/MonthAbbreviations/11=gru
 FormatData/pl_PL/MonthAbbreviations/12=
-CalendarData/pl_PL/firstDayOfWeek=2
-CalendarData/pl_PL/minimalDaysInFirstWeek=4
+CalendarData/pl_PL/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/pl_PL/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/pl_PL/AmPmMarkers/0=AM
 FormatData/pl_PL/AmPmMarkers/1=PM
 
@@ -320,8 +320,8 @@
 FormatData/ru_RU/DayAbbreviations/6=\u0441\u0431
 FormatData/ru_RU/AmPmMarkers/0=\u0414\u041f
 FormatData/ru_RU/AmPmMarkers/1=\u041f\u041f
-CalendarData/ru_RU/firstDayOfWeek=2
-CalendarData/ru_RU/minimalDaysInFirstWeek=1
+CalendarData/ru_RU/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ru_RU/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 
 # bug #4094371, 4098518, 4290801, 6558863
 FormatData/en_AU/TimePatterns/0=h:mm:ss a zzzz
@@ -745,8 +745,8 @@
 FormatData/ar_AE/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_AE/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_AE/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_AE/firstDayOfWeek=7
-CalendarData/ar_AE/minimalDaysInFirstWeek=1
+CalendarData/ar_AE/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_AE/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_AE/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_AE/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_AE/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -833,8 +833,8 @@
 FormatData/ar_BH/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_BH/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_BH/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_BH/firstDayOfWeek=7
-CalendarData/ar_BH/minimalDaysInFirstWeek=1
+CalendarData/ar_BH/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_BH/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_BH/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_BH/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_BH/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -921,8 +921,8 @@
 FormatData/ar_DZ/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_DZ/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_DZ/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_DZ/firstDayOfWeek=7
-CalendarData/ar_DZ/minimalDaysInFirstWeek=1
+CalendarData/ar_DZ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_DZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_DZ/MonthAbbreviations/0=\u062c\u0627\u0646\u0641\u064a
 FormatData/ar_DZ/MonthAbbreviations/1=\u0641\u064a\u0641\u0631\u064a
 FormatData/ar_DZ/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1009,8 +1009,8 @@
 FormatData/ar_EG/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_EG/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_EG/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_EG/firstDayOfWeek=7
-CalendarData/ar_EG/minimalDaysInFirstWeek=1
+CalendarData/ar_EG/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_EG/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_EG/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_EG/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_EG/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1097,8 +1097,8 @@
 FormatData/ar_IQ/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_IQ/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_IQ/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_IQ/firstDayOfWeek=7
-CalendarData/ar_IQ/minimalDaysInFirstWeek=1
+CalendarData/ar_IQ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_IQ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_IQ/MonthAbbreviations/0=\u0643\u0627\u0646\u0648\u0646 \u0627\u0644\u062b\u0627\u0646\u064a
 FormatData/ar_IQ/MonthAbbreviations/1=\u0634\u0628\u0627\u0637
 FormatData/ar_IQ/MonthAbbreviations/2=\u0622\u0630\u0627\u0631
@@ -1218,8 +1218,8 @@
 FormatData/ar_JO/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_JO/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_JO/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_JO/firstDayOfWeek=7
-CalendarData/ar_JO/minimalDaysInFirstWeek=1
+CalendarData/ar_JO/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_JO/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_JO/Eras/0=\u0642.\u0645
 FormatData/ar_JO/Eras/1=\u0645
 LocaleNames/ar_JO/ar=\u0627\u0644\u0639\u0631\u0628\u064a\u0629
@@ -1273,8 +1273,8 @@
 FormatData/ar_KW/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_KW/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_KW/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_KW/firstDayOfWeek=7
-CalendarData/ar_KW/minimalDaysInFirstWeek=1
+CalendarData/ar_KW/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_KW/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_KW/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_KW/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_KW/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1394,8 +1394,8 @@
 FormatData/ar_LB/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_LB/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_LB/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_LB/firstDayOfWeek=2
-CalendarData/ar_LB/minimalDaysInFirstWeek=1
+CalendarData/ar_LB/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_LB/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_LB/Eras/0=\u0642.\u0645
 FormatData/ar_LB/Eras/1=\u0645
 LocaleNames/ar_LB/ar=\u0627\u0644\u0639\u0631\u0628\u064a\u0629
@@ -1449,8 +1449,8 @@
 FormatData/ar_LY/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_LY/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_LY/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_LY/firstDayOfWeek=7
-CalendarData/ar_LY/minimalDaysInFirstWeek=1
+CalendarData/ar_LY/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_LY/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_LY/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_LY/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_LY/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1537,8 +1537,8 @@
 FormatData/ar_MA/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_MA/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_MA/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_MA/firstDayOfWeek=7
-CalendarData/ar_MA/minimalDaysInFirstWeek=1
+CalendarData/ar_MA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_MA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_MA/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_MA/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_MA/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1625,8 +1625,8 @@
 FormatData/ar_OM/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_OM/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_OM/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_OM/firstDayOfWeek=7
-CalendarData/ar_OM/minimalDaysInFirstWeek=1
+CalendarData/ar_OM/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_OM/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_OM/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_OM/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_OM/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1713,8 +1713,8 @@
 FormatData/ar_QA/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_QA/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_QA/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_QA/firstDayOfWeek=7
-CalendarData/ar_QA/minimalDaysInFirstWeek=1
+CalendarData/ar_QA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_QA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_QA/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_QA/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_QA/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1801,8 +1801,8 @@
 FormatData/ar_SA/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_SA/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_SA/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_SA/firstDayOfWeek=1
-CalendarData/ar_SA/minimalDaysInFirstWeek=1
+CalendarData/ar_SA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_SA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_SA/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_SA/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_SA/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -1890,8 +1890,8 @@
 FormatData/ar_SD/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_SD/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_SD/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_SD/firstDayOfWeek=7
-CalendarData/ar_SD/minimalDaysInFirstWeek=1
+CalendarData/ar_SD/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_SD/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_SD/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_SD/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_SD/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -2011,8 +2011,8 @@
 FormatData/ar_SY/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_SY/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_SY/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_SY/firstDayOfWeek=7
-CalendarData/ar_SY/minimalDaysInFirstWeek=1
+CalendarData/ar_SY/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_SY/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_SY/Eras/0=\u0642.\u0645
 FormatData/ar_SY/Eras/1=\u0645
 LocaleNames/ar_SY/ar=\u0627\u0644\u0639\u0631\u0628\u064a\u0629
@@ -2066,8 +2066,8 @@
 FormatData/ar_TN/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_TN/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_TN/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_TN/firstDayOfWeek=1
-CalendarData/ar_TN/minimalDaysInFirstWeek=1
+CalendarData/ar_TN/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_TN/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_TN/MonthAbbreviations/0=\u062c\u0627\u0646\u0641\u064a
 FormatData/ar_TN/MonthAbbreviations/1=\u0641\u064a\u0641\u0631\u064a
 FormatData/ar_TN/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -2154,8 +2154,8 @@
 FormatData/ar_YE/DayNames/4=\u0627\u0644\u062e\u0645\u064a\u0633
 FormatData/ar_YE/DayNames/5=\u0627\u0644\u062c\u0645\u0639\u0629
 FormatData/ar_YE/DayNames/6=\u0627\u0644\u0633\u0628\u062a
-CalendarData/ar_YE/firstDayOfWeek=1
-CalendarData/ar_YE/minimalDaysInFirstWeek=1
+CalendarData/ar_YE/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/ar_YE/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/ar_YE/MonthAbbreviations/0=\u064a\u0646\u0627\u064a\u0631
 FormatData/ar_YE/MonthAbbreviations/1=\u0641\u0628\u0631\u0627\u064a\u0631
 FormatData/ar_YE/MonthAbbreviations/2=\u0645\u0627\u0631\u0633
@@ -2341,9 +2341,9 @@
 FormatData/fr_FR/MonthAbbreviations/10=nov.
 FormatData/fr_FR/MonthAbbreviations/11=d\u00e9c.
 FormatData/fr_FR/MonthAbbreviations/12=
-CalendarData/fr_FR/firstDayOfWeek=2
+CalendarData/fr_FR/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
 # next line changed according the 4518811 bug
-CalendarData/fr_FR/minimalDaysInFirstWeek=4
+CalendarData/fr_FR/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 FormatData/fr_FR/AmPmMarkers/0=AM
 FormatData/fr_FR/AmPmMarkers/1=PM
 
@@ -2488,19 +2488,19 @@
 LocaleNames/ru_RU/MM=\u041c\u044c\u044f\u043d\u043c\u0430 (\u0411\u0438\u0440\u043c\u0430)
 
 #bug 4518811
-CalendarData/ca_ES/minimalDaysInFirstWeek=4
-CalendarData/cs_CZ/minimalDaysInFirstWeek=4
-CalendarData/da_DK/minimalDaysInFirstWeek=4
-CalendarData/de_AT/minimalDaysInFirstWeek=4
-CalendarData/el_GR/minimalDaysInFirstWeek=4
-CalendarData/en_IE/minimalDaysInFirstWeek=4
-CalendarData/es_ES/minimalDaysInFirstWeek=4
-CalendarData/et_EE/minimalDaysInFirstWeek=4
-CalendarData/fi_FI/minimalDaysInFirstWeek=4
-CalendarData/is_IS/minimalDaysInFirstWeek=4
-CalendarData/lt_LT/minimalDaysInFirstWeek=4
-CalendarData/pl_PL/minimalDaysInFirstWeek=4
-CalendarData/pt_PT/minimalDaysInFirstWeek=4
+CalendarData/ca_ES/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/cs_CZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/da_DK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/de_AT/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/el_GR/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/en_IE/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/es_ES/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/et_EE/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/fi_FI/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/is_IS/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/lt_LT/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/pl_PL/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/pt_PT/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 
 #bug 4945388
 CurrencyNames/be_BY/BYR=\u0440.
@@ -2523,7 +2523,7 @@
 LocaleNames/zh/tw=\u7279\u5a01\u6587
 
 #bug 6277020
-CalendarData/ca_ES/firstDayOfWeek=2
+CalendarData/ca_ES/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
 
 #bug 6277696
 #zh_SG, id, id_ID, en_MT, mt_MT, en_PH, el, el_CY, ms, ms_MY
@@ -3324,7 +3324,7 @@
 LocaleNames/el_CY/ZW=\u0396\u03b9\u03bc\u03c0\u03ac\u03bc\u03c0\u03bf\u03c5\u03b5
 #CurrencyNames/el_CY/CYP=<MISSING!>
 CurrencyNames/el_CY/EUR=\u20ac
-CalendarData/el_CY/minimalDaysInFirstWeek=1
+CalendarData/el_CY/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 
 #ms_MY and ms
 FormatData/ms_MY/NumberPatterns/0=#,##0.###
@@ -3538,7 +3538,7 @@
 LocaleNames/es_US/TT=Trinidad y Tobago
 LocaleNames/es_US/VI=Islas V\u00edrgenes de EE. UU.
 CurrencyNames/es_US/USD=$
-CalendarData/es_US/firstDayOfWeek=1
+CalendarData/es_US/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
 #bug 4400849
 LocaleNames/pt/aa=afar
 LocaleNames/pt/ab=abc\u00e1zio
@@ -5389,13 +5389,13 @@
 FormatData/mt/AmPmMarkers/1=PM
 FormatData/mt/DatePatterns/0=EEEE, d 'ta'\u2019 MMMM y
 # bug# 6483191
-CalendarData/ga_IE/firstDayOfWeek=1
-CalendarData/en_PH/firstDayOfWeek=1
-CalendarData/en_SG/firstDayOfWeek=1
-CalendarData/zh_SG/firstDayOfWeek=1
-CalendarData/mt_MT/firstDayOfWeek=1
-CalendarData/en_MT/firstDayOfWeek=1
-CalendarData/es_US/firstDayOfWeek=1
+CalendarData/ga_IE/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/en_PH/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/en_SG/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh_SG/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/mt_MT/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/en_MT/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/es_US/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
 #CalendarData/es_CY/firstDayOfWeek=<MISSING!>
 #CalendarData/in_ID/firstDayOfWeek=<MISSING!>
 #CalendarData/ms_MY/firstDayOfWeek=<MISSING!>
@@ -6122,14 +6122,14 @@
 
 # bug 6998391
 #CalendarData/sr-Latn/firstDayOfWeek=<MISSING!>
-CalendarData/sr-Latn-BA/firstDayOfWeek=2
-CalendarData/sr-Latn-ME/firstDayOfWeek=2
-CalendarData/sr-Latn-RS/firstDayOfWeek=2
+CalendarData/sr-Latn-BA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr-Latn-ME/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr-Latn-RS/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
 #
 #CalendarData/sr-Latn/minimalDaysInFirstWeek=<MISSING!>
-CalendarData/sr-Latn-BA/minimalDaysInFirstWeek=1
-CalendarData/sr-Latn-ME/minimalDaysInFirstWeek=1
-CalendarData/sr-Latn-RS/minimalDaysInFirstWeek=1
+CalendarData/sr-Latn-BA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr-Latn-ME/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr-Latn-RS/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
 #
 LocaleNames/sr-Latn/SR=Surinam
 LocaleNames/sr-Latn-BA/SR=Surinam
@@ -8303,79 +8303,79 @@
 
 # bug #8185841
 
-CalendarData/az-Latn-AZ/firstDayOfWeek=2
-CalendarData/az-Latn-AZ/minimalDaysInFirstWeek=1
-CalendarData/az-Cyrl-AZ/firstDayOfWeek=2
-CalendarData/az-Cyrl-AZ/minimalDaysInFirstWeek=1
-CalendarData/az_AZ/firstDayOfWeek=2
-CalendarData/az-AZ/minimalDaysInFirstWeek=1
-CalendarData/bs-Cyrl-BA/firstDayOfWeek=2
-CalendarData/bs-Cyrl-BA/minimalDaysInFirstWeek=1
-CalendarData/bs_BA/firstDayOfWeek=2
-CalendarData/bs_BA/minimalDaysInFirstWeek=1
-CalendarData/pa-Arab-PK/firstDayOfWeek=1
-CalendarData/pa-Arab-PK/minimalDaysInFirstWeek=1
-CalendarData/pa_PK/firstDayOfWeek=1
-CalendarData/pa_PK/minimalDaysInFirstWeek=1
-CalendarData/pa-Guru-IN/firstDayOfWeek=1
-CalendarData/pa-Guru-IN/minimalDaysInFirstWeek=1
-CalendarData/pa_IN/firstDayOfWeek=1
-CalendarData/pa_IN/minimalDaysInFirstWeek=1
-CalendarData/shi-Latn-MA/firstDayOfWeek=7
-CalendarData/shi-Latn-MA/minimalDaysInFirstWeek=1
-CalendarData/shi-Tfng-MA/firstDayOfWeek=7
-CalendarData/shi-Tfng-MA/minimalDaysInFirstWeek=1
-CalendarData/shi_MA/firstDayOfWeek=7
-CalendarData/shi_MA/minimalDaysInFirstWeek=1
-CalendarData/sr-Cyrl-BA/firstDayOfWeek=2
-CalendarData/sr-Cyrl-BA/minimalDaysInFirstWeek=1
-CalendarData/sr-Cyrl-ME/firstDayOfWeek=2
-CalendarData/sr-Cyrl-ME/minimalDaysInFirstWeek=1
-CalendarData/sr-Cyrl-RS/firstDayOfWeek=2
-CalendarData/sr-Cyrl-RS/minimalDaysInFirstWeek=1
-CalendarData/sr-Cyrl-XK/firstDayOfWeek=2
-CalendarData/sr-Cyrl-XK/minimalDaysInFirstWeek=1
-CalendarData/sr_RS/firstDayOfWeek=2
-CalendarData/sr_RS/minimalDaysInFirstWeek=1
-CalendarData/sr_BA/firstDayOfWeek=2
-CalendarData/sr_BA/minimalDaysInFirstWeek=1
-CalendarData/sr_ME/firstDayOfWeek=2
-CalendarData/sr_ME/minimalDaysInFirstWeek=1
-CalendarData/sr_XK/firstDayOfWeek=2
-CalendarData/sr_XK/minimalDaysInFirstWeek=1
-CalendarData/uz-Arab-AF/firstDayOfWeek=7
-CalendarData/uz-Arab-AF/minimalDaysInFirstWeek=1
-CalendarData/uz-Cyrl-UZ/firstDayOfWeek=2
-CalendarData/uz-Cyrl-UZ/minimalDaysInFirstWeek=1
-CalendarData/uz-Latn-UZ/firstDayOfWeek=2
-CalendarData/uz-Latn-UZ/minimalDaysInFirstWeek=1
-CalendarData/vai-Latn-LR/firstDayOfWeek=2
-CalendarData/vai-Latn-LR/minimalDaysInFirstWeek=1
-CalendarData/vai-Vaii-LR/firstDayOfWeek=2
-CalendarData/vai-Vaii-LR/minimalDaysInFirstWeek=1
-CalendarData/vai_LR/firstDayOfWeek=2
-CalendarData/vai_LR/minimalDaysInFirstWeek=1
-CalendarData/uz_UZ/firstDayOfWeek=2
-CalendarData/uz_UZ/minimalDaysInFirstWeek=1
-CalendarData/zh_CN/firstDayOfWeek=1
-CalendarData/zh_CN/minimalDaysInFirstWeek=1
-CalendarData/zh-Hans-CN/minimalDaysInFirstWeek=1
-CalendarData/zh-Hans-CN/firstDayOfWeek=1
-CalendarData/zh-Hans-HK/firstDayOfWeek=1
-CalendarData/zh-Hans-HK/minimalDaysInFirstWeek=1
-CalendarData/zh-Hans-MO/minimalDaysInFirstWeek=1
-CalendarData/zh-Hans-MO/firstDayOfWeek=1
-CalendarData/zh-Hans-SG/firstDayOfWeek=1
-CalendarData/zh-Hans-SG/minimalDaysInFirstWeek=1
-CalendarData/zh-Hant-HK/minimalDaysInFirstWeek=1
-CalendarData/zh-Hant-HK/firstDayOfWeek=1
-CalendarData/zh-Hant-TW/minimalDaysInFirstWeek=1
-CalendarData/zh-Hant-TW/firstDayOfWeek=1
-CalendarData/zh_HK/minimalDaysInFirstWeek=1
-CalendarData/zh_HK/firstDayOfWeek=1
-CalendarData/zh_MO/minimalDaysInFirstWeek=1
-CalendarData/zh_MO/firstDayOfWeek=1
-CalendarData/zh_SG/minimalDaysInFirstWeek=1
-CalendarData/zh_SG/firstDayOfWeek=1
-CalendarData/zh_TW/firstDayOfWeek=1
-CalendarData/zh_TW/minimalDaysInFirstWeek=1
+CalendarData/az-Latn-AZ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/az-Latn-AZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/az-Cyrl-AZ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/az-Cyrl-AZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/az_AZ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/az-AZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/bs-Cyrl-BA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/bs-Cyrl-BA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/bs_BA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/bs_BA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/pa-Arab-PK/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/pa-Arab-PK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/pa_PK/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/pa_PK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/pa-Guru-IN/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/pa-Guru-IN/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/pa_IN/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/pa_IN/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/shi-Latn-MA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/shi-Latn-MA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/shi-Tfng-MA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/shi-Tfng-MA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/shi_MA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/shi_MA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr-Cyrl-BA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr-Cyrl-BA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr-Cyrl-ME/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr-Cyrl-ME/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr-Cyrl-RS/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr-Cyrl-RS/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr-Cyrl-XK/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr-Cyrl-XK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr_RS/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr_RS/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr_BA/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr_BA/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr_ME/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr_ME/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/sr_XK/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/sr_XK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/uz-Arab-AF/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/uz-Arab-AF/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/uz-Cyrl-UZ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/uz-Cyrl-UZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/uz-Latn-UZ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/uz-Latn-UZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/vai-Latn-LR/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/vai-Latn-LR/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/vai-Vaii-LR/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/vai-Vaii-LR/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/vai_LR/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/vai_LR/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/uz_UZ/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/uz_UZ/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh_CN/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh_CN/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh-Hans-CN/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh-Hans-CN/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh-Hans-HK/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh-Hans-HK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh-Hans-MO/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh-Hans-MO/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh-Hans-SG/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh-Hans-SG/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh-Hant-HK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh-Hant-HK/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh-Hant-TW/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh-Hant-TW/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh_HK/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh_HK/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh_MO/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh_MO/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh_SG/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
+CalendarData/zh_SG/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh_TW/firstDayOfWeek=1: AG AR AS AU BR BS BT BW BZ CA CN CO DM DO ET GT GU HK HN ID IE IL IN JM JP KE KH KR LA MH MM MO MT MX MZ NI NP NZ PA PE PH PK PR PY SA SG SV TH TN TT TW UM US VE VI WS YE ZA ZW;2: 001 AD AI AL AM AN AT AX AZ BA BE BG BM BN BY CH CL CM CR CY CZ DE DK EC EE ES FI FJ FO FR GB GE GF GP GR HR HU IS IT KG KZ LB LI LK LT LU LV MC MD ME MK MN MQ MY NL NO PL PT RE RO RS RU SE SI SK SM TJ TM TR UA UY UZ VA VN XK;6: BD MV;7: AE AF BH DJ DZ EG IQ IR JO KW LY MA OM QA SD SY
+CalendarData/zh_TW/minimalDaysInFirstWeek=1: 001 GU UM US VI;4: AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GG GI GP GR HU IE IM IS IT JE LI LT LU MC MQ NL NO PL PT RE SE SJ SK SM VA
--- a/test/jdk/sun/text/resources/LocaleDataTest.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/test/jdk/sun/text/resources/LocaleDataTest.java	Tue Dec 12 10:21:58 2017 -0800
@@ -37,7 +37,7 @@
  *      7003124 7085757 7028073 7171028 7189611 8000983 7195759 8004489 8006509
  *      7114053 7074882 7040556 8008577 8013836 8021121 6192407 6931564 8027695
  *      8017142 8037343 8055222 8042126 8074791 8075173 8080774 8129361 8134916
- *      8145136 8145952 8164784 8037111 8081643 7037368 8178872 8185841
+ *      8145136 8145952 8164784 8037111 8081643 7037368 8178872 8185841 8190918
  * @summary Verify locale data
  * @modules java.base/sun.util.resources
  * @modules jdk.localedata
--- a/test/jdk/tools/jlink/plugins/IncludeLocalesPluginTest.java	Tue Dec 12 09:33:37 2017 -0800
+++ b/test/jdk/tools/jlink/plugins/IncludeLocalesPluginTest.java	Tue Dec 12 10:21:58 2017 -0800
@@ -40,7 +40,7 @@
 
 /*
  * @test
- * @bug 8152143 8152704 8155649 8165804 8185841
+ * @bug 8152143 8152704 8155649 8165804 8185841 8176841 8190918
  * @summary IncludeLocalesPlugin tests
  * @author Naoto Sato
  * @library ../../lib
@@ -70,6 +70,14 @@
     private static int errors;
 
     private final static Object[][] testData = {
+        // Test data should include:
+        //  - --include-locales command line option
+        //  - --add-modules command line option values
+        //  - List of required resources in the result image
+        //  - List of resources that should not exist in the result image
+        //  - List of available locales in the result image
+        //  - Error message
+
         // without --include-locales option: should include all locales
         {
             "",
@@ -227,11 +235,8 @@
             List.of(
                 "/jdk.localedata/sun/text/resources/ext/FormatData_en_IN.class",
                 "/jdk.localedata/sun/text/resources/ext/FormatData_hi_IN.class",
-                "/jdk.localedata/sun/util/resources/cldr/ext/CalendarData_as_IN.class",
                 "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_en_001.class",
-                "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_en_IN.class",
-                "/jdk.localedata/sun/util/resources/cldr/ext/CalendarData_kok_IN.class",
-                "/jdk.localedata/sun/util/resources/cldr/ext/CalendarData_pa_IN.class"),
+                "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_en_IN.class"),
             List.of(
                 "/jdk.localedata/sun/text/resources/ext/LineBreakIteratorData_th",
                 "/jdk.localedata/sun/text/resources/ext/thai_dict",
@@ -242,6 +247,7 @@
                 "/jdk.localedata/sun/text/resources/ext/FormatData_ja.class",
                 "/jdk.localedata/sun/text/resources/ext/FormatData_th.class",
                 "/jdk.localedata/sun/text/resources/ext/FormatData_zh.class",
+                "/jdk.localedata/sun/util/resources/cldr/ext/CalendarData_as_IN.class",
                 "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_ja.class",
                 "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_th.class",
                 "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_zh.class"),
@@ -327,7 +333,7 @@
                 "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_th.class"),
             List.of(
                 "(root)", "en", "en_US", "en_US_POSIX", "zh", "zh__#Hans", "zh_CN",
-                "zh_HK", "zh_MO", "zh_CN_#Hans", "zh_HK_#Hans", "zh_MO_#Hans", "zh_SG", "zh_SG_#Hans"),
+                "zh_CN_#Hans", "zh_HK_#Hans", "zh_MO_#Hans", "zh_SG", "zh_SG_#Hans"),
             "",
         },
 
@@ -387,6 +393,34 @@
             "",
         },
 
+        // Langtag including extensions. Should be ignored.
+        {
+            "--include-locales=en,ja-u-nu-thai",
+            "jdk.localedata",
+            List.of(
+                "/jdk.localedata/sun/text/resources/ext/FormatData_en_GB.class",
+                "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_en_001.class"),
+            List.of(
+                "/jdk.localedata/sun/text/resources/cldr/ext/FormatData_ja.class",
+                "/jdk.localedata/sun/text/resources/ext/FormatData_th.class"),
+            List.of(
+                "(root)", "en", "en_001", "en_150", "en_AG", "en_AI", "en_AS", "en_AT",
+                "en_AU", "en_BB", "en_BE", "en_BI", "en_BM", "en_BS", "en_BW", "en_BZ",
+                "en_CA", "en_CC", "en_CH", "en_CK", "en_CM", "en_CX", "en_CY", "en_DE",
+                "en_DG", "en_DK", "en_DM", "en_ER", "en_FI", "en_FJ", "en_FK", "en_FM",
+                "en_GB", "en_GD", "en_GG", "en_GH", "en_GI", "en_GM", "en_GU", "en_GY",
+                "en_HK", "en_IE", "en_IL", "en_IM", "en_IN", "en_IO", "en_JE", "en_JM",
+                "en_KE", "en_KI", "en_KN", "en_KY", "en_LC", "en_LR", "en_LS", "en_MG",
+                "en_MH", "en_MO", "en_MP", "en_MS", "en_MT", "en_MU", "en_MW", "en_MY",
+                "en_NA", "en_NF", "en_NG", "en_NL", "en_NR", "en_NU", "en_NZ", "en_PG",
+                "en_PH", "en_PK", "en_PN", "en_PR", "en_PW", "en_RW", "en_SB", "en_SC",
+                "en_SD", "en_SE", "en_SG", "en_SH", "en_SI", "en_SL", "en_SS", "en_SX",
+                "en_SZ", "en_TC", "en_TK", "en_TO", "en_TT", "en_TV", "en_TZ", "en_UG",
+                "en_UM", "en_US", "en_US_POSIX", "en_VC", "en_VG", "en_VI", "en_VU",
+                "en_WS", "en_ZA", "en_ZM", "en_ZW"),
+            "",
+        },
+
         // Error case: No matching locales
         {
             "--include-locales=xyz",