[Arm] Remaining difference in crt0 code

Alexander Fedotov alfedotov@gmail.com
Mon Apr 15 10:17:00 GMT 2019


Ok, thanks.

On Mon, Apr 15, 2019 at 12:14 PM Richard Earnshaw (lists)
<Richard.Earnshaw@arm.com> wrote:
>
> On 12/04/2019 21:42, Alexander Fedotov wrote:
> > Hello Richard
> >
> > There is still some difference in crt0.S code in libgloss and libc
> > respectively. Could you help me figure out what version is correct so
> > we can get rid of this.
> >
>
> I don't think we can clean this up file at a time.  Trying to do so will
> likely create inconsistencies in the sources as some files will be
> patched and others not.
>
> "git blame" and "git show" will be your friends here... For example,
> taking the first hunk:
>
> > Differences are following:
> >
> > --- newlib/libc/sys/arm/crt0.S    2019-04-12 23:28:32.237488800 +0300
> > +++ libgloss/arm/crt0.S    2019-04-12 23:28:32.237488800 +0300
> > @@ -79,6 +79,19 @@
> >      .fnstart
> >  #endif
> >
> > +    /* __ARM_ARCH_PROFILE is defined from GCC 4.8 onwards, however
> > __ARM_ARCH_7A
> > +    has been defined since 4.2 onwards, which is when v7-a support was added
> > +    and hence 'A' profile support was added in the compiler.  Allow for this
> > +    file to be built with older compilers.  We only call this for A profile
> > +    cores.  */
> > +#if defined (__ARM_ARCH_7A__) || (__ARM_ARCH_PROFILE == 'A')
> > +/*  The init hook does not use the stack and is called before the
> > stack has been set up.  */
> > +#ifdef ARM_RDI_MONITOR
> > +    bl    _rdimon_hw_init_hook
> > +    .weak    FUNCTION (_rdimon_hw_init_hook)
> > +#endif
> > +#endif
> > +
>
> "git blame" shows that this hunk is derived from two commits 99be2bc4ff
> and then shortly afterwards 639951dda7.  "git show" can then be used to
> view these individual patches and you can also use the date information
> to identify the post to the newlib mailing list, which may contain
> additional information about the patch.
>
> Unwinding all of this is going to be a bit tedious, I fear, so I really
> appreciate any assistance you can give.
>
> R.



More information about the Newlib mailing list