Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] linux-yocto: Add dependency on libgcc for ARC
@ 2019-02-08 15:32 Alexey Brodkin
  2019-02-08 15:42 ` Bruce Ashfield
  2019-02-08 17:28 ` Khem Raj
  0 siblings, 2 replies; 5+ messages in thread
From: Alexey Brodkin @ 2019-02-08 15:32 UTC (permalink / raw)
  To: openembedded-core; +Cc: Bruce Ashfield, linux-snps-arc, Alexey Brodkin

As of now in case of ARC there's no in-kernel implementation of basic libgcc
functions used for millicode, multiplication, division etc instead we simply
link with libgcc.a which provides everything used by the compiler.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
---
 meta/recipes-kernel/linux/linux-yocto.inc | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/meta/recipes-kernel/linux/linux-yocto.inc b/meta/recipes-kernel/linux/linux-yocto.inc
index 1ebfb606da..f191946f2a 100644
--- a/meta/recipes-kernel/linux/linux-yocto.inc
+++ b/meta/recipes-kernel/linux/linux-yocto.inc
@@ -26,6 +26,10 @@ DEPENDS_append_nios2 = " libgcc"
 KERNEL_CC_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
 KERNEL_LD_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
 
+DEPENDS_append_arc = " libgcc"
+KERNEL_CC_append_arc = " ${TOOLCHAIN_OPTIONS}"
+KERNEL_LD_append_arc = " ${TOOLCHAIN_OPTIONS}"
+
 KERNEL_FEATURES_append_qemuall=" features/debug/printk.scc"
 
 KERNEL_FEATURES_append = " ${@bb.utils.contains('MACHINE_FEATURES', 'numa', 'features/numa/numa.scc', '', d)}"
-- 
2.16.2



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] linux-yocto: Add dependency on libgcc for ARC
  2019-02-08 15:32 [PATCH] linux-yocto: Add dependency on libgcc for ARC Alexey Brodkin
@ 2019-02-08 15:42 ` Bruce Ashfield
  2019-02-08 17:28 ` Khem Raj
  1 sibling, 0 replies; 5+ messages in thread
From: Bruce Ashfield @ 2019-02-08 15:42 UTC (permalink / raw)
  To: Alexey Brodkin
  Cc: linux-snps-arc, Patches and discussions about the oe-core layer

On Fri, Feb 8, 2019 at 10:32 AM Alexey Brodkin
<alexey.brodkin@synopsys.com> wrote:
>
> As of now in case of ARC there's no in-kernel implementation of basic libgcc
> functions used for millicode, multiplication, division etc instead we simply
> link with libgcc.a which provides everything used by the compiler.

I'll grab this for my queue.

Cheers,

Bruce

>
> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
> ---
>  meta/recipes-kernel/linux/linux-yocto.inc | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/meta/recipes-kernel/linux/linux-yocto.inc b/meta/recipes-kernel/linux/linux-yocto.inc
> index 1ebfb606da..f191946f2a 100644
> --- a/meta/recipes-kernel/linux/linux-yocto.inc
> +++ b/meta/recipes-kernel/linux/linux-yocto.inc
> @@ -26,6 +26,10 @@ DEPENDS_append_nios2 = " libgcc"
>  KERNEL_CC_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
>  KERNEL_LD_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
>
> +DEPENDS_append_arc = " libgcc"
> +KERNEL_CC_append_arc = " ${TOOLCHAIN_OPTIONS}"
> +KERNEL_LD_append_arc = " ${TOOLCHAIN_OPTIONS}"
> +
>  KERNEL_FEATURES_append_qemuall=" features/debug/printk.scc"
>
>  KERNEL_FEATURES_append = " ${@bb.utils.contains('MACHINE_FEATURES', 'numa', 'features/numa/numa.scc', '', d)}"
> --
> 2.16.2
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core



-- 
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] linux-yocto: Add dependency on libgcc for ARC
  2019-02-08 15:32 [PATCH] linux-yocto: Add dependency on libgcc for ARC Alexey Brodkin
  2019-02-08 15:42 ` Bruce Ashfield
@ 2019-02-08 17:28 ` Khem Raj
  2019-02-08 17:34   ` Alexey Brodkin
  1 sibling, 1 reply; 5+ messages in thread
From: Khem Raj @ 2019-02-08 17:28 UTC (permalink / raw)
  To: Alexey Brodkin
  Cc: Bruce Ashfield, linux-snps-arc,
	Patches and discussions about the oe-core layer

On Fri, Feb 8, 2019 at 7:32 AM Alexey Brodkin
<alexey.brodkin@synopsys.com> wrote:
>
> As of now in case of ARC there's no in-kernel implementation of basic libgcc
> functions used for millicode, multiplication, division etc instead we simply
> link with libgcc.a which provides everything used by the compiler.
>

this is something you would be fixing in kernel eventually?
we can carry this as a workaround until then but it really needs to be
fixed in kernel.

> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
> ---
>  meta/recipes-kernel/linux/linux-yocto.inc | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/meta/recipes-kernel/linux/linux-yocto.inc b/meta/recipes-kernel/linux/linux-yocto.inc
> index 1ebfb606da..f191946f2a 100644
> --- a/meta/recipes-kernel/linux/linux-yocto.inc
> +++ b/meta/recipes-kernel/linux/linux-yocto.inc
> @@ -26,6 +26,10 @@ DEPENDS_append_nios2 = " libgcc"
>  KERNEL_CC_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
>  KERNEL_LD_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
>
> +DEPENDS_append_arc = " libgcc"
> +KERNEL_CC_append_arc = " ${TOOLCHAIN_OPTIONS}"
> +KERNEL_LD_append_arc = " ${TOOLCHAIN_OPTIONS}"
> +
>  KERNEL_FEATURES_append_qemuall=" features/debug/printk.scc"
>
>  KERNEL_FEATURES_append = " ${@bb.utils.contains('MACHINE_FEATURES', 'numa', 'features/numa/numa.scc', '', d)}"
> --
> 2.16.2
>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] linux-yocto: Add dependency on libgcc for ARC
  2019-02-08 17:28 ` Khem Raj
@ 2019-02-08 17:34   ` Alexey Brodkin
  2019-02-08 17:41     ` Khem Raj
  0 siblings, 1 reply; 5+ messages in thread
From: Alexey Brodkin @ 2019-02-08 17:34 UTC (permalink / raw)
  To: Khem Raj
  Cc: Bruce Ashfield, Vineet Gupta, linux-snps-arc@lists.infradead.org,
	Patches and discussions about the oe-core layer

Hi Khem,

> -----Original Message-----
> From: Khem Raj <raj.khem@gmail.com>
> Sent: Friday, February 8, 2019 8:28 PM
> To: Alexey Brodkin <alexey.brodkin@synopsys.com>
> Cc: Patches and discussions about the oe-core layer <openembedded-core@lists.openembedded.org>; Ross
> Burton <ross.burton@intel.com>; linux-snps-arc@lists.infradead.org; Bruce Ashfield
> <bruce.ashfield@windriver.com>
> Subject: Re: [PATCH] linux-yocto: Add dependency on libgcc for ARC
> 
> On Fri, Feb 8, 2019 at 7:32 AM Alexey Brodkin
> <alexey.brodkin@synopsys.com> wrote:
> >
> > As of now in case of ARC there's no in-kernel implementation of basic libgcc
> > functions used for millicode, multiplication, division etc instead we simply
> > link with libgcc.a which provides everything used by the compiler.
> >
> 
> this is something you would be fixing in kernel eventually?
> we can carry this as a workaround until then but it really needs to be
> fixed in kernel.

Well we do have it in our plans but given this is more a nice feature
than something critical (as currently used approach with libgcc works
perfectly fine) it might not be done very soon.

Thus we'll need to keep this work-around for now.

BTW exporting of libgcc parts into kernel means we'll need to
keep it in sync with real libgcc later which is not optimal as well.

-Alexey

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] linux-yocto: Add dependency on libgcc for ARC
  2019-02-08 17:34   ` Alexey Brodkin
@ 2019-02-08 17:41     ` Khem Raj
  0 siblings, 0 replies; 5+ messages in thread
From: Khem Raj @ 2019-02-08 17:41 UTC (permalink / raw)
  To: Alexey Brodkin
  Cc: Bruce Ashfield, Vineet Gupta, linux-snps-arc@lists.infradead.org,
	Patches and discussions about the oe-core layer

On Fri, Feb 8, 2019 at 9:35 AM Alexey Brodkin
<alexey.brodkin@synopsys.com> wrote:
>
> Hi Khem,
>
> > -----Original Message-----
> > From: Khem Raj <raj.khem@gmail.com>
> > Sent: Friday, February 8, 2019 8:28 PM
> > To: Alexey Brodkin <alexey.brodkin@synopsys.com>
> > Cc: Patches and discussions about the oe-core layer <openembedded-core@lists.openembedded.org>; Ross
> > Burton <ross.burton@intel.com>; linux-snps-arc@lists.infradead.org; Bruce Ashfield
> > <bruce.ashfield@windriver.com>
> > Subject: Re: [PATCH] linux-yocto: Add dependency on libgcc for ARC
> >
> > On Fri, Feb 8, 2019 at 7:32 AM Alexey Brodkin
> > <alexey.brodkin@synopsys.com> wrote:
> > >
> > > As of now in case of ARC there's no in-kernel implementation of basic libgcc
> > > functions used for millicode, multiplication, division etc instead we simply
> > > link with libgcc.a which provides everything used by the compiler.
> > >
> >
> > this is something you would be fixing in kernel eventually?
> > we can carry this as a workaround until then but it really needs to be
> > fixed in kernel.
>
> Well we do have it in our plans but given this is more a nice feature
> than something critical (as currently used approach with libgcc works
> perfectly fine) it might not be done very soon.
>
> Thus we'll need to keep this work-around for now.
>
> BTW exporting of libgcc parts into kernel means we'll need to
> keep it in sync with real libgcc later which is not optimal as well.

aarch64 kernel also bootstrapped with lbgcc for quite a while and then
moved away
I can understand that there might be bigger fish to fry, but this is
not a insignificant issue
where you make kernel dependency on toolchain runtime go away.

>
> -Alexey


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-02-08 17:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-08 15:32 [PATCH] linux-yocto: Add dependency on libgcc for ARC Alexey Brodkin
2019-02-08 15:42 ` Bruce Ashfield
2019-02-08 17:28 ` Khem Raj
2019-02-08 17:34   ` Alexey Brodkin
2019-02-08 17:41     ` Khem Raj

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox