source stringlengths 3 92 | c stringlengths 26 2.25M |
|---|---|
hecmw_partition.c | /*****************************************************************************
* Copyright (c) 2019 FrontISTR Commons
* This software is released under the MIT License, see LICENSE.txt
*****************************************************************************/
#define INAGAKI_PARTITIONER
#include <stdio.h>
#inc... |
nbody_mkl.c |
#include <stdlib.h>
#include <stdio.h>
#include <mkl.h>
#include <mkl_extensions.h>
#include <string.h>
#include <vec.h>
#include "nbody.h"
#include "nbody_mkl.h"
/** Computes Sum(G * pm / r ** 2 * (dx / r)).
*
* Diagonal elements are not counted in the sum.
*
*/
void compute_force(MKL_INT n,
double *dx, do... |
morphology.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_binop__bxnor_int16.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
dotProduct_critical.c | /*
OpenMP example program which computes the dot product of two arrays a and b
(that is sum(a[i]*b[i]) ) using explicit synchronization with a critical region.
Compile with gcc -O3 -fopenmp omp_critical.c -o omp_critical
*/
// Online source: http://users.abo.fi/mats/PP2012/examples/OpenMP/omp_critical.c
// per... |
reduction_minus_1.c | // PASS: *
// RUN: ${CATO_ROOT}/src/scripts/cexecute_pass.py %s -o %t
// RUN: diff <(mpirun -np 4 %t) %s.reference_output
#include <stdio.h>
#include <stdlib.h>
#include <omp.h>
int main()
{
int result = 0;
#pragma omp parallel reduction(-:result)
{
result -= omp_get_thread_num();
}
print... |
3d7pt.c | /*
* Order-1, 3D 7 point stencil
* Adapted from PLUTO and Pochoir test bench
*
* Tareq Malas
*/
#include <stdio.h>
#include <stdlib.h>
#include <sys/time.h>
#ifdef LIKWID_PERFMON
#include <likwid.h>
#endif
#include "print_utils.h"
#define TESTS 2
#define MAX(a,b) ((a) > (b) ? a : b)
#define MIN(a,b) ((a) < (b) ... |
BatchNormalization.c | #ifndef TH_GENERIC_FILE
#define TH_GENERIC_FILE "generic/BatchNormalization.c"
#else
void THNN_(BatchNormalization_updateOutput)(
THNNState *state, THTensor *input, THTensor *output,
THTensor *weight, THTensor *bias,
THTensor *running_mean, THTensor *running_var,
THTensor *save_mean, THTensor *save_std,
bool... |
dds.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
declare_variant_messages.c | // RUN: %clang_cc1 -triple=x86_64-pc-win32 -verify -fopenmp -x c -std=c99 -fms-extensions -Wno-pragma-pack %s
// RUN: %clang_cc1 -triple=x86_64-pc-win32 -verify -fopenmp-simd -x c -std=c99 -fms-extensions -Wno-pragma-pack %s
// expected-error@+1 {{expected an OpenMP directive}}
#pragma omp declare
int foo(void);
#p... |
_Atomic-1.c | /* PR c/65467 */
/* { dg-do compile } */
/* { dg-additional-options "-std=c11" } */
_Atomic int t;
#pragma omp threadprivate (t)
void
foo (void)
{
_Atomic int a = 4, b = 0, c, d = 3, e;
a++;
#pragma omp parallel sections num_threads (a) shared (b) private (c) firstprivate (d) lastprivate (e)
{
#pragma omp s... |
MatrixMN.h | /////////////////////////////////////////////////////////////////////////////
// Authored by Jeong-Mo Hong for CSE4060 course at Dongguk University CSE //
// jeongmo.hong@gmail.com //
// Do whatever you want license. //
////////... |
openmp_worksharing.c | #include <stdio.h>
#include <omp.h>
#define ITERATIONS 100
int main(int argc, char const *argv[])
{
// we will use 4 threads
omp_set_num_threads(4);
// The next pragma directive is used to distribute the for loops in the threads
#pragma omp parallel for
for (int i = 0; i < ITERATIONS; ++i)
{
... |
lu.pluto_orio.seq.large.c | #include <stdio.h>
#include <stdlib.h>
#include <sys/time.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))
double L[N][N];
double U[N][N];
double A[N][... |
traversal.h | #ifndef TRAVERSAL_H_
#define TRAVERSAL_H_
#include "types.h"
#include "adListShared.h"
#include "stinger.h"
#include "darhh.h"
#include "adListChunked.h"
#include "GraphTango.h"
#include "Vertex.h"
#include "topDataStruc.h"
template<typename T>
class neighborhood;
template<typename T>
class neighbo... |
convolution_4x4.h | // Tencent is pleased to support the open source community by making ncnn available.
//
// Copyright (C) 2017 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 copy ... |
7633.c | /* POLYBENCH/GPU-OPENMP
*
* This file is a part of the Polybench/GPU-OpenMP suite
*
* Contact:
* William Killian <killian@udel.edu>
*
* Copyright 2013, The University of Delaware
*/
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <math.h>
/* Include polybench common header. */
#include <po... |
GB_binop__bshift_uint64.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
lensing.c | /** @file lensing.c Documented lensing module
*
* Simon Prunet and Julien Lesgourgues, 6.12.2010
*
* This module computes the lensed temperature and polarization
* anisotropy power spectra \f$ C_l^{X}, P(k), ... \f$'s given the
* unlensed temperature, polarization and lensing potential spectra.
*
* Follows Chal... |
dataset.h | /*!
* Copyright (c) 2016 Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See LICENSE file in the project root for license information.
*/
#ifndef LIGHTGBM_DATASET_H_
#define LIGHTGBM_DATASET_H_
#include <LightGBM/config.h>
#include <LightGBM/feature_group.h>
#include <LightGBM/meta.h>
... |
tabu_search_core.h | /*****************************************************************************/
// Copyright (c) 2020-2021 Yuji KOGUMA
// Released under the MIT license
// https://opensource.org/licenses/mit-license.php
/*****************************************************************************/
#ifndef PRINTEMPS_SOLVER_TABU_SEARCH... |
data.h | /*!
* Copyright (c) 2015 by Contributors
* \file data.h
* \brief The input data structure of xgboost.
* \author Tianqi Chen
*/
#ifndef XGBOOST_DATA_H_
#define XGBOOST_DATA_H_
#include <dmlc/base.h>
#include <dmlc/data.h>
#include <rabit/rabit.h>
#include <xgboost/base.h>
#include <xgboost/span.h>
#include <xgboos... |
reorder.c | // -----------------------------------------------------------------------------
//
// "00_AccelGraph"
//
// -----------------------------------------------------------------------------
// Copyright (c) 2014-2019 All rights reserved
// -----------------------------------------------------------------------------
... |
channel.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
set_value_x_coo.c | #include "alphasparse/kernel.h"
#include "alphasparse/opt.h"
#include "alphasparse/util.h"
#ifdef _OPENMP
#include <omp.h>
#endif
alphasparse_status_t
ONAME(ALPHA_SPMAT_COO *A,
const ALPHA_INT row,
const ALPHA_INT col,
const ALPHA_Number value)
{
ALPHA_INT num_thread = alpha_get_thread_num();
ALPHA_INT f... |
GB_binop__bset_uint16.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http:... |
daxpy.c | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#define N 20480
int main(void) {
double *x, *y;
size_t size = N*sizeof(double);
x = (double *)malloc(size);
y = (double *)malloc(size);
// initialize x and y
srand(time(NULL));
double a = (double)random() / RAND_MAX;
int i;
for (i=0; i<N... |
common_functions.h | /*
* Evan Lezar
* 18 November 2010
*
* Post processing of the eigenvalues calcuated using the ARPACK-based solvers routines
*
*/
void apply_shift ( int N, float* S, float* T, int LDMAT, float shift )
{
// T = T - shift*S
checkpoint t0 = tic();
int row, col;
#pragma omp parallel default(shared) privat... |
ParFriends.h | #ifndef _PAR_FRIENDS_H_
#define _PAR_FRIENDS_H_
#include "mpi.h"
#include <iostream>
#include <cstdarg>
#include "SpParMat.h"
#include "SpParHelper.h"
#include "MPIType.h"
#include "Friends.h"
#include "OptBuf.h"
using namespace std;
template <class IT, class NT, class DER>
class SpParMat;
/**********************... |
GB_binop__bshift_uint16.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
core_dunpack_blasfeo.c | /**
*
* @file
*
* PLASMA is a software package provided by:
* University of Tennessee, US,
* University of Manchester, UK.
*
* @generated from core_blas/core_zlacpy.c, normal z -> d, Thu Aug 8 10:20:04 2019
*
**/
#include <plasma_core_blas.h>
#include "plasma_types.h"
#include "plasma_internal.h"
#includ... |
elemwise_binary_op.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 ... |
hhalignment-C.h | /* -*- mode: c; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */
/*********************************************************************
* Clustal Omega - Multiple sequence alignment
*
* Copyright (C) 2010 University College Dublin
*
* Clustal-Omega is free software; you can redistribute it and/or
* ... |
GB_binop__max_int32.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http:... |
transform.h | /*
* transform.h
*
* Created on: Dec 28, 2015
* @author: agibsonccc
* @author: raver119@gmail.com
*/
#ifndef TRANSFORM_H_
#define TRANSFORM_H_
#include <vector>
#include <templatemath.h>
#include <ops/ops.h>
#include <ops/special_ops.h>
#ifdef _OPENMP
#include <omp.h>
#endif
#include <pairwise_util.h>
#includ... |
opencl_encfs_fmt_plug.c | /*
* Modified by Dhiru Kholia <dhiru at openwall.com> for Keychain format.
*
* This software is Copyright (c) 2012 Lukas Odzioba <ukasz@openwall.net>
* 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, ar... |
3d25pt_var.c | /*
* Order-1, 3D 25 point stencil with axis-symmetric ariable coefficients
* Adapted from PLUTO and Pochoir test bench
*
* Tareq Malas
*/
#include <stdio.h>
#include <stdlib.h>
#include <sys/time.h>
#ifdef LIKWID_PERFMON
#include <likwid.h>
#endif
#include "print_utils.h"
#define TESTS 2
#define MAX(a,b) ((a) >... |
dynamic_fmt.c | /*
* This software was written by Jim Fougeron jfoug AT cox dot net
* in 2009-2013. No copyright is claimed, and the software is hereby
* placed in the public domain. In case this attempt to disclaim
* copyright and place the software in the public domain is deemed
* null and void, then the software is Copyright (... |
core_clantr.c | /**
*
* @file
*
* PLASMA is a software package provided by:
* University of Tennessee, US,
* University of Manchester, UK.
*
* @generated from /home/luszczek/workspace/plasma/bitbucket/plasma/core_blas/core_zlantr.c, normal z -> c, Fri Sep 28 17:38:21 2018
*
**/
#include <plasma_core_blas.h>
#include "pla... |
mm-omp.c | /**
*
* Matrix Multiplication - Shared-memory (OpenMP)
*
* CS3210
*
**/
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <sys/time.h>
#include <assert.h>
#include <omp.h>
#include <xmmintrin.h>
int size;
int threads;
typedef struct
{
float ** element;
} matrix;
long long wall_clock_time()
... |
elemwise_binary_op.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 ... |
ex3.c | #include <stdio.h>
#include <omp.h>
static long num_steps = 100000;
double step;
int main()
{
double pi, sum;
double x;
int i, ts_num;
step = 1.0/(double)num_steps;
double start = omp_get_wtime();
#pragma omp parallel for reduction(+:sum)
for(i=0;i < num_steps;i++)
{
x = (i+0.5)*step;
sum += 4... |
Example_mem_model.1.c | /*
* @@name: mem_model.1c
* @@type: C
* @@compilable: yes
* @@linkable: yes
* @@expect: rt-error
* @@version: omp_3.1
*/
#include <stdio.h>
#include <omp.h>
int main(){
int x;
x = 2;
#pragma omp parallel num_threads(2) shared(x)
{
if (omp_get_thread_num() == 0) {
#pragma omp atomic write
x ... |
BKTree.h | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef _SPTAG_COMMON_BKTREE_H_
#define _SPTAG_COMMON_BKTREE_H_
#include <stack>
#include <string>
#include <vector>
#include <shared_mutex>
#include "../VectorIndex.h"
#include "CommonUtils.h"
#include "QueryResultSet.h... |
dmml.c | /*! @copyright (c) 2017 King Abdullah University of Science and
* Technology (KAUST). All rights reserved.
*
* STARS-H is a software package, provided by King Abdullah
* University of Science and Technology (KAUST)
*
* @file src/backends/mpi/blrm/dmml.c
* @version 0.3.0
* @autho... |
irbuilder_unroll_partial_heuristic.c | // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --function-signature --include-generated-funcs
// RUN: %clang_cc1 -no-opaque-pointers -fopenmp-enable-irbuilder -verify -fopenmp -fopenmp-version=51 -x c -triple x86_64-unknown-unknown -emit-llvm %s -o - | FileCheck %s
// expected-n... |
cuda.h | #ifndef CXXBLAS_AUXILIARY_CUDA_H
#define CXXBLAS_AUXILIARY_CUDA_H 1
#if defined(HAVE_CUBLAS) || defined(HAVE_CUSOLVER)
#include <string> // XXX
#include <vector>
#include <thrust/execution_policy.h>
#include <thrust/device_ptr.h>
// Implement a strided range/iterator
#include <thrust/iterator/counting_iterator.h>
#... |
rotate.h | /*! @file rotate.h
* @brief Rotate the buffers.
* @author Markovtsev Vadim <v.markovtsev@samsung.com>
* @version 1.0
*
* @section Notes
* This code partially conforms to <a href="http://google-styleguide.googlecode.com/svn/trunk/cppguide.xml">Google C++ Style Guide</a>.
*
* @section Copyright
* Copyrigh... |
window_layer.c | /********************************************************************[libaroma]*
* Copyright (C) 2011-2015 Ahmad Amarullah (http://amarullz.com/)
*
* 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 Lic... |
DFTW_omp.c | // the code calculates a DFT of a random complex number input and
// then an IDFT. The IDFT result should be the input vector
// to compile with gcc
// gcc -Wall -O2 -fopenmp -o DFTW DFTW.c -lm
// written by stef
// exercise
#include "stdio.h" // printf
#include "stdlib.h" // malloc and r... |
cache.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
myFunc_cilk.h | //#define __declspec(x)
// Rob Farber
#include <stdlib.h>
#include <string.h>
#include <stdint.h>
#include <malloc.h>
#include <math.h>
//#include <omp.h>
#include <time.h>
#include <sys/time.h>
#include <cilk/cilk.h>
#include <cilk/reducer_opadd.h>
#define MICRO_IN_SEC 1000000.00
#define MIC_DEV 0
#define ALLOC a... |
GB_binop__bxor_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... |
image_random-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 may no... |
DRB024-simdtruedep-orig-yes.c | /*
Copyright (c) 2017, Lawrence Livermore National Security, LLC.
Produced at the Lawrence Livermore National Laboratory
Written by Chunhua Liao, Pei-Hung Lin, Joshua Asplund,
Markus Schordan, and Ian Karlin
(email: liao6@llnl.gov, lin32@llnl.gov, asplund1@llnl.gov,
schordan1@llnl.gov, karlin1@llnl.gov)
LLNL-CODE-73214... |
GB_unaryop__minv_uint64_uint32.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http... |
sieve.c | /*
* Tempo Sequencial
*
*real 0m4.047s
*user 0m3.960s
*sys 0m0.080s
*
*real 0m4.053s
*user 0m3.967s
*sys 0m0.080s
*
*real 0m4.042s
*user 0m3.962s
*sys 0m0.072s
*
*real 0m4.044s
*user 0m3.953s
*sys 0m0.084s
*
*real 0m4.045s
*user 0m3.967s
*sys 0m0.072s
*
* Tempo paralelo (Atividade 03)
*
*real 0m3.700s
*user 0m6.857s
*s... |
prime.c | #include<stdio.h>
#include<stdlib.h>
#include<omp.h>
int main(int argc,char *argv[]){
int index;
int i;
int count;
int first;
int n;
int N;
int prime;
char *marked;
double start, delta;
omp_set_num_threads(1);
if(argc!=2){
printf("Command line: %s <m>\n",argv[0]);
exit(1);
}
n = atoi(argv[1]);
N = n+... |
simd_misc_messages.c | // RUN: %clang_cc1 -fsyntax-only -fopenmp -verify %s -Wuninitialized
// RUN: %clang_cc1 -fsyntax-only -fopenmp-simd -verify %s -Wuninitialized
void xxx(int argc) {
int x; // expected-note {{initialize the variable 'x' to silence this warning}}
#pragma omp simd
for (int i = 0; i < 10; ++i)
argc = x; // expecte... |
crossbar.h | #ifndef _CROSSBAR_H
#define _CROSSBAR_H
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <omp.h>
#include <random>
#include "config.h"
#define NSUM 25
using namespace std;
typedef struct Crossbar
{
float *std_d;
int CB_l;
int CB_w;
int CB_n;
float *CB_cell;
... |
channel.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
Parallel.h | #pragma once
#include <ATen/ATen.h>
#include <cstddef>
#ifdef _OPENMP
#include <omp.h>
#endif
namespace at {
namespace internal {
// This parameter is heuristically chosen to determine the minimum number of
// work that warrants paralellism. For example, when summing an array, it is
// deemed inefficient to paralleli... |
GB_unaryop__lnot_uint64_int16.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http... |
csr_kernels.h | #ifndef CSR_KERNELS_H
#define CSR_KERNELS_H
extern "C" {
/*!
* CSR matrix sketching with CountSketch and Gaussian transforms. Parallelized with OpenMP.
* A is a n*d CSR matrix. S is a r*n CountSketch. C is a row major matrix.
* If m == 0: C has size r * d and we only apply C <- S * A (G is not applied).
... |
prospector.c | #define _DEFAULT_SOURCE // MAP_ANONYMOUS
#include <math.h>
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <string.h>
#include <fcntl.h>
#include <dlfcn.h>
#include <unistd.h>
#include <sys/mman.h>
#include <sys/time.h>
#define ABI __attribute__((sysv_abi))
#define countof(a) (... |
Example_tasking.2.c | /*
* @@name: tasking.2c
* @@type: C
* @@compilable: yes
* @@linkable: no
* @@expect: success
* @@version: omp_3.0
*/
struct node {
struct node *left;
struct node *right;
};
extern void process(struct node *);
void postorder_traverse( struct node *p ) {
if (p->left)
#pragma omp task // p is firstprivat... |
GB_binop__times_uint64.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
omp_for_firstprivate_nothreadprivate.c | // RUN: %libomp-compile-and-run
#include <stdio.h>
#include <math.h>
#include "omp_testsuite.h"
int test_omp_for_firstprivate()
{
int sum;
int sum0;
int known_sum;
int threadsnum;
sum = 0;
sum0 = 12345;
#pragma omp parallel
{
int sum1 = 0;
#pragma omp single
{
threadsnum=omp_get_num... |
main.c | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <omp.h>
int slow_function_with_mp() {
double stuff[1000];
long i;
#pragma omp parallel for private(i) shared(stuff)
for (i=0; i<9999999; i++) {
stuff[i % 1000] = sin(i*i);
}
}
void main(int argc, char **argv) {
double start, end;
int ... |
pr34513.c | /* PR c++/34513 */
/* { dg-do run } */
#include <omp.h>
extern void abort ();
static int errors = 0;
static int thrs = 4;
int
main ()
{
omp_set_dynamic (0);
#pragma omp parallel num_threads (thrs)
{
static int shrd = 0;
#pragma omp atomic
shrd += 1;
#pragma omp barrier
if (shrd != th... |
GB_binop__ne_int8.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
main.c | #include <stdio.h>
#include <math.h>
#include <time.h>
#include <omp.h>
#define mm 15
#define npart 4*mm*mm*mm
/*
* Function declarations
*/
void
dfill(int,double,double[],int);
void
domove(int,double[],double[],double[],double);
void
dscal(int,double,double[],int);
void
fcc(double[],int,int,double);
void
fo... |
pkzip_fmt_plug.c | /* PKZIP patch for john to handle 'old' pkzip passwords (old 'native' format)
*
* Written by Jim Fougeron <jfoug at cox.net> in 2011. No copyright
* is claimed, and the software is hereby placed in the public domain.
* In case this attempt to disclaim copyright and place the software in the
* public domain is dee... |
annoylib_omp.h | // To use OpenMP replace the content of annoylib.h to this file context
#ifndef ANNOYLIB_H
#define ANNOYLIB_H
#include <stdio.h>
#include <sys/stat.h>
#ifndef _MSC_VER
#include <unistd.h>
#endif
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <fcntl.h>
#include <stddef.h>
#include <omp.h>
#if ... |
pgpdisk_fmt_plug.c | /*
* Format for brute-forcing PGP Virtual Disk images.
*
* This software is Copyright (c) 2017, Dhiru Kholia <dhiru.kholia at gmail.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 permitt... |
GB_unop__identity_int64_uint64.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-Li... |
attribute.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
ba81quad.h | /*
Copyright 2012-2014 Joshua Nathaniel Pritikin and contributors
This 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 3 of the License, or
(at your option) any later version.
This pro... |
bitcoin_fmt_plug.c | /* bitcoin-qt (bitcoin) wallet cracker patch for JtR. Hacked together during
* April of 2013 by Dhiru Kholia <dhiru at openwall dot com>.
*
* Also works for Litecoin-Qt (litecoin) wallet files!
*
* This software is Copyright (c) 2013, Dhiru Kholia <dhiru at openwall dot com>,
* and it is hereby released to the ge... |
iwork_fmt_plug.c | /* JtR format to crack iWork '09, and '13 / '14 files.
*
* This software is Copyright (c) 2015, Dhiru Kholia <kholia at kth.se> and
* Maxime Hulliger <hulliger at kth.se>, and it is hereby released to the
* general public under the following terms:
*
* Redistribution and use in source and binary forms, with or wi... |
GB_unop__identity_int16_uint8.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... |
3d7pt.c | /*
* Order-1, 3D 7 point stencil
* Adapted from PLUTO and Pochoir test bench
*
* Tareq Malas
*/
#include <stdio.h>
#include <stdlib.h>
#include <sys/time.h>
#ifdef LIKWID_PERFMON
#include <likwid.h>
#endif
#include "print_utils.h"
#define TESTS 2
#define MAX(a,b) ((a) > (b) ? a : b)
#define MIN(a,b) ((a) < (b) ... |
GB_binop__isge_fp32.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_binop__isge_uint16.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
tinyexr.h | /*
Copyright (c) 2014 - 2018, Syoyo Fujita and many contributors.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this l... |
convolution_winograd_transform_pack4.h | // Tencent is pleased to support the open source community by making ncnn available.
//
// Copyright (C) 2022 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 copy ... |
apply.h | /******************************************************************************
* ** Copyright (c) 2016, Intel Corporation **
* ** All rights reserved. **
* ** ... |
GB_binop__minus_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-... |
mtSpGEMM.h | #ifndef _mtSpGEMM_h
#define _mtSpGEMM_h
#include "CombBLAS.h"
namespace combblas {
/*
Multithreaded prefix sum
Inputs:
in: an input array
size: the length of the input array "in"
nthreads: number of threads used to compute the prefix sum
Output:
return an array of size "size+1"
the memory of ... |
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... |
box_coder_op.h | /* Copyright (c) 2018 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 ag... |
core_dtslqt.c | /**
*
* @file
*
* PLASMA is a software package provided by:
* University of Tennessee, US,
* University of Manchester, UK.
*
* @generated from /home/luszczek/workspace/plasma/bitbucket/plasma/core_blas/core_ztslqt.c, normal z -> d, Fri Sep 28 17:38:24 2018
*
**/
#include <plasma_core_blas.h>
#include "pla... |
targ_static.c | #include <stdio.h>
#include "assert.h"
#include <unistd.h>
#define NZ 10
#define NA 9
#pragma omp declare target
static int colstat[NZ];
#pragma omp end declare target
int main(){
colstat[0]=-1;
#pragma omp target map(alloc:colstat[0:NZ])
{
colstat[1] = 1111;
}
#pragma omp target map(alloc:colstat[:0])
{
... |
GB_AxB_rowscale_meta.c | //------------------------------------------------------------------------------
// GB_AxB_rowscale_meta: C=D*B where D is a square diagonal matrix
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://... |
linear_tree_learner.h | /*!
* Copyright (c) 2020 Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See LICENSE file in the project root for license information.
*/
#ifndef LIGHTGBM_TREELEARNER_LINEAR_TREE_LEARNER_H_
#define LIGHTGBM_TREELEARNER_LINEAR_TREE_LEARNER_H_
#include <string>
#include <cmath>
#include ... |
file_io.c | #include "file_io.h"
void compress_annotations_disk(BFT_Root* bft, char* filename_bft){
ASSERT_NULL_PTR(bft, "compress_annotations_disk()\n")
ASSERT_NULL_PTR(filename_bft, "compress_annotations_disk()\n")
Pvoid_t comp_annots = (PWord_t)NULL;
Word_t Rc_word;
memory_Used* mem;
bool is_compres... |
choleskies_cython.c | /* Generated by Cython 0.29.2 */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#ifndef Py_PYTHON_H
#error Python headers needed to compile C extensions, please install development version of Python.
#elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000)
#error Cython ... |
dds.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
extract_image_patches.h | /* Copyright 2018 The Blueoil 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 agre... |
fws_parfor.c | /*
Standard implementation of the Floyd-Warshall Algorithm
using OpenMP parallel for.
*/
#include <stdio.h>
#include <stdlib.h>
#include <sys/time.h>
#include "util.h"
#include <stdio.h>
#include <omp.h>
inline int min(int a, int b);
int main(int argc, char **argv)
{
int **A;
int i,j,k;
struct timeval t1, t... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.