Android

From Openmoko

(Difference between revisions)
Jump to: navigation, search
(How to Help)
Line 10: Line 10:
  
 
= How to Help =
 
= How to Help =
 +
 +
== Getting Started ==
  
 
You can start by following the instructions to download and build the Android source from scratch. Please see [http://source.android.com/download http://source.android.com/download] and follow the instructions for your architecture.
 
You can start by following the instructions to download and build the Android source from scratch. Please see [http://source.android.com/download http://source.android.com/download] and follow the instructions for your architecture.
 +
 +
== Publicize Your Efforts ==
 +
 +
It's generally a good idea to make your efforts known via wiki systems, public mailing lists, forums, and publically open version control systems.
 +
 +
Always take credit for your work but please don't do it in the form of comments. Some code is already hard enough to read without comments polluting the text. The best thing to do is to create a patch and put a header with your information at the top. Collaboration systems such as git might already do this for you (??).
 +
 +
If you create something new and have the ability to designate the license for it, please consider license compatibility issues.
  
 
== Porting Strategy ==
 
== Porting Strategy ==
Line 29: Line 39:
 
* 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
 +
 +
== Updates ==
 +
 +
Feel free to post a link to any of your work in the list below
 +
 +
[User:Cfriedt] - Android -> FreeRunner updates on my [http://perpetual-notion.blogspot.com/search/label/android blog]
  
 
= Important Links =
 
= Important Links =

Revision as of 20:36, 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

Getting Started

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.

Publicize Your Efforts

It's generally a good idea to make your efforts known via wiki systems, public mailing lists, forums, and publically open version control systems.

Always take credit for your work but please don't do it in the form of comments. Some code is already hard enough to read without comments polluting the text. The best thing to do is to create a patch and put a header with your information at the top. Collaboration systems such as git might already do this for you (??).

If you create something new and have the ability to designate the license for it, please consider license compatibility issues.

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

Updates

Feel free to post a link to any of your work in the list below

[User:Cfriedt] - Android -> FreeRunner updates on my blog

Important Links

(Please Update Me)

Documentation

Hardware Reference

Communities

Buy a Handset and Debug Board

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

Hardware Reference

Communities

Buy a Handset and Debug Board

References

External Links