Update memory usage (latest release)

This commit is contained in:
Arun Prakash Jana 2017-07-05 08:17:51 +05:30
parent 342ecdc3ef
commit 3c612fe64d
No known key found for this signature in database
GPG key ID: A75979F35C080412
2 changed files with 5 additions and 6 deletions

View file

@ -96,12 +96,12 @@ Have fun with it! PRs are welcome. Check out [#1](https://github.com/jarun/nnn/i
### Performance ### Performance
`nnn` vs. ncdu memory usage while listing 438767 files in disk usage analyzer mode: `nnn` vs. ncdu memory usage in disk usage analyzer mode (438767 files on disk):
``` ```
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
22515 vaio 20 0 60348 48712 2240 S 0.0 0.6 0:01.11 ncdu / 22515 vaio 20 0 60348 48712 2240 S 0.0 0.6 0:01.11 ncdu /
22574 vaio 20 0 17588 4320 2584 S 0.0 0.1 0:00.44 nnn / 28306 vaio 20 0 17644 4500 2708 S 0.0 0.1 0:00.52 nnn -S /
``` ```
`nnn` vs. mc vs. ranger memory usage while viewing a directory with 11244 files, sorted by size: `nnn` vs. mc vs. ranger memory usage while viewing a directory with 11244 files, sorted by size:
@ -110,7 +110,7 @@ Have fun with it! PRs are welcome. Check out [#1](https://github.com/jarun/nnn/i
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
28450 vaio 20 0 93848 51548 7724 S 0.0 0.6 0:00.64 /usr/bin/python -O /usr/bin/ranger 28450 vaio 20 0 93848 51548 7724 S 0.0 0.6 0:00.64 /usr/bin/python -O /usr/bin/ranger
27265 vaio 20 0 67188 13620 6908 S 0.0 0.2 0:00.16 mc 27265 vaio 20 0 67188 13620 6908 S 0.0 0.2 0:00.16 mc
28360 vaio 20 0 20520 6932 2512 S 0.0 0.1 0:00.20 nnn 27925 vaio 20 0 20608 7168 2648 S 0.0 0.1 0:00.30 nnn
``` ```
### Installation ### Installation

5
nnn.c
View file

@ -782,8 +782,7 @@ dentcpy(struct entry *dst, struct entry *src)
* Move non-matching entries to the end * Move non-matching entries to the end
*/ */
static void static void
fill(struct entry **dents, fill(struct entry **dents, int (*filter)(regex_t *, char *), regex_t *re)
int (*filter)(regex_t *, char *), regex_t *re)
{ {
static int count; static int count;
@ -1856,7 +1855,7 @@ browse(char *ipath, char *ifilter)
char path[PATH_MAX], oldpath[PATH_MAX], newpath[PATH_MAX]; char path[PATH_MAX], oldpath[PATH_MAX], newpath[PATH_MAX];
char lastdir[PATH_MAX]; char lastdir[PATH_MAX];
char fltr[LINE_MAX]; char fltr[LINE_MAX];
char *dir, *tmp, *run, *env, *tgt=NULL; char *dir, *tmp, *run, *env, *tgt = NULL;
struct stat sb; struct stat sb;
int r, fd, presel; int r, fd, presel;
enum action sel = SEL_RUNARG + 1; enum action sel = SEL_RUNARG + 1;