# Linux Kernel Module Cheat
The perfect emulation setup to study and develop the <<linux-kernel>> v5.9.2, kernel modules, <<qemu-buildroot-setup,QEMU>>, <<gem5-buildroot-setup,gem5>> and x86_64, ARMv7 and ARMv8 <<userland-assembly,userland>> and <<baremetal-setup,baremetal>> assembly, <<c,ANSI C>>, <<cpp,C++>> and <<posix,POSIX>>. <<gdb>> and <<kgdb>> just work. Powered by <<about-the-qemu-buildroot-setup,Buildroot>> and <<about-the-baremetal-setup,crosstool-NG>>. Highly automated. Thoroughly documented. Automated <<test-this-repo,tests>>.

### 29.4. x86 binary arithmetic instructions

Intel 64 and IA-32 Architectures Software Developer’s Manuals Volume 1 5.1.2 "Binary Arithmetic Instructions":

- userland/arch/x86_64/add.S: ADD

  - userland/arch/x86_64/inc.S: INC

  - userland/arch/x86_64/adc.S: ADC

- userland/arch/x86_64/sub.S: SUB

  - userland/arch/x86_64/dec.S: DEC

  - userland/arch/x86_64/sbb.S: SBB

- userland/arch/x86_64/mul.S: MUL

  - userland/arch/x86_64/neg.S: NEG

  - userland/arch/x86_64/imul.S: IMUL

- userland/arch/x86_64/div.S: DIV

  - userland/arch/x86_64/div_overflow.S: DIV overflow

  - userland/arch/x86_64/div_zero.S: DIV zero

  - userland/arch/x86_64/idiv.S: IDIV

- userland/arch/x86_64/cmp.S: CMP