Commit graph

7997 commits

Author SHA1 Message Date
renzhiyuan1
8dfd998db1 cmake:add cmsis-nn CMake build
Signed-off-by: renzhiyuan1 <renzhiyuan1@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
dda8cab335 ml: tflm mean optimization patch
Separate the Int8 implementation of the 'mean' operator to reduce the code size.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
068b2b16bb ml: tflm quantize optimization patch
Separate the 'Float32 to Int8' implementation of the 'quantize' operator to reduce the code size.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
570102c501 delete the neon conv2D
The complete implementation is placed separately in mLearning/tflite-micro/operators/neon, delete this part.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
jihandong
14a591fab2 ml: tflm dequantize optimization patch
Signed-off-by: jihandong <jihandong@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
67f495e360 Added Cortex-A compilation environment.
Cortex-A compilation options are added to tflite-micro and cmsis-nn, and new operator compilation environments are configured.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
11519fe1ca Update third-party library version
Tflite-micro, ruy and cmsis-nn need to be updated to a new version.
Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
fb17e33894 Neon optimized Add operator
VELAPLATFO-25411

On the basis of CMSIS-NN, neon was used to optimize the Add operator, which calculates the offset and addition of eight input and output data in one loop.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
a37ca36a8a Neon optimized Conv operator
Based on CMSIS-NN, the Conv operator was optimized. Using Neon acceleration, multiply 8 input data and 8 filter data in a single loop; Using Im2col technology, convert the output data into a matrix, calculate 2 rows of input data and 4 rows of filter data in a single large loop, and obtain 2x4 output data.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
xinhaiteng
754d9e39a8 TFLM Cortex-A NEON Conv
Use neon to accelerate the conv op, and the output results are the same.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
2024-10-18 09:40:17 +08:00
renzhiyuan1
71cbcb2618 Add configurations files.
Add configuration files of TFLite Micro, its dependent third-party libraries and CMSIS_NN.

Signed-off-by: renzhiyuan1 <renzhiyuan1@xiaomi.com>
2024-10-18 09:40:17 +08:00
xuxin19
bdfce937e9 remove:flatbuffers,gemmlowp,kissfft,ruy repos
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-10-18 09:40:17 +08:00
dengwenqi
6b6e0783cf fix: git status/git status --ignore normalization check problem
Signed-off-by: dengwenqi <dengwenqi@xiaomi.com>
2024-10-18 09:40:17 +08:00
dengwenqi
06189b556c fix: git status/git status --ignore normalization check problem
Signed-off-by: dengwenqi <dengwenqi@xiaomi.com>
2024-10-18 09:40:17 +08:00
Lup Yuen Lee
0a4170daf7 CI: Skip jobs arm-08 to arm-14 when a Complex PR is created / updated
When we submit or update a Complex PR that affects All Architectures (Arm, RISC-V, Xtensa, etc): CI Workflow shall run only half the jobs. Previously CI Workflow will run `arm-01` to `arm-14`, now we will run only `arm-01` to `arm-07`.

When the Complex PR is Merged: CI Workflow will still run all jobs `arm-01` to `arm-14`

Simple PRs with One Single Arch / Board will build the same way as before: `arm-01` to `arm-14`

This is explained here: https://github.com/apache/nuttx/issues/14376

Note that this version of `arch.yml` has diverged from `nuttx` repo, since we are unable to merge https://github.com/apache/nuttx/pull/14377
2024-10-18 02:10:17 +02:00
chenzihan1
f426265ab2 testing: mm test will be skipped to prevent memory overflow
In the mm test, if the memory requested this time exceeds 3/4 of the remaining memory,
the request will be skipped to avoid insufficient memory.

Signed-off-by: chenzihan1 <chenzihan1@xiaomi.com>
2024-10-17 23:29:41 +08:00
Lup Yuen Lee
4b8375ea95 CI: Disable all jobs for macOS and Windows
This PR disables all CI Jobs for macOS and Windows, to reduce GitHub Cost. Details here: https://github.com/apache/nuttx/issues/14376
2024-10-17 23:22:13 +08:00
zhengyu9
697e3bed0a apps/nshlib/cmd_cd: Modify the logic of cd
Modify the implementation logic of changing directory.
There's an error handling the path incluing "../" or "./"

bug examples:

nsh> cd proc/self/group
nsh> cd ../..
nsh: cd: chdir failed: 2

nsh> pwd
/proc/self
nsh> ls
/proc/self:
 status
 cmdline
 stack
 group/
nsh> cd ./group
nsh: cd: chdir failed: 2

Signed-off-by: zhengyu9 <zhengyu9@xiaomi.com>
2024-10-17 18:06:48 +08:00
yinshengkai
59c21c7aee nsh: support watch command
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-17 18:06:32 +08:00
xuxin19
e558c8e028 build(bugfix):fix Make.dep location missing when specifying PREFIX, hide invalid cp output from ar
PREFIX needs to be added to Make.dep to avoid Make.dep regeneration during incremental compilation
AROBJSRULES is just the .o file in the copy archive. Its output content is worthless, so we hide it by default.

Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-10-17 18:06:00 +08:00
wangjianyu3
c5c18a2997 nshlib/cmd_cat: Avoid casting -1 to size_t as count of nsh_write()
Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-10-17 08:55:51 +08:00
wanggang26
cb24b748a5 coredump app: type of info->time has changed into timespec
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2024-10-17 08:55:22 +08:00
makejian
6588ce4840 apps/mbedtls: add compilation configuration
1.Supplement cmake to compile POLY1305/RIPEMD160/Bignum algorithms
2.Add blowfish and arc4 algorithm configuration

Signed-off-by: makejian <makejian@xiaomi.com>
2024-10-17 08:54:55 +08:00
wangjianyu3
0b727d290b examples/sotest: Correct the path in the log
e.g.
  - ERROR: dlopen(/sotest) failed
  + ERROR: dlopen(/mnt/sotest/romfs/sotest) failed

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-10-17 08:53:49 +08:00
yinshengkai
15b081f02d nshlib: fix top command sorting result error
qsort expects the return value to be -1,0,1

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-17 00:00:51 +08:00
cuiziwei
b022a71480 cxxsize: Updata code size.
Signed-off-by: cuiziwei <cuiziwei@xiaomi.com>
2024-10-16 17:10:33 +02:00
wangjianyu3
4eba6101b4 module/sotest: Using syslog to print log
Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-10-16 21:42:39 +08:00
buxiasen
4285c4df73 nsh/ps: fix -heap cut more than 10MB
Signed-off-by: buxiasen <buxiasen@xiaomi.com>
2024-10-16 18:23:54 +08:00
anjiahao
6979fca4dc nshlib: Support top command
show thread sort by cpuloading:
use `top [-n <num> ][ -d <delay>] [ -p <pidlist>] [ -h ]`

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-16 18:23:54 +08:00
anjiahao
6951b64038 nshlib: Reconstruct ps command for top command
divide data collection and data output into two parts

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 18:23:54 +08:00
yinshengkai
b90899b1d5 nshlib: ps supports noheap parameter
Obtaining the heap usage size requires traversing all memory.
When the number of threads is large, it will become very slow.

ps -heap
PID GROUP PRI POLICY   TYPE    NPX STATE    EVENT     SIGMASK              HEAP  STACK   USED  FILLED COMMAND
  0     0   0 FIFO     Kthread   - Ready              0000000000000000  4338432 2162672 0005196   0.2%  Idle_Task

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-16 18:23:54 +08:00
zhushiqshi
a655e067ef apps: added pid list for ps command.
Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2024-10-16 18:23:54 +08:00
anjiahao
c98439f9a1 coredump:update memory region init
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 17:34:02 +08:00
wangyingdong
47c8d3734a Fix to compile failure after mqttc is enabled
Signed-off-by: wangyingdong <wangyingdong@xiaomi.com>
2024-10-16 17:25:46 +08:00
wangyingdong
8eb791763c netutils: introduce libwebsockets support
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2024-10-16 17:25:46 +08:00
ouyangxiangzhen
880e2661dc apps/testing: Introduce timerjitter test case
This commit introduces the timerjitter test case, designed for assessing timer accuracy quickly. It is a simplified cyclictest implementation, optimized for fast and effective testing of timer precision.
The program sets up a periodic timer and awaits the firing of SIGALRM. Upon signal arrived, it computes the time difference between consecutive periods. A smaller time difference indicates higher time accuracy.
You can execute timerjitter without passing any arguments. Alternatively, you have the option to pass '-p' to print the time difference after each period, or provide additional arguments to customize the timer interval (in microseconds) and the number of test iterations.

Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
2024-10-16 17:09:51 +08:00
chao an
43d634ce00 nsh/fsutils: fix build break if CONFIG_NSH_DISABLE_PKILL not disabled
arm-none-eabi/bin/ld: apps/libapps.a(nsh_proccmds.c.obj): in function `cmd_pkill':
apps/nshlib/nsh_proccmds.c:861:(.text.cmd_pkill+0x38): undefined reference to `nsh_getpid'

Signed-off-by: chao an <anchao@lixiang.com>
2024-10-16 14:32:13 +08:00
pengyaozong
63f43e70a9 add LIBUV_HANDLE_BACKTRACE
Signed-off-by: pengyaozong <pengyaozong@xiaomi.com>
2024-10-16 14:30:34 +08:00
anjiahao
c693b3064e system/coredump:support coredump can save board memory
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
anjiahao
9752b57714 system/coredump:upload kernal coredump change
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
anjiahao
b99f92bac5 system/coredump:fix coverity bug
check read return, avoid dead loop if read return zero

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
anjiahao
03f3ce7fd4 system/coredump:Increase coredump swap buffer size to improve speed
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
Xiang Xiao
e96f1ca83a system/ymodem: Change #include <nuttx/mm/circbuf.h> to #include <nuttx/circbuf.h>
follow the change in kernel side change

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-10-16 14:20:34 +08:00
yangguangcai
49941f1d57 cmd_date:Set optind to zero in the error case.
Signed-off-by: yangguangcai <yangguangcai@xiaomi.com>
2024-10-16 12:40:04 +08:00
anjiahao
8130d7e211 zlib:Support using Kconfig to control memory usage in zlib
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 12:39:47 +08:00
Yongrong Wang
3514c6c704 drivertest/Makefile: add CONFIG_BUILD_FLAT limit for drivertest_block.c
If BUILD_FLAT is not enabled, the app and CPU run in user mode and
kernel mode respectively. The kernel and app are in different
memory address spaces. Different apps are in the same memory address
space. drivertest_block.c cannot directly call the kernel API.

Signed-off-by: Yongrong Wang <wangyongrong@xiaomi.com>
2024-10-16 12:34:25 +08:00
Bowen Wang
4af9653b1e nshlib/nsh_parse: support use \\ to pass '\' to argument
Now the nsh can use \\ to pass '\' to the command

Signed-off-by: Bowen Wang <wangbowen6@xiaomi.com>
2024-10-16 10:21:30 +08:00
anjiahao
bb492e789d sotest & chardev:change elf loading method
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 07:38:06 +08:00
anjiahao
bebb7e9a46 module/sotest:use Compile dynamic modules using a unified compilation method
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 07:38:06 +08:00
anjiahao
293c05b5e6 apps/Makefile:Add a postinstall keyword to do something before compilation is completed and linking begin
It is better to package the dynamic module into romfs after it is compiled.

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 07:38:06 +08:00