Skip to content

Commit

Permalink
doc: add doc about nuclei near cycle model profiling and optimize wit…
Browse files Browse the repository at this point in the history
…h NICE/VNICE (#38)

* doc: add doc to show how to use NICE/VNICE for acceleration when using the Nuclei Model

* doc: Fix the writing issues in the document

* doc: Correct the content errors in the document

* doc: Add the introduction to the implementation of NICE/VNICE instructions in the Nuclei Model

* doc: Update the missing explanation of the NICE instruction cycle number in the doc

* doc: Further explain the doc

* doc: Update table description

---------

Co-authored-by: XuZitai <[email protected]>
  • Loading branch information
xzt777 and XuZitai authored Aug 30, 2024
1 parent cb90ae7 commit 978b79d
Show file tree
Hide file tree
Showing 20 changed files with 360 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,6 @@ Nuclei Studio 2024.06 提供 Profiling 功能、Call Graph 功能 以及 Code co
* Nuclei studio:[NucleiStudio 2024.06](https://download.nucleisys.com/upload/files/nucleistudio/NucleiStudio_IDE_202406-win64.zip),以 Windows 版本为例
* 用例: 以 [AMR-WB-enc](https://sourceforge.net/projects/opencore-amr/files/vo-amrwbenc/vo-amrwbenc-0.1.3.tar.gz/download) 即自适应多速率宽带编码音频算法为例,用户可以移植自己的用例

这里提供本示例使用的工程,有兴趣可以下载使用:
[优化前的工程下载链接](https://drive.weixin.qq.com/s?k=ABcAKgdSAFcCRlyEVI)

下载 zip 包后,可以直接导入到 nuclei studio 中运行(导入步骤:File->Import->Existing Projects into Workspace->Next->Select archive file->选择zip压缩包->next即可)

**基于 nuclei-sdk v0.6.0 移植 amrwbenc 裸机用例:**

打开 Nuclei studio 建立 amrwbenc 工程,然后移植 amrwbenc 源码,最终用例可正常运行。用户可以移植自己的用例,不同用例移植的细节各不相同,这一步不是这篇文档的重点,略过。
Expand All @@ -47,7 +42,12 @@ File->New->New Nuclei RISC-V C/C++ Project,选择Nuclei FPGA Evalution Board->

**step2:基于 Profiling demo 工程移植 amrwbenc 裸机用例**

删掉 Profiling demo 工程中 application 中的原始用例,替换成 amrwbenc 用例,形成如下目录结构,并确保能编译成功。
删掉 Profiling demo 工程中 application 中的原始用例,替换成 amrwbenc 用例,形成如下目录结构,并确保能编译成功。

这里提供本示例使用的工程,有兴趣可以下载使用:
[优化前的工程下载链接](https://drive.weixin.qq.com/s?k=ABcAKgdSAFcCRlyEVI)

下载 zip 包后,可以直接导入到 nuclei studio 中运行(导入步骤:File->Import->Existing Projects into Workspace->Next->Select archive file->选择zip压缩包->next即可)

![移植amrwbenc用例](asserts/images/17/amrwbenc_demo.png)

Expand Down Expand Up @@ -93,7 +93,7 @@ int main(int argc, char *argv[]) {
* qemu 模拟器(不需要硬件,简单跑一下流程,测试结果不准确)
* 上板测试 (基于定时器采集数据)
* 基于 xl_cpumodel (也是模拟器,结果比 qemu 准确,另一篇文章介绍)
* 基于 xl_cpumodel (Nuclei near cycle model),参考: [通过Profiling展示Nuclei Model NICE/VNICE指令加速](18-demonstrate_NICE_VNICE_acceleration_of_the_Nuclei_Model_through_profiling.md)
这一篇文章只介绍 qemu 仿真与上板测试两种方式,qemu 收集的数据打印到 Console 口,上板实际运行输出到 Nuclei studio 的 Serial Terminal 口。
Expand Down

Large diffs are not rendered by default.

Binary file added asserts/images/18/Main_configuration.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/RVProf_configuration.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/aes_demo_cycle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/aes_demo_nice_cycle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/aes_demo_profiling.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/aes_main_configuration.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/aes_rvprof_configuration.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/compile_aes_demo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/compile_aes_nice_demo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/create_aes_project.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/model_run_aes_demo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/new_rvprof_configuration.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/nice_inst_intro.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/parse_gprof.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/parse_gprof_aes_enc_dec.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/parse_gprof_nice.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/xlmodel_nice_aes.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added asserts/images/18/xlmodel_nice_build.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 978b79d

Please sign in to comment.