Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是
MOV MUL_AXB[EBX * 4], EAX
应该实际更改有效的 MUL_AXB 地址?
我已将 MUL_AXB 声明为
int* MUL_AXB;
在 using 语句之后的全局范围内,我已经为它分配了一个值
MUL_AXB = (int*) memset(malloc(size), 0, size);
对此问题的任何见解都将受到高度赞赏。
你正在做的事情将在mul_axb指针后面的某个地方写入内存,导致坏事发生。
mul_axb
要实际写入分配的数组,您需要先将指针加载到寄存器中。假设这是 32 位代码:
mov edx, [mul_axb] mov [edx + ebx*4], eax