add dst, num
| 563 | |
| 564 | // add dst, num |
| 565 | int x86ADD(unsigned char *stream, x86Reg dst, int num) |
| 566 | { |
| 567 | if((char)(num) == num) |
| 568 | { |
| 569 | stream[0] = 0x83; |
| 570 | stream[1] = encodeRegister(dst, 0); |
| 571 | stream[2] = (char)(num); |
| 572 | return 3; |
| 573 | } |
| 574 | // else |
| 575 | stream[0] = 0x81; |
| 576 | stream[1] = encodeRegister(dst, 0); |
| 577 | *(int*)(stream+2) = num; |
| 578 | return 6; |
| 579 | } |
| 580 | // add dst, src |
| 581 | int x86ADD(unsigned char *stream, x86Reg dst, x86Reg src) |
| 582 | { |
no test coverage detected