Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

cmpg $8, %rax ja .L2 jmp *.L4 ( , %rax , 8) Based on the assembly code l in the blanks below in its corresponding

image text in transcribed

cmpg $8, %rax ja .L2 jmp *.L4 ( , %rax , 8) Based on the assembly code l in the blanks below in its corresponding C source code You may only use the source-level C variables x, m, result, and value: don't use register names! void prob3 (long value, long x, long m) .L4: long result switch (m) .quad .quad .quad .quad .quad "quad .quad .quad . L2 .L3 5 2 L2 ,L6 .L5 . L2 . L7 case result breaki case case result break case quad *value = L3 : case leaq (trsi, %rsi, 2), trax leag (trax , trax), %rsi addq (trdi), %rsi jmp .L8 result break default: result = .L5 * value = result; leaq (trsi, %rsi, movqtrdx, trax salg $6, trax addqtrax, trsi jmp .L8 2), trax .L6: leaq 80(%rsi), trax movg trax, (rdi) .L7: movg (8rdi),rax jmp .L8 addg $11, %rsi .L2: "L8 : %rsi, (%rdi) movq ret cmpg $8, %rax ja .L2 jmp *.L4 ( , %rax , 8) Based on the assembly code l in the blanks below in its corresponding C source code You may only use the source-level C variables x, m, result, and value: don't use register names! void prob3 (long value, long x, long m) .L4: long result switch (m) .quad .quad .quad .quad .quad "quad .quad .quad . L2 .L3 5 2 L2 ,L6 .L5 . L2 . L7 case result breaki case case result break case quad *value = L3 : case leaq (trsi, %rsi, 2), trax leag (trax , trax), %rsi addq (trdi), %rsi jmp .L8 result break default: result = .L5 * value = result; leaq (trsi, %rsi, movqtrdx, trax salg $6, trax addqtrax, trsi jmp .L8 2), trax .L6: leaq 80(%rsi), trax movg trax, (rdi) .L7: movg (8rdi),rax jmp .L8 addg $11, %rsi .L2: "L8 : %rsi, (%rdi) movq ret

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_step_2

Step: 3

blur-text-image_step3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

What are the objectives of performance appraisal ?

Answered: 1 week ago

Question

State the uses of job description.

Answered: 1 week ago