Skip to contentSkip to conversation

Using f6-f11 floating-point registers

Linux-ia64 Jun Nakajima 3 participants 4 messages Jun 27, 2000 – Jun 28, 2000

lore
Share & tools
lore
#0 lore raw

At this point, the kernel is using more than f6-f11 floating-point registers (using -mfixed-rangeñ0-f15,f32-f127, i.e. those are *not* available to the kernel, but the others, like f16-f31 are).

When do we support the reduced FP model (EL_IA_64_REDUCEFP), where only f6-f11 are used by the kernel? Does the current compiler allow the kernel to use those FP registers only, if we provide -mfixed-rangeò-f5,f12-f127, for example? Of course, we need to change the kernel if we do this.

Thanks,

Signature · 3 lines
Jun U Nakajima
Core OS Development
SCO/Murray Hill, NJ
#1 lore raw

Richard Henderson checked in a compiler patch on June 13 that eliminated the need for the compiler to allocate integer and FP values to different FP registers. So as far as I know, there is no longer any compiler problem that should affect the kernel's use of FP registers. This change will be in the next toolchain release.

Jim

#2 lore raw
In reply to Jun Nakajima
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line · Jun Nakajima

Jun> At this point, the kernel is using more than f6-f11 Jun> floating-point registers (using -mfixed-rangeñ0-f15,f32-f127, Jun> i.e. those are *not* available to the kernel, but the others, Jun> like f16-f31 are).

If the compiler or someone writing assembly code thinks it's beneficial to use a preserved fp register, we should let them use it. Of course, they'll have to explicitly save/restore the register before using it, but there may well be cases where this is beneficial, so we shouldn't prevent it for no good reason.

Jun> When do we support the reduced FP model (EL_IA_64_REDUCEFP), Jun> where only f6-f11 are used by the kernel?

For the record, I have no plans to adopt the REDUCEFP model. I want to reserve the right for kernel developers to tweak the kernel register usage without having to talk to a standards body. Sorry.

	--david
#3 lore raw
In reply to Jun Nakajima

Well, I was just wondering because your (with Don) viewgraphs "IA-64 Linux Kernel Internals" (on the IA-64 Linux Web home page) says (p. 9) "considering a change to only provide f6-f11 to the compiler for integer multiply and divide", and I wanted to know how serious you were about it.

Quoted 22 lines · David Mosberger
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines · Jun Nakajima

Jun> At this point, the kernel is using more than f6-f11 Jun> floating-point registers (using -mfixed-rangeñ0-f15,f32-f127, Jun> i.e. those are *not* available to the kernel, but the others, Jun> like f16-f31 are).

If the compiler or someone writing assembly code thinks it's beneficial to use a preserved fp register, we should let them use it. Of course, they'll have to explicitly save/restore the register before using it, but there may well be cases where this is beneficial, so we shouldn't prevent it for no good reason.

Jun> When do we support the reduced FP model (EL_IA_64_REDUCEFP), Jun> where only f6-f11 are used by the kernel?

For the record, I have no plans to adopt the REDUCEFP model. I want to reserve the right for kernel developers to tweak the kernel register usage without having to talk to a standards body. Sorry.

        --david
Signature · 3 lines
Jun U Nakajima
Core OS Development
SCO/Murray Hill, NJ