Skip to content

Commit

Permalink
Some changes related to config (#158)
Browse files Browse the repository at this point in the history
  • Loading branch information
pimnik98 authored Aug 29, 2024
2 parents 1eb4e95 + 3494146 commit 73ebd91
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
13 changes: 8 additions & 5 deletions common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ ASM_SRC:=$(ASM_SRC:%.s=$(BUILD_PREFIX)/%.s)

ASM=$(ASM_SRC:%.s=$(OBJ_DIRECTORY)/%.o)

ELK=\
kernel/src/lib/elk/elk.c \
kernel/src/lib/elk/elk_engine.c \
kernel/src/lib/elk/elk_libs.c \
kernel/src/lib/elk/jse_func.c \

SOURCES=\
kernel/src/sys/cpuinfo.c \
kernel/src/sys/cpu_isr.c \
Expand Down Expand Up @@ -62,10 +68,7 @@ SOURCES=\
kernel/src/sys/scheduler.c \
kernel/src/lib/php/explode.c \
kernel/src/lib/php/pathinfo.c \
kernel/src/lib/elk/elk.c \
kernel/src/lib/elk/elk_engine.c \
kernel/src/lib/elk/elk_libs.c \
kernel/src/lib/elk/jse_func.c \
$(ELK) \
kernel/src/drv/psf.c \
kernel/src/sys/unwind.c \
kernel/src/fs/NatSuki.c \
Expand Down Expand Up @@ -195,7 +198,7 @@ KERNEL_NEED = $(ASM) $(OBJS)

COMMON_FLAGS = -O$(OPTIMIZATION_LEVEL) -nostdlib -fno-stack-protector -fno-builtin -I$(BUILD_PREFIX)kernel/include/ -ffreestanding \
-Wall -Wno-div-by-zero -Wno-address-of-packed-member -Wno-implicit-function-declaration \
-mno-red-zone -MMD -MP
-mno-red-zone -MMD -MP -g

# Флаги компилятора языка C
CFLAGS=$(DEBUG) $(ADDCFLAGS) $(COMMON_FLAGS)
Expand Down
2 changes: 1 addition & 1 deletion kernel/src/drv/fpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ void fpu_fldcw(const uint16_t cw) {

/// Инициализация FPU
void fpu_init() {
size_t cr4 = 0;
uint32_t cr4 = 0;

__asm__ volatile ("mov %%cr4, %0":"=r"(cr4));
cr4 |= 0x200;
Expand Down
6 changes: 3 additions & 3 deletions kernel/src/lib/string.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#include "common.h"
#include "lib/string.h"
#include "lib/math.h"
#include <emmintrin.h> // SSE functions and types
//#include <emmintrin.h> // SSE functions and types

bool isalnum(char c){
return (c >= '0' && c <= '9') ||
Expand Down Expand Up @@ -137,7 +137,7 @@ size_t struntil(const char* str, const char find) {
* @param src - Указатель на массив источник копируемых данных.
* @param size - Количество байт для копирования
*/
void sse_memcpy(void* restrict dest, const void* restrict src, size_t size) {
/*void sse_memcpy(void* restrict dest, const void* restrict src, size_t size) {
__m128i* d = (__m128i*)dest;
const __m128i* s = (const __m128i*)src;
Expand All @@ -161,7 +161,7 @@ void sse_memcpy(void* restrict dest, const void* restrict src, size_t size) {
}
_mm_sfence();
}
}*/

/**
* @brief Копирование непересекающихся массивов
Expand Down

0 comments on commit 73ebd91

Please sign in to comment.