projects/mips RIP
All changes from projects/mips has been merged to HEAD. Kudos go to imp@ for sieving through mergeinfo mess projects/mips has been.
All changes from projects/mips has been merged to HEAD. Kudos go to imp@ for sieving through mergeinfo mess projects/mips has been.
Good news: LLVM builds fine on RouterStation Pro with root mounted over NFS. Bad news: it segfaults on some tests and when trying to build hello world application. Stay tuned
Since I lent my RS232/USB adapter to a friend it was nice opportunity to experiment with Flyswatter on-board RS232 port. OS X does not support FTDI devices out of the box, but it’s not a problem for OpenOCD, which uses generic interface to communicate JTAG board. Things get a little bit more complicated when you’re trying to get on-board RS232 port working. I started with installing stock drivers from FTDI site. Current version supports Snow Leopard. With these drivers installed system started to detect two COM ports but JTAG part stopped to work as OpenOCD failed to claim USB device. ...
The best way to learn new technology is to use it. Here is a small project I’ve put together while learning Mac OS X/Cocoa development: AudioBookBinder, may be someone will find it useful. This utility takes collection of mp3 files (or any other audio format recognizable by OS X) and binds it to one audiobook(m4b file) suitable for listening on iPod. The initial idea was to make it a GUI app, but I’ve been spoiled with command line power for too long.
Good news everyone! Last two days I’ve been testing FreeBSD/mips by running buildworld on netbooted RouterStation with root mounted over NFS. So far so good, it successfully completed twice. A couple of weeks ago arch-dependent part of libthr (both kernel and userland) was implemented and it seems to work. “Seems to work” means that it passes thr1 and thr2 tests from stress2 and python’s test_thread[ing].py. And yes, python and perl build fine on the same board from the ports do work. As bash et al :) Though perl should be built without Perl malloc but it’s on my ToDo list.
ohloh seems to be unable to grind FreeBSD’s svn repo. I’ve been watching for its efforts for several days now and commits progress meter resets from time to time: https://www.ohloh.net/p/freebsd/enlistments
http://people.freebsd.org/~gonzo/mips/routerstation.log Some issues still pending though. Cache management is major one. Things seemed to work fine in emulation but backfired into face with real hardware. I ran into several “random” bugs that were narrowed down to caches. More to go :( Also ethernet driver performance is low but it’s easier then hunting down ethereal cache matters. Or so I think. This weekend will be dedicated to making openocd work with routerstation, learning debugging and profiling techniques for MIPS hardware and improving FreeBSD/MIPS pieces of DDB.
Well, I was overly optimistic. OpenOCD can halt CPU, reset, examine registers and perform software breakpoints. Trying to figure out what’s wrong with EJTAG support I skimmed the code and the state of it is, well, poor. Current implementation assumes that target is of the same endianness as host. That’s why number of HW breakpoints/watchpoints was detected wrong. But even fixing (endianness and breakpoints) and implementing(watchpoints) in hack’n’slash mode didn’t help. I still can’t get bp/wp to work. But I’ll definitely try. May be next weekend.
As it was mentioned earlier now I have new cool toy to play with. Flyswatter JTAG with MIPS14 adapter. Though Tin Can Tools kindly warned me that OpenOCD did not support EJTAG/MIPS I decided to order it and it turned to be a good deal. Why? Because there is EJTAG/MIPS support for OpenOCD as of 0.1.0. Moreover it works really nice with FreeBSD port of libftdi. So all I had to do was to make devel/openocd port and tweak some configs. And that’s it. Stock gdb for MIPS is not ready yet, but one can attach, examine registers, single step using telnet interface to daemon: ...
My SCM of choice for FreeBSD-related projects is SVK (it’s much faster then subversion and provides offline access to repo history, easy branching/merging and so on). And my editor of choice is vim. And it turns out vim doesn’t highlight svk commit files. What a shame. No bright colors for happy hacker who is about to commit clean and robust code (or break buildworld, whatever). So I spent 20 minutes of tweaking svn.vim and produced this. ...