Suppose variable r of type struct rec ∗ is in register \%rdi. Also assume sizeof(int) =4 and there is no padding in the

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899604
Joined: Mon Aug 02, 2021 8:13 am

Suppose variable r of type struct rec ∗ is in register \%rdi. Also assume sizeof(int) =4 and there is no padding in the

Post by answerhappygod »

Suppose Variable R Of Type Struct Rec Is In Register Rdi Also Assume Sizeof Int 4 And There Is No Padding In The 1
Suppose Variable R Of Type Struct Rec Is In Register Rdi Also Assume Sizeof Int 4 And There Is No Padding In The 1 (56.09 KiB) Viewed 28 times
Suppose variable r of type struct rec ∗ is in register \%rdi. Also assume sizeof(int) =4 and there is no padding in the structure. Which one of the following sequences of assembly instructions copies element r−>i to element r−>j ? a. leaq (\%rdi), \%eax ; movl \%eax, 4 (\%rdi) b. movl \%rdi, \%eax ; movl \%eax, 4(% rdi) c. leaq 4 (\%rdi), \%eax ; movl \%eax, (\%rdi) d. movl 4(\%rdi), \%eax ; movl \%eax, (\%rdi) e. movl (\%rdi), \%eax ; movl \%eax, 4 (\%rdi) f. movl (\%rdi), \%eax ; movl \%eax, 8(% rdi)
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply