diff --git a/build/iso/boot/grub/stage2_eltorito b/build/iso/boot/grub/stage2_eltorito index 0fbaee7..9e1617c 100644 Binary files a/build/iso/boot/grub/stage2_eltorito and b/build/iso/boot/grub/stage2_eltorito differ diff --git a/kernel/arch/x86/boot/boot.s b/kernel/arch/x86/boot/boot.s index a43ce89..34931d3 100644 --- a/kernel/arch/x86/boot/boot.s +++ b/kernel/arch/x86/boot/boot.s @@ -59,8 +59,19 @@ _start: mov esp, stack+STACK_SIZE ; pass multiboot information - push eax push ebx + push eax + + ; enable SSE + mov ecx, cr0 + btr ecx, 2 ; clear CR0.EM bit + bts ecx, 1 ; set CR0.MP bit + mov cr0, ecx + + mov ecx, cr4 + bts ecx, 9 ; set CR4.OSFXSR bit + bts ecx, 10 ; set CR4.OSXMMEXCPT bit + mov cr4, ecx ; call kmain call kmain diff --git a/kernel/core/util.d b/kernel/core/util.d index 27b1faa..28d3f44 100644 --- a/kernel/core/util.d +++ b/kernel/core/util.d @@ -189,7 +189,7 @@ template isPointerType(T) template isPointerType(T : T*) { - const bool isPointerType = true; + const bool isPointerType = true; } /** @@ -363,7 +363,7 @@ char[] itoa(char[] buf, char base, long d) if(base == 'd' && d < 0) { negative = true; - ud = -d; + ud = 0 - d; } else if(base == 'x') divisor = 16;