分别采用中断、查询方式优化转发时间,上传备份代码,通过控制Makefile脚本里的APP_MARCH、MABI的rv32i和rv32e来控制C语言和asm优化
This commit is contained in:
@@ -8,12 +8,6 @@
|
||||
#include "sysDef.h"
|
||||
#include "plic.h"
|
||||
|
||||
#ifdef __riscv_i
|
||||
#define USING_POLL_STRATEGY
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
static void error();
|
||||
static uint32_t init_plic(void);
|
||||
|
||||
@@ -33,15 +27,9 @@ void main()
|
||||
//tx1 上行
|
||||
//rx0 下行
|
||||
//rx1 上行
|
||||
#ifdef USING_POLL_STRATEGY
|
||||
//使用查询策略 POLL_STRATEGY 操作 half lvds mac
|
||||
HLM_poll(WORKMODE_SLAVE);
|
||||
|
||||
#else
|
||||
//使用中断策略操作half lvds mac
|
||||
HLM_work_with_isr(WORKMODE_SLAVE);
|
||||
#endif
|
||||
|
||||
while (1);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user