Skip to content

Commit

Permalink
8252966: CI: Remove KILL_COMPILE_ON_FATAL_ and KILL_COMPILE_ON_ANY ma…
Browse files Browse the repository at this point in the history
…cros

Remove the KILL_COMPILE_ON_FATAL_ and KILL_COMPILE_ON_ANY macros, replacing uses
 of KILL_COMPILE_ON_FATAL_ with CHECK_AND_CLEAR_. Unlike KILL_COMPILE_ON_FATAL_,
 CHECK_AND_CLEAR_ ignores ThreadDeath exceptions, which compiler threads should
 not receive anyway.
  • Loading branch information
robcasloz committed Sep 15, 2020
1 parent 9ea43a9 commit f249446
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 26 deletions.
4 changes: 2 additions & 2 deletions src/hotspot/share/ci/ciEnv.cpp
Expand Up @@ -453,10 +453,10 @@ ciKlass* ciEnv::get_klass_by_name_impl(ciKlass* accessing_klass,
Klass* kls;
if (!require_local) {
kls = SystemDictionary::find_constrained_instance_or_array_klass(sym, loader,
KILL_COMPILE_ON_FATAL_(fail_type));
CHECK_AND_CLEAR_(fail_type));
} else {
kls = SystemDictionary::find_instance_or_array_klass(sym, loader, domain,
KILL_COMPILE_ON_FATAL_(fail_type));
CHECK_AND_CLEAR_(fail_type));
}
found_klass = kls;
}
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/ci/ciField.cpp
Expand Up @@ -400,7 +400,7 @@ bool ciField::will_link(ciMethod* accessing_method,
_name->get_symbol(), _signature->get_symbol(),
methodHandle(THREAD, accessing_method->get_Method()));
fieldDescriptor result;
LinkResolver::resolve_field(result, link_info, bc, false, KILL_COMPILE_ON_FATAL_(false));
LinkResolver::resolve_field(result, link_info, bc, false, CHECK_AND_CLEAR_(false));

// update the hit-cache, unless there is a problem with memory scoping:
if (accessing_method->holder()->is_shared() || !is_shared()) {
Expand Down
23 changes: 0 additions & 23 deletions src/hotspot/share/ci/ciUtilities.inline.hpp
Expand Up @@ -66,27 +66,4 @@
#define GUARDED_VM_QUICK_ENTRY(action) \
{if (IS_IN_VM) { action } else { VM_QUICK_ENTRY_MARK; { action }}}

// Redefine this later.
#define KILL_COMPILE_ON_FATAL_(result) \
THREAD); \
if (HAS_PENDING_EXCEPTION) { \
if (PENDING_EXCEPTION->klass() == \
SystemDictionary::ThreadDeath_klass()) { \
/* Kill the compilation. */ \
fatal("unhandled ci exception"); \
return (result); \
} \
CLEAR_PENDING_EXCEPTION; \
return (result); \
} \
(void)(0

#define KILL_COMPILE_ON_ANY \
THREAD); \
if (HAS_PENDING_EXCEPTION) { \
fatal("unhandled ci exception"); \
CLEAR_PENDING_EXCEPTION; \
} \
(void)(0

#endif // SHARE_CI_CIUTILITIES_INLINE_HPP

0 comments on commit f249446

Please sign in to comment.