in GCC stl_algo.h, why _M_chunk_size = 7 ??

Discussion in 'C++' started by Pgnn.N, Jul 1, 2003.

  1. Pgnn.N

    Pgnn.N Guest

    hi,

    I'm really curious about the _M_chunk_size value.
    It's in line 02303 of stl_algo.h.
    (http://gcc.gnu.org/onlinedocs/libstdc /libstdc -html-USERS-3.3/
    stl__algo_8h-source.html)
    It restricts the elements size to be 7 when use insertion sort (line 02305 to 02315).

    I've heard that using insertion sort is better than quick sort when elements size < 12.
    But, are there any reason for elements size to be 7, not 9 or 11???

    Sorry for my bad english.

    I hope your help.
    thanks.
     
    Pgnn.N, Jul 1, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    8
    Views:
    464
  2. Kevin P. Fleming

    C99 structure initialization in gcc-2.95.3 vs gcc-3.3.1

    Kevin P. Fleming, Nov 6, 2003, in forum: C Programming
    Replies:
    2
    Views:
    682
    Kevin P. Fleming
    Nov 6, 2003
  3. Mr. SweatyFinger

    why why why why why

    Mr. SweatyFinger, Nov 28, 2006, in forum: ASP .Net
    Replies:
    4
    Views:
    997
    Mark Rae
    Dec 21, 2006
  4. Mr. SweatyFinger
    Replies:
    2
    Views:
    2,269
    Smokey Grindel
    Dec 2, 2006
  5. Replies:
    5
    Views:
    390
    Nathan Addy
    Sep 17, 2005
Loading...

Share This Page