danielealbano / cachegrand

cachegrand - a modern data ingestion, processing and serving platform built for today's hardware
BSD 3-Clause "New" or "Revised" License
975 stars 34 forks source link

Disable FFMA and switch to use xalloc (mimalloc) #290

Closed danielealbano closed 1 year ago

danielealbano commented 1 year ago

This PR disables FFMA and switch the code to use only xalloc (mimalloc) in preparation to implement an algorithm to defrag the memory.

Implementing the memory defragmentation for both the memory allocator would be extremely time consuming and although FFMA performs better than mimalloc in certain cases it's not a general memory allocator and cachegrand can't rely only on it.

Down the line it will be re-enabled and a memory defrag algorithm will be implemented for it as well.

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 63.36% and project coverage change: -0.06 :warning:

Comparison is base (7628a8e) 81.98% compared to head (58544f1) 81.92%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #290 +/- ## ========================================== - Coverage 81.98% 81.92% -0.06% ========================================== Files 162 161 -1 Lines 10980 10944 -36 ========================================== - Hits 9001 8965 -36 Misses 1979 1979 ``` | Flag | Coverage Δ | | |---|---|---| | unittests | `81.92% <63.36%> (-0.06%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#carryforward-flags-in-the-pull-request-comment) to find out more. | [Impacted Files](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano) | Coverage Δ | | |---|---|---| | [src/config.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL2NvbmZpZy5j) | `77.90% <ø> (-0.15%)` | :arrow_down: | | [...rc/data\_structures/hashtable/mcmp/hashtable\_data.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL2RhdGFfc3RydWN0dXJlcy9oYXNodGFibGUvbWNtcC9oYXNodGFibGVfZGF0YS5j) | `81.82% <ø> (ø)` | | | [...a\_structures/hashtable/mcmp/hashtable\_op\_get\_key.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL2RhdGFfc3RydWN0dXJlcy9oYXNodGFibGUvbWNtcC9oYXNodGFibGVfb3BfZ2V0X2tleS5j) | `82.86% <ø> (ø)` | | | [...tures/hashtable/mcmp/hashtable\_op\_get\_random\_key.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL2RhdGFfc3RydWN0dXJlcy9oYXNodGFibGUvbWNtcC9oYXNodGFibGVfb3BfZ2V0X3JhbmRvbV9rZXkuYw==) | `100.00% <ø> (ø)` | | | [...data\_structures/hashtable/mcmp/hashtable\_op\_iter.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL2RhdGFfc3RydWN0dXJlcy9oYXNodGFibGUvbWNtcC9oYXNodGFibGVfb3BfaXRlci5j) | `100.00% <ø> (ø)` | | | [...rc/data\_structures/hashtable/spsc/hashtable\_spsc.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL2RhdGFfc3RydWN0dXJlcy9oYXNodGFibGUvc3BzYy9oYXNodGFibGVfc3BzYy5j) | `94.51% <0.00%> (ø)` | | | [...module/redis/command/module\_redis\_command\_append.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL21vZHVsZS9yZWRpcy9jb21tYW5kL21vZHVsZV9yZWRpc19jb21tYW5kX2FwcGVuZC5j) | `77.01% <0.00%> (ø)` | | | [...c/module/redis/command/module\_redis\_command\_copy.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL21vZHVsZS9yZWRpcy9jb21tYW5kL21vZHVsZV9yZWRpc19jb21tYW5kX2NvcHkuYw==) | `75.26% <0.00%> (ø)` | | | [.../module/redis/command/module\_redis\_command\_hello.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL21vZHVsZS9yZWRpcy9jb21tYW5kL21vZHVsZV9yZWRpc19jb21tYW5kX2hlbGxvLmM=) | `69.86% <0.00%> (ø)` | | | [...c/module/redis/command/module\_redis\_command\_incr.c](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano#diff-c3JjL21vZHVsZS9yZWRpcy9jb21tYW5kL21vZHVsZV9yZWRpc19jb21tYW5kX2luY3IuYw==) | `100.00% <ø> (ø)` | | | ... and [31 more](https://codecov.io/gh/danielealbano/cachegrand/pull/290?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano) | | ... and [4 files with indirect coverage changes](https://codecov.io/gh/danielealbano/cachegrand/pull/290/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano) Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Daniele+Salvatore+Albano)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.