¼ÆËã»úϵͳ½á¹¹¿ÎºóÌâ

[ÀýÌâ1.1] ¼ÙÉ轫ijһ²¿¼þµÄ´¦ÀíËٶȼӿ쵽10±¶£¬¸Ã²¿¼þµÄÔ­´¦Àíʱ¼ä½öΪÕû¸öÔËÐÐʱ¼äµÄ40%£¬Ôò²ÉÓüӿì´ëÊ©ºóÄÜʹÕû¸öϵͳµÄÐÔÄÜÌá¸ß¶àÉÙ£¿

[½â´ð] ÓÉÌâÒâ¿ÉÖª£ºFe=0.4, Se=10£¬¸ù¾ÝAmdahl¶¨ÂÉ£¬¼ÓËÙ±ÈΪ£ºSn=1/(0.6+0.4/10)=1.56

[ÀýÌâ1.2] ²ÉÓÃÄÄÖÖʵÏÖ¼¼ÊõÀ´Ç󸡵ãÊýƽ·½¸ùFPSQRµÄ²Ù×÷¶ÔϵͳµÄÐÔÄÜÓ°Ïì½Ï´ó¡£¼ÙÉèFPSQR²Ù×÷Õ¼Õû¸ö²âÊÔ³ÌÐòÖ´ÐÐʱ¼äµÄ20%¡£Ò»ÖÖʵÏÖ·½·¨ÊDzÉÓÃFPSQRÓ²¼þ£¬Ê¹FPSQR²Ù×÷µÄËٶȼӿ쵽10±¶¡£ÁíÒ»ÖÖʵÏÖ·½·¨ÊÇʹËùÓи¡µãÊý¾ÝÖ¸ÁîµÄËٶȼӿ죬ʹFPÖ¸ÁîµÄËٶȼӿ쵽2±¶£¬»¹¼ÙÉèFPÖ¸ÁîÕ¼Õû¸öÖ´ÐÐʱ¼äµÄ50%¡£Çë±È½ÏÕâÁ½ÖÖÉè¼Æ·½°¸¡£

[½â´ð] ·Ö±ð¼ÆËã³öÕâÁ½ÖÖÉè¼Æ·½°¸ËùÄܵõ½µÄ¼ÓËٱȣº

[ÀýÌâ1.2]

[½â´ð]

=(4*25%)+(1.33*75%)=2.0

·½°¸1£ºCPI1=CPIÔ­-2%*£¨CPIÀÏ1-CPIÐÂ1£©=2.0-2%*£¨20-2£©=1.64 ·½°¸2£ºCPI2=CPIÔ­-25%*£¨CPIÀÏ2-CPIÐÂ2£©=2.0-25%*£¨4-2£©=1.5

·½°¸2µÄ¼ÓËÙ±È=CPUʱ¼äÔ­/CPUʱ¼ä2=IC*ʱÖÓÖÜÆÚ*CPIÔ­ / IC*ʱÖÓÖÜÆÚ*CPI2=2/1.5=1.33

[Ï°Ìâ1.17] ¼ÙÉè¸ßËÙ»º´æCache¹¤×÷ËÙ¶ÈΪÖ÷´æµÄ5±¶£¬ÇÒCache±»·ÃÎÊÃüÖеĸÅÂÊΪ90%£¬Ôò²ÉÓÃCacheºó£¬ÄÜʹÕû¸ö´æ´¢ÏµÍ³»ñµÃ¶à¸ßµÄ¼ÓËÙ±ÈSp£¿ [½â´ð] ÎÒÃÇÊ×ÏȶÔеĴ洢ϵͳµÄÐÔÄÜ×öÒÔϵļÙÉ裺ÔÚCache²»ÃüÖеÄÇé¿öÏ£¬¶ÔCacheµÄ·ÃÎʲ»»á¶îÍâËðʧʱ¼ä£¬¼´£ºÊ×ÏÈ£¬¾ö¶¨CacheÊÇ·ñÃüÖÐËùÓõÄʱ¼ä¿ÉÒÔºöÂÔ£»Æä´Î£¬ÔÚ´ÓÖ÷´æÏòCache´«ÊäµÄͬʱ£¬Êý¾ÝÒ²±»´«Êä¸øʹÓò¿¼þ£¨²»ÐèÒªÔÙ´ÓCacheÖжÁÈ¡£©¡£ÕâÑù£¬ÐµĴ洢ϵͳÖУ¬Æ½¾ù´æȡʱ¼ä·ÖΪÁ½¸ö²¿·Ö£º

Tnew_average?Tmiss?Rmiss?Thit?Rhit?Tmain?Rmiss?TCache?Rhit

ÆäÖУ¬R±íʾ¸÷ÖÖÇé¿öËùÕ¼µÄ±ÈÀý¡£ ¸ù¾Ý¼ÓËٱȵļÆË㹫ʽ,

Sp?

[Ï°Ìâ1.19]

Told_averageTnew_average?Tmain1??3.57Tmain?Rmiss?TCache?Rhit1?0.1?5?0.9

[½â´ð] CPI£½¡ÆCPIi¡Á[Ii/Ic]£½45000/10£«£¨32000¡Á2£©/10£«£¨15000¡Á2£©/105£«£¨8000¡Á2£©/105£½1.55

MIPS £½ (40 ¡Á 106)/(1.55 ¡Á 106) £½ 25.8MIPS Te £½ 105/(25.8 ¡Á 106) £½ 3.88ms

[Ï°Ìâ1.20] ij¹¤×÷Õ¾²ÉÓÃʱÖÓƵÂÊΪ15MHz¡¢´¦ÀíËÙÂÊΪ10MIPSµÄ´¦Àí»úÀ´Ö´ÐÐÒ»¸öÒÑÖª»ìºÏ³ÌÐò¡£¼Ù¶¨Ã¿´Î´æ´¢Æ÷´æȡΪ1ÖÜÆÚÑÓ³Ù¡¢ÊÔÎÊ£º£¨1£©´Ë¼ÆËã»úµÄÓÐЧCPIÊǶàÉÙ£¿ £¨2£©¼Ù¶¨½«´¦Àí»úµÄʱÖÓÌá¸ßµ½30MHz£¬µ«´æ´¢Æ÷×ÓϵͳËÙÂʲ»±ä¡£ÕâÑù£¬Ã¿´Î´æ´¢Æ÷´æÈ¡ÐèÒªÁ½¸öʱÖÓÖÜÆÚ¡£Èç¹û30%Ö¸ÁîÿÌõÖ»ÐèÒªÒ»´Î´æ´¢´æÈ¡£¬¶øÁíÍâ5%ÿÌõÐèÒªÁ½´Î´æ´¢´æÈ¡£¬»¹¼Ù¶¨ÒÑÖª»ìºÏ³ÌÐòµÄÖ¸ÁîÊý²»±ä£¬²¢ÓëÔ­¹¤×÷Õ¾¼æÈÝ£¬ÊÔÇó¸Ä½øºóµÄ´¦Àí»úÐÔÄÜ¡£ [½â´ð]£¨1£©ÓÉMIPS = ʱÖÓƵÂÊ/£¨CPI¡Á106£©£¬ ÔòÓУºCPIA =ʱÖÓƵÂÊ/£¨MIPS¡Á106£©= 1.5¡£ £¨2£©µ±Ê±ÖÓƵÂÊΪ15MHZʱ£¬¼ÙÉè²»½øÐд洢²Ù×÷Ö¸ÁîµÄCPIΪx£¬ÔòÒª½øÐÐÒ»´Î´æ´¢²Ù×÷Ö¸ÁîµÄCPIΪ1+ x£¬Òª½øÐжþ´Î´æ´¢²Ù×÷Ö¸ÁîµÄCPIΪ2+ x£¬Òò´ËÓУº 1.5 = x¡Á65% + £¨1+ x£©¡Á30% + £¨2+ x£©¡Á5% ½âµÃx = 1.1

µ±Ê±ÖÓƵÂÊΪ30MHZʱ£¬²»½øÐд洢²Ù×÷Ö¸ÁîµÄCPI²»±äΪ1.1£¬Òª½øÐÐÒ»´Î´æ´¢²Ù×÷Ö¸ÁîµÄCPIΪ2+ x = 3.1£¬Òª½øÐжþ´Î´æ´¢²Ù×÷Ö¸ÁîµÄCPIΪ4+ x = 5.1£¬Òò´Ëƽ¾ùCPIΪ£º CPIB = 1.1¡Á65% + 3.1¡Á30% + 5.1¡Á5% = 1.9 ËùÒÔ MIPSB = ʱÖÓƵÂÊ/£¨CPIB¡Á106£©=£¨30¡Á106£©/£¨1.9¡Á106£©= 15.8

[Ï°Ìâ2.13] Ò»¸ö´¦Àí»ú¹²ÓÐ10ÌõÖ¸Á¸÷Ö¸ÁîÔÚ³ÌÐòÖгöÏֵĸÅÂÊÈçϱí:Ö¸ÁîÐźŠ³öÏÖ¸ÅÂÊ Huffman±àíÀÂë 2/8À©Õ¹±àíÀÂë 3/7À©Õ¹±àíÀÂë 1 0.25 0.20 3 0.15 4 0.10 5 Ò»¸ö´¦Àí»ú¹²ÓÐ10ÌõÖ¸Á¸÷Ö¸ÁîÔÚ³ÌÐòÖгöÏֵĸÅÂÊÈçϱí:

Ö¸ÁîÐźŠ³öÏÖ¸ÅÂÊ Huffman±àíÀÂë 2/8À©Õ¹±àíÀÂë 3/7À©Õ¹±àíÀÂë 1 0.25 2 0.20 3 0.15 4 0.10 5 0.08 6 0.08 7 0.05 8 0.04 9 0.03 10 0.02

(1) ²ÉÓÃ×îÓÅHuffman±àÂë·¨£¨ÐÅÏ¢ìØ£©¼ÆËãÕâ10ÌõÖ¸ÁîµÄ²Ù×÷Âë×î¶Ìƽ¾ù³¤¶È¡£

5

5

(2) ²ÉÓÃHuffman±àÂë·¨±àдÕâ10ÌõÖ¸ÁîµÄ²Ù×÷Â룬²¢¼ÆËã²Ù×÷ÂëµÄƽ¾ù³¤¶È£¬¼ÆËãÓë×îÓÅHuffman±àÂë·¨£¨ÐÅÏ¢ìØ£©Ïà±ÈµÄ²Ù×÷ÂëÐÅÏ¢ÈßÓàÁ¿¡£½«µÃµ½µÄ²Ù×÷Âë±àÂëºÍ¼ÆËãµÄ½á¹ûÌîÈëÉÏÃæµÄ±íÖС£

(3) ²ÉÓÃ2/8À©Õ¹±àÂë·¨±àдÕâ10ÌõÖ¸ÁîµÄ²Ù×÷Â룬²¢¼ÆËã²Ù×÷ÂëµÄƽ¾ù³¤¶È£¬¼ÆËãÓë×îÓÅHuffman±àÂë·¨Ïà±ÈµÄ²Ù×÷ÂëÐÅÏ¢ÈßÓàÁ¿¡£°ÑµÃµ½µÄ²Ù×÷Âë±àÂëºÍ¼ÆËãµÄ½á¹ûÌîÈëÉÏÃæµÄ±íÖС£

(4) ²ÉÓÃ3/7À©Õ¹±àÂë·¨±àдÕâ10ÌõÖ¸ÁîµÄ²Ù×÷Â룬²¢¼ÆËã²Ù×÷ÂëµÄƽ¾ù³¤¶È£¬¼ÆËãÓë×îÓÅHuffman±àÂë·¨Ïà±ÈµÄ²Ù×÷ÂëÐÅÏ¢ÈßÓàÁ¿¡£°ÑµÃµ½µÄ²Ù×÷Âë±àÂëºÍ¼ÆËãµÄ½á¹ûÌîÈëÉÏÃæµÄ±íÖС£ [½â´ð]

[Ï°Ìâ2.14]

һ̨ģÐÍ»ú¹²ÓÐ7ÌõÖ¸Á¸÷Ö¸ÁîµÄʹÓÃƵ¶È·Ö±ðÊÇ35£¥¡¢25£¥¡¢20£¥¡¢10£¥¡¢5£¥¡¢3£¥¡¢ 2£¥£¬ÓÐ8¸öͨÓÃÊý¾Ý¼Ä´æÆ÷£¬2¸ö±äÖ·¼Ä´æÆ÷¡£

(1) ÒªÇó²Ù×÷ÂëµÄƽ¾ù³¤¶È×î¶Ì£¬ÇëÉè¼Æ²Ù×÷ÂëµÄ±àÂ룬²¢¼ÆËãËùÉè¼Æ²Ù×÷Âë µÄƽ¾ù³¤¶È¡£

(2) Éè¼Æ8λ×Ö³¤µÄ¼Ä´æÆ÷£­¼Ä´æÆ÷ÐÍÖ¸Áî3Ìõ£¬16λ×Ö³¤µÄ¼Ä´æÆ÷£­´æ´¢Æ÷ÐͱäÖ·Ñ°Ö··½Ê½Ö¸Áî4Ìõ£¬±äÖ··¶Î§²»Ð¡ÓÚÕý¡¢¸º127¡£ÇëÉè¼ÆÖ¸Áî¸ñʽ£¬²¢¸ø³ö¸÷×ֶεij¤¶ÈºÍ²Ù×÷ÂëµÄ±àÂë¡£ [½â´ð]

[Ï°Ìâ2.15]

ij´¦Àí»úµÄÖ¸Áî×Ö³¤Îª16룬ÓÐË«µØÖ·Ö¸Áî¡¢µ¥µØÖ·Ö¸ÁîºÍÁãµØÖ·Ö¸ÁîÈýÀ࣬²¢¼ÙÉèÿ¸öµØÖ·×ֶεij¤¶È¾ùΪ6λ¡£

(1) Èç¹ûË«µØÖ·Ö¸ÁîÓÐ15Ìõ£¬µ¥µØÖ·Ö¸ÁîºÍÁãµØÖ·Ö¸ÁîµÄÌõÊý»ù±¾Ïàͬ£¬Îʵ¥µØÖ·Ö¸ÁîºÍÁãµØÖ·Ö¸Áî¸÷ÓжàÉÙÌõ£¿²¢ÇÒΪÕâÈýÀàÖ¸Áî·ÖÅä²Ù×÷Âë¡£

(2) Èç¹ûÒªÇóÈýÀàÖ¸ÁîµÄ±ÈÀý´óÖÂΪ1£º9£º9£¬ÎÊË«µØÖ·Ö¸Áî¡¢µ¥µØÖ·Ö¸ÁîºÍÁãµØÖ·Ö¸Áî¸÷ÓжàÉÙÌõ£¿²¢ÇÒΪÕâÈýÀàÖ¸Áî·ÖÅä²Ù×÷Âë¡£ [½â´ð]

ÁªÏµ¿Í·þ£º779662525#qq.com(#Ì滻Ϊ@)