Address
:
[go:
up one dir
,
main page
]
Include Form
Remove Scripts
Session Cookies
Open navigation menu
Close suggestions
Search
Search
en
Change Language
Upload
Sign in
Sign in
Download free for days
0 ratings
0% found this document useful (0 votes)
15 views
9 pages
Unit 4
Important questions for run time environments and code optimization
Uploaded by
Prem Sai
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Download
Save
Save Unit-4 For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
0 ratings
0% found this document useful (0 votes)
15 views
9 pages
Unit 4
Important questions for run time environments and code optimization
Uploaded by
Prem Sai
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Carousel Previous
Carousel Next
Download
Save
Save Unit-4 For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
Download now
Download
You are on page 1
/ 9
Search
Fullscreen
=) the Size of the SS. SB) F AIAHALL AG, csé& DS A\SS ? ment oneal 1) Define Storoge Organizatfon. 1 fy From -the Perspective ofthe compiler coriter, the execuéi ro layge t program yuns $n tS aon Lefcal Address space | Ne 4 Was. a fo woh%th, each Prograro value Was @ location. “The “en J-ement aud eygarizatfon Of thin logical acldvess space ‘ Shaved bette! the compiler, operatirg Syptem ud org} -tt machine | =the os Maps the logtcal addvess Sinko ea | yess) which ave usually Spread throughout memory | => The von-time ye presentation of an object program | in the logical add vesspate consist Of cate aud Pa | sam aveas ap Sheon below | | code | | \ reap) “peal Subdisshin Moe uv -fime memory Snto Code qud data aveas. anevated target code fA fined ak Compile ime, So gf. compiler Can piace the exctutale\, lage coe ina aes delerrrined) aves, COAe, Usually $n the tow end of Niemory: => Semilayly , the Size of Some Progen data Objects, Such as global dongianté, aud dato enevated. by the | Compiler, Suth as ta-frzwation Re to Sapport ae taBa Cplledtion, May be Kamen at Compfle Hime and these ., Object can be possible placed fin augthey staticalis mm =ned avea called Slatfe- =) One yeason —fov Stastfeallg as possible % that the addves SH be Compiled Gnto ~the target lata =) "Tb Manknize The vtfization of Sp ty two auens', Slacks and tleap area OF the yemainder Of the address space: € % ‘the =>) These ArYeob ave iene the sige GU 4ousvds each other oqvam executes, these ArcaS geo as inceded. the ciack 12 osed 40) data shuctures €alled act?vation vecords that ge fa during yours Fouards bower acllvesses) ak dala oy allocatt $e these’ Objects @ ak yea Hime, the ace. tice Opposite
En practice, te staek -the heap doucand? faa | 2D! hak % activation yecord 7 write the various 4elds | of gett vation Record. {| Aid Aet®vatlon Lecord wn we ans = Activation Record tov) Frame %% a Contiguous block of alovage that Con4ains all «the Snformatfes xcquired -tor) ar a Single énecttfon of o Be 1 vecord consist of sevenfeldS Shown thy = An activate 1 d Figure. % “Tem porary voluck e— MI ann Ne oe i => this field holds LT (eed valle’ §: Ahad are Used in the evaluation of expressions: }Relorned value factual parameters) [control tinie TAecess tate | Machine. tos | Local Chia [Temporary val y ve ues | * Local: Datai- aa] | a tid holds att the data that if locol to 2 proceed “ve. i ) # Machire Slatus\— | AAAS AAR this fietd saves the .S Procedure occ uyE. r | x Access link (— | we Jatos Of the mathire when a call to} ina) tield. | link 4p data Cnon—tocal) hold ty | ae a this ig an opti a this -field holde & cihey activation recerde. x Control - link {- We
Tt basically work OP aM ot Cele eho an shorter G4 fost 2 ty outpue “the.| peephole B optimntation: ‘which o part of Code. without @ cho machine — de pendent ° bject?ves cephole optimization i— Objectives: of Peeps Ccmncanes “the objective Of peephole Optfmigation |® ag Follows: | te 716) improve per dtoymance. a- TO edule memor “footprint 3. To vetie de Size ec phdle timiaati ini {= phat Ope aan a. | |: leash ond. Sis. Aaa Is eliminated in thip technique. Tnftab 2 Bean Ose Opthniged | let at oL) We geo I] Stee YB no tro. | H wel | Welve yemoved +Wo vedundaut i Variables Say whope | Redundant lead and Store elimination ved on dency eS j i i were just beirg Copied -fom one cendther.vo, _ ae a 2 de Conskank fea c _ EBERT aa nay a me Cos pe piredmame crapecaton, fo ve oy done at yuntme ave yeplaced with simplified Code > | Avoid com putation- | anSttal cade ra | TMs, | imized code? uae 2s Cc. Stren ibe | a Reduction The | Operators -thod tensome higher exe} =cution time are replaced y the operators Con soning i optimiacd Cale execution time. Tastlal code: A gufitel code i Bert >) 7) Sea | Ogun are te fh rien ek elect) 4 ame | ves sion’ tha Alge bral |b. Null Sequenes ( simplify Agee ous Usetess Operator axe deleted Ot 2ak0% at =arxly Ga hie \ 6 ar +a-04 ! ‘a ‘ al operat ons one veploced bya €- combine Operating: Seve Single equivalent operation: (0 Qeadeode Elimination velers 4a. portion’ ob 4 cam hee \ ane! never affect The Pe vamls ObSewable behavioow- €liminatt dead a ee fm prove Whe efficiency and pemiorts oF mg Compt « program Bi reducing pnnecesary Computer Gus When le_— — yee roe 8 ai ae suse arnt oa ei eos * pat). 5 Ne aan Pilea “ ie 4 pl | | ao Mo cat S| shotte, Mano Hilocatia) J) aS or ma 1 oie ab Compile and ip allocate ie memory wa Hine: Jae ime. d wl i ou can not be chougel weuie| =p reevsnry Cos HC Cte |p Memon Co” cle exec, ial enceutig a fate He = Used in an array b> ar ip fast ard saves venning time Hes rt alloctes memory -hom F -+the gyacke E> Allocated Nicwor, ones EHorn giart +0 crcl abe ProTo™ Te is less efticient than the One allocation Strategy. => used inthe liaed fst gt tp a bik: $ low. wor to | > > allocateé -m -the heap | Sy ewnny (Ge lee allocate He aud cou . at a eluted oF any stime. > Tein more efficient: tod she siatie allocation Shaty | Teo pi that Vs Sate Membr Con not he Chavged. d => D0 Oyramic Mew AULocatton Guy re Si bad ealloe(), malloc ¢), ave the Imevaony 1 allocaicad mem) t SRC Can be che ae Tmplementation of this +ype “tt afallocation 's simple. HYP) > amplementation of is | bs an s Be FC ec ‘yPe OF allocation \ |? Be wets Complicated. | \ | loat 5 ps -- L. float j 5 pe malloc Cage oF Cnt) \ the I differen@ beludecn Stale ANd Oynamic Mewor ion) Allocet i lon ered SRe s fad ip allocated at vn!Y ' eer *, 3 ization mento in the pects eats, of of compiler wrtier i Ore diogam? ‘lt F Hay INheo “the a yoqram e-xecete —then legend adthess Uspace sin aihich the valle ef cotaiire location. =the cal addiess gpace ip shored aworg ihe Compiler , Qpesating AoWget machire -foy marapemine aud Oy 3 The. Operotig Sptem I iysed) “fo trop “the loaical adkhess toto physio address which 36 ay spieadl -lhnoughouk the memo Sobdivisten of Rin--time J OOS OSIM OT apace eS HS Memory Wcabiong for, code ave Odlermrinel I — ok coinpi ler, Here 4. |<— Jocation of state Date cur also be determined ot Compiler me: Je— Dota objects alloetcated a Rin time CAcBuation Recorela) bE rund in Tk p Oton ron hoy a er ond other ac Aillcoltdl Dal Objects at] ST Ron tirte (for cxauple, Malloc Ara inc) => Ron-Hme e comes ‘nfo blocks’, whee qi byte 1S aed , 1S psed' Show -the Smallest unit of Addlessable memory. “ysing the foor tf @ machine 0rd can -form, Sd > object OF ae @ Stored 40 consecutive bores gud a the first bye acklyes } 2 oe Con be Soddivide “to hold ‘the clifferent -pnemip ef an erecuting Program? h Genevated CxeCulable Code d. Static data objects & Dynamic closa— Dbject - heap YY. Automatfe Weta
+p rane Tt Used by both the aualipin aud Spotty, ve 1 for fe Ulsieg povpos=s: the vore ofall enittes id a Strtsctemed fom] | ff a variable has been cleclaved Used “fo determine, the Scop: of @ heme. §5 sed ty implement Jype checking BY Phy te 49 implement type checking By verthying albGorney I npressioa in the Sourte cede ave Emeatate covect. 5 1 RS \ Sambo] table Can efthey be Jineay oY @ hash’ table, format, 41. maintains He cin fox 1a Mord i? © 2 variable Store the ‘cformabion aout the "i declanation - | ek then 7 stove 4 ‘ | cM rE Stow acta airy format: Ze OR ae [F satay Re | State 5] we > “the clause ath Me \ nn OMeute Contains the, ents nine TS velated 49 the 4 | Procedure ; ie Insert (2 —> insert ©) Operation %§ m f ie frequen ty ey By phase when “the tokens aie 5) ited Secl In the Aualysis | in the _Jable cn iFied and rarres are Corey: > The bast format Of look upc i-function se o4 Follows. ythe insert (5 6, ration 4 i Syrecl Jatble Nee ine te Used to insert tpg Siete Teformation jn ihe \ ao ; "re Oceurita in he Source Cale Be Te SOUT Cte, the autitade oul Symol 18 the informakt alsectated why, had Len a ae v f, ae AYPe ancl cpniae Scope ahout
Enitialization Of the S.rnbol. ~ Cheeving whether the vame i declared multiol -Hme. ol. The information Containe the slate lookup Symbol, cod > The format 6 varloos a tp the ern Longe Mae
You might also like
Oodp Unit 1
PDF
No ratings yet
Oodp Unit 1
38 pages
OOPS
PDF
No ratings yet
OOPS
53 pages
UNIT 5 _067f90418e66cb1fc1c3be24a1979c61
PDF
No ratings yet
UNIT 5 _067f90418e66cb1fc1c3be24a1979c61
18 pages
2nd unit PPL notes
PDF
No ratings yet
2nd unit PPL notes
13 pages
PCPF ?
PDF
No ratings yet
PCPF ?
35 pages
CD-Unit-V_Material
PDF
No ratings yet
CD-Unit-V_Material
23 pages
Unit 1
PDF
No ratings yet
Unit 1
49 pages
Spos Model Answer 2018
PDF
No ratings yet
Spos Model Answer 2018
14 pages
DSA Unit 1
PDF
No ratings yet
DSA Unit 1
10 pages
LP Assignment
PDF
No ratings yet
LP Assignment
10 pages
Unit-7-Runtime Environment
PDF
No ratings yet
Unit-7-Runtime Environment
38 pages
SS
PDF
No ratings yet
SS
40 pages
CD - Unit V
PDF
No ratings yet
CD - Unit V
30 pages
DocScanner 23-Jun-2023 9-16 pm
PDF
No ratings yet
DocScanner 23-Jun-2023 9-16 pm
19 pages
PPS Unit-4 Notes-2
PDF
No ratings yet
PPS Unit-4 Notes-2
14 pages
C Language Assignment
PDF
No ratings yet
C Language Assignment
16 pages
PPL Unit I-13-24
PDF
No ratings yet
PPL Unit I-13-24
12 pages
OOP Assignment 5 and 6
PDF
No ratings yet
OOP Assignment 5 and 6
12 pages
Storage_Class_Keyword_�_1720373206
PDF
No ratings yet
Storage_Class_Keyword_�_1720373206
11 pages
Java Unit-1
PDF
No ratings yet
Java Unit-1
12 pages
Doc
PDF
No ratings yet
Doc
29 pages
Adobe Scan Nov 13, 2024
PDF
No ratings yet
Adobe Scan Nov 13, 2024
35 pages
Unit IV
PDF
No ratings yet
Unit IV
57 pages
Assignment
PDF
No ratings yet
Assignment
33 pages
Begin: Ciro
PDF
No ratings yet
Begin: Ciro
11 pages
Java 6
PDF
No ratings yet
Java 6
32 pages
Assembly 3
PDF
No ratings yet
Assembly 3
19 pages
DS Part1 Merged Compressed
PDF
No ratings yet
DS Part1 Merged Compressed
212 pages
C++ Notes FULL - Compressed
PDF
No ratings yet
C++ Notes FULL - Compressed
176 pages
System Software Notes
PDF
No ratings yet
System Software Notes
16 pages
C notes (2) ~by Isha Parmar
PDF
No ratings yet
C notes (2) ~by Isha Parmar
40 pages
SPOS Assignment
PDF
No ratings yet
SPOS Assignment
16 pages
spcc (2)
PDF
No ratings yet
spcc (2)
36 pages
Compiler Bipin
PDF
No ratings yet
Compiler Bipin
94 pages
BCS402-model-paper-set-1solution
PDF
No ratings yet
BCS402-model-paper-set-1solution
41 pages
Data Structre and Algorithm
PDF
No ratings yet
Data Structre and Algorithm
109 pages
DS UNIT 1 HAND,CLASS WRITTED NOTES
PDF
No ratings yet
DS UNIT 1 HAND,CLASS WRITTED NOTES
43 pages
DSA Oral Questions-1
PDF
No ratings yet
DSA Oral Questions-1
13 pages
OOPS Notes ? - Removed
PDF
No ratings yet
OOPS Notes ? - Removed
20 pages
Microprocessor8085 Except Interfacing
PDF
No ratings yet
Microprocessor8085 Except Interfacing
25 pages
8tohc Void Main (Shingi Aas) : Corvso Le
PDF
No ratings yet
8tohc Void Main (Shingi Aas) : Corvso Le
14 pages
Compiler Design
PDF
No ratings yet
Compiler Design
27 pages
Adobe Scan 19 Oct 2024
PDF
No ratings yet
Adobe Scan 19 Oct 2024
20 pages
Adobe Scan 04-Feb-2024
PDF
No ratings yet
Adobe Scan 04-Feb-2024
20 pages
MPMC Lab Notes
PDF
No ratings yet
MPMC Lab Notes
35 pages
Microprocessor and Microcontroller Notes
PDF
100% (1)
Microprocessor and Microcontroller Notes
52 pages
Bhavya 28th January 2023 Notes
PDF
No ratings yet
Bhavya 28th January 2023 Notes
13 pages
DocScanner 03-Aug-2024 2-00 pm
PDF
No ratings yet
DocScanner 03-Aug-2024 2-00 pm
9 pages
DocScanner Mar 11, 2025 2-02 PM
PDF
No ratings yet
DocScanner Mar 11, 2025 2-02 PM
11 pages
UNIT-1_PSTC
PDF
No ratings yet
UNIT-1_PSTC
25 pages
OOSD
PDF
No ratings yet
OOSD
20 pages
C&Matlab Primer
PDF
No ratings yet
C&Matlab Primer
412 pages
DS Module 1 Solutions
PDF
No ratings yet
DS Module 1 Solutions
59 pages
C Programming Notes Part 1
PDF
No ratings yet
C Programming Notes Part 1
24 pages
20cse74 Ajeet Yadav
PDF
No ratings yet
20cse74 Ajeet Yadav
35 pages
CA Assignment
PDF
No ratings yet
CA Assignment
52 pages
all time favourites 1
PDF
No ratings yet
all time favourites 1
3 pages
C Programming
PDF
No ratings yet
C Programming
42 pages