OpenJDK / jdk-updates / jdk12u
changeset 53432:cad98a9ab184
Merge
author | robm |
---|---|
date | Mon, 04 Feb 2019 06:49:11 -0800 |
parents | ed560272ea49 ffac5eabbf28 |
children | 4a708c0cc1b7 |
files | .hgtags |
diffstat | 74 files changed, 1002 insertions(+), 522 deletions(-) [+] |
line wrap: on
line diff
--- a/.hgtags Thu Jan 17 10:44:17 2019 -0500 +++ b/.hgtags Mon Feb 04 06:49:11 2019 -0800 @@ -531,6 +531,8 @@ de9fd809bb475401aad188eab2264226788aad81 jdk-12+26 f15d443f97318e9b40e6f451e327ff69ed4ec361 jdk-12+27 659b004b6a1bd8c31e766cbdf328d8f8473fd4d7 jdk-12+28 +44f41693631f9b5ac78ff4d2bfabd6734fe46df2 jdk-12+29 +6c377af36a5c4203f16aed8a5e4c2ecc08fcd8bd jdk-12+30 60ff8949381adea46f489f6bbecf9232a028e830 jdk-12.0.1+1 c3fc07bf408084671904abac6b1873aebf7983c7 jdk-12.0.1+2 d52a133717eef8e05abd6d12bb75d943607c517c jdk-12.0.1+3
--- a/make/data/lsrdata/language-subtag-registry.txt Thu Jan 17 10:44:17 2019 -0500 +++ b/make/data/lsrdata/language-subtag-registry.txt Mon Feb 04 06:49:11 2019 -0800 @@ -1,4 +1,4 @@ -File-Date: 2018-10-31 +File-Date: 2018-11-30 %% Type: language Subtag: aa @@ -593,6 +593,7 @@ Type: language Subtag: lg Description: Ganda +Description: Luganda Added: 2005-10-16 %% Type: language
--- a/src/hotspot/cpu/x86/gc/z/zBarrierSetAssembler_x86.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/cpu/x86/gc/z/zBarrierSetAssembler_x86.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2018, 2019, 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 @@ -280,7 +280,7 @@ ref_addr = stub->ref_addr()->as_pointer_register(); } else { // Load address into tmp register - ce->leal(stub->ref_addr(), stub->tmp(), stub->patch_code(), stub->patch_info()); + ce->leal(stub->ref_addr(), stub->tmp()); ref_addr = stub->tmp()->as_pointer_register(); }
--- a/src/hotspot/share/c1/c1_LIRAssembler.hpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/c1/c1_LIRAssembler.hpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2019, 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 @@ -240,7 +240,7 @@ void align_call(LIR_Code code); void negate(LIR_Opr left, LIR_Opr dest, LIR_Opr tmp = LIR_OprFact::illegalOpr); - void leal(LIR_Opr src, LIR_Opr dest, LIR_PatchCode patch_code, CodeEmitInfo* info); + void leal(LIR_Opr src, LIR_Opr dest, LIR_PatchCode patch_code = lir_patch_none, CodeEmitInfo* info = NULL); void rt_call(LIR_Opr result, address dest, const LIR_OprList* args, LIR_Opr tmp, CodeEmitInfo* info);
--- a/src/hotspot/share/code/nmethod.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/code/nmethod.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1100,7 +1100,11 @@ "must be at safepoint"); // Unregister must be done before the state change - Universe::heap()->unregister_nmethod(this); + { + MutexLockerEx ml(SafepointSynchronize::is_at_safepoint() ? NULL : CodeCache_lock, + Mutex::_no_safepoint_check_flag); + Universe::heap()->unregister_nmethod(this); + } // Log the unloading. log_state_change();
--- a/src/hotspot/share/gc/shared/c1/barrierSetC1.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/gc/shared/c1/barrierSetC1.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2018, 2019, 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 @@ -62,9 +62,13 @@ if (resolve_in_register) { LIR_Opr resolved_addr = gen->new_pointer_register(); - __ leal(addr_opr, resolved_addr); - resolved_addr = LIR_OprFact::address(new LIR_Address(resolved_addr, access.type())); - return resolved_addr; + if (needs_patching) { + __ leal(addr_opr, resolved_addr, lir_patch_normal, access.patch_emit_info()); + access.clear_decorators(C1_NEEDS_PATCHING); + } else { + __ leal(addr_opr, resolved_addr); + } + return LIR_OprFact::address(new LIR_Address(resolved_addr, access.type())); } else { return addr_opr; }
--- a/src/hotspot/share/gc/shared/c1/barrierSetC1.hpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/gc/shared/c1/barrierSetC1.hpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2018, 2019, 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 @@ -92,17 +92,18 @@ load_offset(); } - LIRGenerator* gen() const { return _gen; } - CodeEmitInfo*& patch_emit_info() { return _patch_emit_info; } - CodeEmitInfo*& access_emit_info() { return _access_emit_info; } - LIRAddressOpr& base() { return _base; } - LIRAddressOpr& offset() { return _offset; } - BasicType type() const { return _type; } - LIR_Opr resolved_addr() const { return _resolved_addr; } - void set_resolved_addr(LIR_Opr addr) { _resolved_addr = addr; } - bool is_oop() const { return _type == T_ARRAY || _type == T_OBJECT; } - DecoratorSet decorators() const { return _decorators; } - bool is_raw() const { return (_decorators & AS_RAW) != 0; } + LIRGenerator* gen() const { return _gen; } + CodeEmitInfo*& patch_emit_info() { return _patch_emit_info; } + CodeEmitInfo*& access_emit_info() { return _access_emit_info; } + LIRAddressOpr& base() { return _base; } + LIRAddressOpr& offset() { return _offset; } + BasicType type() const { return _type; } + LIR_Opr resolved_addr() const { return _resolved_addr; } + void set_resolved_addr(LIR_Opr addr) { _resolved_addr = addr; } + bool is_oop() const { return _type == T_ARRAY || _type == T_OBJECT; } + DecoratorSet decorators() const { return _decorators; } + void clear_decorators(DecoratorSet ds) { _decorators &= ~ds; } + bool is_raw() const { return (_decorators & AS_RAW) != 0; } }; // The BarrierSetC1 class is the main entry point for the GC backend of the Access API in C1.
--- a/src/hotspot/share/gc/shenandoah/c2/shenandoahSupport.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/gc/shenandoah/c2/shenandoahSupport.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1023,6 +1023,9 @@ "sha512_implCompressMB", { { TypeFunc::Parms, ShenandoahLoad }, { TypeFunc::Parms+1, ShenandoahStore }, { -1, ShenandoahNone }, { -1, ShenandoahNone}, { -1, ShenandoahNone}, { -1, ShenandoahNone} }, + "encodeBlock", + { { TypeFunc::Parms, ShenandoahLoad }, { TypeFunc::Parms+3, ShenandoahStore }, { -1, ShenandoahNone }, + { -1, ShenandoahNone}, { -1, ShenandoahNone}, { -1, ShenandoahNone} }, }; if (call->is_call_to_arraycopystub()) {
--- a/src/hotspot/share/gc/z/c1/zBarrierSetC1.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/gc/z/c1/zBarrierSetC1.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2019, 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 @@ -36,7 +36,6 @@ _ref_addr(access.resolved_addr()), _ref(ref), _tmp(LIR_OprFact::illegalOpr), - _patch_info(access.patch_emit_info()), _runtime_stub(runtime_stub) { // Allocate tmp register if needed @@ -72,28 +71,14 @@ return _tmp; } -LIR_PatchCode ZLoadBarrierStubC1::patch_code() const { - return (_decorators & C1_NEEDS_PATCHING) != 0 ? lir_patch_normal : lir_patch_none; -} - -CodeEmitInfo*& ZLoadBarrierStubC1::patch_info() { - return _patch_info; -} - address ZLoadBarrierStubC1::runtime_stub() const { return _runtime_stub; } void ZLoadBarrierStubC1::visit(LIR_OpVisitState* visitor) { - if (_patch_info != NULL) { - visitor->do_slow_case(_patch_info); - } else { - visitor->do_slow_case(); - } - + visitor->do_slow_case(); visitor->do_input(_ref_addr); visitor->do_output(_ref); - if (_tmp->is_valid()) { visitor->do_temp(_tmp); } @@ -174,6 +159,14 @@ __ branch_destination(stub->continuation()); } +LIR_Opr ZBarrierSetC1::resolve_address(LIRAccess& access, bool resolve_in_register) { + // We must resolve in register when patching. This is to avoid + // having a patch area in the load barrier stub, since the call + // into the runtime to patch will not have the proper oop map. + const bool patch_before_barrier = barrier_needed(access) && (access.decorators() & C1_NEEDS_PATCHING) != 0; + return BarrierSetC1::resolve_address(access, resolve_in_register || patch_before_barrier); +} + #undef __ void ZBarrierSetC1::load_at_resolved(LIRAccess& access, LIR_Opr result) {
--- a/src/hotspot/share/gc/z/c1/zBarrierSetC1.hpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/gc/z/c1/zBarrierSetC1.hpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2019, 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,12 +32,11 @@ class ZLoadBarrierStubC1 : public CodeStub { private: - DecoratorSet _decorators; - LIR_Opr _ref_addr; - LIR_Opr _ref; - LIR_Opr _tmp; - CodeEmitInfo* _patch_info; - address _runtime_stub; + DecoratorSet _decorators; + LIR_Opr _ref_addr; + LIR_Opr _ref; + LIR_Opr _tmp; + address _runtime_stub; public: ZLoadBarrierStubC1(LIRAccess& access, LIR_Opr ref, address runtime_stub); @@ -46,8 +45,6 @@ LIR_Opr ref() const; LIR_Opr ref_addr() const; LIR_Opr tmp() const; - LIR_PatchCode patch_code() const; - CodeEmitInfo*& patch_info(); address runtime_stub() const; virtual void emit_code(LIR_Assembler* ce); @@ -67,6 +64,7 @@ void load_barrier(LIRAccess& access, LIR_Opr result) const; protected: + virtual LIR_Opr resolve_address(LIRAccess& access, bool resolve_in_register); virtual void load_at_resolved(LIRAccess& access, LIR_Opr result); virtual LIR_Opr atomic_xchg_at_resolved(LIRAccess& access, LIRItem& value); virtual LIR_Opr atomic_cmpxchg_at_resolved(LIRAccess& access, LIRItem& cmp_value, LIRItem& new_value);
--- a/src/hotspot/share/gc/z/zNMethodTable.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/gc/z/zNMethodTable.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -264,21 +264,17 @@ } } -bool ZNMethodTable::unregister_entry(ZNMethodTableEntry* table, size_t size, nmethod* nm) { +void ZNMethodTable::unregister_entry(ZNMethodTableEntry* table, size_t size, nmethod* nm) { if (size == 0) { // Table is empty - return false; + return; } size_t index = first_index(nm, size); for (;;) { const ZNMethodTableEntry table_entry = table[index]; - - if (!table_entry.registered() && !table_entry.unregistered()) { - // Entry not found - return false; - } + assert(table_entry.registered() || table_entry.unregistered(), "Entry not found"); if (table_entry.registered() && table_entry.method() == nm) { // Remove entry @@ -287,7 +283,7 @@ // Destroy GC data ZNMethodData::destroy(gc_data(nm)); set_gc_data(nm, NULL); - return true; + return; } index = next_index(index, size); @@ -451,8 +447,6 @@ return; } - assert(CodeCache_lock->owned_by_self(), "Lock must be held"); - while (_iter_table != NULL) { MutexUnlockerEx mu(CodeCache_lock, Mutex::_no_safepoint_check_flag); os::naked_short_sleep(1); @@ -460,6 +454,7 @@ } void ZNMethodTable::unregister_nmethod(nmethod* nm) { + assert(CodeCache_lock->owned_by_self(), "Lock must be held"); ResourceMark rm; sweeper_wait_for_iteration(); @@ -467,14 +462,9 @@ log_unregister(nm); // Remove entry - if (unregister_entry(_table, _size, nm)) { - // Entry was unregistered. When unregister_entry() instead returns - // false the nmethod was not in the table (because it didn't have - // any oops) so we do not want to decrease the number of registered - // entries in that case. - _nregistered--; - _nunregistered++; - } + unregister_entry(_table, _size, nm); + _nunregistered++; + _nregistered--; } void ZNMethodTable::disarm_nmethod(nmethod* nm) {
--- a/src/hotspot/share/gc/z/zNMethodTable.hpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/gc/z/zNMethodTable.hpp Mon Feb 04 06:49:11 2019 -0800 @@ -57,7 +57,7 @@ static void sweeper_wait_for_iteration(); static bool register_entry(ZNMethodTableEntry* table, size_t size, ZNMethodTableEntry entry); - static bool unregister_entry(ZNMethodTableEntry* table, size_t size, nmethod* nm); + static void unregister_entry(ZNMethodTableEntry* table, size_t size, nmethod* nm); static void rebuild(size_t new_size); static void rebuild_if_needed();
--- a/src/hotspot/share/opto/compile.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/opto/compile.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -2188,13 +2188,16 @@ // They were inserted during parsing (see add_safepoint()) to make // infinite loops without calls or exceptions visible to root, i.e., // useful. -void Compile::remove_root_to_sfpts_edges() { +void Compile::remove_root_to_sfpts_edges(PhaseIterGVN& igvn) { Node *r = root(); if (r != NULL) { for (uint i = r->req(); i < r->len(); ++i) { Node *n = r->in(i); if (n != NULL && n->is_SafePoint()) { r->rm_prec(i); + if (n->outcnt() == 0) { + igvn.remove_dead_node(n); + } --i; } } @@ -2263,7 +2266,7 @@ // Now that all inlining is over, cut edge from root to loop // safepoints - remove_root_to_sfpts_edges(); + remove_root_to_sfpts_edges(igvn); // Remove the speculative part of types and clean up the graph from // the extra CastPP nodes whose only purpose is to carry them. Do
--- a/src/hotspot/share/opto/compile.hpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/opto/compile.hpp Mon Feb 04 06:49:11 2019 -0800 @@ -1088,7 +1088,7 @@ void inline_string_calls(bool parse_time); void inline_boxing_calls(PhaseIterGVN& igvn); bool optimize_loops(PhaseIterGVN& igvn, LoopOptsMode mode); - void remove_root_to_sfpts_edges(); + void remove_root_to_sfpts_edges(PhaseIterGVN& igvn); // Matching, CFG layout, allocation, code generation PhaseCFG* cfg() { return _cfg; }
--- a/src/hotspot/share/opto/convertnode.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/opto/convertnode.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2019, 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 @@ -393,7 +393,11 @@ assert(rxlo == (int)rxlo && rxhi == (int)rxhi, "x should not overflow"); assert(rylo == (int)rylo && ryhi == (int)ryhi, "y should not overflow"); Node* cx = phase->C->constrained_convI2L(phase, x, TypeInt::make(rxlo, rxhi, widen), NULL); + Node *hook = new Node(1); + hook->init_req(0, cx); // Add a use to cx to prevent him from dying Node* cy = phase->C->constrained_convI2L(phase, y, TypeInt::make(rylo, ryhi, widen), NULL); + hook->del_req(0); // Just yank bogus edge + hook->destruct(); switch (op) { case Op_AddI: return new AddLNode(cx, cy); case Op_SubI: return new SubLNode(cx, cy);
--- a/src/hotspot/share/opto/library_call.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/opto/library_call.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -6260,6 +6260,11 @@ Node* dp = argument(5); Node* isURL = argument(6); + src = must_be_not_null(src, true); + src = access_resolve(src, ACCESS_READ); + dest = must_be_not_null(dest, true); + dest = access_resolve(dest, ACCESS_WRITE); + Node* src_start = array_element_address(src, intcon(0), T_BYTE); assert(src_start, "source array is NULL"); Node* dest_start = array_element_address(dest, intcon(0), T_BYTE);
--- a/src/hotspot/share/opto/memnode.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/opto/memnode.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1532,10 +1532,14 @@ Node* address = in(MemNode::Address); bool progress = false; + bool addr_mark = ((phase->type(address)->isa_oopptr() || phase->type(address)->isa_narrowoop()) && + phase->type(address)->is_ptr()->offset() == oopDesc::mark_offset_in_bytes()); + // Skip up past a SafePoint control. Cannot do this for Stores because // pointer stores & cardmarks must stay on the same side of a SafePoint. if( ctrl != NULL && ctrl->Opcode() == Op_SafePoint && - phase->C->get_alias_index(phase->type(address)->is_ptr()) != Compile::AliasIdxRaw ) { + phase->C->get_alias_index(phase->type(address)->is_ptr()) != Compile::AliasIdxRaw && + !addr_mark ) { ctrl = ctrl->in(0); set_req(MemNode::Control,ctrl); progress = true;
--- a/src/hotspot/share/prims/jvmtiManageCapabilities.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/prims/jvmtiManageCapabilities.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -107,6 +107,14 @@ #ifndef ZERO jc.can_pop_frame = 1; jc.can_force_early_return = 1; + // Workaround for 8195635: + // disable pop_frame and force_early_return capabilities with Graal +#if INCLUDE_JVMCI + if (UseJVMCICompiler) { + jc.can_pop_frame = 0; + jc.can_force_early_return = 0; + } +#endif // INCLUDE_JVMCI #endif // !ZERO jc.can_get_source_debug_extension = 1; jc.can_access_local_variables = 1;
--- a/src/hotspot/share/prims/whitebox.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/prims/whitebox.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2019, 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 @@ -93,6 +93,9 @@ #include "services/memTracker.hpp" #include "utilities/nativeCallStack.hpp" #endif // INCLUDE_NMT +#if INCLUDE_AOT +#include "aot/aotLoader.hpp" +#endif // INCLUDE_AOT #ifdef LINUX #include "osContainer_linux.hpp" @@ -2118,6 +2121,14 @@ return (jint) SystemDictionary::pd_cache_table()->removed_entries_count(); WB_END +WB_ENTRY(jint, WB_AotLibrariesCount(JNIEnv* env, jobject o)) + jint result = 0; +#if INCLUDE_AOT + result = (jint) AOTLoader::heaps_count(); +#endif + return result; +WB_END + #define CC (char*) static JNINativeMethod methods[] = { @@ -2350,6 +2361,7 @@ {CC"disableElfSectionCache", CC"()V", (void*)&WB_DisableElfSectionCache }, {CC"resolvedMethodRemovedCount", CC"()I", (void*)&WB_ResolvedMethodRemovedCount }, {CC"protectionDomainRemovedCount", CC"()I", (void*)&WB_ProtectionDomainRemovedCount }, + {CC"aotLibrariesCount", CC"()I", (void*)&WB_AotLibrariesCount }, };
--- a/src/hotspot/share/runtime/vmOperations.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/runtime/vmOperations.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2019, 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 @@ -333,8 +333,7 @@ if (_with_locked_synchronizers) { tcl = concurrent_locks.thread_concurrent_locks(jt); } - ThreadSnapshot* ts = snapshot_thread(jt, tcl); - _result->add_thread_snapshot(ts); + snapshot_thread(jt, tcl); } } else { // Snapshot threads in the given _threads array @@ -345,7 +344,7 @@ if (th() == NULL) { // skip if the thread doesn't exist // Add a dummy snapshot - _result->add_thread_snapshot(new ThreadSnapshot()); + _result->add_thread_snapshot(); continue; } @@ -362,24 +361,22 @@ jt->is_exiting() || jt->is_hidden_from_external_view()) { // add a NULL snapshot if skipped - _result->add_thread_snapshot(new ThreadSnapshot()); + _result->add_thread_snapshot(); continue; } ThreadConcurrentLocks* tcl = NULL; if (_with_locked_synchronizers) { tcl = concurrent_locks.thread_concurrent_locks(jt); } - ThreadSnapshot* ts = snapshot_thread(jt, tcl); - _result->add_thread_snapshot(ts); + snapshot_thread(jt, tcl); } } } -ThreadSnapshot* VM_ThreadDump::snapshot_thread(JavaThread* java_thread, ThreadConcurrentLocks* tcl) { - ThreadSnapshot* snapshot = new ThreadSnapshot(_result->t_list(), java_thread); +void VM_ThreadDump::snapshot_thread(JavaThread* java_thread, ThreadConcurrentLocks* tcl) { + ThreadSnapshot* snapshot = _result->add_thread_snapshot(java_thread); snapshot->dump_stack_at_safepoint(_max_depth, _with_locked_monitors); snapshot->set_concurrent_locks(tcl); - return snapshot; } volatile bool VM_Exit::_vm_exited = false;
--- a/src/hotspot/share/runtime/vmOperations.hpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/runtime/vmOperations.hpp Mon Feb 04 06:49:11 2019 -0800 @@ -445,7 +445,7 @@ bool _with_locked_monitors; bool _with_locked_synchronizers; - ThreadSnapshot* snapshot_thread(JavaThread* java_thread, ThreadConcurrentLocks* tcl); + void snapshot_thread(JavaThread* java_thread, ThreadConcurrentLocks* tcl); public: VM_ThreadDump(ThreadDumpResult* result,
--- a/src/hotspot/share/services/management.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/services/management.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2019, 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 @@ -1097,15 +1097,13 @@ for (int i = 0; i < num_threads; i++) { jlong tid = ids_ah->long_at(i); JavaThread* jt = dump_result.t_list()->find_JavaThread_from_java_tid(tid); - ThreadSnapshot* ts; if (jt == NULL) { // if the thread does not exist or now it is terminated, // create dummy snapshot - ts = new ThreadSnapshot(); + dump_result.add_thread_snapshot(); } else { - ts = new ThreadSnapshot(dump_result.t_list(), jt); + dump_result.add_thread_snapshot(jt); } - dump_result.add_thread_snapshot(ts); } } else { // obtain thread dump with the specific list of threads with stack trace
--- a/src/hotspot/share/services/threadService.cpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/services/threadService.cpp Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2019, 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 @@ -503,8 +503,25 @@ } } +ThreadSnapshot* ThreadDumpResult::add_thread_snapshot() { + ThreadSnapshot* ts = new ThreadSnapshot(); + link_thread_snapshot(ts); + return ts; +} -void ThreadDumpResult::add_thread_snapshot(ThreadSnapshot* ts) { +ThreadSnapshot* ThreadDumpResult::add_thread_snapshot(JavaThread* thread) { + // Note: it is very important that the ThreadSnapshot* gets linked before + // ThreadSnapshot::initialize gets called. This is to ensure that + // ThreadSnapshot::oops_do can get called prior to the field + // ThreadSnapshot::_threadObj being assigned a value (to prevent a dangling + // oop). + ThreadSnapshot* ts = new ThreadSnapshot(); + link_thread_snapshot(ts); + ts->initialize(t_list(), thread); + return ts; +} + +void ThreadDumpResult::link_thread_snapshot(ThreadSnapshot* ts) { assert(_num_threads == 0 || _num_snapshots < _num_threads, "_num_snapshots must be less than _num_threads"); _num_snapshots++; @@ -831,12 +848,9 @@ memset((void*) _perf_recursion_counts, 0, sizeof(_perf_recursion_counts)); } -ThreadSnapshot::ThreadSnapshot(ThreadsList * t_list, JavaThread* thread) { +void ThreadSnapshot::initialize(ThreadsList * t_list, JavaThread* thread) { _thread = thread; _threadObj = thread->threadObj(); - _stack_trace = NULL; - _concurrent_locks = NULL; - _next = NULL; ThreadStatistics* stat = thread->get_thread_stat(); _contended_enter_ticks = stat->contended_enter_ticks(); @@ -846,9 +860,6 @@ _sleep_ticks = stat->sleep_ticks(); _sleep_count = stat->sleep_count(); - _blocker_object = NULL; - _blocker_object_owner = NULL; - _thread_status = java_lang_Thread::get_thread_status(_threadObj); _is_ext_suspended = thread->is_being_ext_suspended(); _is_in_native = (thread->thread_state() == _thread_in_native);
--- a/src/hotspot/share/services/threadService.hpp Thu Jan 17 10:44:17 2019 -0500 +++ b/src/hotspot/share/services/threadService.hpp Mon Feb 04 06:49:11 2019 -0800 @@ -213,12 +213,15 @@ ThreadConcurrentLocks* _concurrent_locks; ThreadSnapshot* _next; -public: - // Dummy snapshot + // ThreadSnapshot instances should only be created via + // ThreadDumpResult::add_thread_snapshot. + friend class ThreadDumpResult; ThreadSnapshot() : _thread(NULL), _threadObj(NULL), _blocker_object(NULL), _blocker_object_owner(NULL), _stack_trace(NULL), _concurrent_locks(NULL), _next(NULL) {}; - ThreadSnapshot(ThreadsList * t_list, JavaThread* thread); + void initialize(ThreadsList * t_list, JavaThread* thread); + +public: ~ThreadSnapshot(); java_lang_Thread::ThreadStatus thread_status() { return _thread_status; } @@ -367,12 +370,16 @@ ThreadsListSetter _setter; // Helper to set hazard ptr in the originating thread // which protects the JavaThreads in _snapshots. + void link_thread_snapshot(ThreadSnapshot* ts); + public: ThreadDumpResult(); ThreadDumpResult(int num_threads); ~ThreadDumpResult(); - void add_thread_snapshot(ThreadSnapshot* ts); + ThreadSnapshot* add_thread_snapshot(); + ThreadSnapshot* add_thread_snapshot(JavaThread* thread); + void set_next(ThreadDumpResult* next) { _next = next; } ThreadDumpResult* next() { return _next; } int num_threads() { return _num_threads; }
--- a/src/java.base/share/classes/java/lang/Character.java Thu Jan 17 10:44:17 2019 -0500 +++ b/src/java.base/share/classes/java/lang/Character.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2019, 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 @@ -35,35 +35,29 @@ /** * The {@code Character} class wraps a value of the primitive - * type {@code char} in an object. An object of type + * type {@code char} in an object. An object of class * {@code Character} contains a single field whose type is * {@code char}. * <p> - * In addition, this class provides several methods for determining - * a character's category (lowercase letter, digit, etc.) and for converting - * characters from uppercase to lowercase and vice versa. + * In addition, this class provides a large number of static methods for + * determining a character's category (lowercase letter, digit, etc.) + * and for converting characters from uppercase to lowercase and vice + * versa. + * + * <h3><a id="conformance">Unicode Conformance</a></h3> * <p> - * Character information is based on the Unicode Standard, version 11.0.0. + * The fields and methods of class {@code Character} are defined in terms + * of character information from the Unicode Standard, specifically the + * <i>UnicodeData</i> file that is part of the Unicode Character Database. + * This file specifies properties including name and category for every + * assigned Unicode code point or character range. The file is available + * from the Unicode Consortium at + * <a href="http://www.unicode.org">http://www.unicode.org</a>. * <p> - * The methods and data of class {@code Character} are defined by - * the information in the <i>UnicodeData</i> file that is part of the - * Unicode Character Database maintained by the Unicode - * Consortium. This file specifies various properties including name - * and general category for every defined Unicode code point or - * character range. - * <p> - * The file and its description are available from the Unicode Consortium at: - * <ul> - * <li><a href="http://www.unicode.org">http://www.unicode.org</a> - * </ul> - * <p> - * The code point, U+32FF, is reserved by the Unicode Consortium - * to represent the Japanese square character for the new era that begins - * May 2019. Relevant methods in the Character class return the same - * properties as for the existing Japanese era characters (e.g., U+337E for - * "Meizi"). For the details of the code point, refer to - * <a href="http://blog.unicode.org/2018/09/new-japanese-era.html"> - * http://blog.unicode.org/2018/09/new-japanese-era.html</a>. + * The Java SE 12 Platform uses character information from version 11.0 + * of the Unicode Standard, plus the Japanese Era code point, + * {@code U+32FF}, from the first version of the Unicode Standard + * after 11.0 that assigns the code point. * * <h3><a id="unicode">Unicode Character Representations</a></h3> * @@ -9495,7 +9489,7 @@ * character in a Java identifier. * <p> * A character may start a Java identifier if and only if - * one of the following is true: + * one of the following conditions is true: * <ul> * <li> {@link #isLetter(char) isLetter(ch)} returns {@code true} * <li> {@link #getType(char) getType(ch)} returns {@code LETTER_NUMBER} @@ -9524,8 +9518,8 @@ * Determines if the specified character may be part of a Java * identifier as other than the first character. * <p> - * A character may be part of a Java identifier if and only if any - * of the following are true: + * A character may be part of a Java identifier if and only if one + * of the following conditions is true: * <ul> * <li> it is a letter * <li> it is a currency symbol (such as {@code '$'}) @@ -9667,7 +9661,7 @@ * identifier as other than the first character. * <p> * A character may be part of a Java identifier if any of the following - * are true: + * conditions are true: * <ul> * <li> it is a letter * <li> it is a currency symbol (such as {@code '$'}) @@ -9704,7 +9698,7 @@ * identifier as other than the first character. * <p> * A character may be part of a Java identifier if any of the following - * are true: + * conditions are true: * <ul> * <li> it is a letter * <li> it is a currency symbol (such as {@code '$'}) @@ -9715,7 +9709,7 @@ * <li> it is a non-spacing mark * <li> {@link #isIdentifierIgnorable(int) * isIdentifierIgnorable(codePoint)} returns {@code true} for - * the character + * the code point * </ul> * * @param codePoint the character (Unicode code point) to be tested.
--- a/src/java.base/share/classes/java/time/chrono/JapaneseEra.java Thu Jan 17 10:44:17 2019 -0500 +++ b/src/java.base/share/classes/java/time/chrono/JapaneseEra.java Mon Feb 04 06:49:11 2019 -0800 @@ -88,15 +88,33 @@ /** * An era in the Japanese Imperial calendar system. * <p> - * This class defines the valid eras for the Japanese chronology. - * Japan introduced the Gregorian calendar starting with Meiji 6. - * Only Meiji and later eras are supported; - * dates before Meiji 6, January 1 are not supported. - * The number of the valid eras may increase, as new eras may be - * defined by the Japanese government. Once an era is defined, - * future versions of the platform may add a singleton instance - * for it. The defined era is expected to have a consecutive integer - * associated with it. + * The Japanese government defines the official name and start date of + * each era. Eras are consecutive and their date ranges do not overlap, + * so the end date of one era is always the day before the start date + * of the next era. + * <p> + * The Java SE Platform supports all eras defined by the Japanese government, + * beginning with the Meiji era. Each era is identified in the Platform by an + * integer value and a name. The {@link #of(int)} and {@link #valueOf(String)} + * methods may be used to obtain a singleton instance of {@code JapaneseEra} + * for each era. The {@link #values()} method returns the singleton instances + * of all supported eras. + * <p> + * For convenience, this class declares a number of public static final fields + * that refer to singleton instances returned by the {@link #values()} method. + * + * @apiNote + * The fields declared in this class may evolve over time, in line with the + * results of the {@link #values()} method. However, there is not necessarily + * a 1:1 correspondence between the fields and the singleton instances. + * + * @apiNote + * The Japanese government may announce a new era and define its start + * date but not its official name. In this scenario, the singleton instance + * that represents the new era may return a name that is not stable until + * the official name is defined. Developers should exercise caution when + * relying on the name returned by any singleton instance that does not + * correspond to a public static final field. * * @implSpec * This class is immutable and thread-safe. @@ -199,14 +217,18 @@ //----------------------------------------------------------------------- /** * Obtains an instance of {@code JapaneseEra} from an {@code int} value. + * <ul> + * <li>The value {@code 1} is associated with the 'Showa' era, because + * it contains 1970-01-01 (ISO calendar system).</li> + * <li>The values {@code -1} and {@code 0} are associated with two earlier + * eras, Meiji and Taisho, respectively.</li> + * <li>A value greater than {@code 1} is associated with a later era, + * beginning with Heisei ({@code 2}).</li> + * </ul> * <p> - * The {@link #SHOWA} era that contains 1970-01-01 (ISO calendar system) has the value 1. - * Later era is numbered 2 ({@link #HEISEI}). Earlier eras are numbered 0 ({@link #TAISHO}), - * -1 ({@link #MEIJI}), only Meiji and later eras are supported. - * <p> - * In addition to the known era singletons, values for additional - * eras may be defined. Those values are the {@link Era#getValue()} - * of corresponding eras from the {@link #values()} method. + * Every instance of {@code JapaneseEra} that is returned from the {@link #values()} + * method has an int value (available via {@link Era#getValue()} which is + * accepted by this method. * * @param japaneseEra the era to represent * @return the {@code JapaneseEra} singleton, not null
--- a/src/java.base/share/classes/sun/security/ssl/SSLAlgorithmDecomposer.java Thu Jan 17 10:44:17 2019 -0500 +++ b/src/java.base/share/classes/sun/security/ssl/SSLAlgorithmDecomposer.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2019, 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 @@ -266,7 +266,8 @@ // ignore: unknown or unsupported ciphersuite } - if (cipherSuite != null) { + if (cipherSuite != null && + cipherSuite != CipherSuite.TLS_EMPTY_RENEGOTIATION_INFO_SCSV) { return decompose(cipherSuite.keyExchange, cipherSuite.bulkCipher, cipherSuite.macAlg,
--- a/src/java.desktop/share/legal/mesa3d.md Thu Jan 17 10:44:17 2019 -0500 +++ b/src/java.desktop/share/legal/mesa3d.md Mon Feb 04 06:49:11 2019 -0800 @@ -1,10 +1,10 @@ -## Mesa 3-D Graphics Library v4.1 +## Mesa 3-D Graphics Library v5.0 ### Mesa License <pre> Mesa 3-D graphics library -Version: 4.1 +Version: 5.0 Copyright (C) 1999-2002 Brian Paul All Rights Reserved.
--- a/src/java.desktop/share/native/libfontmanager/freetypeScaler.c Thu Jan 17 10:44:17 2019 -0500 +++ b/src/java.desktop/share/native/libfontmanager/freetypeScaler.c Mon Feb 04 06:49:11 2019 -0800 @@ -754,7 +754,10 @@ /* generate bitmap if it is not done yet e.g. if algorithmic styling is performed and style was added to outline */ if (ftglyph->format == FT_GLYPH_FORMAT_OUTLINE) { - FT_Render_Glyph(ftglyph, FT_LOAD_TARGET_MODE(target)); + error = FT_Render_Glyph(ftglyph, FT_LOAD_TARGET_MODE(target)); + if (error != 0) { + return ptr_to_jlong(getNullGlyphImage()); + } } width = (UInt16) ftglyph->bitmap.width;
--- a/src/java.desktop/unix/classes/sun/awt/X11/XChoicePeer.java Thu Jan 17 10:44:17 2019 -0500 +++ b/src/java.desktop/unix/classes/sun/awt/X11/XChoicePeer.java Mon Feb 04 06:49:11 2019 -0800 @@ -468,6 +468,7 @@ if (unfurledChoice.isMouseInListArea(e)) { int newIdx = helper.getSelectedIndex(); if (newIdx >= 0) { + int currentItem = ((Choice)target).getSelectedIndex(); // Update the selected item in the target now that // the mouse selection is complete. if (newIdx != dragStartIdx) { @@ -484,7 +485,7 @@ * LeftMouseButton used */ if (e.getButton() == MouseEvent.BUTTON1 && (!firstPress || wasDragged ) && - ((Choice)target).getSelectedIndex() != newIdx) + (newIdx != currentItem)) { ((Choice)target).select(newIdx); postEvent(new ItemEvent((Choice)target,
--- a/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerExactExceptionTest.java Thu Jan 17 10:44:17 2019 -0500 +++ b/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerExactExceptionTest.java Mon Feb 04 06:49:11 2019 -0800 @@ -98,6 +98,10 @@ } } + public void testIntegerExactOverflowWithoutUse3() { + Math.addExact(Integer.MAX_VALUE, 1); + } + @Test public void testIntegerExactWithoutUse1() throws InvalidInstalledCodeException { ResolvedJavaMethod method = getResolvedJavaMethod("testIntegerExactOverflowWithoutUse1"); @@ -126,6 +130,20 @@ assertTrue(gotException); } + @Test + public void testIntegerExactWithoutUse3() throws InvalidInstalledCodeException { + ResolvedJavaMethod method = getResolvedJavaMethod("testIntegerExactOverflowWithoutUse3"); + InstalledCode code = getCode(method); + + boolean gotException = false; + try { + code.executeVarargs(this); + } catch (ArithmeticException e) { + gotException = true; + } + assertTrue(gotException); + } + static long longCounter = 10; public void testLongExactOverflowSnippet(long input) {
--- a/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StandardGraphBuilderPlugins.java Thu Jan 17 10:44:17 2019 -0500 +++ b/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StandardGraphBuilderPlugins.java Mon Feb 04 06:49:11 2019 -0800 @@ -560,19 +560,14 @@ } private static boolean createIntegerExactOperation(GraphBuilderContext b, JavaKind kind, ValueNode x, ValueNode y, IntegerExactOp op) { - if (x.isConstant() && y.isConstant()) { - b.addPush(kind, createIntegerExactArithmeticNode(x, y, null, op)); + BytecodeExceptionKind exceptionKind = kind == JavaKind.Int ? BytecodeExceptionKind.INTEGER_EXACT_OVERFLOW : BytecodeExceptionKind.LONG_EXACT_OVERFLOW; + AbstractBeginNode exceptionEdge = b.genExplicitExceptionEdge(exceptionKind); + if (exceptionEdge != null) { + IntegerExactArithmeticSplitNode split = b.addPush(kind, createIntegerExactSplit(x, y, exceptionEdge, op)); + split.setNext(b.add(new BeginNode())); return true; - } else { - BytecodeExceptionKind exceptionKind = kind == JavaKind.Int ? BytecodeExceptionKind.INTEGER_EXACT_OVERFLOW : BytecodeExceptionKind.LONG_EXACT_OVERFLOW; - AbstractBeginNode exceptionEdge = b.genExplicitExceptionEdge(exceptionKind); - if (exceptionEdge != null) { - IntegerExactArithmeticSplitNode split = b.addPush(kind, createIntegerExactSplit(x, y, exceptionEdge, op)); - split.setNext(b.add(new BeginNode())); - return true; - } - return false; } + return false; } private static void registerMathPlugins(InvocationPlugins plugins, boolean allowDeoptimization) {
--- a/src/jdk.javadoc/share/legal/jquery.md Thu Jan 17 10:44:17 2019 -0500 +++ b/src/jdk.javadoc/share/legal/jquery.md Mon Feb 04 06:49:11 2019 -0800 @@ -3,8 +3,7 @@ ### jQuery License ``` jQuery v 3.3.1 -Copyright 2005, 2018 jQuery Foundation, Inc. and other contributors -http://jquery.com/ +Copyright JS Foundation and other contributors, https://js.foundation/ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the
--- a/test/hotspot/jtreg/ProblemList-Xcomp.txt Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/ProblemList-Xcomp.txt Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ # -# Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2018, 2019, 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 @@ -27,5 +27,4 @@ # ############################################################################# -vmTestbase/vm/mlvm/meth/stress/jni/nativeAndMH/Test.java 8208235 solaris-all -runtime/appcds/cacheObject/DifferentHeapSizes.java 8210102 solaris-all +vmTestbase/vm/mlvm/meth/stress/jni/nativeAndMH/Test.java 8058176 solaris-all
--- a/test/hotspot/jtreg/ProblemList-graal.txt Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/ProblemList-graal.txt Mon Feb 04 06:49:11 2019 -0800 @@ -39,8 +39,6 @@ compiler/graalunit/JttThreadsTest.java 8208066 generic-all -compiler/intrinsics/mathexact/LongMulOverflowTest.java 8196568 generic-all - compiler/jvmci/SecurityRestrictionsTest.java 8181837 generic-all compiler/unsafe/UnsafeGetConstantField.java 8181833 generic-all @@ -64,7 +62,7 @@ compiler/compilercontrol/directives/LogTest.java 8181753 generic-all -gc/parallel/TestPrintGCDetailsVerbose.java 8200186 macosx-all +gc/parallel/TestPrintGCDetailsVerbose.java 8196611 macosx-all compiler/jvmci/compilerToVM/ReprofileTest.java 8201333 generic-all @@ -107,20 +105,10 @@ vmTestbase/nsk/jdi/ThreadReference/forceEarlyReturn/forceEarlyReturn007/TestDescription.java 8195600 generic-all -vmTestbase/nsk/jdi/VirtualMachine/redefineClasses/redefineclasses026/TestDescription.java 8195627 generic-all -vmTestbase/nsk/jdi/VirtualMachine/redefineClasses/redefineclasses028/TestDescription.java 8195627 generic-all -vmTestbase/nsk/jdi/VirtualMachine/redefineClasses/redefineclasses030/TestDescription.java 8195627 generic-all -vmTestbase/nsk/jdb/wherei/wherei001/wherei001.java 8195627 generic-all - vmTestbase/vm/mlvm/anonloader/stress/oome/heap/Test.java 8186299 generic-all vmTestbase/vm/mlvm/anonloader/stress/oome/metaspace/Test.java 8186299 generic-all # jvmti tests -vmTestbase/nsk/jvmti/IterateThroughHeap/filter-tagged/TestDescription.java 8193577 generic-all -vmTestbase/nsk/jvmti/IterateThroughHeap/filter-class-tagged/TestDescription.java 8193577 generic-all - -vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretbase/TestDescription.java 8195635 generic-all - vmTestbase/nsk/jvmti/PopFrame/popframe009/TestDescription.java 8195639 generic-all vmTestbase/nsk/jvmti/ForceEarlyReturn/ForceEarlyReturn001/TestDescription.java 8195674 generic-all @@ -139,6 +127,61 @@ serviceability/jvmti/FieldAccessWatch/FieldAccessWatch.java 8202482 generic-all +# tests require pop_frame and force_early_return capabilities +vmTestbase/nsk/jdb/pop/pop001/pop001.java 8195635 generic-all +vmTestbase/nsk/jdb/pop_exception/pop_exception001/pop_exception001.java 8195635 generic-all +vmTestbase/nsk/jdb/reenter/reenter001/reenter001.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc01x002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc02x001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc02x002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc04x001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc04x002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc06x001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc08x001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/BScenarios/hotswap/tc10x002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/MethodExitEvent/returnValue/returnValue003/returnValue003.java 8195635 generic-all +vmTestbase/nsk/jdi/Scenarios/invokeMethod/popframes001/TestDescription.jav 8195635 generic-all +vmTestbase/nsk/jdi/Scenarios/invokeMethod/popframes001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/ThreadReference/popFrames/popframes001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/VirtualMachine/redefineClasses/redefineclasses002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/stress/serial/forceEarlyReturn001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/stress/serial/forceEarlyReturn002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdi/stress/serial/mixed002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jdwp/ThreadReference/ForceEarlyReturn/forceEarlyReturn002/forceEarlyReturn002.java 8195635 generic-all +vmTestbase/nsk/jvmti/ForceEarlyReturn/ForceEarlyReturn001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/ForceEarlyReturn/ForceEarlyReturn002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/PopFrame/popframe001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/PopFrame/popframe003/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/PopFrame/popframe005/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/capability/CM01/cm01t007/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/capability/CM03/cm03t001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS102/hs102t001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t001/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t002/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS202/hs202t002/hs202t002.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS203/hs203t001/hs203t001.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS203/hs203t002/hs203t002.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS203/hs203t003/hs203t003.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS203/hs203t004/hs203t004.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS204/hs204t001/hs204t001.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS204/hs204t003/hs204t003.java 8195635 generic-all +vmTestbase/nsk/jvmti/scenarios/hotswap/HS204/hs204t004/hs204t004.java 8195635 generic-all +vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretbase/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretfp/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretint/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretlong/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretobj/TestDescription.java 8195635 generic-all +vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretstr/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2manyDiff_a/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2manySame_a/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2none_b/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2same_a/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2same_b/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_none2indy_a/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_none2indy_b/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/redefineClassInTarget/TestDescription.java 8195635 generic-all +vmTestbase/vm/mlvm/indy/func/jvmti/stepBreakPopReturn/INDIFY_Test.java 8195635 generic-all + compiler/stable/TestStableBoolean.java 8204347 generic-all compiler/stable/TestStableByte.java 8204347 generic-all compiler/stable/TestStableChar.java 8204347 generic-all @@ -157,11 +200,10 @@ org.graalvm.compiler.core.test.OptionsVerifierTest 8205081 org.graalvm.compiler.hotspot.test.CompilationWrapperTest 8205081 org.graalvm.compiler.replacements.test.classfile.ClassfileBytecodeProviderTest 8205081 +org.graalvm.compiler.debug.test.DebugContextTest 8205081 org.graalvm.compiler.core.test.deopt.CompiledMethodTest 8202955 -org.graalvm.compiler.debug.test.DebugContextTest 8203504 -org.graalvm.compiler.hotspot.test.GraalOSRTest 8206947 org.graalvm.compiler.hotspot.test.ReservedStackAccessTest 8213567 windows-all -org.graalvm.compiler.replacements.test.StringCompressInflateTest 8213556 +org.graalvm.compiler.replacements.test.StringCompressInflateTest 8214947
--- a/test/hotspot/jtreg/ProblemList.txt Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/ProblemList.txt Mon Feb 04 06:49:11 2019 -0800 @@ -53,39 +53,34 @@ compiler/c2/Test6852078.java 8194310 generic-all -applications/ctw/modules/java_desktop.java 8189604 windows-all -applications/ctw/modules/java_desktop_2.java 8189604 windows-all -applications/ctw/modules/jdk_jconsole.java 8189604 windows-all - compiler/cpuflags/TestAESIntrinsicsOnSupportedConfig.java 8190680 generic-all compiler/runtime/Test8168712.java 8211769,8211771 generic-ppc64,generic-ppc64le,linux-s390x +applications/ctw/modules/java_desktop.java 8189604 windows-all +applications/ctw/modules/java_desktop_2.java 8189604 windows-all +applications/ctw/modules/jdk_jconsole.java 8189604 windows-all + ############################################################################# # :hotspot_gc gc/epsilon/TestMemoryMXBeans.java 8206434 generic-all gc/g1/humongousObjects/objectGraphTest/TestObjectGraphAfterGC.java 8156755 generic-all -gc/survivorAlignment/TestPromotionToSurvivor.java 8129886 generic-all +gc/survivorAlignment/TestPromotionToSurvivor.java 8218049 generic-all +gc/survivorAlignment/TestPromotionFromSurvivorToTenuredAfterMinorGC.java 8218049 generic-all gc/g1/logging/TestG1LoggingFailure.java 8169634 generic-all gc/g1/humongousObjects/TestHeapCounters.java 8178918 generic-all gc/stress/gclocker/TestGCLockerWithParallel.java 8180622 generic-all gc/stress/gclocker/TestGCLockerWithG1.java 8180622 generic-all -gc/survivorAlignment/TestPromotionFromSurvivorToTenuredAfterMinorGC.java 8177765 generic-all gc/stress/TestJNIBlockFullGC/TestJNIBlockFullGC.java 8192647 generic-all -gc/logging/TestUnifiedLoggingSwitchStress.java 8208778 macosx-x64 gc/metaspace/CompressedClassSpaceSizeInJmapHeap.java 8193639 solaris-all ############################################################################# # :hotspot_runtime -runtime/appcds/javaldr/GCSharedStringsDuringDump.java 8208778 macosx-x64 -runtime/appcds/javaldr/GCDuringDump.java 8208778 macosx-x64 -runtime/CompressedOops/UseCompressedOops.java 8079353 generic-all runtime/handshake/HandshakeWalkSuspendExitTest.java 8214174 generic-all -runtime/RedefineTests/RedefineRunningMethods.java 8208778 macosx-x64 runtime/SharedArchiveFile/SASymbolTableTest.java 8193639 solaris-all ############################################################################# @@ -161,36 +156,25 @@ vmTestbase/nsk/monitoring/MemoryPoolMBean/isUsageThresholdExceeded/isexceeded005/TestDescription.java 8153598 generic-all vmTestbase/nsk/monitoring/ThreadMXBean/ThreadInfo/Deadlock/JavaDeadlock001/TestDescription.java 8060733 generic-all -vmTestbase/nsk/jdi/AttachingConnector/attachnosuspend/attachnosuspend001/TestDescription.java 8153613 generic-all -vmTestbase/nsk/jdi/ThreadReference/frameCount/framecount001/TestDescription.java 6530620 generic-all vmTestbase/nsk/jdi/ThreadReference/isSuspended/issuspended002/TestDescription.java 4903717 generic-all vmTestbase/nsk/jdi/ThreadReference/resume/resume001/TestDescription.java 8072701 generic-all vmTestbase/nsk/jdi/ThreadReference/stop/stop001/TestDescription.java 7034630 generic-all vmTestbase/nsk/jdi/BScenarios/hotswap/tc10x001/TestDescription.java 8013728 generic-all -vmTestbase/nsk/jdi/BScenarios/multithrd/tc02x004/TestDescription.java 4751860 generic-all vmTestbase/nsk/jdi/EventRequest/setEnabled/setenabled003/TestDescription.java 8066993 generic-all -vmTestbase/nsk/jdi/StackFrame/_bounds_/bounds001/TestDescription.java 6604963 generic-all vmTestbase/nsk/jdi/VirtualMachine/redefineClasses/redefineclasses021/TestDescription.java 8065773 generic-all vmTestbase/nsk/jdi/VirtualMachine/redefineClasses/redefineclasses023/TestDescription.java 8065773 generic-all vmTestbase/nsk/jdi/EventQueue/remove_l/remove_l005/TestDescription.java 8068225 generic-all -vmTestbase/nsk/jdi/stress/ClassPrepareEvents/ClassPrepareEvents001/ClassPrepareEvents001.java 6426321 generic-all vmTestbase/metaspace/gc/firstGC_10m/TestDescription.java 8208250 generic-all vmTestbase/metaspace/gc/firstGC_50m/TestDescription.java 8208250 generic-all vmTestbase/metaspace/gc/firstGC_99m/TestDescription.java 8208250 generic-all vmTestbase/metaspace/gc/firstGC_default/TestDescription.java 8208250 generic-all -vmTestbase/nsk/jvmti/ClearBreakpoint/clrbrk001/TestDescription.java 8016181 generic-all -vmTestbase/nsk/jvmti/FieldModification/fieldmod001/TestDescription.java 8016181 generic-all -vmTestbase/nsk/jvmti/ResourceExhausted/resexhausted001/TestDescription.java 7013634 generic-all vmTestbase/nsk/jvmti/ResourceExhausted/resexhausted003/TestDescription.java 6606767 generic-all -vmTestbase/nsk/jvmti/ResourceExhausted/resexhausted004/TestDescription.java 7013634,6606767 generic-all -vmTestbase/nsk/jvmti/ThreadStart/threadstart001/TestDescription.java 8016181 generic-all +vmTestbase/nsk/jvmti/ResourceExhausted/resexhausted004/TestDescription.java 6606767 generic-all vmTestbase/nsk/jvmti/scenarios/extension/EX03/ex03t001/TestDescription.java 8173658 generic-all vmTestbase/nsk/jvmti/scenarios/sampling/SP06/sp06t003/TestDescription.java 8051349 generic-all -vmTestbase/nsk/jvmti/AttachOnDemand/attach034/TestDescription.java 8042145 generic-all vmTestbase/nsk/jvmti/AttachOnDemand/attach045/TestDescription.java 8202971 generic-all -vmTestbase/nsk/jvmti/unit/heap/HeapWalkTests/TestDescription.java 8016181 generic-all vmTestbase/gc/lock/jni/jnilock002/TestDescription.java 8208243,8192647 generic-all @@ -198,18 +182,15 @@ vmTestbase/jit/escape/LockCoarsening/LockCoarsening002/TestDescription.java 8208259 generic-all vmTestbase/vm/mlvm/indy/func/jvmti/redefineClassInBootstrap/TestDescription.java 8013267 generic-all -vmTestbase/vm/mlvm/indy/stress/java/relinkMutableCallSite/Test.java 8079664 generic-all -vmTestbase/vm/mlvm/indy/stress/java/relinkVolatileCallSite/Test.java 8079664 generic-all -vmTestbase/vm/mlvm/meth/func/java/throwException/Test.java 8208255 generic-all -vmTestbase/vm/mlvm/meth/func/jdi/breakpointOtherStratum/Test.java 8208257,8208255 generic-all -vmTestbase/vm/mlvm/meth/stress/compiler/deoptimize/Test.java 8079642,8208255 generic-all -vmTestbase/vm/mlvm/meth/stress/compiler/i2c_c2i/Test.java 8208255 generic-all -vmTestbase/vm/mlvm/meth/stress/compiler/sequences/Test.java 8208255 generic-all -vmTestbase/vm/mlvm/meth/stress/gc/callSequencesDuringGC/Test.java 8208255 generic-all -vmTestbase/vm/mlvm/meth/stress/java/sequences/Test.java 8208255 generic-all -vmTestbase/vm/mlvm/meth/stress/jdi/breakpointInCompiledCode/Test.java 8208255 generic-all +vmTestbase/vm/mlvm/meth/func/java/throwException/Test.java 8058176 generic-all +vmTestbase/vm/mlvm/meth/func/jdi/breakpointOtherStratum/Test.java 8208257,8058176 generic-all +vmTestbase/vm/mlvm/meth/stress/compiler/deoptimize/Test.java 8058176 generic-all +vmTestbase/vm/mlvm/meth/stress/compiler/i2c_c2i/Test.java 8058176 generic-all +vmTestbase/vm/mlvm/meth/stress/compiler/sequences/Test.java 8058176 generic-all +vmTestbase/vm/mlvm/meth/stress/gc/callSequencesDuringGC/Test.java 8058176 generic-all +vmTestbase/vm/mlvm/meth/stress/java/sequences/Test.java 8058176 generic-all +vmTestbase/vm/mlvm/meth/stress/jdi/breakpointInCompiledCode/Test.java 8058176 generic-all vmTestbase/vm/mlvm/mixed/stress/java/findDeadlock/TestDescription.java 8208278 generic-all -vmTestbase/vm/mlvm/mixed/stress/regression/b6969574/INDIFY_Test.java 8079650 generic-all vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2none_a/TestDescription.java 8013267 generic-all vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2manyDiff_b/TestDescription.java 8013267 generic-all vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2manySame_b/TestDescription.java 8013267 generic-all
--- a/test/hotspot/jtreg/TEST.ROOT Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/TEST.ROOT Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ # -# Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2005, 2019, 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 @@ -59,13 +59,15 @@ vm.rtm.cpu \ vm.rtm.compiler \ vm.aot \ + vm.aot.enabled \ vm.cds \ vm.cds.custom.loaders \ vm.cds.archived.java.heap \ vm.graal.enabled \ vm.compiler1.enabled \ vm.compiler2.enabled \ - docker.support + docker.support \ + test.vm.gc.nvdimm # Minimum jtreg version requiredVersion=4.2 b13
--- a/test/hotspot/jtreg/TEST.groups Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/TEST.groups Mon Feb 04 06:49:11 2019 -0800 @@ -59,7 +59,8 @@ -:hotspot_compiler \ -:hotspot_gc \ -:hotspot_runtime \ - -:hotspot_serviceability + -:hotspot_serviceability \ + -gc/nvdimm hotspot_native_sanity = \ native_sanity @@ -197,7 +198,7 @@ gc_epsilon = \ gc/epsilon/ \ gc/CriticalNativeArgs.java \ - gc/stress/CriticalNativeStress.java + gc/stress/CriticalNativeStress.java tier1_gc_gcold = \ gc/stress/gcold/TestGCOldWithG1.java \ @@ -210,7 +211,7 @@ gc/stress/gcbasher/TestGCBasherWithCMS.java \ gc/stress/gcbasher/TestGCBasherWithSerial.java \ gc/stress/gcbasher/TestGCBasherWithParallel.java - + tier1_gc_shenandoah = \ gc/shenandoah/options/ \ gc/shenandoah/compiler/ \
--- a/test/hotspot/jtreg/compiler/aot/AotCompiler.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/compiler/aot/AotCompiler.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2019, 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 @@ -117,6 +117,8 @@ // Execute with asserts args.add("-J-ea"); args.add("-J-esa"); + // we don't want to run jaotc w/ Xcomp even if it's in extraopts + args.add("-J-Xmixed"); return launchJaotc(args, extraopts); }
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/hotspot/jtreg/compiler/c2/Test8217359.java Mon Feb 04 06:49:11 2019 -0800 @@ -0,0 +1,74 @@ +/* + * Copyright (c) 2019, Huawei Technologies Co. Ltd. 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 8217359 + * @summary C2 compiler triggers SIGSEGV after transformation in ConvI2LNode::Ideal + * + * @run main/othervm -XX:-TieredCompilation + * -XX:CompileCommand=compileonly,compiler.c2.Test8217359::test + * compiler.c2.Test8217359 + */ + +package compiler.c2; + +public class Test8217359 { + + public static int ival = 0; + public static long lsum = 0; + public static long lval = 0; + + public static void test() { + short s = -25632; + float f = 0.512F, f1 = 2.556F; + int i6 = 32547, i7 = 9, i8 = -9, i9 = 36, i10 = -223; + + for (i6 = 4; i6 < 182; i6++) { + i8 = 1; + while (++i8 < 17) { + f1 = 1; + do { + i7 += (182 + (f1 * f1)); + } while (++f1 < 1); + + Test8217359.ival += (i8 | Test8217359.ival); + } + } + + for (i9 = 9; i9 < 100; ++i9) { + i10 -= i6; + i10 >>= s; + i7 += (((i9 * i10) + i6) - Test8217359.lval); + } + + lsum += i6 + i7 + i8; + } + + public static void main(String[] args) { + for (int i = 0; i < 16000; i++) { + test(); + } + } + +}
--- a/test/hotspot/jtreg/compiler/ciReplay/CiReplayBase.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/compiler/ciReplay/CiReplayBase.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2019, 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 @@ -71,6 +71,11 @@ "-XX:+ReplayCompiles", REPLAY_FILE_OPTION}; protected final Optional<Boolean> runServer; + public static class EmptyMain { + public static void main(String[] args) { + } + } + static { try { CLIENT_VM_AVAILABLE = ProcessTools.executeTestJvm(CLIENT_VM_OPTION, VERSION_OPTION) @@ -135,7 +140,7 @@ options.addAll(Arrays.asList(REPLAY_GENERATION_OPTIONS)); options.addAll(Arrays.asList(vmopts)); options.add(needCoreDump ? ENABLE_COREDUMP_ON_CRASH : DISABLE_COREDUMP_ON_CRASH); - options.add(VERSION_OPTION); + options.add(EmptyMain.class.getName()); if (needCoreDump) { crashOut = ProcessTools.executeProcess(getTestJavaCommandlineWithPrefix( RUN_SHELL_NO_LIMIT, options.toArray(new String[0])));
--- a/test/hotspot/jtreg/compiler/intrinsics/bigInteger/TestMulAdd.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/compiler/intrinsics/bigInteger/TestMulAdd.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2019, 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 @@ * @test * @bug 8081778 * @summary Add C2 x86 intrinsic for BigInteger::mulAdd() method + * @comment the test disables intrinsics, so it can't be run w/ AOT'ed java.base + * @requires !vm.aot.enabled * * @run main/othervm/timeout=600 -XX:-TieredCompilation -Xbatch * -XX:+IgnoreUnrecognizedVMOptions -XX:+UnlockDiagnosticVMOptions -XX:-UseSquareToLenIntrinsic -XX:-UseMultiplyToLenIntrinsic
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/MaterializeVirtualObjectTest.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/MaterializeVirtualObjectTest.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2019, 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 @@ -24,9 +24,13 @@ /* * @test * @bug 8136421 + * * @requires vm.jvmci - * & (vm.compMode != "Xcomp" | vm.opt.TieredCompilation == null | vm.opt.TieredCompilation == true) - * @summary no "-Xcomp -XX:-TieredCompilation" combination allowed until JDK-8140018 is resolved + * @requires vm.opt.final.EliminateAllocations == true + * + * @comment no "-Xcomp -XX:-TieredCompilation" combination allowed until JDK-8140018 is resolved + * @requires vm.compMode != "Xcomp" | vm.opt.TieredCompilation == null | vm.opt.TieredCompilation == true + * * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc
--- a/test/hotspot/jtreg/gc/TestAllocateHeapAtMultiple.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/gc/TestAllocateHeapAtMultiple.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, 2019, 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 @@ -53,9 +53,8 @@ "-Xmx32m -Xms32m -XX:+UseCompressedOops", // 1. With compressedoops enabled. "-Xmx32m -Xms32m -XX:-UseCompressedOops", // 2. With compressedoops disabled. "-Xmx32m -Xms32m -XX:HeapBaseMinAddress=3g", // 3. With user specified HeapBaseMinAddress. - "-Xmx4g -Xms4g", // 4. With larger heap size (UnscaledNarrowOop not possible). - "-Xmx4g -Xms4g -XX:+UseLargePages", // 5. Set UseLargePages. - "-Xmx4g -Xms4g -XX:+UseNUMA" // 6. Set UseNUMA. + "-Xmx32m -Xms32m -XX:+UseLargePages", // 4. Set UseLargePages. + "-Xmx32m -Xms32m -XX:+UseNUMA" // 5. Set UseNUMA. }; for(String extraOpts : extraOptsList) {
--- a/test/hotspot/jtreg/gc/nvdimm/TestAllocateOldGenAt.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/gc/nvdimm/TestAllocateOldGenAt.java Mon Feb 04 06:49:11 2019 -0800 @@ -25,6 +25,7 @@ * @key gc * @summary Test to check allocation of Java Heap with AllocateOldGenAt option * @requires vm.gc=="null" & os.family != "aix" + * @requires test.vm.gc.nvdimm * @library /test/lib * @modules java.base/jdk.internal.misc */
--- a/test/hotspot/jtreg/gc/nvdimm/TestAllocateOldGenAtError.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/gc/nvdimm/TestAllocateOldGenAtError.java Mon Feb 04 06:49:11 2019 -0800 @@ -25,6 +25,7 @@ * @key gc * @summary Test to check correct handling of non-existent directory passed to AllocateOldGenAt option * @requires vm.gc=="null" & os.family != "aix" + * @requires test.vm.gc.nvdimm * @library /test/lib * @modules java.base/jdk.internal.misc */
--- a/test/hotspot/jtreg/gc/nvdimm/TestAllocateOldGenAtMultiple.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/gc/nvdimm/TestAllocateOldGenAtMultiple.java Mon Feb 04 06:49:11 2019 -0800 @@ -25,6 +25,7 @@ * @key gc * @summary Test to check allocation of Java Heap with AllocateOldGenAt option. Has multiple sub-tests to cover different code paths. * @requires vm.gc=="null" & os.family != "aix" + * @requires test.vm.gc.nvdimm * @library /test/lib * @modules java.base/jdk.internal.misc * @requires vm.bits == "64"
--- a/test/hotspot/jtreg/gc/nvdimm/TestHumongousObjectsOnNvdimm.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/gc/nvdimm/TestHumongousObjectsOnNvdimm.java Mon Feb 04 06:49:11 2019 -0800 @@ -26,6 +26,7 @@ * @summary Check that humongous objects reside in nv-dimm * @library /test/lib / * @requires vm.gc=="null" & os.family != "aix" + * @requires test.vm.gc.nvdimm * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * @run main TestHumongousObjectsOnNvdimm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions
--- a/test/hotspot/jtreg/gc/nvdimm/TestOldObjectsOnNvdimm.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/gc/nvdimm/TestOldObjectsOnNvdimm.java Mon Feb 04 06:49:11 2019 -0800 @@ -25,6 +25,7 @@ * @test TestOldObjectsOnNvdimm * @summary Check that objects in old generation reside in dram. * @requires vm.gc=="null" & os.family != "aix" + * @requires test.vm.gc.nvdimm * @library /test/lib * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox
--- a/test/hotspot/jtreg/gc/nvdimm/TestYoungObjectsOnDram.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/gc/nvdimm/TestYoungObjectsOnDram.java Mon Feb 04 06:49:11 2019 -0800 @@ -25,6 +25,7 @@ * @test TestYoungObjectsOnDram * @summary Check that objects in young generation reside in dram. * @requires vm.gc=="null" & os.family != "aix" + * @requires test.vm.gc.nvdimm * @library /test/lib * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox
--- a/test/hotspot/jtreg/runtime/CompressedOops/UseCompressedOops.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/runtime/CompressedOops/UseCompressedOops.java Mon Feb 04 06:49:11 2019 -0800 @@ -63,7 +63,7 @@ testCompressedOopsModes(args, "-XX:+UseParallelGC"); testCompressedOopsModes(args, "-XX:+UseParallelOldGC"); if (GC.Shenandoah.isSupported()) { - testCompressedOopsModes(args, "-XX:+UseShenandoahGC"); + testCompressedOopsModes(args, "-XX:+UnlockExperimentalVMOptions", "-XX:+UseShenandoahGC"); } }
--- a/test/hotspot/jtreg/testlibrary/ctw/src/sun/hotspot/tools/ctw/CtwRunner.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/ctw/src/sun/hotspot/tools/ctw/CtwRunner.java Mon Feb 04 06:49:11 2019 -0800 @@ -263,6 +263,8 @@ "-XX:-UseCounterDecay", "-XX:-ShowMessageBoxOnError", "-XX:+UnlockDiagnosticVMOptions", + // redirect VM output to cerr so it won't collide w/ ctw output + "-XX:+DisplayVMOutputToStderr", // define phase start "-DCompileTheWorldStartAt=" + classStart, "-DCompileTheWorldStopAt=" + classStop,
--- a/test/hotspot/jtreg/testlibrary/jittester/Makefile Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/Makefile Mon Feb 04 06:49:11 2019 -0800 @@ -83,9 +83,9 @@ .PHONY: cleantmp -all: JAR +all: $(DIST_JAR) -JAR: INIT COMPILE manifest +$(DIST_JAR): INIT COMPILE manifest $(JAR) cfm $(DIST_JAR) $(MANIFEST) -C $(CLASSES_DIR) . manifest: @@ -107,7 +107,7 @@ INIT: $(DIST_DIR) $(shell if [ ! -d $(CLASSES_DIR) ]; then mkdir -p $(CLASSES_DIR); fi) -install: clean_testbase testgroup testroot copytestlibrary copyaot JAR cleantmp +install: clean_testbase testgroup testroot copytestlibrary copyaot $(DIST_JAR) cleantmp $(JAVA) --add-exports=java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED -ea -jar $(DIST_JAR) $(APPLICATION_ARGS) clean_testbase:
--- a/test/hotspot/jtreg/testlibrary/jittester/conf/default.properties Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/conf/default.properties Mon Feb 04 06:49:11 2019 -0800 @@ -1,6 +1,6 @@ seed=SEED2 number-of-tests=1000 -testbase-dir=ws/hotspot/test +testbase-dir=testbase fp-precision=7 min-cfg-depth=5 max-cfg-depth=5
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/AotTestGeneratorsFactory.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/AotTestGeneratorsFactory.java Mon Feb 04 06:49:11 2019 -0800 @@ -32,7 +32,7 @@ private static final String AOT_COMPILER_BUILD_ACTION = "@build compiler.aot.AotCompiler"; private static final String AOT_COMPILER_RUN_ACTION_PREFIX - = "@run driver compiler.aot.AotCompiler -libname aottest.so -class "; + = "@run driver compiler.aot.AotCompiler -extraopt -Xmixed -libname aottest.so -class "; @Override public List<TestsGenerator> apply(String[] input) {
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/Automatic.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/Automatic.java Mon Feb 04 06:49:11 2019 -0800 @@ -110,6 +110,7 @@ public static void main(String[] args) { initializeTestGenerator(args); int counter = 0; + System.out.printf("Generating %d tests...%n", ProductionParams.numberOfTests.value()); System.out.printf(" %13s | %8s | %8s | %8s |%n", "start time", "count", "generat", "running"); System.out.printf(" %13s | %8s | %8s | %8s |%n", "---", "---", "---", "---");
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/ByteCodeGenerator.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/ByteCodeGenerator.java Mon Feb 04 06:49:11 2019 -0800 @@ -39,7 +39,7 @@ private static final String DEFAULT_SUFFIX = "bytecode_tests"; ByteCodeGenerator() { - super(DEFAULT_SUFFIX); + super(DEFAULT_SUFFIX, s -> new String[0], "-Xcomp"); } ByteCodeGenerator(String suffix, Function<String, String[]> preRunActions, String jtDriverOptions) {
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/JavaCodeGenerator.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/JavaCodeGenerator.java Mon Feb 04 06:49:11 2019 -0800 @@ -34,7 +34,7 @@ private static final String DEFAULT_SUFFIX = "java_tests"; JavaCodeGenerator() { - this(DEFAULT_SUFFIX, JavaCodeGenerator::generatePrerunAction, ""); + this(DEFAULT_SUFFIX, JavaCodeGenerator::generatePrerunAction, "-Xcomp"); } JavaCodeGenerator(String prefix, Function<String, String[]> preRunActions, String jtDriverOptions) { @@ -64,13 +64,16 @@ } private void compileJavaFile(String mainClassName) { - String classPath = getRoot().resolve(generatorDir) - .toAbsolutePath() - .toString(); - ProcessBuilder pb = new ProcessBuilder(JAVAC, "-cp", classPath, + String classPath = tmpDir.toString(); + ProcessBuilder pb = new ProcessBuilder(JAVAC, + "-d", classPath, + "-cp", classPath, generatorDir.resolve(mainClassName + ".java").toString()); try { - runProcess(pb, generatorDir.resolve(mainClassName).toString()); + int r = runProcess(pb, tmpDir.resolve(mainClassName + ".javac").toString()); + if (r != 0) { + throw new Error("Can't compile sources, exit code = " + r); + } } catch (IOException | InterruptedException e) { throw new Error("Can't compile sources ", e); }
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/TestsGenerator.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/TestsGenerator.java Mon Feb 04 06:49:11 2019 -0800 @@ -42,6 +42,7 @@ protected static final String JAVAC = Paths.get(JAVA_BIN, "javac").toString(); protected static final String JAVA = Paths.get(JAVA_BIN, "java").toString(); protected final Path generatorDir; + protected final Path tmpDir; protected final Function<String, String[]> preRunActions; protected final String jtDriverOptions; private static final String DISABLE_WARNINGS = "-XX:-PrintWarnings"; @@ -52,15 +53,19 @@ protected TestsGenerator(String suffix, Function<String, String[]> preRunActions, String jtDriverOptions) { - generatorDir = getRoot().resolve(suffix); + generatorDir = getRoot().resolve(suffix).toAbsolutePath(); + try { + tmpDir = Files.createTempDirectory(suffix).toAbsolutePath(); + } catch (IOException e) { + throw new Error("Can't get a tmp dir for " + suffix, e); + } this.preRunActions = preRunActions; this.jtDriverOptions = jtDriverOptions; } protected void generateGoldenOut(String mainClassName) { - String classPath = getRoot().resolve(generatorDir) - .toAbsolutePath() - .toString(); + String classPath = tmpDir.toString() + File.pathSeparator + + generatorDir.toString(); ProcessBuilder pb = new ProcessBuilder(JAVA, "-Xint", DISABLE_WARNINGS, "-Xverify", "-cp", classPath, mainClassName); String goldFile = mainClassName + ".gold"; @@ -89,9 +94,10 @@ return -1; } - protected static void compilePrinter() { + protected void compilePrinter() { Path root = getRoot(); ProcessBuilder pbPrinter = new ProcessBuilder(JAVAC, + "-d", tmpDir.toString(), root.resolve("jdk") .resolve("test") .resolve("lib")
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/TypeList.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/TypeList.java Mon Feb 04 06:49:11 2019 -0800 @@ -23,11 +23,6 @@ package jdk.test.lib.jittester; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.util.function.Predicate; - import jdk.test.lib.jittester.types.TypeBoolean; import jdk.test.lib.jittester.types.TypeByte; import jdk.test.lib.jittester.types.TypeChar; @@ -39,6 +34,11 @@ import jdk.test.lib.jittester.types.TypeShort; import jdk.test.lib.jittester.types.TypeVoid; +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; +import java.util.function.Predicate; + public class TypeList { public static final TypeVoid VOID = new TypeVoid(); public static final TypeBoolean BOOLEAN = new TypeBoolean(); @@ -56,7 +56,7 @@ private static final List<Type> BUILTIN_TYPES = new ArrayList<>(); private static final List<Type> BUILTIN_INT_TYPES = new ArrayList<>(); private static final List<Type> BUILTIN_FP_TYPES = new ArrayList<>(); - private static final List<Type> REFERENCE_TYPES = new ArrayList<>(); + private static final List<TypeKlass> REFERENCE_TYPES = new ArrayList<>(); static { BUILTIN_INT_TYPES.add(BOOLEAN); @@ -99,7 +99,7 @@ return BUILTIN_FP_TYPES; } - protected static Collection<Type> getReferenceTypes() { + protected static Collection<TypeKlass> getReferenceTypes() { return REFERENCE_TYPES; } @@ -148,7 +148,7 @@ return null; } - public static void add(Type t) { + public static void add(TypeKlass t) { REFERENCE_TYPES.add(t); TYPES.add(t); } @@ -159,8 +159,12 @@ } public static void removeAll() { - Predicate<? super Type> isNotBasic = t -> t.getName().startsWith("Test_"); - TYPES.removeIf(isNotBasic); - REFERENCE_TYPES.removeIf(isNotBasic); + Predicate<? super String> isNotBasic = s -> s.startsWith("Test_"); + Predicate<? super Type> isNotBasicType = t -> isNotBasic.test(t.getName()); + REFERENCE_TYPES.stream() + .map(TypeKlass::getChildrenNames) + .forEach(l -> l.removeIf(isNotBasic)); + TYPES.removeIf(isNotBasicType); + REFERENCE_TYPES.removeIf(isNotBasicType); } }
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/factories/CastOperatorFactory.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/factories/CastOperatorFactory.java Mon Feb 04 06:49:11 2019 -0800 @@ -67,7 +67,7 @@ SymbolTable.merge(); return castOperator; } - throw new ProductionFailedException(); + SymbolTable.pop(); } catch (ProductionFailedException e) { SymbolTable.pop(); }
--- a/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/types/TypeKlass.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/testlibrary/jittester/src/jdk/test/lib/jittester/types/TypeKlass.java Mon Feb 04 06:49:11 2019 -0800 @@ -25,6 +25,7 @@ import java.util.Collection; import java.util.HashSet; +import java.util.Objects; import java.util.TreeSet; import jdk.test.lib.jittester.ProductionParams; import jdk.test.lib.jittester.Symbol; @@ -124,26 +125,28 @@ TreeSet<TypeKlass> result = new TreeSet<>(); parentsList.stream() .map(TypeList::find) - .filter(parentKlass -> parentKlass != null) - .map(parentKlass -> (TypeKlass) parentKlass) - .forEach(parentKlass -> { - result.add(parentKlass); - result.addAll(parentKlass.getAllParents()); + .filter(Objects::nonNull) + .map(k -> (TypeKlass) k) + .forEach(k -> { + if (result.add(k)) { + result.addAll(k.getAllParents()); + } }); return result; } public TreeSet<TypeKlass> getAllChildren() { - TreeSet<TypeKlass> r = new TreeSet<>(); + TreeSet<TypeKlass> result = new TreeSet<>(); childrenList.stream() .map(TypeList::find) - .filter(childKlass -> childKlass != null) - .map(childKlass -> (TypeKlass) childKlass) - .forEach(childKlass -> { - r.add(childKlass); - r.addAll(childKlass.getAllChildren()); + .filter(Objects::nonNull) + .map(k -> (TypeKlass) k) + .forEach(k -> { + if (result.add(k)) { + result.addAll(k.getAllChildren()); + } }); - return r; + return result; } @Override
--- a/test/hotspot/jtreg/vmTestbase/vm/mlvm/mixed/stress/regression/b6969574/INDIFY_Test.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/hotspot/jtreg/vmTestbase/vm/mlvm/mixed/stress/regression/b6969574/INDIFY_Test.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2019, 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 @@ -27,8 +27,7 @@ * @bug 6969574 * * @summary converted from VM Testbase vm/mlvm/mixed/stress/regression/b6969574. - * VM Testbase keywords: [feature_mlvm, nonconcurrent, quarantine] - * VM Testbase comments: 8079650 + * VM Testbase keywords: [feature_mlvm, nonconcurrent] * * @library /vmTestbase * /test/lib @@ -313,10 +312,8 @@ private final static int REFLECTION_CALL = 1; private final static int INVOKE_EXACT = 2; private final static int INVOKE = 3; - private final static int INVOKE_WITHARG = 4; - private final static int INVOKE_WITHARG_TYPECONV = 5; - private final static int INDY = 6; - private final static int BENCHMARK_COUNT = 7; + private final static int INDY = 4; + private final static int BENCHMARK_COUNT = 5; // // Test body @@ -356,18 +353,6 @@ } }); - benchmarks[INVOKE_WITHARG] = new Benchmark("MH.invokeWithArguments(), exact types", new T() { - public void run() throws Throwable { - mhTestee.invokeWithArguments(testData, TESTEE_ARG2, TESTEE_ARG3); - } - }); - - benchmarks[INVOKE_WITHARG_TYPECONV] = new Benchmark("MH.invokeWithArguments() + type conv.", new T() { - public void run() throws Throwable { - mhTestee.invokeWithArguments((Object) testData, null, (Short) Short.MAX_VALUE); - } - }); - benchmarks[INDY] = new Benchmark("invokedynamic instruction", new T() { public void run() throws Throwable { indyWrapper(testData); @@ -412,11 +397,9 @@ // TODO: exclude GC time, compilation time (optionally) from measurements print("Comparing invocation time orders"); - verifyTimeOrder(results[REFLECTION_CALL], results[INVOKE_EXACT]); + verifyTimeOrder(results[INDY], results[REFLECTION_CALL]); verifyTimeOrder(results[INVOKE_EXACT], results[DIRECT_CALL]); verifyTimeOrder(results[INVOKE], results[DIRECT_CALL]); - verifyTimeOrder(results[INVOKE_WITHARG], results[INVOKE_EXACT]); - verifyTimeOrder(results[INVOKE_WITHARG_TYPECONV], results[INVOKE_EXACT]); verifyTimeOrder(results[INVOKE_EXACT], results[INDY]); return true;
--- a/test/jdk/ProblemList-Xcomp.txt Thu Jan 17 10:44:17 2019 -0500 +++ b/test/jdk/ProblemList-Xcomp.txt Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ # -# Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2018, 2019, 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,4 +28,5 @@ ############################################################################# java/lang/invoke/MethodHandles/CatchExceptionTest.java 8146623 generic-all -java/lang/Class/forName/modules/TestDriver.java 8205526 solaris-all +java/util/concurrent/CountDownLatch/Basic.java 8195057 generic-all +java/util/stream/test/org/openjdk/tests/java/util/stream/StreamLinkTest.java 8216317 solaris-all
--- a/test/jdk/ProblemList-graal.txt Thu Jan 17 10:44:17 2019 -0500 +++ b/test/jdk/ProblemList-graal.txt Mon Feb 04 06:49:11 2019 -0800 @@ -69,6 +69,29 @@ java/lang/Runtime/exec/LotsOfOutput.java 8196611 generic-all java/util/concurrent/ScheduledThreadPoolExecutor/BasicCancelTest.java 8196611 generic-all +# tests require pop_frame and force_early_return capabilities +com/sun/jdi/RedefineTTYLineNumber.java 8195635 generic-all +com/sun/jdi/RedefineG.java 8195635 generic-all +com/sun/jdi/RedefineCrossStart.java 8195635 generic-all +com/sun/jdi/PopSynchronousTest.java 8195635 generic-all +com/sun/jdi/RedefineTTYLineNumber.java 8195635 generic-all +com/sun/jdi/RedefineG.java 8195635 generic-all +com/sun/jdi/RedefineCrossStart.java 8195635 generic-all +com/sun/jdi/PopSynchronousTest.java 8195635 generic-all +com/sun/jdi/PopAsynchronousTest.java 8195635 generic-all +com/sun/jdi/PopAndStepTest.java 8195635 generic-all +com/sun/jdi/PopAsynchronousTest.java 8195635 generic-all +com/sun/jdi/PopAndStepTest.java 8195635 generic-all +com/sun/jdi/EarlyReturnTest.java 8195635 generic-all +com/sun/jdi/RedefineTTYLineNumber.java 8195635 generic-all +com/sun/jdi/RedefineG.java 8195635 generic-all +com/sun/jdi/RedefineCrossStart.java 8195635 generic-all +com/sun/jdi/PopSynchronousTest.java 8195635 generic-all +com/sun/jdi/PopAsynchronousTest.java 8195635 generic-all +com/sun/jdi/PopAndStepTest.java 8195635 generic-all +com/sun/jdi/EarlyReturnTest.java 8195635 generic-all +com/sun/jdi/EarlyReturnTest.java 8195635 generic-all + # Next JFR tests fail with Graal. Assuming 8193210. jdk/jfr/event/compiler/TestCodeSweeper.java 8193210 generic-all jdk/jfr/event/compiler/TestCompilerInlining.java 8193210 generic-all
--- a/test/jdk/ProblemList.txt Thu Jan 17 10:44:17 2019 -0500 +++ b/test/jdk/ProblemList.txt Mon Feb 04 06:49:11 2019 -0800 @@ -254,7 +254,6 @@ java/awt/Choice/ChoiceMouseWheelTest/ChoiceMouseWheelTest.java 7100044 macosx-all,linux-all java/awt/Component/CreateImage/CreateImage.java 8198334 windows-all java/awt/Component/GetScreenLocTest/GetScreenLocTest.java 4753654 generic-all -java/awt/Choice/SelectCurrentItemTest/SelectCurrentItemTest.html 8192929 windows-all,linux-all java/awt/Clipboard/HTMLTransferTest/HTMLTransferTest.html 8017454 macosx-all java/awt/Focus/NonFocusableWindowTest/NoEventsTest.java 8000171 windows-all java/awt/Frame/MiscUndecorated/RepaintTest.java 8079267 windows-all,linux-all @@ -516,6 +515,7 @@ java/lang/StringCoding/CheckEncodings.sh 7008363 generic-all java/lang/ProcessHandle/InfoTest.java 8211847 aix-ppc64 +java/lang/invoke/LFCaching/LFMultiThreadCachingTest.java 8151492 generic-all ############################################################################
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/jdk/java/awt/Choice/SelectNewItemTest/SelectNewItemTest.java Mon Feb 04 06:49:11 2019 -0800 @@ -0,0 +1,180 @@ +/* + * Copyright (c) 2019, 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 8215921 + @summary Test that selecting a different item does send an ItemEvent + @key headful + @run main SelectNewItemTest +*/ + +import java.awt.Choice; +import java.awt.Robot; +import java.awt.Frame; +import java.awt.BorderLayout; +import java.awt.AWTException; +import java.awt.Point; +import java.awt.Dimension; +import java.awt.event.InputEvent; +import java.awt.event.ItemListener; +import java.awt.event.WindowListener; +import java.awt.event.ItemEvent; +import java.awt.event.WindowEvent; +import java.util.concurrent.CountDownLatch; +import java.util.concurrent.TimeUnit; + +public class SelectNewItemTest implements ItemListener, WindowListener { + //Declare things used in the test, like buttons and labels here + private Frame frame; + private Choice theChoice; + private Robot robot; + + private CountDownLatch latch = new CountDownLatch(1); + private volatile boolean passed = false; + + private void init() + { + try { + robot = new Robot(); + robot.setAutoDelay(500); + } catch (AWTException e) { + throw new RuntimeException("Unable to create Robot. Test fails."); + } + + frame = new Frame("SelectNewItemTest"); + frame.setLayout(new BorderLayout()); + theChoice = new Choice(); + for (int i = 0; i < 10; i++) { + theChoice.add(new String("Choice Item " + i)); + } + theChoice.addItemListener(this); + frame.add(theChoice); + frame.addWindowListener(this); + + frame.setLocation(1,20); + frame.setSize(200, 50); + robot.mouseMove(10, 30); + frame.pack(); + frame.setVisible(true); + } + + public static void main(String... args) { + SelectNewItemTest test = new SelectNewItemTest(); + test.init(); + try { + test.latch.await(12000, TimeUnit.MILLISECONDS); + } catch (InterruptedException e) {} + test.robot.waitForIdle(); + + try { + if (!test.passed) { + throw new RuntimeException("TEST FAILED."); + } + } finally { + test.frame.dispose(); + } + } + + private void run() { + try { + Thread.sleep(1000); + + Point loc = theChoice.getLocationOnScreen(); + int selectedIndex = theChoice.getSelectedIndex(); + Dimension size = theChoice.getSize(); + + robot.mouseMove(loc.x + size.width - 10, loc.y + size.height / 2); + + robot.setAutoDelay(250); + robot.mousePress(InputEvent.BUTTON1_DOWN_MASK); + robot.mouseRelease(InputEvent.BUTTON1_DOWN_MASK); + + robot.delay(1000); + + //make sure that the mouse moves to a different item, so that + //itemStateChanged is called. + robot.mouseMove(loc.x + size.width / 2, loc.y + 3 * size.height); + robot.mousePress(InputEvent.BUTTON1_DOWN_MASK); + robot.mouseRelease(InputEvent.BUTTON1_DOWN_MASK); + robot.waitForIdle(); + + if (selectedIndex == theChoice.getSelectedIndex()) + throw new RuntimeException("Test case failed - expected to select" + + " a different item than " + selectedIndex); + + selectedIndex = theChoice.getSelectedIndex(); + //now click on the same item and make sure that item event is + //not generated. + robot.delay(1000); + robot.mouseMove(loc.x + size.width - 10, loc.y + size.height / 2); + + robot.mousePress(InputEvent.BUTTON1_DOWN_MASK); + //Make sure that the popup menu scrolls back to show the index from + //beginning, so that the second mouse click happens on the previously + //selected item. + //For example, on windows, it automatically scrolls the list to show + //the currently selected item just below the choice, which can + //throw off the test. + if (System.getProperty("os.name").toLowerCase().startsWith("win")) { + robot.mouseWheel(-100); + } + robot.mouseRelease(InputEvent.BUTTON1_DOWN_MASK); + + robot.delay(1000); + robot.mouseMove(loc.x + size.width / 2, loc.y + 3 * size.height); + robot.mousePress(InputEvent.BUTTON1_DOWN_MASK); + robot.mouseRelease(InputEvent.BUTTON1_DOWN_MASK); + robot.waitForIdle(); + + if (selectedIndex != theChoice.getSelectedIndex()) + throw new RuntimeException("Test failed. Expected to select the same item " + + "located at: " + selectedIndex + " but got an item selected at: " + theChoice.getSelectedIndex()); + } catch(InterruptedException e) { + throw new RuntimeException(e.getCause()); + } finally { + latch.countDown(); + } + } + + @Override public void itemStateChanged(ItemEvent e) { + if (!passed) { + System.out.println("ItemEvent received. Test passes"); + passed = true; + } else { + System.out.println("ItemEvent received for second click. Test fails"); + passed = false; + } + } + + @Override public void windowOpened(WindowEvent e) { + System.out.println("windowActivated()"); + (new Thread(this::run)).start(); + } + + @Override public void windowActivated(WindowEvent e) {} + @Override public void windowDeactivated(WindowEvent e) {} + @Override public void windowClosed(WindowEvent e) {} + @Override public void windowClosing(WindowEvent e) {} + @Override public void windowIconified(WindowEvent e) {} + @Override public void windowDeiconified(WindowEvent e) {} +}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/jdk/java/awt/FontClass/FontSize1Test.java Mon Feb 04 06:49:11 2019 -0800 @@ -0,0 +1,56 @@ +/* + * Copyright (c) 2019, 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 8216965 + * @summary verify no crash when rendering size 1 fonts + */ + +import java.awt.Font; +import java.awt.Graphics2D; +import java.awt.GraphicsEnvironment; +import java.awt.image.BufferedImage; + +public class FontSize1Test { + + static final String text = "abcdefghijklmnopqrstuvwxyz"; + + public static void main(String[] args) { + + BufferedImage bi = + new BufferedImage(100, 20, BufferedImage.TYPE_INT_RGB); + Graphics2D g2d = bi.createGraphics(); + Font af[] = + GraphicsEnvironment.getLocalGraphicsEnvironment().getAllFonts(); + + for (Font f : af) { + System.out.println("Looking at font " + f); + g2d.setFont(f); + g2d.getFontMetrics().getWidths(); + g2d.drawString(text, 50, 10); + } + g2d.dispose(); + } + +}
--- a/test/jdk/java/net/Socket/ExceptionText.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/jdk/java/net/Socket/ExceptionText.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2018, 2019, 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,12 +25,10 @@ * @test * @library /test/lib * @build jdk.test.lib.Utils - * @bug 8204233 8207846 8208691 + * @bug 8204233 * @summary Add configurable option for enhanced socket IOException messages * @run main/othervm * ExceptionText - * @run main/othervm - * ExceptionText * WITHOUT_Enhanced_Text * @run main/othervm * -Djdk.includeInExceptions= @@ -64,7 +62,6 @@ import java.nio.channels.AsynchronousSocketChannel; import java.nio.channels.ClosedChannelException; import java.nio.channels.SocketChannel; -import java.security.Security; import java.util.concurrent.ExecutionException; import jdk.test.lib.Utils; @@ -73,33 +70,20 @@ enum TestTarget {SOCKET, CHANNEL, ASYNC_CHANNEL}; public static void main(String args[]) throws Exception { - if (args.length == 0) { - testSecProp(); + String passOrFail = args[0]; + boolean expectEnhancedText; + if (passOrFail.equals("expectEnhancedText")) { + expectEnhancedText = true; } else { - String passOrFail = args[0]; - boolean expectEnhancedText; - if (passOrFail.equals("expectEnhancedText")) { - expectEnhancedText = true; - } else { - expectEnhancedText = false; - } - test(expectEnhancedText); + expectEnhancedText = false; } + test(expectEnhancedText); } static final InetSocketAddress dest = Utils.refusingEndpoint(); static final String PORT = ":" + Integer.toString(dest.getPort()); static final String HOST = dest.getHostString(); - static void testSecProp() { - String incInExc = Security.getProperty("jdk.includeInExceptions"); - if (incInExc != null) { - throw new RuntimeException("Test failed: default value of " + - "jdk.includeInExceptions security property is not null: " + - incInExc); - } - } - static void test(boolean withProperty) { // Socket IOException e = getException(TestTarget.SOCKET); @@ -132,10 +116,11 @@ static IOException getException(TestTarget target) { try { if (target == TestTarget.SOCKET) { - Socket s = new Socket(); - s.connect(dest); + try (Socket s = new Socket()) { + s.connect(dest); + } } else if (target == TestTarget.CHANNEL) { - SocketChannel c = SocketChannel.open(dest); + SocketChannel.open(dest); } else if (target == TestTarget.ASYNC_CHANNEL) { AsynchronousSocketChannel c = AsynchronousSocketChannel.open(); try {
--- a/test/jdk/javax/net/ssl/sanity/ciphersuites/CheckCipherSuites.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/jdk/javax/net/ssl/sanity/ciphersuites/CheckCipherSuites.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2019, 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,221 +23,180 @@ /* * @test - * @bug 4750141 4895631 + * @bug 4750141 4895631 8217579 * @summary Check enabled and supported ciphersuites are correct - * @ignore JSSE supported cipher suites are changed with CR 6916074, - * need to update this test case in JDK 7 soon + * @run main CheckCipherSuites default + * @run main/othervm CheckCipherSuites limited */ import java.util.*; - +import java.security.Security; import javax.net.ssl.*; -import javax.crypto.Cipher; -import javax.crypto.spec.*; - public class CheckCipherSuites { + // List of enabled cipher suites when the "crypto.policy" security + // property is set to "unlimited" (the default value). private final static String[] ENABLED_DEFAULT = { - "SSL_RSA_WITH_RC4_128_MD5", - "SSL_RSA_WITH_RC4_128_SHA", + "TLS_AES_128_GCM_SHA256", + "TLS_AES_256_GCM_SHA384", + "TLS_CHACHA20_POLY1305_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256", + "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256", + "TLS_RSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384", + "TLS_DHE_RSA_WITH_AES_256_GCM_SHA384", + "TLS_DHE_RSA_WITH_CHACHA20_POLY1305_SHA256", + "TLS_DHE_DSS_WITH_AES_256_GCM_SHA384", + "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_RSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_DSS_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", + "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384", + "TLS_RSA_WITH_AES_256_CBC_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384", + "TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384", + "TLS_DHE_RSA_WITH_AES_256_CBC_SHA256", + "TLS_DHE_DSS_WITH_AES_256_CBC_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA", + "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA", + "TLS_RSA_WITH_AES_256_CBC_SHA", + "TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA", + "TLS_ECDH_RSA_WITH_AES_256_CBC_SHA", + "TLS_DHE_RSA_WITH_AES_256_CBC_SHA", + "TLS_DHE_DSS_WITH_AES_256_CBC_SHA", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_RSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_DSS_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", "TLS_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_RC4_128_SHA", "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_RSA_WITH_RC4_128_SHA", "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_RC4_128_SHA", - "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_RSA_WITH_RC4_128_SHA", - "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", "TLS_DHE_RSA_WITH_AES_128_CBC_SHA", "TLS_DHE_DSS_WITH_AES_128_CBC_SHA", - "SSL_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA", - "SSL_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_DSS_WITH_DES_CBC_SHA", - "SSL_RSA_EXPORT_WITH_RC4_40_MD5", - "SSL_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA", - "TLS_EMPTY_RENEGOTIATION_INFO_SCSV", - + "TLS_EMPTY_RENEGOTIATION_INFO_SCSV" }; - private final static String[] ENABLED_UNLIMITED = { - "SSL_RSA_WITH_RC4_128_MD5", - "SSL_RSA_WITH_RC4_128_SHA", + // List of enabled cipher suites when the "crypto.policy" security + // property is set to "limited". + private final static String[] ENABLED_LIMITED = { + "TLS_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_RSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_DSS_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_RSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_DSS_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", "TLS_RSA_WITH_AES_128_CBC_SHA", - "TLS_RSA_WITH_AES_256_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_RC4_128_SHA", "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA", - "TLS_ECDH_RSA_WITH_RC4_128_SHA", "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_RSA_WITH_AES_256_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_RC4_128_SHA", - "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA", - "TLS_ECDHE_RSA_WITH_RC4_128_SHA", - "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA", "TLS_DHE_RSA_WITH_AES_128_CBC_SHA", - "TLS_DHE_RSA_WITH_AES_256_CBC_SHA", "TLS_DHE_DSS_WITH_AES_128_CBC_SHA", - "TLS_DHE_DSS_WITH_AES_256_CBC_SHA", - "SSL_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA", - "SSL_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_DSS_WITH_DES_CBC_SHA", - "SSL_RSA_EXPORT_WITH_RC4_40_MD5", - "SSL_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA", - "TLS_EMPTY_RENEGOTIATION_INFO_SCSV", - + "TLS_EMPTY_RENEGOTIATION_INFO_SCSV" }; - // supported ciphersuites using default JCE policy jurisdiction files - // AES/256 unavailable + // List of supported cipher suites when the "crypto.policy" security + // property is set to "unlimited" (the default value). private final static String[] SUPPORTED_DEFAULT = { - "SSL_RSA_WITH_RC4_128_MD5", - "SSL_RSA_WITH_RC4_128_SHA", + "TLS_AES_128_GCM_SHA256", + "TLS_AES_256_GCM_SHA384", + "TLS_CHACHA20_POLY1305_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256", + "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256", + "TLS_RSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384", + "TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384", + "TLS_DHE_RSA_WITH_AES_256_GCM_SHA384", + "TLS_DHE_RSA_WITH_CHACHA20_POLY1305_SHA256", + "TLS_DHE_DSS_WITH_AES_256_GCM_SHA384", + "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_RSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_DSS_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", + "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384", + "TLS_RSA_WITH_AES_256_CBC_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384", + "TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384", + "TLS_DHE_RSA_WITH_AES_256_CBC_SHA256", + "TLS_DHE_DSS_WITH_AES_256_CBC_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA", + "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA", + "TLS_RSA_WITH_AES_256_CBC_SHA", + "TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA", + "TLS_ECDH_RSA_WITH_AES_256_CBC_SHA", + "TLS_DHE_RSA_WITH_AES_256_CBC_SHA", + "TLS_DHE_DSS_WITH_AES_256_CBC_SHA", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_RSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_DSS_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", "TLS_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_RC4_128_SHA", "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_RSA_WITH_RC4_128_SHA", "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_RC4_128_SHA", - "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_RSA_WITH_RC4_128_SHA", - "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", "TLS_DHE_RSA_WITH_AES_128_CBC_SHA", "TLS_DHE_DSS_WITH_AES_128_CBC_SHA", - "SSL_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA", - "SSL_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_DSS_WITH_DES_CBC_SHA", - "SSL_RSA_EXPORT_WITH_RC4_40_MD5", - "SSL_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA", - "TLS_EMPTY_RENEGOTIATION_INFO_SCSV", - - "SSL_RSA_WITH_NULL_MD5", - "SSL_RSA_WITH_NULL_SHA", - "TLS_ECDH_ECDSA_WITH_NULL_SHA", - "TLS_ECDH_RSA_WITH_NULL_SHA", - "TLS_ECDHE_ECDSA_WITH_NULL_SHA", - "TLS_ECDHE_RSA_WITH_NULL_SHA", - "SSL_DH_anon_WITH_RC4_128_MD5", - "TLS_DH_anon_WITH_AES_128_CBC_SHA", - "SSL_DH_anon_WITH_3DES_EDE_CBC_SHA", - "SSL_DH_anon_WITH_DES_CBC_SHA", - "TLS_ECDH_anon_WITH_RC4_128_SHA", - "TLS_ECDH_anon_WITH_AES_128_CBC_SHA", - "TLS_ECDH_anon_WITH_3DES_EDE_CBC_SHA", - "SSL_DH_anon_EXPORT_WITH_RC4_40_MD5", - "SSL_DH_anon_EXPORT_WITH_DES40_CBC_SHA", - "TLS_ECDH_anon_WITH_NULL_SHA", - "TLS_KRB5_WITH_RC4_128_SHA", - "TLS_KRB5_WITH_RC4_128_MD5", - "TLS_KRB5_WITH_3DES_EDE_CBC_SHA", - "TLS_KRB5_WITH_3DES_EDE_CBC_MD5", - "TLS_KRB5_WITH_DES_CBC_SHA", - "TLS_KRB5_WITH_DES_CBC_MD5", - "TLS_KRB5_EXPORT_WITH_RC4_40_SHA", - "TLS_KRB5_EXPORT_WITH_RC4_40_MD5", - "TLS_KRB5_EXPORT_WITH_DES_CBC_40_SHA", - "TLS_KRB5_EXPORT_WITH_DES_CBC_40_MD5", - + "TLS_EMPTY_RENEGOTIATION_INFO_SCSV" }; - // supported ciphersuites using unlimited JCE policy jurisdiction files - // AES/256 available - private final static String[] SUPPORTED_UNLIMITED = { - "SSL_RSA_WITH_RC4_128_MD5", - "SSL_RSA_WITH_RC4_128_SHA", + // List of supported cipher suites when the "crypto.policy" security + // property is set to "limited". + private final static String[] SUPPORTED_LIMITED = { + "TLS_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_RSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_RSA_WITH_AES_128_GCM_SHA256", + "TLS_DHE_DSS_WITH_AES_128_GCM_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_RSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256", + "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_RSA_WITH_AES_128_CBC_SHA256", + "TLS_DHE_DSS_WITH_AES_128_CBC_SHA256", + "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", + "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", "TLS_RSA_WITH_AES_128_CBC_SHA", - "TLS_RSA_WITH_AES_256_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_RC4_128_SHA", "TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA", - "TLS_ECDH_RSA_WITH_RC4_128_SHA", "TLS_ECDH_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDH_RSA_WITH_AES_256_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_RC4_128_SHA", - "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA", - "TLS_ECDHE_RSA_WITH_RC4_128_SHA", - "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA", - "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA", "TLS_DHE_RSA_WITH_AES_128_CBC_SHA", - "TLS_DHE_RSA_WITH_AES_256_CBC_SHA", "TLS_DHE_DSS_WITH_AES_128_CBC_SHA", - "TLS_DHE_DSS_WITH_AES_256_CBC_SHA", - "SSL_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA", - "TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA", - "SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA", - "SSL_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_RSA_WITH_DES_CBC_SHA", - "SSL_DHE_DSS_WITH_DES_CBC_SHA", - "SSL_RSA_EXPORT_WITH_RC4_40_MD5", - "SSL_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA", - "SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA", - "TLS_EMPTY_RENEGOTIATION_INFO_SCSV", - - "SSL_RSA_WITH_NULL_MD5", - "SSL_RSA_WITH_NULL_SHA", - "TLS_ECDH_ECDSA_WITH_NULL_SHA", - "TLS_ECDH_RSA_WITH_NULL_SHA", - "TLS_ECDHE_ECDSA_WITH_NULL_SHA", - "TLS_ECDHE_RSA_WITH_NULL_SHA", - "SSL_DH_anon_WITH_RC4_128_MD5", - "TLS_DH_anon_WITH_AES_128_CBC_SHA", - "TLS_DH_anon_WITH_AES_256_CBC_SHA", - "SSL_DH_anon_WITH_3DES_EDE_CBC_SHA", - "SSL_DH_anon_WITH_DES_CBC_SHA", - "TLS_ECDH_anon_WITH_RC4_128_SHA", - "TLS_ECDH_anon_WITH_AES_128_CBC_SHA", - "TLS_ECDH_anon_WITH_AES_256_CBC_SHA", - "TLS_ECDH_anon_WITH_3DES_EDE_CBC_SHA", - "SSL_DH_anon_EXPORT_WITH_RC4_40_MD5", - "SSL_DH_anon_EXPORT_WITH_DES40_CBC_SHA", - "TLS_ECDH_anon_WITH_NULL_SHA", - "TLS_KRB5_WITH_RC4_128_SHA", - "TLS_KRB5_WITH_RC4_128_MD5", - "TLS_KRB5_WITH_3DES_EDE_CBC_SHA", - "TLS_KRB5_WITH_3DES_EDE_CBC_MD5", - "TLS_KRB5_WITH_DES_CBC_SHA", - "TLS_KRB5_WITH_DES_CBC_MD5", - "TLS_KRB5_EXPORT_WITH_RC4_40_SHA", - "TLS_KRB5_EXPORT_WITH_RC4_40_MD5", - "TLS_KRB5_EXPORT_WITH_DES_CBC_40_SHA", - "TLS_KRB5_EXPORT_WITH_DES_CBC_40_MD5", - + "TLS_EMPTY_RENEGOTIATION_INFO_SCSV" }; private static void showSuites(String[] suites) { @@ -252,19 +211,21 @@ public static void main(String[] args) throws Exception { long start = System.currentTimeMillis(); + if (args.length != 1) { + throw new Exception("One arg required"); + } + String[] ENABLED; String[] SUPPORTED; - try { - Cipher c = Cipher.getInstance("AES/CBC/NoPadding"); - SecretKeySpec key = new SecretKeySpec(new byte[32], "AES"); - c.init(Cipher.ENCRYPT_MODE, key); - System.out.println("AES/256 is available"); - ENABLED = ENABLED_UNLIMITED; - SUPPORTED = SUPPORTED_UNLIMITED; - } catch (Exception e) { - System.out.println("AES/256 is NOT available (" + e + ")"); + if (args[0].equals("default")) { ENABLED = ENABLED_DEFAULT; SUPPORTED = SUPPORTED_DEFAULT; + } else if (args[0].equals("limited")) { + Security.setProperty("crypto.policy", "limited"); + ENABLED = ENABLED_LIMITED; + SUPPORTED = SUPPORTED_LIMITED; + } else { + throw new Exception("Illegal argument"); } SSLSocketFactory factory = (SSLSocketFactory)SSLSocketFactory.getDefault();
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/jdk/jdk/security/JavaDotSecurity/TestJDKIncludeInExceptions.java Mon Feb 04 06:49:11 2019 -0800 @@ -0,0 +1,45 @@ +/* + * Copyright (c) 2018, 2019, 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.security.Security; + +/** + * @test + * @bug 8207846 8208691 + * @summary Test the default setting of the jdk.net.includeInExceptions + * security property + * @comment In OpenJDK, this property is empty by default and on purpose. + * This test assures the default is not changed. + * @run main TestJDKIncludeInExceptions + */ +public class TestJDKIncludeInExceptions { + + public static void main(String args[]) throws Exception { + String incInExc = Security.getProperty("jdk.includeInExceptions"); + if (incInExc != null) { + throw new RuntimeException("Test failed: default value of " + + "jdk.includeInExceptions security property is not null: " + + incInExc); + } + } +}
--- a/test/jdk/tools/launcher/Test7029048.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/jdk/tools/launcher/Test7029048.java Mon Feb 04 06:49:11 2019 -0800 @@ -154,12 +154,22 @@ } desc = "LD_LIBRARY_PATH should not be set (no libjvm.so)"; + if (TestHelper.isAIX) { + System.out.println("Skipping test case \"" + desc + + "\" because the Aix launcher adds the paths in any case."); + continue; + } break; case NO_DIR: if (dstLibDir.exists()) { recursiveDelete(dstLibDir); } desc = "LD_LIBRARY_PATH should not be set (no directory)"; + if (TestHelper.isAIX) { + System.out.println("Skipping test case \"" + desc + + "\" because the Aix launcher adds the paths in any case."); + continue; + } break; default: throw new RuntimeException("unknown case");
--- a/test/jtreg-ext/requires/VMProps.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/jtreg-ext/requires/VMProps.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2019, 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 @@ -86,6 +86,7 @@ map.put("vm.rtm.cpu", vmRTMCPU()); map.put("vm.rtm.compiler", vmRTMCompiler()); map.put("vm.aot", vmAOT()); + map.put("vm.aot.enabled", vmAotEnabled()); // vm.cds is true if the VM is compiled with cds support. map.put("vm.cds", vmCDS()); map.put("vm.cds.custom.loaders", vmCDSForCustomLoaders()); @@ -96,6 +97,7 @@ map.put("vm.compiler2.enabled", isCompiler2Enabled()); map.put("docker.support", dockerSupport()); map.put("release.implementor", implementor()); + map.put("test.vm.gc.nvdimm", isNvdimmTestEnabled()); vmGC(map); // vm.gc.X = true/false vmOptFinalFlags(map); @@ -266,6 +268,7 @@ vmOptFinalFlag(map, "ClassUnloading"); vmOptFinalFlag(map, "UseCompressedOops"); vmOptFinalFlag(map, "EnableJVMCI"); + vmOptFinalFlag(map, "EliminateAllocations"); } /** @@ -334,6 +337,13 @@ return "" + Files.exists(jaotc); } + /* + * @return true if there is at least one loaded AOT'ed library. + */ + protected String vmAotEnabled() { + return "" + (WB.aotLibrariesCount() > 0); + } + /** * Check for CDS support. * @@ -460,6 +470,15 @@ return null; } + private String isNvdimmTestEnabled() { + String isEnbled = System.getenv("TEST_VM_GC_NVDIMM"); + if (isEnbled != null && isEnbled.toLowerCase().equals("true")) { + return "true"; + } + return "false"; + } + + /** * Dumps the map to the file if the file name is given as the property.
--- a/test/lib/sun/hotspot/WhiteBox.java Thu Jan 17 10:44:17 2019 -0500 +++ b/test/lib/sun/hotspot/WhiteBox.java Mon Feb 04 06:49:11 2019 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2019, 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 @@ -549,4 +549,7 @@ // Protection Domain Table public native int protectionDomainRemovedCount(); + + // Number of loaded AOT libraries + public native int aotLibrariesCount(); }