Suggested patch for defmod
Stewart Brodie
stewart.brodie at pace.co.uk
Wed Apr 19 09:57:21 BST 2000
In message <58e740b149.tom at compton.compton.nu>
Tom Hughes <tom at compton.nu> wrote:
> In message <1f2626b149.sbrodie at sbrodie.cam.pace.co.uk>
> Stewart Brodie <stewart.brodie at pace.co.uk> wrote:
>
> > I suggest the following patch for defmod - this will make the code
> > generated by defmod safe for use by APCS 3/32 applications which wish
> > to run on pre-ARM6 core based processors.
>
> Surely pre-ARM6 processors only support 26 bit mode? or are you saying
> that it will allow 32 bit compatible output from DefMod to work in 26 bit
> mode as well?
There are two independent factors: 26-bit/32-bit processor mode execution,
and 26-bit/32-bit APCS. Whilst you must not use the 26-bit APCS whilst
executing in a 32-bit mode, it is perfectly legal to use the 32-bit APCS when
running in 26-bit modes, even on systems that do not have 32-bit modes at
all, and that is what my patch allows. In fact, APCS 3/32 on a 26-bit mode
systems is the transitional phase it would be ideal for people to move to in
preparation for future processors which do not have any 26-bit modes, should
they ever come out.
Your MRS will succeed only on ARM6 cored processors and later. It is a NOP
on ARM3 processors. The MOV will be superfluous on post-ARM3 processors, as
the MRS will override it. So with the exception of the issue of I32_bit and
F32_bit not being the same as I26_bit and F26_bit, and the non-existence of
T32_bit in ARM3, everything should be just fine.
--
Stewart Brodie, Senior Software Engineer (Views expressed are my own and
Pace Micro Technology PLC not those of my employer)
645 Newmarket Road
Cambridge, CB5 8PB, United Kingdom WWW: http://www.pacemicro.com/
More information about the oslib-team
mailing list