• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Programming Standards

 
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

As we know mobiles are very resource constrained, sow while creating any application we should keep this in mind...
so does your book cover any Tips for writing efficient code ..??

 
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Imrad, the book certainly covers writing code efficiently. It would not be much of a book if it hadn't. However, check out the full table of contents at pragmatic programmers' website
 
Author
Posts: 142
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, writing efficient code is mentioned several times in the book. You can also find some tips collected by the Android team here:

http://d.android.com/guide/practices/design/performance.html

As of Android 1.1, the compiler and VM are pretty dumb when it comes to automatic optimization. There is no just-in-time compilation or escape analysis or anything like that. At last year's Google I/O conference I asked designer Dan Bornstein about this and he said they were trying to make the VM as small and simple as possible in the first version. So if you have a tight loop, simple things like hoisting common subexpressions and memory allocation out of the loop can make a big difference. According to Dan, they have plenty of ideas for improving things in the future so that existing code will run faster. But for now, that's what you have to put up with.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic