lede/package
Chuck aaba169f2f
optimize the performance of obtaining CPU usage (#6399)
Preformance Test (on NanoPi R2s, repeat 1000 times):

old command

cpu_usage=$(expr 100 - $(cat /tmp/top_tmp | grep 'CPU:' | awk -F '%' '{print$4}' | awk -F ' ' '{print$2}'))

```
real    0m 14.25s
user    0m 7.96s
sys     0m 20.33s
```

new command

cpu_usage=$(cat /tmp/top_tmp | awk '/^CPU/ { printf("%d%%", 100 - $8) }')

```
real    0m 6.91s
user    0m 4.29s
sys     0m 6.06s
```

Signed-off-by: Chuck <fanck0605@qq.com>
2021-02-21 12:26:19 +08:00
..
base-files add function extra_command (#6357) 2021-02-11 09:19:12 +08:00
boot kernel: bump 5.4 to 5.4.95 (#6340) 2021-02-08 17:13:28 +08:00
devel Sync to snapshot kernel 5.4 version 2020-07-02 23:30:56 +08:00
firmware mac80211: update to 5.8.18-1 (#6200) 2021-01-18 13:06:03 +08:00
kernel kernel: bump 5.4 to 5.4.91 (#6225) 2021-01-21 20:51:19 +08:00
lean optimize the performance of obtaining CPU usage (#6399) 2021-02-21 12:26:19 +08:00
libs openssl: bump to 1.1.1j (#6410) 2021-02-21 12:25:02 +08:00
network Bump wireguard to 1.0.20210124 (#6285) 2021-02-01 11:16:20 +08:00
system Revert back to May 12th Version (#5803) 2020-11-17 19:18:31 +08:00
utils kernel: bump to 4.14.193, 4.19.138, 5.4.59 (#5350) 2020-08-26 11:31:50 +08:00
Makefile sync build script for OpenWrt 19.07 2020-02-21 02:41:00 +08:00