On Mon, Feb 03, 2020 at 04:52:42PM -0500, Michael Meissner wrote: > > I understand why this is needed for pcrel (or useful at least), but why > > for prefixed addressing in general as well? What OS support is needed > > for that? > > > > Put another way, is this just carefulness, or do you run into actual > > problems without it? > > Just caution. I can just do the PCREL.
See below... It really isn't "OS support", so maybe a better name will help. > > > +/* Enable support for pc-relative and numeric prefixed addressing on the > > > + 'future' system. */ > > > +#undef PREFIXED_ADDR_SUPPORTED_BY_OS > > > +#define PREFIXED_ADDR_SUPPORTED_BY_OS 1 > > > + > > > +#undef PCREL_SUPPORTED_BY_OS > > > +#define PCREL_SUPPORTED_BY_OS 1 > > > > "Numeric prefixed addressing"? What's that? Just "and other prefixed > > addressing", maybe? > > Using a prefixed address with a large offset, or using a small offset because > the traditional instruction is a DS/DQ instruction and the bottom 2/4 bits are > non-zero. Okay. So pretty much any prefixed load/store instruction. "Support for pc-relative and other prefixed addressing". It's fine to point out pcrel specifically, but just don't try to detail the rest here :-) > > > +/* Addressing related flags on a future processor. These are options > > > that need > > > + to be cleared if the target OS is not capable of supporting prefixed > > > + addressing at all (such as 32-bit mode or if the object file format > > > is not > > > + ELF v2). */ > > > > Ah. If we are missing the needed relocations (or other as/ld support). > > So it is not about OS really, missing toolchain support instead? > > It also plays into the dynamic loader of the system. If the dynamic loader > doesn't support the new relocations, you can't do PCREL. If you are building shared stuff at all. Right. So toolchain support and dl support (i.e. binutils and glibc)? Anything else? We'll be best off if you separate those out now, because those restrictions are independent. Also handled by different people on different projects ;-) Thanks, Segher