Skip to content

Commit

Permalink
fabtests/benchmarks: Add synapseai support
Browse files Browse the repository at this point in the history
Signed-off-by: Itai Masuari <[email protected]>
  • Loading branch information
imasuari authored and j-xiong committed Jul 11, 2024
1 parent f71ae74 commit f3138e3
Show file tree
Hide file tree
Showing 10 changed files with 501 additions and 3 deletions.
1 change: 1 addition & 0 deletions fabtests/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,7 @@ libfabtests_la_SOURCES = \
common/hmem_rocr.c \
common/hmem_ze.c \
common/hmem_neuron.c \
common/hmem_synapseai.c \
include/shared.h \
include/ft_list.h \
include/hmem.h \
Expand Down
2 changes: 1 addition & 1 deletion fabtests/Makefile.win
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ CFLAGS = $(CFLAGS) /O2 /MT
basedeps = common\hmem.c common\shared.c \
common\windows\getopt.c common\windows\osd.c \
common\hmem_cuda.c common\hmem_rocr.c common\hmem_ze.c \
common\hmem_neuron.c
common\hmem_neuron.c common\hmem_synapseai.c

includes = /Iinclude /Iinclude\windows /I..\include /FIft_osd.h \
/Iinclude\windows\getopt /Imultinode\include
Expand Down
12 changes: 12 additions & 0 deletions fabtests/common/hmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,18 @@ static struct ft_hmem_ops hmem_ops[] = {
.copy_from_hmem = ft_host_memcpy,
.get_dmabuf_fd = ft_hmem_no_get_dmabuf_fd,
},
[FI_HMEM_SYNAPSEAI] = {
.init = ft_synapseai_init,
.cleanup = ft_synapseai_cleanup,
.alloc = ft_synapseai_alloc,
.alloc_host = ft_synapseai_alloc_host,
.free = ft_synapseai_free,
.free_host = ft_synapseai_free_host,
.mem_set = ft_synapseai_memset,
.copy_to_hmem = ft_synapseai_copy_to_hmem,
.copy_from_hmem = ft_synapseai_copy_from_hmem,
.get_dmabuf_fd = ft_synapseai_get_dmabuf_fd,
},
[FI_HMEM_CUDA] = {
.init = ft_cuda_init,
.cleanup = ft_cuda_cleanup,
Expand Down
Loading

0 comments on commit f3138e3

Please sign in to comment.