From: Waldemar Brodkorb <wbx@openadk.org>
To: buildroot@busybox.net
Subject: [Buildroot] or1k system calls appear broken
Date: Thu, 7 Dec 2017 20:28:39 +0100 [thread overview]
Message-ID: <20171207192839.GG27558@waldemar-brodkorb.de> (raw)
In-Reply-To: <20171206224419.GC2890@lianli.shorne-pla.net>
Hi,
Stafford Horne wrote,
> On Wed, Dec 06, 2017 at 07:20:00PM +0100, Waldemar Brodkorb wrote:
> > Hi Stafford,
> > Stafford Horne wrote,
> >
> > > I was thinking we can just update : libc/sysdeps/linux/common/syscall.c
> > >
> > > There is not much openrisc specific about this. But it's up to Waldemar.
> >
> > What are the advantages or disadvantages using it in
> > common/syscall.c?
>
> The advantages would be that the code is generic enough to work for any
> architecture, reducing code needed for porting. Also the implementation
> arguments will match the header delared arguments.
>
> > Does it might break support for existing architectures using no
> > special syscall.c/syscall.S?
>
> I dont think so, but some possible downsides:
> - if those architectures have buggy handling of vargs it will have issues
> - the varargs code might be sub optimal compared to the regular args code
>
> I did a quick audit of some of the other syscall.c implementation so see if any
> other architectures use generic c code.
>
> ./libc/sysdeps/linux/common/syscall.c COMMON generic implementation
> ./libc/sysdeps/linux/arc/syscall.c Same as COMMON
> ./libc/sysdeps/linux/hppa/syscall.c varargs + asm
> ./libc/sysdeps/linux/frv/syscall.c asm
> ./libc/sysdeps/linux/c6x/syscall.c varargs + asm
> ./libc/sysdeps/linux/nds32/syscall.c GENERIC varargs (7 args?)
> ./libc/sysdeps/linux/arm/syscall.c asm
> ./libc/sysdeps/linux/metag/syscall.c asm
>
> So it looks like we could remove the arc and nds32 syscall.c files as they are
> generic.
>
> The architectures using the common syscall.c are:
>
> bfin
> h8300
> lm32
> m68k
> microblaze
> nios2
> or1k
> sh
>
> If we feel we dont have good test coverage for these then maybe its best we just
> add this as a OR1K only file as per Joel's patch.
I checked the test suite and no syscall() is used.
Would it be possible for you to suggest a test case for syscall()?
Then I can run the tests for all architectures, where I can do
runtime testing.
best regards
Waldemar
next prev parent reply other threads:[~2017-12-07 19:28 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-20 13:09 [Buildroot] or1k system calls appear broken Joel Stanley
2017-11-21 3:56 ` Waldemar Brodkorb
[not found] ` <20171121092441.GW29237@lianli.shorne-pla.net>
2017-11-21 19:56 ` Waldemar Brodkorb
2017-11-28 6:49 ` Waldemar Brodkorb
2017-12-06 0:41 ` Stafford Horne
2017-12-06 12:38 ` Joel Stanley
2017-12-06 12:55 ` Stafford Horne
2017-12-06 18:20 ` Waldemar Brodkorb
2017-12-06 22:44 ` Stafford Horne
2017-12-07 19:28 ` Waldemar Brodkorb [this message]
2017-12-07 19:33 ` Max Filippov
2017-12-10 10:17 ` Waldemar Brodkorb
2017-12-10 11:10 ` Stafford Horne
2017-12-12 19:37 ` Waldemar Brodkorb
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20171207192839.GG27558@waldemar-brodkorb.de \
--to=wbx@openadk.org \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox