Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Reverse engineer the values of the constants, R, S, and T given the assembly code struct 1node char *str; II points to 16 character string
Reverse engineer the values of the constants, R, S, and T given the assembly code
struct 1node char *str; II points to 16 character string struct 1node *next; Consider the following source code, where R, S, and T are constants declared with #denne. The struct inode is as defined from problem 1. You will need to determine the values for R, S, andT struct 1node A[R][S] [T]; int store ele(int h, int i, int j, struct lnode dest) A[h][i][j] - dest return sizeof (A); In compiling this program, GCC generates the following assembly code (with -02) store ele: movs1q movs1q movs1q %edi, %esi, %edx, %rdi %rsi %rdx leaq leaq addq leaq salq movq movq movl ret (%rdi,%rax,4), (Arsi,Arsi,2), %rdi, %rax (%rdx,%rax,8), $4,%rax %rcx, A(%rax) %r8, A+8(Arax) $139776, %eax Nrdi %rax Arax struct 1node char *str; II points to 16 character string struct 1node *next; Consider the following source code, where R, S, and T are constants declared with #denne. The struct inode is as defined from problem 1. You will need to determine the values for R, S, andT struct 1node A[R][S] [T]; int store ele(int h, int i, int j, struct lnode dest) A[h][i][j] - dest return sizeof (A); In compiling this program, GCC generates the following assembly code (with -02) store ele: movs1q movs1q movs1q %edi, %esi, %edx, %rdi %rsi %rdx leaq leaq addq leaq salq movq movq movl ret (%rdi,%rax,4), (Arsi,Arsi,2), %rdi, %rax (%rdx,%rax,8), $4,%rax %rcx, A(%rax) %r8, A+8(Arax) $139776, %eax Nrdi %rax AraxStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started