This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC = mpicc | |
CFLAGS = -std=gnu99 -O3 -Wall | |
# OMPI_MPICC = clang | |
all: matrix_mul | |
matrix_mul: matrix_mul.c matrix_mul.h | |
ifdef OMPI_MPICC | |
env OMPI_MPICC=$(OMPI_MPICC) $(CC) $(CFLAGS) -o matrix_mul matrix_mul.c | |
else |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <assert.h> | |
#include <cuda.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <stddef.h> | |
/* Example from "Introduction to CUDA C" from NVIDIA website: | |
https://developer.nvidia.com/cuda-education | |
Compile with: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC = mpicc | |
CFLAGS = -std=gnu99 -O3 -Wall | |
# OMPI_MPICC = clang | |
all: matrix_mul | |
matrix_mul: matrix_mul.c matrix_mul.h | |
ifdef OMPI_MPICC | |
env OMPI_MPICC=$(OMPI_MPICC) $(CC) $(CFLAGS) -o matrix_mul matrix_mul.c | |
else |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC = clang | |
CFLAGS = -std=gnu99 -O3 -Wall | |
all: matrix_gen | |
matrix_gen: matrix_gen.o tpl.o | |
$(CC) $(CFLAGS) matrix_gen.o tpl.o -o matrix_gen | |
matrix_gen.o: matrix_gen.c | |
$(CC) $(CFLAGS) -c matrix_gen.c |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
max_vector | |
max_vector.c |
NewerOlder