Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6787299
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T17:20:59+00:00 2026-05-26T17:20:59+00:00

This is an open question towards learning about memory optimization and code optimization for

  • 0

This is an open question towards learning about memory optimization and code optimization for faster execution. What would you give more importance within the two ?

How do you usually optimize you code to use memory efficiently ?

How do you optimize your code to run faster ?

As a mobile developer we’ve to give importance to use memory properly. But sometimes using it usually backfires by creating more objects or under utilizing the memory.

What are your usual methods to optimize memory & decrease the run time of the application ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T17:20:59+00:00Added an answer on May 26, 2026 at 5:20 pm

    This is a difficult to answer question. There is no general answer to this question, it depends on your priorities. For some apps(chess programs) it is the efficiency, for some apps(gallery app) it is the memory usage that is more important. However, more often than not, neither of these could be a bottleneck. In such cases, you should choose the cleanest and easiest to maintain way.

    However in my experience, most of the time it is the memory that cause the bottleneck(if there is one at all) on Android. On StackOverflow, everyday I see some posts about OutOfMemory errors and I rarely see a my app is running too slow post.

    Here are some specific tips that come to my mind:

    1) Call

    bitmap.recycle();
    

    whenever the bitmap is not needed. This could release the memory earlier.

    2)
    Try to avoid file access as much as possible. Using a SQLite db can help you achieve that in a more efficient way.

    3)
    Don’t leak memory. Use memory management tools that come with eclipse to track those leaks.

    4)
    Hand big files in chunks, and small files without chunks!

    5)
    Check this video on "android memory management". It gives plenty of useful information.

    Also there is similar discussion here: Memory efficiency vs Processor efficiency (note that it is not specifically for android)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is a bit of an open question but I would really like to
This question is about etiquette and open source projects. I have forked an application
This is more of an open question rather than looking for one specific answer.
I found this open question online. How do you process a large data file
This is related to another open question of mine . While there aren't any
This is a difficult and open-ended question I know, but I thought I'd throw
This question is a bit open ended as I'm not sure it's possible or
This question will expand on: Best way to open a socket in Python When
I hope this question isn't too open ended, but a nudge in the right
This is a question from a Java noob. I have eclipse open (JRE 1.6),

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.