20081021

Hello, Open-Source World!

It's official... Google's brainchild, Android, has finally said
Hello, Open-Source World!

I wonder how many hours it will take for the first Neo 1973 or Neo FreeRunner port to surface. The biggest challenge, it will seem, will be to provide a bridge between the (minimal) ARMv5TE instruction set that Android was designed for, and the OpenMoko handsets' ARMv4T instruction set (as present in the Samsung 2442 SoC).

Perhaps the next handset that OpenMoko releases will feature native ARMv5TE compatibility.

Update: I've been building android for the last few hours, having made a few build-oriented changes that I think will help bridge the ARMv5TE - ARMv4T gap. I'm going to list a few of the errors I've been running into below. Please note - although I only list each undefined instruction once, the errors occur in multiplicity and in different subdirectories. I will post ARMv4T compliant work-arounds soon. Please be patient.

  • bionic/libc/arch-arm/bionic/memcmp.S:44: Error: selected processor does not support `pld [r0,#0]
  • system/core/libpixelflinger/t32cb16blend.S:121: Error: selected processor does not support `smulbb lr,r7,lr'
  • system/core/libpixelflinger/t32cb16blend.S ... Error: selected processor does not support `smulbt ...'
  • external/jpeg/jidctfst.S:148: Error: selected processor does not support `smlabb r0,r2,r3,r5'
  • dalvik/vm/arch/arm/CallEABI.S:239: Error: selected processor does not support `blx ip'
  • dalvik/vm/mterp/out/InterpAsm-armv5.S:2653: Error: selected processor does not support `ldrd r2,[r0,#offStaticField_value]'
  • dalvik/vm/mterp/out/InterpAsm-armv5.S ... Error: selected processor does not support `strd ...'
  • external/sonivox/arm-wt-22k/lib_src/ARM-E_mastergain_gnu.s:77: Error: selected processor does not support `smulwb r4,r4,nGain'
  • external/sonivox/arm-wt-22k/lib_src/ARM-E_voice_gain_gnu.s:114: Error: selected processor does not support `smlawb tmp1,gainLeft,tmp0,tmp1'
  • external/opencore//codecs_v2/audio/aac/dec/src/calc_auto_corr.cpp
    /tmp/ccBi9nUH.s: Assembler messages:
    /tmp/ccBi9nUH.s:652: Error: selected processor does not support `clz r0,ip'
  • smultt, smlatt, smlawt, smulwt, qadd, qsub, qdadd, qdsub, smlabt
  • etc, etc, etc ...
Build problems that were not architecturally related:
  • out/target/product/generic/obj/SHARED_LIBRARIES/libdvm_intermediates/Misc.o: In function `dvmAllocBit': dalvik/vm/Misc.c:247: undefined reference to `ffs'
Theoretically, there are three possibilities to in order to have Android on the FreeRunner.
  • The first is to ] replace [ the red-highlighted mnemonics using an equivalent ARMv4 or ARMv4T instruction sequence. In some cases, this is impossible without a lot of context information.
  • The second is to completely re-implement each section from scratch, wherever one of the ARMv5TE instructions are issued, but using an algorithm optimized for the ARMv4 or ARMv4T architecture
  • The third option is to just remove it, e.g. for the pld instruction which only optimizes memory fetches by hinting (or not?)

1 comment:

Unknown said...

Interesting that a google search for "Error: selected processor does not support `blx" brought me back to my own blog post...

This time, however, I am encountering this error while compiling HaRET using the 0.51.0 release of CeGCC (mingw32ce).