Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-17 Thread Vladimir Kozlov
On Wed, 17 Apr 2024 20:27:53 GMT, Dean Long wrote: >> Okay. But I will put above code under `#ifdef ASSERT` then. > > The ASSERT block above looks unnecessary, now that field assignments below > are using checked_cast. Agree, but I need to change how I use checked_cast below to get the same

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-17 Thread Dean Long
On Tue, 16 Apr 2024 16:09:21 GMT, Vladimir Kozlov wrote: >> src/hotspot/share/code/nmethod.cpp line 1441: >> >>> 1439: int deps_size = align_up((int)dependencies->size_in_bytes(), >>> oopSize); >>> 1440: int sum_size = oops_size + metadata_size + deps_size; >>> 1441:

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-16 Thread Vladimir Kozlov
On Tue, 16 Apr 2024 06:13:59 GMT, Dean Long wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Union fields which usages do not overlap > > src/hotspot/share/code/nmethod.cpp line 1235: > >> 1233: int

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-16 Thread Vladimir Kozlov
On Tue, 16 Apr 2024 06:48:05 GMT, Dean Long wrote: >> I thought about that but in both places where these accessors are called >> (`frame::get_native_monitor()` and `frame::get_native_receiver()`) there are >> such asserts already: >>

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-16 Thread Dean Long
On Tue, 16 Apr 2024 03:12:48 GMT, Vladimir Kozlov wrote: >> src/hotspot/share/code/nmethod.hpp line 282: >> >>> 280: _has_flushed_dependencies:1, // Used for maintenance of >>> dependencies (under CodeCache_lock) >>> 281: _is_unlinked:1, // mark during class

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-16 Thread Dean Long
On Tue, 16 Apr 2024 03:06:13 GMT, Vladimir Kozlov wrote: >> src/hotspot/share/code/nmethod.hpp line 205: >> >>> 203: // offsets to find the receiver for non-static native wrapper >>> frames. >>> 204: ByteSize _native_receiver_sp_offset; >>> 205: ByteSize

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-16 Thread Dean Long
On Mon, 15 Apr 2024 03:24:07 GMT, Vladimir Kozlov wrote: >> This is part of changes which try to reduce size of `nmethod` and `codeblob` >> data vs code in CodeCache. >> These changes reduced size of `nmethod` header from 288 to 232 bytes. From >> 304 to 248 in optimized VM: >> >> Statistics

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-16 Thread Dean Long
On Mon, 15 Apr 2024 03:24:07 GMT, Vladimir Kozlov wrote: >> This is part of changes which try to reduce size of `nmethod` and `codeblob` >> data vs code in CodeCache. >> These changes reduced size of `nmethod` header from 288 to 232 bytes. From >> 304 to 248 in optimized VM: >> >> Statistics

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-16 Thread Dean Long
On Mon, 15 Apr 2024 03:24:07 GMT, Vladimir Kozlov wrote: >> This is part of changes which try to reduce size of `nmethod` and `codeblob` >> data vs code in CodeCache. >> These changes reduced size of `nmethod` header from 288 to 232 bytes. From >> 304 to 248 in optimized VM: >> >> Statistics

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-15 Thread Vladimir Kozlov
On Tue, 16 Apr 2024 02:28:14 GMT, Dean Long wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Union fields which usages do not overlap > > src/hotspot/share/code/nmethod.hpp line 282: > >> 280:

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-15 Thread Vladimir Kozlov
On Tue, 16 Apr 2024 02:34:29 GMT, Dean Long wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Union fields which usages do not overlap > > src/hotspot/share/code/nmethod.hpp line 205: > >> 203: // offsets

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-15 Thread Dean Long
On Mon, 15 Apr 2024 03:24:07 GMT, Vladimir Kozlov wrote: >> This is part of changes which try to reduce size of `nmethod` and `codeblob` >> data vs code in CodeCache. >> These changes reduced size of `nmethod` header from 288 to 232 bytes. From >> 304 to 248 in optimized VM: >> >> Statistics

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-15 Thread Dean Long
On Mon, 15 Apr 2024 03:24:07 GMT, Vladimir Kozlov wrote: >> This is part of changes which try to reduce size of `nmethod` and `codeblob` >> data vs code in CodeCache. >> These changes reduced size of `nmethod` header from 288 to 232 bytes. From >> 304 to 248 in optimized VM: >> >> Statistics

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-15 Thread Vladimir Kozlov
On Tue, 16 Apr 2024 01:30:50 GMT, Dean Long wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Union fields which usages do not overlap > > src/hotspot/share/code/codeBlob.cpp line 88: > >> 86:

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-15 Thread Dean Long
On Mon, 15 Apr 2024 03:24:07 GMT, Vladimir Kozlov wrote: >> This is part of changes which try to reduce size of `nmethod` and `codeblob` >> data vs code in CodeCache. >> These changes reduced size of `nmethod` header from 288 to 232 bytes. From >> 304 to 248 in optimized VM: >> >> Statistics

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-15 Thread Dean Long
On Mon, 15 Apr 2024 03:24:07 GMT, Vladimir Kozlov wrote: >> This is part of changes which try to reduce size of `nmethod` and `codeblob` >> data vs code in CodeCache. >> These changes reduced size of `nmethod` header from 288 to 232 bytes. From >> 304 to 248 in optimized VM: >> >> Statistics

Re: RFR: 8329433: Reduce nmethod header size [v3]

2024-04-14 Thread Vladimir Kozlov
> This is part of changes which try to reduce size of `nmethod` and `codeblob` > data vs code in CodeCache. > These changes reduced size of `nmethod` header from 288 to 240 bytes. From > 304 to 256 in optimized VM: > > Statistics for 1282 bytecoded nmethods for C2: > total in heap = 5560352