t o w a a r r d d s s b b e e t t t e r c c o o d d e e g
play

T o w a a r r d d s s B B e e t t t e r C C o - PowerPoint PPT Presentation

D mi t r y B o r i s e n k o v , L e o n i d K h o l o d o v , D mi t r y S h t u k e n b e r g T o w a a r r d d s s B B e e t t t e r C C o o d d e e G G e e n n e e


  1. D mi t r y B o r i s e n k o v , L e o n i d K h o l o d o v , D mi t r y S h t u k e n b e r g T o w a a r r d d s s B B e e t t t e r C C o o d d e e G G e e n n e e r r a a t t o o r r D e e s s i g g n n a a n n d d U U n n i f f i i c c a a t t i i o o n f o r S S t a c c k k M M a a c c h h i i n n e e

  2. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e Wh y d d o w w e e c c a a r r e e ? ? • N e w s t a c k ma c h i n e s k e e p o n a p p e a r i n g g i v e n t h e d e v e l o p me n t o f b l o c k c h a i n t e c h n o l o g y ( E V M , T V M ) . • T h e r e a s o n f o r c h o o s i n g s t a c k ma c h i n e s i n b l o c k c h a i n i s b e t t e r c o d e d e n s i t y . I t a l l o w s r e d u c i n g c o s t s i n c u r r e d f r o m c o n t r a c t s t o r a g e i n t h e b l o c k c h a i n . • B e t t e r v e r i f i c a t i o n i s a n o t h e r r e a s o n t o u s e s t a c k ma c h i n e s .

  3. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e C o o m mp a a r r i i n n g g e x i s s t t i i n g s s t t a a c c k ma a c c h h i i n e e s s P P r r o p e r t y y \ \ T V M E V M We b A A s s s e mb l y x 8 7 . . n n e t A A r r c h i i t t e c t u r e S t a c k o o p p e r a t i i o o n n s M a t e r i a l i z i n g C o p y , p u s h , P u s h P u s h , p o p , i n d e x P u s h , d u p , p o p c o n s t a n t s , c o p y , p o p , x c h g x c h g , p u s h , p o p , a n d d e r i v a t i v e s N o n - - s s t a a c c k e e n t i i t t i i e e s N o n G P - r e g i s t e r s M e mo r y , L o c a l s , g l o b a l s M e mo r y L o c a l s , g l o b a l s , S t o r a g e f u n c t i o n a r g u me n t s M e mo o r r y M o d e l l i n g C o n v e n t i o n a l C o n v e n t i o n a l C o n v e n t i o n a l C o n v e n t i o n a l C C o o n t r o l l f f l l o w C o n t i n u a t i o n s B r a n c h e s B r a n c h e s + L o o p s N / A B r a n c h e s I I n n s t r u c t i i o o n n s s e t C I S C w / o d i r e c t R I S C R I S C C I S C R I S C ma n i p u l a t i o n s w i t h r e g i s t e r s

  4. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e S a a m mp l l e e T T V V M M c c o o d d e i n t f u n c ( i n t a , i n t b ) { . g l o b l f u n c r e t u r n ( a + b ) * ( a - b ) ; . t y p e f u n c , @f u n c t i o n } f u n c : ; %b b . 0 : P U S H 2 s 1 , s 0 S U B X C H Gs 0 , s 2 A D D M U L . L f u n c _ e n d 0 :

  5. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e S t a c c k k ma ma c c h h i n e e a a s s a a n n a a b b s s t t r r a a c c t t i i o o n n • E a c h N - t h o p e r a t i o n c o n s u me s N - t o p mo s t v a l u e s f r o m t h e s t a c k a n d r e c o r d s t h e r e s u l t o n t o p o f t h e s t a c k . • S t a c k r e a r r a n g e me n t s r e l a t e d t o c o mp u t a t i o n h a v e c o s t s . T h e T V M a r c h i t e c t u r e u s e s c o p i e s a n d e x c h a n g e s , o t h e r a r c h i t e c t u r e s - p u s h e s . • T h e c o d e g e n e r a t o r g o a l i s t o mi n i mi z e s t a c k ma n i p u l a t i o n c o s t s .

  6. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e C u u r r r e e n n t t a a p p p r o a a c c h h t t o o t t r r a a n n s l a t t i i o o n n G l o b a l I S E L ? S e l e c t i o n D A G a = x 1 + x 2 d = x 3 + x 4 b = x 5 + x 6 M I R f o r a r e g i s t e r c = a + b ma c h i n e c = a + b ; [ b , d , a ] a = x 1 + x 2 b = x 5 + x 6 P H I e l i mi n a t i o n x c h g s 1 , s 2 ;[ b , d , a ] c = a + b c = a + b ; [ b , a , d ] d = x 3 + x 4 S t a c k i f i c a t i o n S t a c k M o d e l l i n g ( We b A s s e mb l y ) ( T V M ) M I R f o r a s t a c k V M

  7. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e Wh h a a t t c c a a n n b e e i i mp r o v e e d d ? • I n a d d i t i o n t o S c h e d u l e D A G F a s t & S c h e d u l e D A G V L I W, S e l e c t i o n D A G c o n f i g u r a t i o n c a n b e mo d i f i e d t o p r o v i d e b e t t e r s c h e d u l e s f o r s t a c k ma c h i n e s . • S t a c k mo d e l i n g g e n e r a l i z a t i o n c a n b e c o n s i d e r e d . • P o s t - R A s c h e d u l i n g ( c o n t r o l - f l o w s t a c k i f i c a t i o n ) a n d s t a c k - a w a r e r e a s s o c i a t i o n a r e a l s o o p t i o n s t o c o n s i d e r .

  8. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e P P r r e e - - R R A s s c c h e e d d u u l l e e r r o o p p t t i i mi z a t t i i o n s • L R N o r R L N t r a v e r s a l s o f D A G f o r b e t t e r s t a c k ma c h i n e s c h e d u l i n g . • P a s s e s t h a t i n t r o d u c e c o p i e s o f v i r t u a l r e g i s t e r s w i t h mu l t i p l e u s e s .

  9. T o w a r d s B B e t t e r C C o o d d e G G e n n e e r a t o o r r D D e s i g n n a a n d U U n i f i c a t i o o n n f f o o r r S t a c k M M a c h i n e S t a c c k k mo mo d e e l l l l i i n n g g p p o t t e e n n t t i i a a l l • Wh i l e n o w w e ma y s e e m t h e o n l y u s e r s o f s t a c k ma c h i n e mo d e l l i n g , i t c a n b e g e n e r a l i z e d t o s u p p o r t v a r i o u s s t a c k ma n i p u l a t i o n t y p e s . • F o r b o t h r e g i s t e r a n d s t a c k M I R , s t a c k mo d e l l i n g c a n p r o v i d e a h e l p f u l a n a l y s i s p a s s t o r e q u e s t s t a c k c o n f i g u r a t i o n f o r a s p e c i f i c i n s t r u c t i o n .

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend