×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    May 2005
    Posts
    76

    optimization: "index creation outside of the loops"

    I came across the article http://wiki.forum.nokia.com/index.ph...ize_in_Java_ME. One of the optimizations listed there is "index creation outside of the loops" (with code example).

    Is this hint really true? Can such optimization really "save a few seconds on a real device!" ?

    Thanks.
    Last edited by hnipak; 2008-08-07 at 12:25.

  2. #2
    Super Contributor
    Join Date
    Oct 2007
    Location
    Deva, Romania
    Posts
    3,471

    Re: optimization: "index creation outside of the loops"

    I guess the "save a few seconds" part depends on the device and the loop (meaning the number of times the same operation is performed). Theoretically this should help, as you only create the variables once (outside the loop) rather than several times (each time the loop returns). But again, it's hard to determine just how much it would help...

  3. #3
    Registered User
    Join Date
    May 2005
    Posts
    76

    Re: optimization: "index creation outside of the loops"

    I guess I misunderstood. I can see the benefit of moving index value calculation of the innermost loop etc.

    I misread "index creation" as "index declaration"...

Similar Threads

  1. API Partnering request for SIP profile creation
    By Dipakbaviskar in forum VoIP
    Replies: 4
    Last Post: 2008-01-10, 03:45
  2. File creation time
    By Trojan in forum Symbian
    Replies: 0
    Last Post: 2006-11-23, 07:08
  3. Content creation tools.
    By DavidTimperley in forum Streaming and Video
    Replies: 0
    Last Post: 2006-01-29, 21:52
  4. Content creation tools.
    By DavidTimperley in forum Symbian Media (Closed)
    Replies: 0
    Last Post: 2006-01-29, 21:49
  5. Content creation tools.
    By DavidTimperley in forum Mobile Java Media (Graphics & Sounds)
    Replies: 0
    Last Post: 2006-01-29, 21:46

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×