提交 8c343485 编写于 作者: W William Wang

atom: lr should raise load misalign exception

上级 b4edc553
......@@ -144,7 +144,8 @@ class AtomicsUnit(implicit p: Parameters) extends XSModule with MemoryOpConstant
"b10".U -> (in.src(0)(1,0) === 0.U), //w
"b11".U -> (in.src(0)(2,0) === 0.U) //d
))
exceptionVec(storeAddrMisaligned) := !addrAligned
exceptionVec(loadAddrMisaligned) := !addrAligned && isLr
exceptionVec(storeAddrMisaligned) := !addrAligned && !isLr
exceptionVec(storePageFault) := io.dtlb.resp.bits.excp(0).pf.st
exceptionVec(loadPageFault) := io.dtlb.resp.bits.excp(0).pf.ld
exceptionVec(storeAccessFault) := io.dtlb.resp.bits.excp(0).af.st
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册