• S
    Remove unnecessary options from fast-import. · e5808826
    Shawn O. Pearce 提交于
    The --objects command line option is rather unnecessary.  Internally
    we allocate objects in 5000 unit blocks, ensuring that any sort
    of malloc overhead is ammortized over the individual objects to
    almost nothing.  Since most frontends don't know how many objects
    they will need for a given import run (and its hard for them to
    predict without just doing the run) we probably won't see anyone
    using --objects.  Further since there's really no major benefit
    to using the option, most frontends won't even bother supplying
    it even if they could estimate the number of objects.  So I'm
    removing it.
    
    The --max-objects-per-pack option was probably a mistake to even
    have added in the first place.  The packfile format is limited
    to 4 GiB today; given that objects need at least 3 bytes of data
    (and probably need even more) there's no way we are going to exceed
    the limit of 1<<32-1 objects before we reach the file size limit.
    So I'm removing it (to slightly reduce the complexity of the code)
    before anyone gets any wise ideas and tries to use it.
    Signed-off-by: NShawn O. Pearce <spearce@spearce.org>
    e5808826
fast-import.c 46.9 KB