Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdint.h>
- #include <stddef.h>
- #include "system.h"
- int32_t kmain(void) {
- clear_screen();
- install_gdt();
- install_idt();
- puts("ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789\nNEWLINE\n");
- // TEST CASE 1: works (exception 0)
- // __asm__("xor %eax, %eax");
- // __asm__("div %eax, %eax");
- // TEST CASE 2: works (exception 3)
- // __asm__("int $3");
- // TEST CASE 3: doesn't work?? (should be exception 0, but it is exception 6 which is Invalid Opcode)
- putc('A' / 0);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment