From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10020 Path: news.gmane.org!not-for-mail From: Gry Gunvor Newsgroups: gmane.linux.lib.musl.general Subject: Re: porting musl to RISCV-64 Date: Wed, 11 May 2016 09:32:16 -0700 Message-ID: References: <20160511112518.GB22574@port70.net> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1462984374 16197 80.91.229.3 (11 May 2016 16:32:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 11 May 2016 16:32:54 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-10033-gllmg-musl=m.gmane.org@lists.openwall.com Wed May 11 18:32:53 2016 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1b0X47-0008H1-0t for gllmg-musl@m.gmane.org; Wed, 11 May 2016 18:32:51 +0200 Original-Received: (qmail 5604 invoked by uid 550); 11 May 2016 16:32:48 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 5583 invoked from network); 11 May 2016 16:32:47 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=tgtml3oBf61b7Li5c+YPMsJvqkM+Mgl57RQhHkuBPu8=; b=hdd791/t6bxiPBw4HQxLkDXvGn62d1cO9MDagWy+VVqriwSdegUMqw2XM9rp61+bMr 1RV/p9cxosOmum9VRt5GbUL3XkqEpYdccQHZmkjuAa3YrJ4mBYAKbuEHwt98CbLYNRNs lrP53HTZdc1fl0wAuviSbIJPpRQOQeJ7b5OLxwK/SefsZlQclVpwVjKyF7y0hRgylcpo 5VVWFtJgnB8ROzJBTjkkBBsQQMXGd5Vga7DhUaV0jwfTJD8MQs+FWDsg1TsQCPZsSRHu adcXvnKpRTdBKhm7P/xfRFH2fTTxiATmlkIxncosyasIBeMhldEyvmDx8yhrYf37bwbY G3tg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=tgtml3oBf61b7Li5c+YPMsJvqkM+Mgl57RQhHkuBPu8=; b=NuXRr5c2522S6TFdkDtl4foao2cqxViHNl2trVKCBiH+ERE+DKMjHDAPocapS13woU +q3MIi/C+fsIvuqcadvvWF1dTcEC4SahqR3FWYY3RtIPNn1cx4Ql1SnRIUbnLqphwCMs JjpAAu8M8M/WAicDXMrsy3bmz0+M9TGfYIC8s89vFlUt90EBDrMtc96l9HWohMt7ZnnF u35Rpkq0hGExSNSLEjxKKUUOah/EhNb+oqPWm++POkjnHFgwsMWGB0YWJu5h22jwXB8n GHYg2J2tNZZHpF07HUCxqPDHyp+yjmfpYBSP309TP5WreW6iFb1TyAM4y7FW9SefZfQI d0IQ== X-Gm-Message-State: AOPr4FUw6E5Ot6yjKClqrk7yi+6TXs981nqzUpBQkA+bxCw7JJAOt75sYxulPug/xlY1EL7eeMpMJLUYTrUDCw== X-Received: by 10.107.0.7 with SMTP id 7mr4166612ioa.35.1462984356092; Wed, 11 May 2016 09:32:36 -0700 (PDT) In-Reply-To: <20160511112518.GB22574@port70.net> Xref: news.gmane.org gmane.linux.lib.musl.general:10020 Archived-At: On Wed, May 11, 2016 at 4:25 AM, Szabolcs Nagy wrote: > newlib is for baremetal development, you don't > need to use threading with it It's attempt at reentrancy support is causing me problems. > musl now has 32bit mips, mips64 and mipsn32 support as well. > these are different abis so they have to be separate ports, > same is true for the riscv targets. Your documentation does not seem to mention the MIPS64 port, but now that I look in arch, I see the directory for it. > there is a google summer of code project to add riscv support > http://www.openwall.com/lists/musl/2016/04/27/3 > i think it is supposed to provide a working port within 1-2 > months (?) so if you can wait you don't need to do much work. Suppose I can't wait and I attempt this myself. Right now I'm just trying to get a generic libc working. I do not want to handle multi-threading or signals. What can I omit? Are the non-portabilities isolated in arch/ ? That is, is there much more to it than cloning the arch/mips64 directory and hacking on it? atomic_arch.h: I think I can make all of these functions empty as I am not going to be using multi-threading, right? crt_arch.h: program startup; what is this doing in a libc implementation? doesn't the compiler handle this? ksigaction.h: sorry, I'm not a hardware person; I suppose different hardware has a different default layout for a signal object? so this is not a thing determined by kernel software? I don't care to handle signals right now anyway. pthread_arch.h: again, I think I can make all of these functions empty as I am not going to be using multi-threading. reloc.h: I can't figure out what this is. syscall_arch.h: I've already written this for RISCV-64 (and so have the RISCV people). bits: to what extent is this MIPS64-specific? since there is *no* inline assembly, how come arch/generic/ doesn't do here? Gry