SoCVistaFPGA时序分析之GateClock

上传人:痛*** 文档编号:136539423 上传时间:2022-08-17 格式:DOC 页数:8 大小:459KB
返回 下载 相关 举报
SoCVistaFPGA时序分析之GateClock_第1页
第1页 / 共8页
SoCVistaFPGA时序分析之GateClock_第2页
第2页 / 共8页
SoCVistaFPGA时序分析之GateClock_第3页
第3页 / 共8页
点击查看更多>>
资源描述
Bruce Zha n个人空间:由E件:zhanbin.dsp2009-2-26Version 1-0-0History:Versio n 1-0-0, released in itiailly(一)FPGA设计一条原则是尽量使用同步逻辑,即尽量整个设计中使用一个clock,而且该clock尽量走全局时钟线,也就是不要在clock path上加上逻辑,不要用 受控时钟”但是在有些情况下,受控时钟”难以避免,例如在用FPGA进行验证ASIC设计时,因为ASIC为了 low power的要求,通常会使用逻辑控制时钟的开关。如果对 受控时钟不加以任何变换,其负面作用通常是通常会有 hold timing冲突。hold timing 问题不像setup timing问题,不能靠依靠降低时钟频率解决; 在ASIC设计时解决hold timing 问题通常靠工具自动增加时钟树分支延迟,使时钟到目标寄存器的时间在建立-保持时间窗内。在FPGA阶段,通常有几种办法:1. 不理会hold timing问题,这样可能有时编译出来的系统可以正常工作,有时候又不能工 作,比较飘逸;2. 手工将gate clock等系统 异步”寸钟改成同步时钟,办法就是将clock path上的逻辑合并 到寄存器的数据输入端。3. 使用 synplify 将 gate clock 转换为 non-gate clock4. altera quartus8.0 以上有转换 gate clock的功能,可以使用。(二)synplify把gate clock转换为non-gate clock 的功能早已具有,这里先不讨论,下面主要试 试 altera 的 gate clock 功能。(1 )先试个简单的电路图,(2 )打开菜单 assignments-settings ,在 Analysis&Synthesis Settings项,选 Moresett in gs,打开如下图对话框,注意将 Auto Gated Clock Conversion选项设置为:On。还要写一个sdc约束文件,因为要使用Auto Gated Clock Conversion功能,必须使用TimeQuest Timing Analyzer 作时序分析,并且在 sdc文件中定义所有的base clocks 。简单SDC文件如下,If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If IfII II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II# Gen erated by : Bruce Zha n# Purpose : To verify gate-clock conversion using quartus8.1# Project : No ne# Revisi on : None# Date:#If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If If IfII II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II II# *# *Time In formatio n# set_time_format -un it ns -decimal_places 3# *Create Clock 100MHz# set period 10.000set periodl expr $period*2 create_clock get_ports i_clk -n ame clk -period $period -waveform 0.000 5.000然后在Timi ng An alysis Sett in gs项下,作如下图设置,记住要选中 Using TimeQuest Timing Analysis during compilation然后开始编译。(3)查看结果。编译报告见下图,Oo *0*尹1皿* 总 Lek1i cvflwcl品Bi母 Flw Tin4 亡W Flwr OSfil Flpw EtEl 8(. I Suth!K| fffl 母FilterEl 爭m IbkilhMlt IlBihC 弘疽章唐襦 SJK Ftl4 UHr nri Clcki- ljJ 郭 E N|*1E l j-J Fut *t 113ITilITI. t l-t Mt Dlk.Lh.上图表明有一个 clock 被作了 auto gated clock conversion打开如下图菜单,查看电路图,E .业 nd UlrKwft 即丄 SLAdiiili Atj Tfrdl一k晦TinkELC jbiLlyiii=2 LgdhSptrCt Elvrtr1 一 _ !j *l0 国“讥血 J#!iori1 匚bip1*逞戸1讳 u! Eii *ir LO | Lnp 0的下降沿,但因为 工作” Register上升沿有效,所以不会产生误动作。当Gating逻辑使用 或”门时:同步Register的 clock 端口使用 primary in put clock 的上升沿,工作Register的clock端口使用gated clock的下降沿;当关闭时钟时,假如primary in put clock 处于“ 0关闭后是“ 1”这时有一个“ 0” “ 1的上升沿,但因为 工作” Register下降沿有效,所以不会产生误动作;当关闭时钟时,假如primary in put clock 处于1,关闭后还是“ 1”所以也没有毛刺。5) 为了减少整个FPGA电路系统中glitch (组合逻辑通常会有glitch )的传播,因此作为Gating logic的与门/或”门应该尽量靠近 同步Register6) 整个 Gating clock 做成一个 module,其中包括 Gating逻辑,同步 Register。根据上述指导原则,第一幅电路图有1处问题:gate信号没有用 register同步;修改后的电路图见下, Bl- IMI a HaBd IU BUB I ,clKIyCL1HiPUL rledtOck EUTPillcat综合后的网表电路,wofklnadfli dettwofklnadfl从上图中可以看出 Working Register的clock已经是non-gated的了。
展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 图纸专区 > 成人自考


copyright@ 2023-2025  zhuangpeitu.com 装配图网版权所有   联系电话:18123376007

备案号:ICP2024067431-1 川公网安备51140202000466号


本站为文档C2C交易模式,即用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知装配图网,我们立即给予删除!