source stringlengths 3 92 | c stringlengths 26 2.25M |
|---|---|
par_relax_more.c | /******************************************************************************
* Copyright 1998-2019 Lawrence Livermore National Security, LLC and other
* HYPRE Project Developers. See the top-level COPYRIGHT file for details.
*
* SPDX-License-Identifier: (Apache-2.0 OR MIT)
**************************************... |
image_pyramid.h | /*
*
* This file is part of the open-source SeetaFace engine, which includes three
*modules:
* SeetaFace Detection, SeetaFace Alignment, and SeetaFace Identification.
*
* This file is part of the SeetaFace Detection module, containing codes
*implementing the
* face detection method described in the following pa... |
common.h | #ifndef LIGHTGBM_UTILS_COMMON_FUN_H_
#define LIGHTGBM_UTILS_COMMON_FUN_H_
#include <LightGBM/utils/log.h>
#include <LightGBM/utils/openmp_wrapper.h>
#include <cstdio>
#include <string>
#include <vector>
#include <sstream>
#include <cstdint>
#include <algorithm>
#include <cmath>
#include <functional>
#include <memory>... |
initialize.c | //-------------------------------------------------------------------------//
// //
// This benchmark is an OpenMP C version of the NPB SP code. This OpenMP //
// C version is developed by the Center for Manycore Programming at Seoul //
// Nati... |
relax.c | /*BHEADER**********************************************************************
* Copyright (c) 2006 The Regents of the University of California.
* Produced at the Lawrence Livermore National Laboratory.
* Written by the HYPRE team. UCRL-CODE-222953.
* All rights reserved.
*
* This file is part of HYPRE (see ht... |
benchmark_bandwidth.c | /**************************************************************************************************
* *
* This file is part of BLASFEO. *
* ... |
GB_subassign_18.c | //------------------------------------------------------------------------------
// GB_subassign_18: C(I,J)<!M,repl> = A ; using S
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http://suitesparse.com ... |
GB_unop__identity_int8_int8.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX-Li... |
mxEvaluateVertAverage.c | //
// main.c
// matEvaluateVertAverage
//
// Created by li12242 on 17/11/1.
// Copyright (c) 2017年 li12242. All rights reserved.
//
#include "mex.h"
#define INF 10.0e9
#ifdef _OPENMP
#include <omp.h>
#endif
#define max(a, b) ((a > b) ? a : b)
#define min(a, b) ((a < b) ? a : b)
void mexFunction(int nlhs, mxArra... |
alignments_slow.c | /*-----------------------------------------------------------------------------
alignments_slow \
author: jose lezama/rafael grompone von gioi \
version: 5.1 (2014.08.12) ... |
FrameBuffer.h | // --------------------------------------------------------------------------
// Binary Brain -- binary neural net framework
//
// Copyright (C) 2018 by Ryuji Fuchikami
// https://github.com/ryuz
// ryuji.fuch... |
gemv_c_dia_conj.c | #include "alphasparse/kernel.h"
#include "alphasparse/opt.h"
#include "alphasparse/util.h"
#include <string.h>
#ifdef _OPENMP
#include <omp.h>
#endif
static alphasparse_status_t ONAME_omp(const ALPHA_Number alpha,
const ALPHA_SPMAT_DIA* A,
const ALPHA_Number* x,
const ALPH... |
prior_box_op.h | /* Copyright (c) 2016 PaddlePaddle Authors. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or... |
md5test.c | /***
* How to compile:
* GCC 4.6.3: mpicc md5test.c -o md5test -fopenmp -lcrypto -lssl -std=c99
* GCC 6.3.0: mpicc md5test.c -o md5test -fopenmp -lcrypto -lssl
*
* 5 nodos no máximo
* - 1 mestre
* - O mestre só envia a mensagem para os escravos dizendo encontre essa linha e me digam se encontrar ou não.
... |
fig4.43-schedule-clause.c | /*
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
Copyright 2009 Sun Microsystems, Inc. All rights reserved.
The contents of this file are subject to the terms of the BSD License("BSD")(the "License").
You can obtain a copy of the License at: http://www.opensparc.net/pubs/t1/licenses/BSD+_Lice... |
GB_unaryop__one_uint8_uint8.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http... |
GB_binop__div_uint16.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
GB_unop__identity_int8_bool.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX-Li... |
close_manual.c | // RUN: %libomptarget-compile-run-and-check-generic
#include <omp.h>
#include <stdio.h>
// ---------------------------------------------------------------------------
// Various definitions copied from OpenMP RTL
extern void __tgt_register_requires(int64_t);
extern void __tgt_target_data_begin(int64_t device_id, in... |
2Dpfold.c | /*
minimum free energy
RNA secondary structure with
basepair distance d_1 to reference structure 1 and distance d_2 to reference structure 2
*/
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <ctype.h>
#include <string.h>
#include <float.h> /* #defines FLT_MAX ... */
#include "u... |
hello_omp.c | #include <stdio.h>
#include <stdlib.h>
#include <omp.h>
void Hello_thread(void);
int main(int argc, char *argv[])
{
int thread_count=4;
if(argc < 2)
printf("usage: hello_omp <number threads>\n");
else
{
sscanf(argv[1], "%d", &thread_count);
printf("Will use %d threads for test\n", th... |
mrcore.c |
/***************************************************************************
*
Copyright 2013 CertiVox IOM Ltd. *
*
This file i... |
pr90954.c | /* PR sanitizer/90954 */
/* { dg-do compile } */
/* { dg-options "-fopenmp -fsanitize=undefined" } */
float v;
int i;
void
foo (float x, float y)
{
#pragma omp atomic
v += x / y;
}
void
bar (int x, int y)
{
#pragma omp atomic
i += x / y;
}
void
baz (int x, int y)
{
#pragma omp atomic
i *= (x << y);
}
|
primitives.h | #pragma once
#include <vector>
#include <cstdint>
#include <omp.h>
#ifndef CACHE_LINE_ENTRY
#define CACHE_LINE_ENTRY (16)
#endif
using namespace std;
/*
* Both Primitives Are Inclusive
* histogram is for cache-aware thread-local histogram purpose
* output should be different from the variables captured in functi... |
softmax-inl.h | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... |
ordered-4.c | extern
#ifdef __cplusplus
"C"
#endif
void abort (void);
void
foo (int i, char *j)
{
#pragma omp atomic
j[i]++;
#pragma omp ordered threads
{
int t;
#pragma omp atomic read
t = j[i];
if (t != 3)
abort ();
if (i > 1)
{
#pragma omp atomic read
t = j[i - 1];
if (t == 2)
abort ... |
Sema.h | //===--- Sema.h - Semantic Analysis & AST Building --------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
fox_floats_timer_caching_omp_fileIO_benchmark.c | /* fox_floats_timer_caching_omp_fileIO_benchmark.c -- uses Fox's algorithm to multiply two square matrices
*
* Implementation of parallel matrix multiplication:
* LaTeX: $C_{i,j} = \sum_{k} A_{i,k}B_{k,j}$
*
* Input:
* Input Matrix file name: A.dat, B.dat
*
* Output:
* Output Matrix file name: C.dat... |
example4.c | // calculation example of far-field intensity distributions.
// radar chart is output for a distant scattering field.
#include "emf_mie_ms.h"
int main(int argc,char *argv[])
{
MSPD msp;
FILE *fp1,*fp2;
double complex e[3],h[3];
double th,ph,phd,dthd,dthr,dphr,dphd,ra,r[3],*ie,*ih,mf,iemax,ihmax;
int i,j,sn... |
displacement_lagrangemultiplier_mixed_contact_criteria.h | // KRATOS ___| | | |
// \___ \ __| __| | | __| __| | | __| _` | |
// | | | | | ( | | | | ( | |
// _____/ \__|_| \__,_|\___|\__|\__,_|_| \__,_|_| MECHANICS
//
// License: BSD License
// ... |
ep.c | /*--------------------------------------------------------------------
NAS Parallel Benchmarks 3.0 structured OpenMP C versions - EP
This benchmark is an OpenMP C version of the NPB EP code.
The OpenMP C 2.3 versions are derived by RWCP from the serial Fortran versions
in "NPB 2.3-serial" developed by NA... |
Parser.h | //===--- Parser.h - C Language Parser ---------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
symv_c_csr_u_lo_conj.c | #include "alphasparse/kernel.h"
#include "alphasparse/util.h"
#include "alphasparse/opt.h"
#ifdef _OPENMP
#include <omp.h>
#endif
#include <memory.h>
#include<stdlib.h>
static alphasparse_status_t
symv_s_csr_u_lo_conj_omp(const ALPHA_Number alpha,
c... |
Parallel Programming in C - Merge Sort.c | #include <stdio.h>
#include <stdlib.h>
#include "omp.h"
/*
OpenMP implementation example
Details of implementation/tutorial can be found here: http://madhugnadig.com/articles/parallel-processing/2017/02/25/parallel-computing-in-c-using-openMP.html
*/
void mergesort(int a[],int i,int j);
void merge(int a[],int i1,int... |
sharing-1.c | /* { dg-do compile } */
/* { dg-require-effective-target tls } */
#include <stdlib.h>
int thrglobalvar;
#pragma omp threadprivate (thrglobalvar)
int globalvar;
const int constvar = 8;
int
foo (int x)
{
return x;
}
int
bar (int *x)
{
return *x;
}
int
main (void)
{
static int thrlocvar;
#pragma omp threadpriva... |
pr59591-2.c | /* PR tree-optimization/59591 */
/* { dg-additional-options "-fopenmp-simd" } */
#ifndef CHECK_H
#include "tree-vect.h"
#endif
extern void abort (void);
long long int p[256], r[256], t[256];
int q[256];
__attribute__((noinline, noclone)) void
foo (void)
{
int i;
#pragma omp simd safelen(64)
for (i = 0; i < 25... |
GB_binop__lxor_uint8.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
hopscotch_hash.c | /******************************************************************************
* Copyright (c) 1998 Lawrence Livermore National Security, LLC and other
* HYPRE Project Developers. See the top-level COPYRIGHT file for details.
*
* SPDX-License-Identifier: (Apache-2.0 OR MIT)
***************************************... |
health.c | /**********************************************************************************************/
/* This program is part of the Barcelona OpenMP Tasks Suite */
/* Copyright (C) 2009 Barcelona Supercomputing Center - Centro Nacional de Supercomputacion */
/* Copyright (C) 2009 Univer... |
convolution_1x1_int8.h | // Tencent is pleased to support the open source community by making ncnn available.
//
// Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
//
// Licensed under the BSD 3-Clause License (the "License"); you may not use this file except
// in compliance with the License. You may obtain a ... |
nco_rth_utl.c | /* $Header$ */
/* Purpose: Arithmetic controls and utilities */
/* Copyright (C) 1995--present Charlie Zender
This file is part of NCO, the netCDF Operators. NCO is free software.
You may redistribute and/or modify NCO under the terms of the
3-Clause BSD License with exceptions described in the LICENSE file... |
blake2sp.c | /*
BLAKE2 reference source code package - optimized C implementations
Copyright 2012, Samuel Neves <sneves@dei.uc.pt>. You may use this under the
terms of the CC0, the OpenSSL Licence, or the Apache Public License 2.0, at
your option. The terms of these licenses can be found at:
- CC0 1.0 Universal :... |
par_csr_matop.c | /*BHEADER**********************************************************************
* Copyright (c) 2008, Lawrence Livermore National Security, LLC.
* Produced at the Lawrence Livermore National Laboratory.
* This file is part of HYPRE. See file COPYRIGHT for details.
*
* HYPRE is free software; you can redistribute... |
GB_binop__bget_int32.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
omp_threadprivate.c | // RUN: %libomp-compile-and-run
/*
* Threadprivate is tested in 2 ways:
* 1. The global variable declared as threadprivate should have
* local copy for each thread. Otherwise race condition and
* wrong result.
* 2. If the value of local copy is retained for the two adjacent
* parallel regions
*/
#include "omp... |
GB_binop__le_int16.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
convolution_3x3_pack8to4_fp16s.h | // Tencent is pleased to support the open source community by making ncnn available.
//
// Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved.
//
// Licensed under the BSD 3-Clause License (the "License"); you may not use this file except
// in compliance with the License. You may obtain a ... |
atomic-5.c | /* PR middle-end/36106 */
/* { dg-additional-options "-mcx16" { target { { i?86-*-* x86_64-*-* } && lp64 } } } */
#ifdef __x86_64__
# include "cpuid.h"
#endif
extern void abort (void);
int __attribute__((noinline))
do_test (void)
{
long double d = .0L;
int i;
#pragma omp parallel for shared (d)
for (i = 0;... |
ThreadSafeVec.h | //
// smarties
// Copyright (c) 2018 CSE-Lab, ETH Zurich, Switzerland. All rights reserved.
// Distributed under the terms of the MIT license.
//
// Created by Guido Novati (novatig@ethz.ch).
//
#ifndef smarties_ThreadSafeVec_h
#define smarties_ThreadSafeVec_h
#include "../Settings/Definitions.h"
#include <casser... |
Example_target_task_reduction.2b.c | /*
* @@name: target_task_reduction.2b.c
* @@type: C
* @@compilable: yes
* @@linkable: yes
* @@expect: success
* @@version: omp_5.0
*/
#include <stdio.h>
#pragma omp declare target to(device_compute)
extern void device_compute(int *);
extern void host_compute(int *);
int main()
{
int sum = 0;
#pragma omp parallel... |
GB_bitmap_assign_M_row_template.c | //------------------------------------------------------------------------------
// GB_bitmap_assign_M_row_template: traverse M for GB_ROW_ASSIGN
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-Lic... |
3d25pt.lbpar.c | #include <omp.h>
#include <math.h>
#define ceild(n,d) ceil(((double)(n))/((double)(d)))
#define floord(n,d) floor(((double)(n))/((double)(d)))
#define max(x,y) ((x) > (y)? (x) : (y))
#define min(x,y) ((x) < (y)? (x) : (y))
/*
* Order-2, 3D 25 point stencil
* Adapted from PLUTO and Pochoir test bench
*
* Tar... |
GB_binop__lt_fp32.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
GB_unop__abs_int32_int32.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://... |
omp_smithW-v6.2-target-inlined.c | /*********************************************************************************
* Smith–Waterman algorithm
* Purpose: Local alignment of nucleotide or protein sequences
* Authors: Daniel Holanda, Hanoch Griner, Taynara Pinheiro
*
* Compilation: gcc omp_smithW.c -o omp_smithW -fopenmp -DDEBUG // debuggin... |
threshold.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
fourier.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
main.c | #include "libabl.h"
#include "time.h"
#include "stdio.h"
#include "CL/cl.h"
#include "omp.h"
typedef struct {
float2 pos;
double desiredSpeed;
float2 velocity;
bool isFinished;
int leader;
int id;
float2 target;
int envId;
}Point;
static const type_info Point_info[] = {
{ TYPE_FLO... |
selectionSimd.c | /*
Versão otimizada do algoritmo base do Selection Sort utilizando
a diretiva do OpenMP #pragma omp for simd
Compilação: gcc -o selectionSimd -fopenmp selectionSimd.c
*/
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <omp.h>
void selectionSort (int vet[],int tam);
void... |
blackberry_ES10_fmt_plug.c | /* Cracker for BlackBerry Enterprise Server 10 hashes.
*
* Thanks to Nicolas RUFF for providing the algorithm details and sample
* hashes!
*
* USE BDSMgmt;
* SELECT LoginPassword FROM EASUsers;
*
* This software is Copyright (c) 2013 Dhiru Kholia <dhiru at openwall.com>
* and it is hereby released to the gener... |
ex_particle_OPENMP_seq.cuda.c | #include <stdio.h>
__device__ inline int hclib_get_current_worker() {
return blockIdx.x * blockDim.x + threadIdx.x;
}
template<class functor_type>
__global__ void wrapper_kernel(unsigned iter_offset, unsigned niters, functor_type functor) {
const int tid = blockIdx.x * blockDim.x + threadIdx.x;
if (tid < n... |
GB_unop__identity_fc32_fp64.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://... |
Parser.h | //===--- Parser.h - C Language Parser ---------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
GB_binop__bclr_uint32.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX... |
completion.c |
/******************************************************************************
* INCLUDES
*****************************************************************************/
#include "completion.h"
#include "../io.h"
#include "../util.h"
#include <math.h>
#include <omp.h>
/******************************************... |
morn_image.c | /*
Copyright (C) 2019-2020 JingWeiZhangHuai <jingweizhanghuai@163.com>
Licensed under the Apache License, Version 2.0; you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in wri... |
cpi_omp.c | #include <stdio.h>
#include <sys/time.h>
#include <omp.h>
static long nSteps = 1000000000;
static double PI25DT = 3.141592653589793238462643;
double getTime(void) {
struct timeval tv;
struct timezone tz;
gettimeofday(&tv, &tz);
return tv.tv_sec + 1e-6*(double)tv.tv_usec;
}
int main(int argc, char** a... |
papi.c | #include "XSbench_header.h"
void counter_init( int *eventset, int *num_papi_events )
{
char error_str[PAPI_MAX_STR_LEN];
// int events[] = {PAPI_TOT_INS,PAPI_BR_INS,PAPI_SR_INS};
int events[] = {PAPI_TOT_CYC,PAPI_L3_TCM};
int stat;
int thread = omp_get_thread_num();
if( thread == 0 )
printf("Initializing PAP... |
papi.c | #include "rsbench.h"
void counter_init( int *eventset, int *num_papi_events )
{
char error_str[PAPI_MAX_STR_LEN];
int stat;
/////////////////////////////////////////////////////////////////////////
// PAPI EVENT SELECTION
///////////////////////////////////////////////////////////////////... |
hello.c | #include <omp.h>
#include <stdio.h>
#include <stdlib.h>
#define DEF_N 10
int main(int argc, char **argv) {
int def_nthreads, nthreads, tid;
if (argc > 1) {
def_nthreads = atoi(argv[1]);
} else {
def_nthreads = DEF_N;
}
omp_set_num_threads(def_nthreads);
#pragma omp parallel p... |
DRACC_OMP_008_Counter_no_lock_simd_Intra_yes.c | /*
Concurrent access on a counter with no lock with simd. Atomicity Violation. Data Race in line 28. Intra Region.
*/
#include <stdio.h>
#include <stdbool.h>
#define N 100000
#define C 64
int countervar[C];
int init(){
for(int i=0; i<C; i++){
countervar[i]=0;
}
return 0;
}
int count(){
#pr... |
openmp_2k.c | // C program for implementation of selection sort
#include <stdio.h>
#include <time.h>
#include "omp.h"
void swap(int *xp, int *yp)
{
int temp = *xp;
*xp = *yp;
*yp = temp;
}
void selectionSort(int arr[], int n)
{
int i=0, j=0, min_i=0;
// One by one move boundary of unsorted subarray
for (i = 0; i < n-1; ++i)
... |
paint.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
additionally.c | #include "additionally.h"
#include "gpu.h"
#ifdef OPENCL
#include "ocl.h"
#endif
#ifdef CUDNN
#pragma comment(lib, "cudnn.lib")
#endif
#ifdef _OPENMP
#include <omp.h>
#endif
#define STB_IMAGE_IMPLEMENTATION
#include "stb_image.h"
#define STB_IMAGE_WRITE_IMPLEMENTATION
#include "stb_image_write.h"
// global GPU ind... |
ext_kernels.h | #pragma once
#include <stdbool.h>
void initialise_device_memory(void);
#pragma omp declare target
void zero_edge_flux_buffers(void);
#pragma omp end declare target
void zero_flux_moments_buffer(void);
void zero_flux_in_out(void);
void zero_scalar_flux(void);
void calc_inner_source(void);
void calc_outer_source(void... |
GB_unaryop__abs_fp64_uint16.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http... |
quick_gemm.h | // Quick gemm if alpha==0.0
if ( alpha==zero ) {
if ( beta==zero )
if ( orderC=='C' ) {
#pragma omp parallel
for (int jc=0; jc<n; jc++ )
for (int ic=0; ic<m; ic++ )
Ccol(ic,jc) = 0.0;
}
else {
#pragma omp parallel
for (int jc=0; jc<n; jc++ ... |
expected_output.c | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <time.h>
#include <sys/time.h>
//---------------------------------------------------------------------
// program SP
//---------------------------------------------------------------------
//----------
// Class S:
//----------
//----------
// Class W:
... |
shared.c | // An OpenMP clause keyword: num_threads
// used as a regular variable in a clause's variable list
// Extracted from NPB 3.2 benchmarks
//
// 6/10/2010
#ifdef _OPENMP
#include <omp.h>
#endif
void c_print_results( )
{
int num_threads, max_threads, omp =0, dynamic =0, none =0; // none is another OpenMP keyword used... |
heat-3d.c | /**
* This version is stamped on May 10, 2016
*
* Contact:
* Louis-Noel Pouchet <pouchet.ohio-state.edu>
* Tomofumi Yuki <tomofumi.yuki.fr>
*
* Web address: http://polybench.sourceforge.net
*/
/* heat-3d.c: this file is part of PolyBench/C */
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#incl... |
2.norace4.c | // RUN: clang %loadLLOV %s -o /dev/null 2>&1 | FileCheck %s
#include <omp.h>
#define N 20
int main() {
int A[N][N];
for (int i = 1; i < N; i++)
#pragma omp simd
for (int j = 1; j < N; j++)
A[i - 1][j] += A[i][j] + i + j;
}
// CHECK: Region is Data Race Free.
// END
|
CCGSubSurf_opensubdiv.c | /*
* ***** BEGIN GPL LICENSE BLOCK *****
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is d... |
correlation_teams.c | /**
* correlation.c This file was adapted from PolyBench/GPU 1.0 test suite
* to run on GPU with OpenMP 4.0 pragmas and OpenCL driver.
*
* Web address: http://www.cse.ohio-state.edu/~pouchet/software/polybench/GPU
*
* Contacts: Marcio M Pereira <mpereira@ic.unicamp.br>
* Rafael Cardoso F Sousa <rafael.... |
mixed_tentusscher_myo_epi_2004_S2_7.c | // Scenario 2 - Mixed-Model TenTusscher 2004 (Myocardium + Epicardium)
// (AP + max:dvdt)
#include <stdio.h>
#include "mixed_tentusscher_myo_epi_2004_S2_7.h"
GET_CELL_MODEL_DATA(init_cell_model_data)
{
if(get_initial_v)
cell_model->initial_v = INITIAL_V;
if(get_neq)
cell_model->number_of_ode_... |
bt_hash_type_192.c | /*
* This software is Copyright (c) 2015 Sayantan Datta <std2048 at gmail dot com>
* and it is hereby released to the general public under the following terms:
* Redistribution and use in source and binary forms, with or without modification, are permitted.
*/
#ifdef HAVE_OPENCL
#include <stdlib.h>
#include <stdi... |
CG.h | /**
* This file contains (modified) code from the Eigen library.
* Eigen License:
*
* Copyright (C) 2008 Gael Guennebaud <gael.guennebaud@inria.fr>
* Copyright (C) 2007-2011 Benoit Jacob <jacob.benoit.1@gmail.com>
*
* This Source Code Form is subject to the terms of the Mozilla
* Public License v. 2.0. If a co... |
Sema.h | //===--- Sema.h - Semantic Analysis & AST Building --------------*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===-------------------------------------------------------... |
threshold.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_subref_slice.c | //------------------------------------------------------------------------------
// GB_subref_slice: construct coarse/fine tasks for C = A(I,J)
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX-Licens... |
selu_ref.c | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* License); you ma... |
GB_binop__bshift_uint32.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http:... |
cones.c | #include "cones.h"
#ifdef LAPACK_LIB_FOUND
#include <cblas.h>
#include <lapacke.h>
#endif
void projectsdc(double * X, int n, Work * w);
/* in place projection (with branches) */
void projCone(double *x, Cone * k, Work * w, int iter)
{
int i;
int count;
/* project onto positive orthant */
for(i = k->f... |
pr79428-5.c | /* PR c/79428 */
/* { dg-options "-fopenmp" } */
#pragma omp ordered /* { dg-error "expected declaration specifiers before end of line" } */
|
GB_unop__minv_uint32_uint32.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://... |
ast-dump-openmp-distribute-simd.c | // RUN: %clang_cc1 -triple x86_64-unknown-unknown -fopenmp -ast-dump %s | FileCheck --match-full-lines -implicit-check-not=openmp_structured_block %s
void test_one(int x) {
#pragma omp distribute simd
for (int i = 0; i < x; i++)
;
}
void test_two(int x, int y) {
#pragma omp distribute simd
for (int i = 0; i <... |
95a93_so12.c | #define _POSIX_C_SOURCE 200809L
#include "stdlib.h"
#include "math.h"
#include "sys/time.h"
#include "xmmintrin.h"
#include "pmmintrin.h"
#include "omp.h"
#include <stdio.h>
#define min(a, b) (((a) < (b)) ? (a) : (b))
#define max(a, b) (((a) > (b)) ? (a) : (b))
struct dataobj
{
void *restrict data;
int *size;... |
3d7pt_var.lbpar.c | #include <omp.h>
#include <math.h>
#define ceild(n,d) ceil(((double)(n))/((double)(d)))
#define floord(n,d) floor(((double)(n))/((double)(d)))
#define max(x,y) ((x) > (y)? (x) : (y))
#define min(x,y) ((x) < (y)? (x) : (y))
/*
* Order-1, 3D 7 point stencil with variable coefficients
* Adapted from PLUTO and Po... |
GB_unop__identity_uint64_bool.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://... |
kmp_atomic_cas.c | // RUN: %libomp-compile-and-run
#include <stdio.h>
#include <stdbool.h>
#include <omp.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef void* ident_t;
extern bool
__kmpc_atomic_bool_1_cas(ident_t *loc, int gtid, char *x, char e, char d);
extern bool
__kmpc_atomic_bool_2_cas(ident_t *loc, int gtid, short *x, short e,... |
sparse_matrix_multiplication_utility.h | // | / |
// ' / __| _` | __| _ \ __|
// . \ | ( | | ( |\__ `
// _|\_\_| \__,_|\__|\___/ ____/
// Multi-Physics
//
// License: BSD License
// Kratos default license: kratos/license.txt
//
// Main authors: Vicente Mataix Ferrandiz
//
#if !defined(KRATOS_... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.