Posts

Showing posts with the label firefox

MIPS N32 Firefox

Almost forget to mention, now with this workaround http://bit.ly/d5rBqp , N32 firefox-3.6.8 is working again. I am still trying to fix the binutils bug. http://sourceware.org/bugzilla/show_bug.cgi?id=11956 I am feeling that I am not far from a break through. BTW, Shenzhen Linux User Group will celebrate Software Freedom Day 2010 on this Saturday. If you happen to be in town by then, do drop by, ;) http://bit.ly/sz_sfd_2010 If you can come, and don't understand Chinese, I am always ready for help. ;)

Setting CFLAGS on a per-package basis

Update: as reported by Fai Wong, -O1 is actually fine. Obviously, it must be some flag(s) which is(are) enabled at -O2 but not at -O1 caused this problem. However, it is not a priority ATM. Anyone who is interested in it is welcome to investigate it further. As I have mentioned earlier , sqlite compiled with -O2 may cause xulrunner to segfault in N32 userland on Loongson. Well, I almost forget it. So to remove the -O2 from CFLAGS once and for all, I adopted the technique described here . zhangle@2f env $ pwd /etc/portage/env zhangle@2f env $ find . ./dev-db ./dev-db/sqlite ./O2-removal zhangle@2f env $ cat O2-removal pre_pkg_setup() { elog "bashrc is removing \"-O2\" from CFLAGS for $PN" CFLAGS="${CFLAGS/-O2/}" } zhangle@2f env $ ls -l dev-db/sqlite lrwxrwxrwx 1 zhangle zhangle 13 2009-08-01 16:10 dev-db/sqlite -> ../O2-removal

MIPS N32 firefox in acid3 test

Image
My quest for MIPS N32 firefox could finally come to an end, since I just got it scores the same as X86 firefox . Remember I said it would encounter bus error on a few websites in my last related post . But I didn't plan to look into this issue before dealing with cache aliasing problem. However, since Rayson Ho helped me to locate the exact cause of this issue, I decided to finish it first. The problem is caused by unaligned access of ldc1/sdc1 instruction. These two instructions' operand must be 8 bytes aligned. But when crashing, the operand is only 4 bytes aligned. After some discussion and experimenting, I found a workaround for sina.com.cn crashing problem. Yeah, a padding pointer sounds scary and fragile, but it did work. Before posting any comment to this, please make sure you have read all the emails in that thread. Then Fai Wong reported to me that it still crash in acid3 test . So I took another look. This time the problem happened in a different location, and it i

Firefox for MIPS N32 ABI

Finally, I could announce that it is working (tm). I just submitted the patches (together with O32 ABI patch) to upstream. https://bugzilla.mozilla.org/show_bug.cgi?id=482759 This is a big step forward for MIPS N32 GNU/Linux desktop. One thing to note though: It (the N32 one) would encounter bus error on a few websites, e.g. www.sina.com.cn. I will try to find out why later when I have time. For those who are into long stories, please read on: I finally sorted out the font size problem, independently. It turned out that the problem is caused by strict aliasing issue in NSPR (NetScape Portable Runtime). Specifically, when parsing css file, in order to get the font size, PR_strtod() will be used to convert string to floating point value. But because of the strict aliasing issue, certain code in PR_strtod will be optimized out if -fstrict-aliasing is turned on, which is just the case if -O2 is used. And as a result, the floating point value would be wrong, e.g. "1.5" will be con