请教 TMS570LS1227芯片内部是否有软件陷阱中断?

请问TMS570LS1227芯片内部是否有软件陷阱中断?如计算除法时,除数是0产生了错误,堆栈溢出时......等此类问题是否会产生错误的中断?

1 个回复

  • TMS570LS1227的话,这些软件陷阱中断是包含在ARM® Cortex®-R4F的处理中的

    如除数是0等许多FPU错误情况,ARM提供可屏蔽的CPU输出,然后TI将这些输出组合并连接到VIM中断控制器。如果启用,FP除以零将导致在FPDZC CPU输出上驱动输出,然后将导致对VIM 47号线的中断请求(FPU中断)。

    Table 4-25 Secondary Auxiliary Control Register bit functions

    为了在FPU中生成未定义的异常,ARM在R4 TRM中给出了一些提示:

    • section 12.1.1 - "Any data processing instruction that operates on a vector generates an UNDEFINED exception." 
    • section 12.1.2 - "An instruction which attempts to access any of the registers D16-D31 generates an UNDEFINED exception"
    • section 12.3 - "When a privileged mode is required, an instruction that attempts to access a register in a nonprivileged mode takes the UNDEFINED exception"
    • section 12.3.3 - "Clearing EN disables VFP functionality, causing all VFP instructions apart from privileged system register accesses to generate an UNDEFINED exception"

    建议尝试使用ARM指出的任何一种情况来生成异常。

    DDI0363E_cortexr4_r1p3_trm.pdf

     

    若是该回复回答了您的问题,请点击“确认此为答案”,谢谢

    If a post answers your question, please mark it with the "verify answer" button.