3. The following is a working assembly language implementation of the “adddigit” function from calcc. Explain the relati
Posted: Sat May 14, 2022 7:55 pm
3. The following is a working assembly language implementation of the “adddigit” function from calcc. Explain the relationship between this implementation and the C code. 1 #define adddigit(c) asm( "lodsb \n" "movb $10, %%b/ \n" "mulb %%bl \n" "subb $48, %%al \n" "addb %%cl, %%al\n" "stosb \n" : : "S" (SP), "D" (SP), "c" (c) ) 4. In the stropy program, the instructions lodsb and stosb are used to load and store bytes of data as if they were string references. Show how you could modify the strcpy program to use just the mov operation rather than the lods and stos operations.