Commit Graph

14 Commits

Author SHA1 Message Date
Denys Vlasenko
feafb3423e bzip2: ~1% speedup by special-casing "store 1 bit" function
function                                             old     new   delta
bsW1                                                   -      52     +52
BZ2_compressBlock                                    230     225      -5
BZ2_blockSort                                        125     118      -7
sendMTFValues                                       2070    2051     -19
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 0/3 up/down: 52/-31)             Total: 21 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-02-03 04:43:46 +01:00
Denys Vlasenko
982c44d030 bzip2: rewrite bit of code which depends on integer overflow
function                                             old     new   delta
sendMTFValues                                       2093    2070     -23

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-02-03 03:34:40 +01:00
Denys Vlasenko
83dd4ff696 bzip2: delete write-only fave[] array
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-02-03 03:17:48 +01:00
Denys Vlasenko
3a2c97bd12 bgip2: fewer specifically-sized [u]int32_t's locals in sendMTFValues
Generic ints/unsigneds are usually fine. Yes, really.

function                                             old     new   delta
sendMTFValues                                       2100    2093      -7

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-02-03 03:14:07 +01:00
Denys Vlasenko
359230da8e bzip2: code shrink
function                                             old     new   delta
sendMTFValues                                       2111    2100     -11

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-02-03 02:03:42 +01:00
Denys Vlasenko
e594fb2171 bzip2: code shrink
function                                             old     new   delta
BZ2_compressBlock                                    225     230      +5
handle_compress                                      356     355      -1
bsW16                                                 59      56      -3
bsW                                                   64      61      -3
bsFinishWrite                                         37      32      -5
prepare_new_block                                     48      34     -14
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/5 up/down: 5/-26)             Total: -21 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-02-03 01:30:12 +01:00
Denys Vlasenko
125c3ff4b1 bzip2: code shrink
function                                             old     new   delta
bsW16                                                  -      59     +59
sendMTFValues                                       2116    2111      -5
bsPutU16                                              36       -     -36
bsPutU32                                              76      31     -45
------------------------------------------------------------------------------
(add/remove: 1/1 grow/shrink: 0/2 up/down: 59/-86)            Total: -27 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-02-02 20:59:28 +01:00
Maninder Singh
97f2f7ca7f Removes stray empty line from code
This patch removes stray empty line from busybox code
reported by script find_stray_empty_lines

Signed-off-by: Maninder Singh <maninder1.s@samsung.com>
Signed-off-by: Akhilesh Kumar <akhilesh.k@samsung.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-07-13 03:25:46 +02:00
Denys Vlasenko
9b2a9f0210 fix assorted unused code and wrong format specs found by cppchekc (bug 6716)
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2013-11-29 16:43:33 +01:00
Denys Vlasenko
5117eff6f9 Fix some compiler warnings emitted by gcc-4.8.0
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2013-10-16 14:21:20 +02:00
Denys Vlasenko
522041ee7b regularize options which control size/speed trade
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2011-09-10 13:25:57 +02:00
Denys Vlasenko
60a9414cad fix "variable 'foo' set but not used" warnings
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2011-05-13 20:57:01 +02:00
Denys Vlasenko
ed9b08d1c1 bzip2: plug memory leak on every processed file
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2010-12-30 04:43:35 +01:00
Denys Vlasenko
833d4e7f84 rename archival/libunarchive -> archival/libarchive; move bz/ into it
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2010-11-03 02:38:31 +01:00