aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorGravatar Moon Flower <moon@coffin.ir> 2025-03-01 13:56:44 +0330
committerGravatar Moon Flower <moon@coffin.ir> 2025-03-01 13:56:44 +0330
commit1bfd885ad36af68bb5348ee92560553f9829ef2f (patch)
treeaebb2b06d7b40b09b23f873bffae33a50206f39c /Makefile
parentAdded a (rather useless) profiler (and also linked list speed optimizations) (diff)
Speed optimizations. If you can help with the memory allocator's efficiency, please lmk!
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index d079677..01e6e0a 100644
--- a/Makefile
+++ b/Makefile
@@ -12,6 +12,11 @@ c:
test:
./out.bin
+profile:
+ clang main.c -o out.bin.profile $(FLAGS) -O3
+ perf record ./out.bin.profile
+ perf report > ./out.profile.txt
+
# useless. it don't work.
# profile:
# clang -D__MOONSHINE_PROFILER main.c -o out.bin.profile $(FLAGS) $(SIZE_FLAGS) -fprofile-generate