Closed xiangzhai closed 5 days ago
Hi,
Sorry for introduced the issue!
Passed testcase for LOCK ADC:
LOCK ADC
#include <stdio.h> #include <stdint.h> #include <assert.h> void test_lock_adc32(uint32_t n, uint32_t m, uint32_t expected_eax, uint32_t expected_edx) { uint32_t eax; uint32_t edx; __asm__ __volatile__ ( "movl %[n], %%edx\n" "movl %[m], %%eax\n" "addl %[m], %%eax\n" "lock; adcl %[n], %%edx\n" "movl %%eax, %[eax]\n" "movl %%edx, %[edx]\n" : [eax] "=r" (eax), [edx] "=r" (edx) : [n] "r" (n), [m] "r" (m) : "eax", "edx", "memory"); printf("eax=0x%x\n", eax); printf("edx=0x%x\n", edx); assert(eax == expected_eax && edx == expected_edx); } int main(int argc, char* argv[]) { test_lock_adc32(0x0, 0xFFFFFFFF, 0xFFFFFFFE, 0x1); return 0; }
Please review my patch.
Thanks, Leslie Zhai
Just merge this fix into the other PR.
Hi,
Sorry for introduced the issue!
Passed testcase for
LOCK ADC
:Please review my patch.
Thanks, Leslie Zhai