-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: 256*256 double矩阵乘法耗时不符合预期 #21
Labels
bug
Something isn't working
Comments
该问题已复现,正在处理中。 |
暂无进展,后面结合裸机仿真找找原因。 |
|
仿真比较慢,今天未出结果,下周有初步结果再做进一步分析、测试。 |
|
|
soc 仿真已经复现了问题,目前正在分析波形。 |
目前还在分析波形,未确定问题。 |
|
问题及目前测试情况已汇总到晶哥那边,晶哥后面和平头哥沟通,待反馈。 |
请问这个问题有结论了吗? |
目前能确认是像64对齐下,dcache miss率显著提高,矩阵访存时addr[6]相同甚至就是同一个dcache index,一是同一index每次只能回填1路,另一路回填就得死等,另一个是伪随机替换策略导致可能刚回填的路马上被替换。建议可以试试以下2种优化:
|
当前是demo程序,实际应用中也不能确定什么时候会出现这个问题,不容易规避,这个问题有办法解决吗? |
问题2的计算量和耗时不成线性关系的原因是什么呢? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What happened
2.计算耗时没有线性关系,200x200矩阵 255x255的矩阵,计算量差距约2倍,实际耗时差6倍
Reproduction steps
代码如下,MATRIX_SIZE 修改矩阵维数,编译参数:
riscv64-unknown-linux-gnu-gcc -march=rv64imafdcxthead -mabi=lp64d -mcmodel=medany -ffunction-sections -fdata-sections -funroll-loops -Wall -std=gnu11 -mtune=c908 -O2 matrix.c -o matrix
Hardware board
k230 evb board
Software version
No response
Bug frequency
No response
Anything else
No response
The text was updated successfully, but these errors were encountered: