[m-rev.] for post-commit review: grade-and-architecture-specific extensions

Zoltan Somogyi zoltan.somogyi at runbox.com
Sat Sep 21 01:13:17 AEST 2024



On Sat, 21 Sep 2024 00:56:36 +1000, Julien Fischer <jfischer at opturion.com> wrote:
> >  :- type ext_cur_gs
> > +    --->    ext_cur_gs_lib_init                 % ".init"
> > +    ;       ext_cur_gs_lib_jar.                 % ".jar"
> 
> I assume you put .jar files in the _gs category, because Java byte code
> is not architecture specific?

Yes, that's right.

> However, the CIL byte code used in the.dll files
> generated in the C# grade is similarly architecture independent,

I thought .dll files generally contain ISA-specific code, so I figured
the C# compilers we now use generated real, not virtual, machine code.

> but they are
> in the _gas category.

I will put them back into the _gs category,
as ext_cur_gs_lib_dll.

> (I guess the issue is that Microsoft also use the .dll
> extension for native code libraries as well.)

Microsoft's talent for making things confusing shines again!
It certainly confused me.

Actually, file_names.m can treat the two kinds of .dlls separately.
We can put dlls into the _gs category as ext_cur_gs_lib_dll,
while ext_cur_gas_lib_sh_lib_opt remains in the _gas category.
Specifying "--shared-library-extension .dll" makes *those* .dll files
ISA-dependent.

Unfortunately, while the code can handle this just fine. *documenting it*
without causing confusion will be far from trivial :-(

> The diff looks fine otherwise.

Thanks for the review.

Zoltan.


More information about the reviews mailing list