mirror of
https://github.com/openjdk/jdk.git
synced 2026-03-20 12:53:29 +00:00
8300823: UB: Compile::_phase_optimize_finished is initialized too late
Reviewed-by: thartmann, chagedorn
This commit is contained in:
parent
db8fa1be05
commit
e4252bb914
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1997, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1997, 2023, 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
|
||||
@ -977,6 +977,12 @@ void Compile::Init(bool aliasing) {
|
||||
|
||||
_immutable_memory = NULL; // filled in at first inquiry
|
||||
|
||||
#ifdef ASSERT
|
||||
_type_verify_symmetry = true;
|
||||
_phase_optimize_finished = false;
|
||||
_exception_backedge = false;
|
||||
#endif
|
||||
|
||||
// Globally visible Nodes
|
||||
// First set TOP to NULL to give safe behavior during creation of RootNode
|
||||
set_cached_top_node(NULL);
|
||||
@ -1070,12 +1076,6 @@ void Compile::Init(bool aliasing) {
|
||||
Copy::zero_to_bytes(_alias_cache, sizeof(_alias_cache));
|
||||
// A NULL adr_type hits in the cache right away. Preload the right answer.
|
||||
probe_alias_cache(NULL)->_index = AliasIdxTop;
|
||||
|
||||
#ifdef ASSERT
|
||||
_type_verify_symmetry = true;
|
||||
_phase_optimize_finished = false;
|
||||
_exception_backedge = false;
|
||||
#endif
|
||||
}
|
||||
|
||||
//---------------------------init_start----------------------------------------
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user