source stringlengths 3 92 | c stringlengths 26 2.25M |
|---|---|
2mm.c | /**
* 2mm.c: This file was adapted from PolyBench/GPU 1.0 test suite
* to run on GPU with OpenMP 4.0 pragmas and OpenCL driver.
*
* http://www.cse.ohio-state.edu/~pouchet/software/polybench/GPU
*
* Contacts: Marcio M Pereira <mpereira@ic.unicamp.br>
* Rafael Cardoso F Sousa <rafael.cardoso@students.ic.... |
convolution_sgemm_pack4to1_bf16s.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 copy ... |
GB_unaryop__identity_uint64_uint64.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http... |
sms4speed.c | /* crypto/sms4/sms4speed.c */
/* ====================================================================
* Copyright (c) 2014 - 2016 The GmSSL Project. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* ar... |
GB_transpose_bucket.c | //------------------------------------------------------------------------------
// GB_transpose_bucket: transpose and optionally typecast and/or apply operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserve... |
kmp_stats.h | #ifndef KMP_STATS_H
#define KMP_STATS_H
/** @file kmp_stats.h
* Functions for collecting statistics.
*/
//===----------------------------------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license... |
GB_unop__identity_uint64_bool.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... |
eigen.h | /*
* Copyright 2009-2020 The VOTCA Development Team
* (http://www.votca.org)
*
* 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
*
* h... |
GrB_Vector_wait.c | //------------------------------------------------------------------------------
// GrB_Vector_wait: wait for a vector to complete
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-License-Identifier:... |
ep.c | /*******************************************************************************
* Copyright 2021 UChicago Argonne, LLC.
* (c.f. AUTHORS, LICENSE)
*
* This file is part of the NRM Benchmarks project.
* For more info, see https://github.com/anlsys/nrm-benchmarks
*
* SPDX-License-Identifier: BSD-3-Clause
********... |
GB_unaryop__identity_uint8_int8.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http... |
GB_unop__isfinite_bool_fp32.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... |
deconvolution_pack4.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 copy ... |
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) >... |
colormap.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
Questao02.c | //Programa que permite o usuario inserir a precisao do PI(versão paralelizada)
//Criado por Gustavo Lopes Rodrigues
#include <stdio.h>
//Função que encapsula o código do cálculo do PI
double calcularPi();
//Função main
int main(void){
int precisao;
scanf("%d", &precisao);
double pi = calcularPi(precisao);
... |
graph.h | // Copyright (c) 2015, The Regents of the University of California (Regents)
// See LICENSE.txt for license details
#ifndef GRAPH_H_
#define GRAPH_H_
#include <algorithm>
#include <cinttypes>
#include <cstddef>
#include <iostream>
#include <type_traits>
#include "pvector.h"
#include "util.h"
/*
GAP Benchmark Suite
... |
mandel_reduction.c | /*
** PROGRAM: Mandelbrot area (solution)
**
** PURPOSE: Program to compute the area of a Mandelbrot set.
** The correct answer should be around 1.510659.
**
** USAGE: Program runs without input ... just run the executable
**
** ADDITIONAL EXERCISES: Experiment with the schedule clause to fix ... |
convolution_3x3.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 ... |
parallel.c | /* Copyright (C) 2005-2017 Free Software Foundation, Inc.
Contributed by Richard Henderson <rth@redhat.com>.
This file is part of the GNU Offloading and Multi Processing Library
(libgomp).
Libgomp is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public Licen... |
fenceIssue.c | extern int omp_get_thread_num();
extern int printf(char *[], ...);
int main () {
int X = 0;
int Y = 0;
#pragma omp parallel num_threads(2)
{
if (omp_get_thread_num() == 0) {
X = 42;
#pragma omp atomic write
Y = 1;
} else {
int t1;
while (1) {
#pragma omp atomic read
t1 = Y;
if (t1) {
bre... |
ClangASTHelper.h | //
// Copyright (c) 2012, University of Erlangen-Nuremberg
// Copyright (c) 2012, Siemens AG
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
//
// 1. Redistributions of source code must retain... |
GB_binop__bshift_int32.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
trsm_c_sky_n_hi_col_conj.c | #include "alphasparse/kernel.h"
#include "alphasparse/util.h"
#include <memory.h>
#ifdef _OPENMP
#include <omp.h>
#endif
alphasparse_status_t ONAME(const ALPHA_Number alpha, const ALPHA_SPMAT_SKY *A, const ALPHA_Number *x, const ALPHA_INT columns, const ALPHA_INT ldx, ALPHA_Number *y, const ALPHA_INT ldy)
{
ALPHA_... |
residualbased_predictorcorrector_velocity_bossak_scheme.h | /*
==============================================================================
KratosStructuralApplication
A library based on:
Kratos
A General Purpose Software for Multi-Physics Finite Element Analysis
Version 1.0 (Released on march 05, 2007).
Copyright 2007
Pooyan Dadvand, Riccardo Rossi, Janosch Stascheit, Felix... |
stat_ops_dm.c | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include "stat_ops_dm.h"
#include "utility.h"
#include "constant.h"
// calculate norm
double dm_state_norm_squared(const CTYPE *state, ITYPE dim) {
ITYPE index;
double norm = 0;
#ifdef _OPENMP
#pragma omp parallel for reduction(+:norm... |
beta_projectors_strain_deriv.h | #ifndef __BETA_PROJECTORS_STRAIN_DERIV_H__
#define __BETA_PROJECTORS_STRAIN_DERIV_H__
#include "beta_projectors_base.h"
namespace sirius {
class Beta_projectors_strain_deriv : public Beta_projectors_base<9>
{
private:
void generate_pw_coefs_t(std::vector<int> const& igk__)
{
PROFILE("sirius::Beta_... |
GB_unaryop__abs_int64_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... |
GB_unop__cos_fp32_fp32.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... |
laplace2d.c | /*
* Copyright 2012 NVIDIA Corporation
*
* 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 ... |
GB_binop__minus_int8.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
data.h | /*!
* Copyright (c) 2015 by Contributors
* \file data.h
* \brief The input data structure of tsoobgx.
* \author Tianqi Chen
*/
#ifndef TSOOBGX_DATA_H_
#define TSOOBGX_DATA_H_
#include <dmlc/base.h>
#include <dmlc/data.h>
#include <rabit/rabit.h>
#include <cstring>
#include <memory>
#include <numeric>
#include <al... |
nlk_pv.c | /******************************************************************************
* NLK - Neural Language Kit
*
* Copyright (c) 2014 Luis Rei <me@luisrei.com> http://luisrei.com @lmrei
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation fi... |
GB_unop__exp2_fc32_fc32.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... |
saxpy.c | /**
* @file saxpy.c
*
* @mainpage saxpy
*
* @author Xin Wu (PC²)
* @date 05.04.2020
* @copyright CC BY-SA 2.0
*
* saxpy performs the \c saxpy operation on host as well as accelerator.
* The performance (in MB/s) for different implementations is also compared.
*
* The \c saxpy operation is defined as:
*
* ... |
GB_unaryop__minv_int64_bool.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_unaryop__identity_int64_uint64.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http... |
GB_critical_section.c | //------------------------------------------------------------------------------
// Source/Template/GB_critical_section: execute code in a critical section
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
//... |
jacobi-ompacc.c | #include <stdio.h>
#include <math.h>
#ifdef _OPENMP
#include <omp.h>
#endif
// Add timing support
#include <sys/time.h>
double time_stamp()
{
struct timeval t;
double time;
gettimeofday(&t, NULL);
time = t.tv_sec + 1.0e-6*t.tv_usec;
return time;
}
double time1, time2;
void driver(void);
void initialize(voi... |
GB_unop__identity_fp32_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... |
11_omp_mpi_simple.c | // clang-format off
// RUN: %c-to-llvm -fno-discard-value-names %omp_c_flags %s | %apply-typeart -typeart-alloca -call-filter -S 2>&1 | FileCheck %s
// RUN: %c-to-llvm -fno-discard-value-names %omp_c_flags %s | opt -O2 -S | %apply-typeart -typeart-alloca -call-filter -S 2>&1 | FileCheck %s
// REQUIRES: openmp
// XFAIL:... |
GB_binop__times_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... |
rt_dsymm.c | #include "runtime.h"
#ifdef PLASMA_WITH_SMP
#pragma omp target device (smp) copy_deps
#pragma omp task in([lda*m]A, [ldb*n]B) inout([ldc*n]C) label(ldsymm_smp)
void CORE_ldsymm_ompss(PLASMA_enum uplo, int m , int n, double alpha, double *A, int lda, double *B, int ldb, double beta, double *C, int ldc, int nb)
{
CORE_... |
dynmat.c | /* Copyright (C) 2015 Atsushi Togo */
/* All rights reserved. */
/* This file is part of phonopy. */
/* 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 abo... |
trsv_x_sky_n_hi.c | #include "alphasparse/kernel.h"
#include "alphasparse/util.h"
#include "alphasparse/opt.h"
#include <memory.h>
#ifdef _OPENMP
#include <omp.h>
#endif
alphasparse_status_t ONAME(const ALPHA_Number alpha, const ALPHA_SPMAT_SKY *A, const ALPHA_Number *x, ALPHA_Number *y)
{
ALPHA_Number diag[A->cols];
memset(diag,... |
GB_assign_zombie4.c | //------------------------------------------------------------------------------
// GB_assign_zombie4: delete entries in C(i,:) for C_replace_phase
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-Li... |
HYPRE_IJMatrix.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)
**************************************... |
ex02.c | #include <stdio.h>
#include <omp.h>
static long num_steps = 1000000;
double step;
int main(int argv, char* argc)
{
int num_threads;
double pi, total_sum = 0.0;
step = 1.0 / (double) num_steps;
int num_procs = omp_get_num_procs();
// omp_set_num_threads(num_procs);
double* sum;
int steps_per_thread;
// int n... |
pbkdf2_hmac_sha256_fmt_plug.c | /* 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, are permitted.
*
* Based on hmac-sha512 by magnum
*
* Minor fixes, format uni... |
omp_multiplicacao.c | /******************************************************************************
* FILE: mm.c
* DESCRIPTION:
* Matrix Multiply - C Version
* Modified from Blaise Barney OpenMP code.
******************************************************************************/
#include <stdio.h>
#include <stdlib.h>
#include <omp.... |
GB_unop__frexpe_fp64_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://... |
profile.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
rgb_matrix.h | #ifndef RGB_MATRIX_H
#define RGB_MATRIX_H
#include <stdio.h>
#include <math.h>
#define PIX_MAX_NORM 1
#define PIX_MIN_NORM 0
/*
* Represents symetric 2x2 matrix that contains RGB values of the given pixel.
* Top left element represents R value, bottom left B value and other 2 elements G value.
*/
template<typenam... |
r32x16b_avx2.c | /*
* AVX2 edition using 32 RANS states. This uses a shared pointer for the
* compressed buffer.
*
* TODO: implement SIMD version of the order-1 encoder (decoder is done).
*/
#ifdef _MSC_VER
#include <intrin.h>
#pragma warning(push)
#pragma warning(disable: 4752)
#if _MSC_VER < 1910
inline __forceinline __int64 _mm25... |
block-2.c | // { dg-do compile }
void foo()
{
int i, j;
#pragma omp for
for (i = 0; i < 10; ++i)
break; // { dg-error "break" }
bad1:
#pragma omp for
for (i = 0; i < 10; ++i)
goto bad1; // { dg-error "invalid exit" }
goto bad2; // { dg-error "invalid entry" }
#pragma omp for
for (i = 0; i < 10; ... |
3d25pt_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 25 point stencil with axis-symmetric ariable coefficients
* Adapted fr... |
mutation.h | /*!
* Functions to determine the number of fit mutated genomes that exist
* a Hamming distance m (or h) away from a given, fit genome.
*/
#ifndef _MUTATION_H_
#define _MUTATION_H_
#include <math.h>
#ifndef __FITNESS_FUNCTION__
#error "#include a fitness.h before #including mutations.h to ensure evaluate_fitness()... |
1body.h | /*
* Copyright (C) 2004-2020 Edward F. Valeev
*
* This file is part of Libint.
*
* Libint is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your opt... |
parte2.c | #include <stdio.h>
#include <stdlib.h>
#include <omp.h>
#include <unistd.h>
static unsigned long num_steps;
double step;
int main (int argc, char **argv)
{
unsigned long int i, cores;
double x, pi, sum = 0.0;
cores = sysconf( _SC_NPROCESSORS_ONLN );
num_steps = atol(argv[1]);
step = 1.0/(double) num_steps;
om... |
ast-dump-openmp-taskyield.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() {
#pragma omp taskyield
}
// CHECK: TranslationUnitDecl {{.*}} <<invalid sloc>> <invalid sloc>
// CHECK: `-FunctionDecl {{.*}} <{{.*}}ast-dump-openmp-taskyi... |
textbook_msd.c | #include <math.h>
#include <stdio.h>
#include <stdbool.h>
void textbook_msd(unsigned int first, unsigned int second, unsigned short* in_data, double* mean, double* sd){
double sum = 0.0;
double temp_sd = 0.0;
for(unsigned int i = 0; i < first; i++){
sum = 0.0;
temp_sd = 0.0;
for(unsigned int j = 0; j < secon... |
bt.c | /*--------------------------------------------------------------------
NAS Parallel Benchmarks 3.0 structured OpenMP C versions - BT
This benchmark is an OpenMP C version of the NPB BT code.
The OpenMP C 2.3 versions are derived by RWCP from the serial Fortran versions
in "NPB 2.3-serial" developed by N... |
Quicksort.c | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <omp.h>
#include <time.h>
// array init modes -> "random", "crescent", "decrescent"
#define ARRAY_INIT_MODE "random"
#define ARRAY_SIZE 500000
// quicksort modes -> "sequential", "tasks", "tasks_and_for", "sections"
#define QUICKSORT_MODE "t... |
6708.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__isle_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... |
GB_unaryop__identity_uint8_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... |
GB_unop__identity_int16_uint32.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... |
pst_search.c | #include <omp.h>
#include <string.h>
#include "tldevel.h"
#include "tlrng.h"
#include "tlseqio.h"
#include "tlmisc.h"
#include "tlalphabet.h"
#include "pst.h"
#include "pst_structs.h"
#include "pst_hash.h"
#include "search_db.h"
#define PST_SEARCH_IMPORT
#include "pst_search.h"
static int copy_sequences(struct tl... |
Trapezium.c | /** Trapezoidal rule for Numerical Integration
https://rosettacode.org/wiki/Numerical_integration
@file Trapezium.c */
#include "Trapezium.h"
//TRAP-Serial
double trapezium(double from, double to, double n, double (*func)())
{
double h = (to-from)/n;
double sum = func(from)+func(to);
int i;
for(i=1... |
3d7pt.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
* Adapted from PLUTO and Pochoir test bench
*
* Tare... |
GB_binop__div_fp64.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
decode_from_pgm.c | #include "PGM.h"
void extract_img(int height, int width, int *p1, int *q1, int *p1_star, int *p2_star, int *q1_star, int *q2_star)
{
// Creating the original image.
int *original_img = (int *)malloc(height * width * sizeof(int));
if (!original_img)
{
printf("ERROR: Memory Allocation of Image Ex... |
fill_ints.c | /* Copyright 2014-2018 The PySCF Developers. 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 ... |
kernel.h | /*
* This file contains the implementation of a kernel for the
* point-in-polygon problem using the crossing number algorithm
*
* The kernel pnpoly_base is used for correctness checking.
*
* The algorithm used here is adapted from:
* 'Inclusion of a Point in a Polygon', Dan Sunday, 2001
* (http://geoma... |
compiler_cgen.c | /* Generated by Nim Compiler v0.15.0 */
/* (c) 2016 Andreas Rumpf */
/* The generated code is subject to the original license. */
#define NIM_INTBITS 32
#include "nimbase.h"
#include <string.h>
typedef struct Tcgen527027 Tcgen527027;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
typedef stru... |
CombinedOtherStartIndexNNeighboursWorklet.h | //============================================================================
// Copyright (c) Kitware, Inc.
// All rights reserved.
// See LICENSE.txt for details.
// This software is distributed WITHOUT ANY WARRANTY; without even
// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
// PURPOSE... |
SplineC2RAdoptor.h | //////////////////////////////////////////////////////////////////////////////////////
// This file is distributed under the University of Illinois/NCSA Open Source License.
// See LICENSE file in top directory for details.
//
// Copyright (c) 2016 Jeongnim Kim and QMCPACK developers.
//
// File developed by: Jeremy Mc... |
image.h | // Copyright (c) 2017 Marek Dvoroznak
// Licensed under the MIT License.
// Define IMAGE_READ_WRITE for writing and reading methods to be included.
// Define IMAGE_READ_WRITE_NO_COMPRESSION for not including miniz.
// Define IMAGE_SCALE for up-/down- scaling (using stb_image_resize)
#ifndef IMAGE_H
#define IMAGE_H
#... |
GB_binop__eq_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:... |
blake2bp.c | /*
BLAKE2 reference source code package - reference 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 :... |
skein_fmt_plug.c | /* Skein cracker patch for JtR. Hacked together during April of 2013 by Dhiru
* Kholia <dhiru at openwall.com>.
*
* This software is Copyright (c) 2013 Dhiru Kholia <dhiru at openwall.com> and
* it is hereby released to the general public under the following terms:
*
* Redistribution and use in source and binary ... |
mrcore.c |
/***************************************************************************
*
Copyright 2013 CertiVox IOM Ltd. *
*
This file i... |
conversion.h | #pragma once
#include "infra/cast.h"
#include <algorithm>
#include <cmath>
namespace gdx {
template <template <typename> typename RasterType, typename T>
RasterType<T> replace_value(const RasterType<T>& ras, const T oldValue, const T newValue)
{
RasterType<T> result(ras.metadata());
std::transform(begin(ra... |
GB_unop__identity_int8_int64.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... |
omp_lock.c | // RUN: %libomp-compile-and-run
// RUN: env KMP_LOCK_KIND=tas KMP_SPIN_BACKOFF_PARAMS=2048,200 %libomp-run
// RUN: env KMP_LOCK_KIND=futex %libomp-run
#include <stdio.h>
#include "omp_testsuite.h"
omp_lock_t lck;
int test_omp_lock()
{
int nr_threads_in_single = 0;
int result = 0;
int nr_iterations = 0;
int i;... |
add.c | #include <stdio.h>
#include <omp.h>
int main(){
int A[10], B[10] = {0,1,2,3,4,5,6,7,8,9}, C[10] = {0,1,2,3,4,5,6,7,8,9}, i, m, k;
omp_set_dynamic(0);
m = omp_get_num_procs();
omp_set_num_threads(m);
printf("Parallel\n------------");
#pragma omp parallel for shared(A, B, C) private(i)... |
palshop_fmt_plug.c | /* This format is reverse engineered from InsidePro Hash Manager!
*
* This software is Copyright (c) 2016, 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 ... |
ep.c | /*--------------------------------------------------------------------
NAS Parallel Benchmarks 2.3 OpenMP C versions - EP
This benchmark is an OpenMP C version of the NPB EP code.
The OpenMP C versions are developed by RWCP and derived from the serial
Fortran versions in "NPB 2.3-serial" developed by NAS.
... |
threshold.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
ddd_in_h.h | //****************************************************************************************
//
// Copyright (c) 2015-2020, Yoshifumi Nakamura <nakamura@riken.jp>
// Copyright (c) 2015-2020, Yuta Mukai <mukai.yuta@fujitsu.com>
// Copyright (c) 2018-2020, Ken-Ichi Ishikawa <ishikawa@theo.phys.sci.hirosima-u.ac... |
barrier-1.c | /* { dg-do compile } */
/* { dg-options "-fopenmp -fdump-tree-gimple" } */
void f1(void)
{
#pragma omp barrier
}
void f2(_Bool p)
{
if (p)
{
#pragma omp barrier
}
}
/* { dg-final { scan-tree-dump-times "GOMP_barrier" 2 "gimple" } } */
/* { dg-final { cleanup-tree-dump "gimple" } } */
|
GB_binop__ge_fp64.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
exercise3.c | # include <math.h>
# include <omp.h>
# define np 400
# define nnmax 7
# define ndr (2 * np)
# define pi2 (2.0 * 3.141592653589793)
extern double s1[np][3], s2[np][3], s3[np][3];
extern int ldr[ndr][3];
void topol(double s[][3], double *q)
{
double siga;
double cc, cc1, cc2, cc3;
double ss, ss1, ss2, ss3;
... |
section_reduction.c | // Skip testing on 64 bit systems for now!
#ifndef __LP64__
#include <stdio.h>
#include <math.h>
#include "omp_testsuite.h"
int
check_section_reduction (FILE * logFile)
{
int sum = 7;
int known_sum;
double dpt, dsum = 0;
double dknown_sum;
double dt = 0.5; /* base of geometric row for + and - test */
dou... |
GB_unop__abs_fp64_fc64.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... |
_uniform_ld.c | /* The batman package: fast computation of exoplanet transit light curves
* Copyright (C) 2015 Laura Kreidberg
*
* 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 3 of the L... |
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
//
//===---------------------------... |
shape.h | /*******************************************************************************
* Copyright (c) 2015-2018 Skymind, Inc.
*
* This program and the accompanying materials are made available under the
* terms of the Apache License, Version 2.0 which is available at
* https://www.apache.org/licenses/LICENSE-2.0.
*
*... |
geminate.c | /*
* This file is part of the GROMACS molecular simulation package.
*
* Copyright (c) 1991-2000, University of Groningen, The Netherlands.
* Copyright (c) 2001-2004, The GROMACS development team,
* check out http://www.gromacs.org for more information.
* Copyright (c) 2012,2013, by the GROMACS development team, l... |
communication.h | /*! @brief Flag for checking if this header has already been included. */
#ifndef YGGCOMMUNICATION_H_
#define YGGCOMMUNICATION_H_
#include "../tools.h"
#include "../datatypes/datatypes.h"
#include "CommBase.h"
#include "IPCComm.h"
#include "ZMQComm.h"
#include "ServerComm.h"
#include "ClientComm.h"
#include "AsciiFile... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.