mailing list of musl libc
 help / color / mirror / code / Atom feed
From: Rich Felker <dalias@libc.org>
To: Tom Storey <tom@snnap.net>
Cc: musl@lists.openwall.com
Subject: Re: [musl] Building for m68k
Date: Thu, 23 Apr 2020 20:51:01 -0400	[thread overview]
Message-ID: <20200424005101.GA11469@brightrain.aerifal.cx> (raw)
In-Reply-To: <CAFDgZgWe2Sc83DEWjDLUQd=wW5AAzJ7eUp-C4YDm4Hq9g8YPbQ@mail.gmail.com>

On Fri, Apr 24, 2020 at 10:36:23AM +1000, Tom Storey wrote:
> Thanks Rich.
> 
> Just for gits and shiggles I tried #ifdef'ing out the cas.l instruction in
> the atomic_arch.h file for 68020+ processors, and compilation then

That won't work. But for NOMMU without a separate kernel domain it
would work to do cli;nonatomic_cas;sti (not sure what the actual m68k
insns for that are). There are plenty of places where a cas that does
nothing will break code, probably even during common paths in simple
programs.

> proceeded along very smoothly for a while, but then hit another roadblock
> in src/setjmp/m68k/longjmp.s where it tries to execute a floating point
> instruction, and then subsequently fails with a "needs M68K fpu" error
> message. So maybe there was a way to work around that, but FPU adds another
> dimension to this problem.

You can add a softfloat ABI; nominally there even is one, but it's
clearly not working. The setjmp/longjmp files should be made .S
instead of .s with #if around the floating point save/restore
conditioned on being hardfloat ABI.

> Trying to make this work is probably more than I'm really willing to take
> on for this project, so I may put it on the back burner and perhaps look at

You're really probably 90% there to at least having something that'll
build and that should run if you wire up syscalls.

Rich

  reply	other threads:[~2020-04-24  0:51 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-23  2:05 Tom Storey
2020-04-23  2:32 ` Rich Felker
2020-04-23  5:04   ` Tom Storey
2020-04-23 16:30     ` Rich Felker
2020-04-24  0:36       ` Tom Storey
2020-04-24  0:51         ` Rich Felker [this message]
2020-04-24  1:14           ` Tom Storey
2020-04-24  1:20             ` Rich Felker
2020-04-24  2:29               ` Tom Storey
2020-04-24  2:37                 ` Rich Felker

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=20200424005101.GA11469@brightrain.aerifal.cx \
    --to=dalias@libc.org \
    --cc=musl@lists.openwall.com \
    --cc=tom@snnap.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.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).