Android

From Openmoko

(Difference between revisions)
Jump to: navigation, search
(New page: = Introduction = As [http://benno.id.au Ben Leslie] had pointed out on his [http://benno.id.au/blog/2007/11/21/android-neo1973 blog] far before the source code was released, Android was o...)
 
Line 3: Line 3:
 
As [http://benno.id.au Ben Leslie] had pointed out on his [http://benno.id.au/blog/2007/11/21/android-neo1973 blog] far before the source code was released, Android was originally designed to work with the ARMv5TE [http://en.wikipedia.org/wiki/Instruction_set_architecture instruction set architecture] (ISA), which allows for [http://en.wikipedia.org/wiki/ARM_architecture#DSP_Enhancement_Instructions DSP enhanced instructions]. Contrary to the ARMv5TE ISA, the Neo1973 and FreeRunner handsets both feature an arm920t core, which comply to the ARMv4T ISA.
 
As [http://benno.id.au Ben Leslie] had pointed out on his [http://benno.id.au/blog/2007/11/21/android-neo1973 blog] far before the source code was released, Android was originally designed to work with the ARMv5TE [http://en.wikipedia.org/wiki/Instruction_set_architecture instruction set architecture] (ISA), which allows for [http://en.wikipedia.org/wiki/ARM_architecture#DSP_Enhancement_Instructions DSP enhanced instructions]. Contrary to the ARMv5TE ISA, the Neo1973 and FreeRunner handsets both feature an arm920t core, which comply to the ARMv4T ISA.
  
Before the source code was released, kernel trap handlers were implemented to 'emulate' the ARMv5TE ISA. Although the results worked in many cases, trapping is costly and performance suffered as a result. Moreover, without explicitly knowing which conditions were set by various instructions, such as Thumb Mode execution, the result became nondeterministic.  
+
Before the source code was released, kernel trap handlers were implemented to 'emulate' the ARMv5TE ISA. Although the results worked in many cases, trapping is costly and performance suffered as a result. Moreover, without explicitly knowing which conditions were set by various instructions, such as Thumb Mode execution, the result became nondeterministic.
  
 
With the release of the Android source code, the Open Source community is no longer limited to dealing with a binary-only product. The Open Handset Alliance (OHA) has let their source code become a part of their product for everyone to benefit from and enrich.
 
With the release of the Android source code, the Open Source community is no longer limited to dealing with a binary-only product. The Open Handset Alliance (OHA) has let their source code become a part of their product for everyone to benefit from and enrich.
  
Since the [Android OS http://www.android.com] was [http://source.android.com/posts/opensource  publically released] on 20081021, [http://benno.id.au/blog/2007/11/21/android-neo1973 work] [http://perpetual-notion.blogspot.com/search/label/android is] [http://groups.google.com/group/android-porting currently underway] to port Android to the [http://wiki.openmoko.org/wiki/Neo1973_Hardware Neo 1973] and [http://wiki.openmoko.org/wiki/Neo_FreeRunner_GTA02_Hardware FreeRunner] handsets.  
+
Since the [Android OS http://www.android.com] was [http://source.android.com/posts/opensource  publically released] on 20081021, [http://benno.id.au/blog/2007/11/21/android-neo1973 work] [http://perpetual-notion.blogspot.com/search/label/android is] [http://groups.google.com/group/android-porting currently underway] to port Android to the [http://wiki.openmoko.org/wiki/Neo1973_Hardware Neo 1973] and [http://wiki.openmoko.org/wiki/Neo_FreeRunner_GTA02_Hardware FreeRunner] handsets.
  
 
= How to Help =
 
= How to Help =
Line 22: Line 22:
 
* Isolating ARMv5TE ISA dependent code
 
* Isolating ARMv5TE ISA dependent code
 
** e.g. grep -n -R -i "${armv5te_isa_pattern}" ~/android
 
** e.g. grep -n -R -i "${armv5te_isa_pattern}" ~/android
* Abstracting  
+
* Abstracting
 
** ( C/C++ ) Use inlined functions / #ifdef statments to implement functions in a portable manner
 
** ( C/C++ ) Use inlined functions / #ifdef statments to implement functions in a portable manner
 
** ( ASM ) #ifdef statements ?
 
** ( ASM ) #ifdef statements ?
  
For each ARMv5TE instruction, one could potentially  
+
For each ARMv5TE instruction, one could potentially
 
* Implement the instruction using general registers instead of DSP calls (i.e. eabi / softfloat)
 
* Implement the instruction using general registers instead of DSP calls (i.e. eabi / softfloat)
 
* If that is a) nondeterministic, or b) slow, then sections of code need to be analyzed and hand-optimized for the ARMv4T isa
 
* If that is a) nondeterministic, or b) slow, then sections of code need to be analyzed and hand-optimized for the ARMv4T isa
Line 38: Line 38:
 
== Hardware Reference ==
 
== Hardware Reference ==
  
[Neo1973 Hardware] -
+
[Neo1973 Hardware]
[Neo FreeRunner GTA02 Hardware] -
+
[Neo FreeRunner GTA02 Hardware]
  
 
== Communities ==
 
== Communities ==
Line 49: Line 49:
 
== Buy a Handset and Debug Board ==
 
== Buy a Handset and Debug Board ==
  
[http://wwww.koolu.com KoolU.com] - North American distributor of the OpenMoko, backed by [http://koolu.com/component/option,com_mojo/Itemid,225/ John "Mad Dog" Hall].  
+
[http://wwww.koolu.com KoolU.com] - North American distributor of the OpenMoko, backed by [http://koolu.com/component/option,com_mojo/Itemid,225/ John "Mad Dog" Hall].
 
[http://us.direct.openmoko.com/collections/frontpage] - [Debug Board v3]
 
[http://us.direct.openmoko.com/collections/frontpage] - [Debug Board v3]
  
Line 55: Line 55:
  
 
== External Links ==
 
== External Links ==
 +
 +
[[Category:Distributions]]
 +
[[Category:Neo1973 Hardware]]
 +
[[Category:Neo FreeRunner Hardware]]
 +
[[Category:System Developers]]
 +
[[Category:User Interfaces]]
 +
[[Category:Community]]

Revision as of 20:17, 22 October 2008

Contents

Introduction

As Ben Leslie had pointed out on his blog far before the source code was released, Android was originally designed to work with the ARMv5TE instruction set architecture (ISA), which allows for DSP enhanced instructions. Contrary to the ARMv5TE ISA, the Neo1973 and FreeRunner handsets both feature an arm920t core, which comply to the ARMv4T ISA.

Before the source code was released, kernel trap handlers were implemented to 'emulate' the ARMv5TE ISA. Although the results worked in many cases, trapping is costly and performance suffered as a result. Moreover, without explicitly knowing which conditions were set by various instructions, such as Thumb Mode execution, the result became nondeterministic.

With the release of the Android source code, the Open Source community is no longer limited to dealing with a binary-only product. The Open Handset Alliance (OHA) has let their source code become a part of their product for everyone to benefit from and enrich.

Since the [Android OS http://www.android.com] was publically released on 20081021, work is currently underway to port Android to the Neo 1973 and FreeRunner handsets.

How to Help

You can start by following the instructions to download and build the Android source from scratch. Please see http://source.android.com/download and follow the instructions for your architecture.

Porting Strategy

  • Analysis and leverage of the existing build system
    • buid/core/combo/arm-linux.mk
      • -D__ARCH_ARM_4__ -D__ARCH_ARM_4T__
      • -march=armv4t -mcpu=arm920t
    • fix various static references to 'armv5'
  • Isolating ARMv5TE ISA dependent code
    • e.g. grep -n -R -i "${armv5te_isa_pattern}" ~/android
  • Abstracting
    • ( C/C++ ) Use inlined functions / #ifdef statments to implement functions in a portable manner
    • ( ASM ) #ifdef statements ?

For each ARMv5TE instruction, one could potentially

  • Implement the instruction using general registers instead of DSP calls (i.e. eabi / softfloat)
  • If that is a) nondeterministic, or b) slow, then sections of code need to be analyzed and hand-optimized for the ARMv4T isa

Important Links

(Please Update Me)

Documentation

Android Documentation - Bring yourself up to speed

Hardware Reference

[Neo1973 Hardware] [Neo FreeRunner GTA02 Hardware]

Communities

Android Public Mailing Lists Android on FreeRunner at KoolU.com [Openmoko Local Groups] [Openmoko:Community_Portal]

Buy a Handset and Debug Board

KoolU.com - North American distributor of the OpenMoko, backed by John "Mad Dog" Hall. [1] - [Debug Board v3]

References

External Links

Personal tools

Introduction

As Ben Leslie had pointed out on his blog far before the source code was released, Android was originally designed to work with the ARMv5TE instruction set architecture (ISA), which allows for DSP enhanced instructions. Contrary to the ARMv5TE ISA, the Neo1973 and FreeRunner handsets both feature an arm920t core, which comply to the ARMv4T ISA.

Before the source code was released, kernel trap handlers were implemented to 'emulate' the ARMv5TE ISA. Although the results worked in many cases, trapping is costly and performance suffered as a result. Moreover, without explicitly knowing which conditions were set by various instructions, such as Thumb Mode execution, the result became nondeterministic.

With the release of the Android source code, the Open Source community is no longer limited to dealing with a binary-only product. The Open Handset Alliance (OHA) has let their source code become a part of their product for everyone to benefit from and enrich.

Since the [Android OS http://www.android.com] was publically released on 20081021, work is currently underway to port Android to the Neo 1973 and FreeRunner handsets.

How to Help

You can start by following the instructions to download and build the Android source from scratch. Please see http://source.android.com/download and follow the instructions for your architecture.

Porting Strategy

  • Analysis and leverage of the existing build system
    • buid/core/combo/arm-linux.mk
      • -D__ARCH_ARM_4__ -D__ARCH_ARM_4T__
      • -march=armv4t -mcpu=arm920t
    • fix various static references to 'armv5'
  • Isolating ARMv5TE ISA dependent code
    • e.g. grep -n -R -i "${armv5te_isa_pattern}" ~/android
  • Abstracting
    • ( C/C++ ) Use inlined functions / #ifdef statments to implement functions in a portable manner
    • ( ASM ) #ifdef statements ?

For each ARMv5TE instruction, one could potentially

  • Implement the instruction using general registers instead of DSP calls (i.e. eabi / softfloat)
  • If that is a) nondeterministic, or b) slow, then sections of code need to be analyzed and hand-optimized for the ARMv4T isa

Important Links

(Please Update Me)

Documentation

Android Documentation - Bring yourself up to speed

Hardware Reference

[Neo1973 Hardware] - [Neo FreeRunner GTA02 Hardware] -

Communities

Android Public Mailing Lists Android on FreeRunner at KoolU.com [Openmoko Local Groups] [Openmoko:Community_Portal]

Buy a Handset and Debug Board

KoolU.com - North American distributor of the OpenMoko, backed by John "Mad Dog" Hall. [1] - [Debug Board v3]

References

External Links