Re: [fpc-devel] FPC for MIPS
On Tue, Jan 15, 2013 at 02:04:20AM +0100, SkyDiablo wrote: hi ho, i'm back again ;) i have try this: http://www.mail-archive.com/fpc-devel@lists.freepascal.org/msg27336.html but my Ubuntu Desktop 12.04 LTS can't run the ppcmips binary? Ubuntu has a MIPS port? Even for LTS!? $ chmod +x ppcmips $ ./ppcmips -iV bash: ./ppcmips: Kann die Datei nicht ausf?hren. (Can't run this file) What computer are you running this on? ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] Feature announcement: Extension of TThread's interface
On Fri, Dec 28, 2012 at 08:49:51AM +, Mark Morgan Lloyd wrote: microc...@zoho.com wrote: On Thu, Dec 27, 2012 at 07:01:08PM +, Mark Morgan Lloyd wrote: Ewald wrote: Now, for the implementation of ProcessorCount I've got code here that reads the amount of processor cores from `/proc/cpuinfo` (linux only I think) and some assembly code [asmmode att] (tested on x86_64 and i386) that *tries* to get the amount of cpu cores by the use of CPUID. The In the general case, you have to be careful with this since (a) every architecture puts different info in /proc/cpuinfo and (b) the processor numbering and affinity vectors can have gaps. In the general case how is his x86 asm supposed to ever work on anything but Intel or AMD boxes? .. Looks like a weird bug in the probing. Why does it miss CPs 2,3,6,7? Because on that architecture every board, when initialising, starts off by running independently and gets an ID from its slot position. One slot (slot 1, not 0) is taken up by the mandatory card which has things like keyboard, serial and diagnostic JTAG support, and another (slot 3 on the system here) by a card with enough SCSI and Ethernet to boot. Once all cards have decided they're OK, the first card sends JTAG commands to the bus controllers on every card to rewire them to distribute resources over the centerplane, but the CPU IDs persist through to the process and interrupt affinity vectors (the taskset command on Linux). Oh sorry, I misunderstood your post. I thought you meant only 12 of 16 CPUs were showing in Linux. If you only have 12 CPUs in this case then I understand the explanation. I seem to remember a discussion where you said you have a box with 16 sockets. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] Feature announcement: Extension of TThread's interface
On Thu, Dec 27, 2012 at 07:01:08PM +, Mark Morgan Lloyd wrote: Ewald wrote: Now, for the implementation of ProcessorCount I've got code here that reads the amount of processor cores from `/proc/cpuinfo` (linux only I think) and some assembly code [asmmode att] (tested on x86_64 and i386) that *tries* to get the amount of cpu cores by the use of CPUID. The In the general case, you have to be careful with this since (a) every architecture puts different info in /proc/cpuinfo and (b) the processor numbering and affinity vectors can have gaps. In the general case how is his x86 asm supposed to ever work on anything but Intel or AMD boxes? type: sun4u ncpus probed: 12 ncpus active: 12 .. CPU0: online CPU1: online CPU4: online CPU5: online CPU8: online CPU9: online CPU10: online CPU11: online CPU12: online CPU13: online CPU14: online CPU15: online Looks like a weird bug in the probing. Why does it miss CPs 2,3,6,7? ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] mips-linux and mipsel-linux snapshots available
On Wed, Dec 26, 2012 at 04:21:48PM +0100, Pierre Free Pascal wrote: -Message d'origine- De?: fpc-devel-boun...@lists.freepascal.org [mailto:fpc-devel- boun...@lists.freepascal.org] De la part de microc...@zoho.com Envoy??: mercredi 26 d?cembre 2012 16:13 ??: fpc-devel@lists.freepascal.org Objet?: Re: [fpc-devel] mips-linux and mipsel-linux snapshots available Will this work on other OS running on MIPS? How much work would it be to get it going on OpenBSD for example? It shouldn't be much work... just look at the content of openbsd/CPU/ directories, you will see what needs to be implemented specifically... Starting with the linux equivalent code should work for most include files, the startup prt0.as file might be a little bit more problematic... Thanks, I'll wait until Mark/Fuxin get it running 100% on Linux and then maybe have a look at it. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] ABI documentation on wiki
On Tue, 12 Jun 2012 20:26:14 + Mark Morgan Lloyd markmll.fpc-de...@telemetry.co.uk wrote: microc...@zoho.com wrote: Mark, Guys, I just added the SPARC information in the SPARC section. Looking further, I see Mark intended to group the ABI information together, separate from the architecture sections above. Mark: do you want to keep the ABI information separate or would it be more useful to group it with the coding examples? If you don't like the way it is I will move it. I should have read the whole page but I missed it until I saved my updates. Well, the whole point of a Wiki is that the chap doing the work decides on the layout, so I'm really in no position to dictate :-) Not at all, I just didn't take the time to review the whole page. My fault, and happy to change it to your liking. However, what I was hoping to do was have one collection of material directly relevant to the lowest levels of the compiler (code generator and assembler reader), and another relevant to the calling conventions and RTL. And as you've said yourself, there's a decided shortage of collected reference material for the various ABIs. I think another argument for keeping the assembler and ABI stuff separate is that you can have several assembler formats for a processor (e.g. Intel and ATT format for x86) and you can also have several ABIs applicable to a particular processor, e.g. Linux, Windows and Solaris for x86-64. I have moved the material to the end section. I also added a link to the Linux MIPS page that has the MIPS ABI linked from it. Until now I think we're safe with so many levels of indirection ;-) Just a note on the IBM examples, most of them don't apply to Linux since Linux uses a completely different ABI than MVS. Since FPC will probably never run on MVS (although it may well someday on z/Linux) do those sections really belong on the wiki? The first example is obviously relevant, since it's part of the same series (a fragment of kernel source) as the examples for the other processors. Right, I said most of them don't apply and even that was somewhat of an understatement since the entire platform is completely unsupported in FPC, as you know. I would have added comments in the wiki but I didn't know how to create a small discussion section where the comments would be understood to be linked to particular topic. I agree that the others are fairly awkward, but what I was trying to do was demonstrate (a) the IBM format assembler source, i.e. as distinct from what the GNU assembler (gas) expects, and (b) what GCC did when told to compile for various targets. I don't think this is relevant since gcc doesn't target IBM's assembler. Given z/Linux support is just a dream right now and MVS support is not on the horizon, I think it's just confusing to have the material there, just as it would be to add ABI or assembly examples for other platforms FPC doesn't support now and likely won't support in the future. Is the page to be about FPC, or a generic assembler page? That's really where I'm coming from. I think too much information can sometimes not be helpful. My intent with the latter was to show how much simpler code generation was if you restricted yourself to late-era S/390 targets (for which you apparently have to tell GCC to target a z900), there's previously been somebody trying to convince us that the most desirable target is MUSIC/SP running on an S/370 and that the 12-bit offset limitation was never an issue. I don't think you can conclude that, because there are too many variables. gcc targets only gas as a back end, the IBM assembler isn't an option. On z/Linux there is no IBM assembler, there's only gas. So really the discussion ought to be focused on that reality since people understand Linux and gas. The later code examples aren't more clear to IBM programmers since the relative and immediate facility, although not exactly new, hasn't been widely adopted in hand written assembler. The z900 code generated by gcc is especially unfamiliar since gcc isn't used on IBM products except for the public domain versions from the 1970s. z/OS customers get IBM's C/C++ compiler which of course is far better than gcc and has no licensing or runtime issues, and does have a much better runtime than gcc. Anyway, gcc's z900 mode uses not only the relative and immediate facility, but also the 64 bit versions. Any this is not representative of what IBM's C/C++ compiler will generate, since IBM's C/C++ targets object code directly, and not any assembler back end. Although you can get the IBM compiler to produce an assembly listing that is not what the compiler uses to do code generation, it generates object code directly. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
[fpc-devel] ABI documentation on wiki
Mark, Guys, I just added the SPARC information in the SPARC section. Looking further, I see Mark intended to group the ABI information together, separate from the architecture sections above. Mark: do you want to keep the ABI information separate or would it be more useful to group it with the coding examples? If you don't like the way it is I will move it. I should have read the whole page but I missed it until I saved my updates. Just a note on the IBM examples, most of them don't apply to Linux since Linux uses a completely different ABI than MVS. Since FPC will probably never run on MVS (although it may well someday on z/Linux) do those sections really belong on the wiki? ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
On Sat, 9 Jun 2012 09:27:30 +0800 (CST) Fuxin Zhang zhan...@lemote.com wrote: Fuxin, is there a formal 64 bit ABI from MIPS Inc.? I think you said earlier the Linux 64 bit ABI is not exactly stable, but there are a few other OS running on 64 bit MIPS (OpenBSD and FreeBSD and NetBSD, as far as I know). If MIPS or some other standards body has documented the 64 bit MIPS ABI I'd like to get a copy of it. I found some old SGI doc but I don't know how universal it is. I get a copy from my colleague for N32 ABI, no N64 found yet.See http://www.lemote.com/upfiles/mips-abi-n32.pdf. I put it here because no confidential sign in the document. But I am not sure whether it comes from MIPS as a material to licensee. Will check later. Thanks, I already have several copies of n32 doc. I'm specifically looking for n64 doc. UNIX is chaos, it seems like there is no single place to get the ABIs for all platforms. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
On Sat, 09 Jun 2012 20:52:01 + Mark Morgan Lloyd markmll.fpc-de...@telemetry.co.uk wrote: microc...@zoho.com wrote: On Sat, 9 Jun 2012 09:27:30 +0800 (CST) Fuxin Zhang zhan...@lemote.com wrote: Fuxin, is there a formal 64 bit ABI from MIPS Inc.? I think you said earlier the Linux 64 bit ABI is not exactly stable, but there are a few other OS running on 64 bit MIPS (OpenBSD and FreeBSD and NetBSD, as far as I know). If MIPS or some other standards body has documented the 64 bit MIPS ABI I'd like to get a copy of it. I found some old SGI doc but I don't know how universal it is. I get a copy from my colleague for N32 ABI, no N64 found yet.See http://www.lemote.com/upfiles/mips-abi-n32.pdf. I put it here because no confidential sign in the document. But I am not sure whether it comes from MIPS as a material to licensee. Will check later. Thanks, I already have several copies of n32 doc. I'm specifically looking for n64 doc. UNIX is chaos, it seems like there is no single place to get the ABIs for all platforms. So guess why I started that wiki page? :-) It's a good idea but I'm not sure we can solve the greater problem which is there's no authority on which specs are official, valid etc. When you're lucky enough to find some doc on the net, you are never sure it's the latest copy since there is no top-level official repository. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
On Sun, 10 Jun 2012 08:18:36 +0800 (CST) Fuxin Zhang zhan...@lemote.com wrote: Please keep copyright in mind when adding new stuff! I have removed the link in the wiki and the files from lemote web. Sorry for the thinkless action. Opening the ABI documents should be a good thing to help its eco-system, if I have chance I will try to pasuade mips. The n32 ABI and a 64 bit conversion guide are available in SGI pubs from SGI's site without signing up. I don't think you have anything to be concerned about. MIPS lets anyone who signs up download their doc. It seems there aren't any trade secrets involved and it seems to me linking to their doc would be the safe thing to do. I don't think you did anything wrong though. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
On Fri, 8 Jun 2012 17:15:51 +0800 (CST) Fuxin Zhang zhan...@lemote.com wrote: I made a start at trying to get assembler and backend info into the Wiki, my intention was to at least have URLs for the various ABIs. I rather ground to a halt after getting examples of the assembler format together for most targets, if anybody could contribute ABI stuff it would be much appreciated. http://wiki.lazarus.freepascal.org/Assembler_and_ABI_Resources I have added a link to mips O32 ABI file to the MIPS section. Mark, guys, were you wanting the information itself on the wiki or are links good enough? If the latter and they aren't there already, I'll add the SPARC ABI links next week. Fuxin, is there a formal 64 bit ABI from MIPS Inc.? I think you said earlier the Linux 64 bit ABI is not exactly stable, but there are a few other OS running on 64 bit MIPS (OpenBSD and FreeBSD and NetBSD, as far as I know). If MIPS or some other standards body has documented the 64 bit MIPS ABI I'd like to get a copy of it. I found some old SGI doc but I don't know how universal it is. Thanks. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
On Fri, 08 Jun 2012 13:32:18 + Mark Morgan Lloyd markmll.fpc-de...@telemetry.co.uk wrote: microc...@zoho.com wrote: On Fri, 8 Jun 2012 17:15:51 +0800 (CST) Fuxin Zhang zhan...@lemote.com wrote: I made a start at trying to get assembler and backend info into the Wiki, my intention was to at least have URLs for the various ABIs. I rather ground to a halt after getting examples of the assembler format together for most targets, if anybody could contribute ABI stuff it would be much appreciated. http://wiki.lazarus.freepascal.org/Assembler_and_ABI_Resources I have added a link to mips O32 ABI file to the MIPS section. Mark, guys, were you wanting the information itself on the wiki or are links good enough? If the latter and they aren't there already, I'll add the SPARC ABI links next week. My intention was to put links in, although obviously a note would be in order where FPC and/or GCC departs from conventions. I don't know enough about either FPC or GCC to speak to this issue. One of the reasons that I started that page was that some manufacturers require you to register with them before they will give you full processor info- I think that MIPS was one of those. Yes, definitely. ARM is also. At that point a link to a copy of the document which happens to have been published on e.g. a university website or at archive.org has some value to people who don't want to raise their head above the parapet. Fortunately the SPARC doc is all open. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
On Mon, 4 Jun 2012 14:56:06 -0700 (PDT) Leonardo M. Ramé martinr...@yahoo.com wrote: You are right, the machine (http://www-03.ibm.com/systems/power/hardware/560/specs.html) doesn't have a MIPS processor, but an IBM's Power6. BTW, does anyone know which Linux distribution runs on that machine?, can FPC be compiled to run on it?. Leonardo M. Ramé http://leonardorame.blogspot.com Congrats, that's a nice box. POWER6 is one generation behind but from what I read it can still run the latest version of AIX. The best OS is the one IBM made for it, AIX which is a POSIX UNIX with IBM extensions (and great doc!). You should be able to get a copy without too much difficulty if one isn't already installed. On the same page you linked above, there is a list of some Linux that are certified to run on your box. Running Linux on it would be a horrible waste of a good server. You can probably virtualize Linux and BSD instances under AIX though, as you had mentioned in your first post. If you find you're not happy with the server, just tell me how much it would cost to ship and I'll take it off your hands ;-) ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
From mar...@stack.nl Sun Jun 3 08:34:51 2012 In our previous episode, microc...@zoho.com said: AFAIK, as far as Windows, nothing but Windows CE (not XP, 7, Vista etc) runs on MIPS Afaik NT up to and including 4.0 ran on MIPS (r3000/4000). After 4.0 architectures were severely cut. NT3.51 also ran SPARC. Given the question was about wanting to run Windows and Linux on an IBM MIPS server and do virtualization, I didn't think it would help to discuss Windows NT, etc. I am aware Windows was supposed to have run on more platforms in the old days. My point was that you can't run XP, 7, or Vista on MIPS hardware, not that I was trying to beat anyone out in a trivia contest about what versions of various things were ever rumored to run on MIPS ;-) ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] progress of freepascal for mips
On Sat, 2 Jun 2012 07:04:24 -0700 (PDT) Leonardo M. Ramé martinr...@yahoo.com wrote: Hi, while this interesting discussion about fpc for Linux/MIPS is evolving, we've received an IBM Mips server from a customer (I don't know the model yet) to try to install an hypervisor. Sorry if this has already been answered but I have tons of mail and haven't read them all yet. I am near certain IBM doesn't make any MIPS hardware at all and never has in their history. In the past they've made all sorts of odd things but at the moment all they make is Intel and POWER servers, as far as servers go. MIPS in IBM-speak is millions of instructions per second which is how they describe mainframe performance since they don't publish clock speeds. We need to run at least Windows and Linux servers on it. Do you know if Xen/VMWare or similar hypervisors run on this architecture?. AFAIK, as far as Windows, nothing but Windows CE (not XP, 7, Vista etc) runs on MIPS and I don't think Windows CE will run on server hardware. And all of the virtualization options available are Intel-only except for Oracle's SPARC VM, so no, you don't have any virtualization options except for perhaps QEMU, but so does everyone who has an Intel box, so there isn't anything to offer via virtualization. If I can install an hypervisor, I could create one virtual machine to let the FPC team test the MIPS version on this machine, it can be online 24/7. Virtualization is thin to none on anything but Intel hardware. But there is QEMU and it provides support for various architectures including MIPS. If you install Linux on your MIPS server (if it really is a MIPS server, which I don't think it is, or if it is, it isn't IBM) you can use QEMU like Fuxin Zhang wrote he was using, but then so can everyone else who has an Intel box (everybody) so I don't think it's going to be very helpful. And the guy working on fpc on MIPS, Fuxin, is working for a MIPS manufacturer so I would guess he has all the hardware he needs ;-) ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] about freepascal for mips
On Sat, 26 May 2012 21:00:23 +0800 (CST) zhan...@lemote.com wrote: microcode wrote Hello and may I say EXCELLENT! Now all we need to know is where to get a good price on your MIPS boxes so we can all run them ;-) Well, we decide to sell some machines at very low price to help promote the mips world. How about Yeeloong netbooks with $100-$150(for various configurations and amounts + shipment? Hi, I was more interested in the single box version. I forget what you call it. I will email Betty, thanks for the connection. I'm looking for a MIPS box for my own study. You can contact be...@lemote.com to buy. And I've declared that we can donate some for developers. If I could help I would be glad to, but unfortunately I am not an fpc developer. So I can't ask for a donation. I can ask for a good price though ;-) Thanks and good luck with fpc. Seems like a great group of guys to me. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] about freepascal for mips
Thank you. -Original Message- From: Fuxin Zhang zhan...@lemote.com Sender: fpc-devel-boun...@lists.freepascal.org Date: Mon, 28 May 2012 07:49:43 To: FPC developers' listfpc-devel@lists.freepascal.org Reply-To: zhan...@lemote.com, FPC developers' list fpc-devel@lists.freepascal.org Subject: Re: [fpc-devel] about freepascal for mips Hi, I was more interested in the single box version. I forget what you call it. I will email Betty, thanks for the connection. I'm looking for a MIPS box for my own study. It is called Fuloong, and I find I made a mistake, betty's mail is zha...@lemote.com, not be...@lemote.com. You can contact be...@lemote.com to buy. And I've declared that we can donate some for developers. If I could help I would be glad to, but unfortunately I am not an fpc developer. So I can't ask for a donation. I can ask for a good price though ;-) Thanks and good luck with fpc. Seems like a great group of guys to me. Thanks, people here are really nice. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel
Re: [fpc-devel] about freepascal for mips
Fuxin Zhang zhan...@lemote.com wrote: Hello everybody, I am Fuxin Zhang from lemote, now we are working on mips support of fpc Hello and may I say EXCELLENT! Now all we need to know is where to get a good price on your MIPS boxes so we can all run them ;-) ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel