Skip to content

Latest commit

 

History

History
58 lines (52 loc) · 3.51 KB

README.md

File metadata and controls

58 lines (52 loc) · 3.51 KB

Usage

Setup

Target architecture: i686

My setup, overall, is:

  • 64 bit CPU
  • 32 bit OS (compiled using i686 cross compiler)
  • 32 bit applications will be able to be run

Building and running

I've been running this on a virtualized x86_64 processor.

$ make clean
$ make
$ qemu-system-x86_64 build/unnamed_os.bin 
# or for rhel:
$ qemu-kvm -cpu host -drive file=./build/unnamed_os.bin,format=raw -nographic
# View source 
$ objdump -D -b binary -mi386 -Maddr32,data32 build/disk.img

Notes:

  • x86: (2.1.1) Refers to a processors in the 8086 family. (80186 80286 80386 80486...). Usually, it means compatability with the 80386 32 bit instruction set because 16 bit only is so old
  • i686: (2.1.6) Intel686. P6 Family Microarchitecture on the Pentium Pro.
  • One of the 6th generation of x86 processor.
  • i386: (2.1.3) Intel386. AKA 80386. First 32 bit
  • x86_64 The 64-bit instruction set (sometimes called amd64) brother of x86
    • backwards compatible to x86 (ie x86 instructions can run
    • on x86_64 processors)
  • Here's a nice summary of intel cpu architecture (chapter 2.1).
  • Here's another nice explanation of i related architectures
  • 32 bit and 64 bit:
    • A 32-bit OS will run on a 32-bit or 64-bit processor without any problem.
    • A 32-bit application will run on a 32-bit or 64-bit OS without any problem.
    • But a 64-bit application will only run on a 64-bit OS and a 64-bit OS will only run on a 64-bit processor

References I've been using