Naming things in the AOT cache
ioi.lam at oracle.com
ioi.lam at oracle.com
Thu Sep 4 16:21:32 UTC 2025
I have started to refactor/rename code from "CDS" to "AOT". This is the
umbrella JBS issue
https://bugs.openjdk.org/browse/JDK-8366473
One thing I need to decide is how to call the things that we store
inside the AOT cache. In CDS, they are called "shared xxx".
Specifically, the words "shared class" is used a lot. It's grammatically
correct, but semantically it doesn't make sense anymore.
An obvious new name would be "AOT class", but this is not actually
grammatically correct. You can't read it as is:
"an ahead-of-time class"
It needs to be understood to be a class with some AOT operations
performed on it. It could mean any of the following
"an ahead-of-time (parsed) class"
"an ahead-of-time (linked) class"
"an ahead-of-time (inited) class"
So to be 100% correct, the correct interpretation is rather loose:
"an ahead-of-time (processed) class"
An alternative would be to call it
"a class in the AOT cache"
But this is rather verbose, and doesn't look good in C++. I.e.,
void do_something(Klass* aot_class); vs
void do_something(Klass* class_in_aot_cache);
So, do we want to adopt the convention of using "AOT" as a prefix for
the objects in the AOT cache, and interpreted them as
"AOT xyz" = "an ahead-of-time (processed) xyz"
i.e.,
Klass* aot_class;
Method* aot_method;
nmethod* aot_nmethod;
oop aot_obj, aot_mirror;
// Copy this AOT nmethod from the temporary buffer into its final
location
install(aot_nmethod);
// Initialize this AOT class
aot_ik->initialize();
// Copy fields in this AOT mirror
copy_fields(aot_mirror);
Thanks
- Ioi
More information about the leyden-dev
mailing list