source stringlengths 3 92 | c stringlengths 26 2.25M |
|---|---|
steepest_descent.c | #include "common_clib.h"
#include "math.h"
void sd_update_spin (double *spin, double *spin_last, double *magnetisation,
double *mxH, double *mxmxH, double *mxmxH_last, double tau,
int* pins, int n) {
// Update the field ----------------------------------------------------... |
GB_binop__pair_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... |
openmp_pi_threshold_static.c | #include <stdio.h>
#include <stdlib.h>
#include <omp.h>
int threshold_omp = 100;
void main(int argc, char *argv[]) {
int i;
int count = 0;
double x, y;
int samples, nthreads;
double pi;
samples = atoi(argv[1]);
nthreads = atoi(argv[2]);
omp_set_num_threads(nthreads);
double start = omp_get_wtime();... |
vsum.c | //
// vsum.c : Demo of multi-target mulit-source OpenMP offload
//
#include <stdio.h>
void vsum(int*a, int*b, int*c, int N){
#pragma omp target teams map(to: a[0:N],b[0:N]) map(from:c[0:N])
#pragma omp distribute parallel for
for(int i=0;i<N;i++) {
c[i]=a[i]+b[i];
}
}
|
util.h | /*
Copyright (c) 2013, Taiga Nomi
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 list of conditi... |
pi_omp.c | #include <stdio.h>
#include "random.c"
#include <stdlib.h>
#include <omp.h>
#include <time.h>
#include <math.h>
int main (int argc, char* argv[]) {
double pi;
long sum = 0;
if (argc != 3){ //Anzahl der Argumente passend pruefen.
fprintf(stderr,"Usage: ./pi_omp <n_threads> <n_samples>\n");
exit(EXIT_FAILURE);
... |
compatibility.h | // -*- C++ -*-
// Copyright (C) 2007-2020 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library 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... |
omp_hello.c | /******************************************************************************
* FILE: omp_hello.c
* DESCRIPTION:
* OpenMP Example - Hello World - C/C++ Version
* In this simple example, the master thread forks a parallel region.
* All threads in the team obtain their unique thread number and print it.
* The m... |
perftest.c | /**
* Copyright (C) Mellanox Technologies Ltd. 2001-2014. ALL RIGHTS RESERVED.
* Copyright (C) The University of Tennessee and The University
* of Tennessee Research Foundation. 2015. ALL RIGHTS RESERVED.
* Copyright (C) UT-Battelle, LLC. 2015. ALL RIGHTS RESERVED.
*
* See file LICENSE for terms.
*/
#... |
batched_matrix.h | /*
* Copyright (c) 2018, 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 ... |
image.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
rose_jacobi_float_sve.c | #include "rex_kmp.h"
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <sys/timeb.h>
#include <malloc.h>
#include <math.h>
#include <arm_sve.h>
#define REAL float
static double read_timer_ms()
{
struct timeb tm;
ftime(&tm);
return ((double )tm . time) * 1000.0 + ((double )tm . millitm);
}
/****... |
8722.c | // this source is derived from CHILL AST originally from file '/uufs/chpc.utah.edu/common/home/u1142914/lib/ytopt_vinu/polybench/polybench-code/stencils/heat-3d/kernel.c' as parsed by frontend compiler rose
void kernel_heat_3d(int tsteps, int n, double A[200 + 0][200 + 0][200 + 0], double B[200 + 0][200 + 0][200 + 0])... |
jacobi_openmp.c | #include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <math.h>
#include <omp.h>
#define MAX_ITER 10000
// Maximum value of the matrix element
#define MAX 10000
#define TOL 0.000001
// Generate a random float number with the maximum value of max
float rand_float(const int max) {
return ((float)rand(... |
DRB017-outputdep-var-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... |
ast-dump-openmp-distribute-parallel-for.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 parallel for
for (int i = 0; i < x; i++)
;
}
void test_two(int x, int y) {
#pragma omp distribute parallel for
for... |
GB_unop__signum_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://... |
project.c | //-----------------------------------------------------------------------------
// project.c
//
// Project: EPA SWMM5
// Version: 5.1
// Date: 03/19/14 (Build 5.1.000)
// 04/14/14 (Build 5.1.004)
// 09/15/14 (Build 5.1.007)
// 03/19/15 (Build 5.1.008)
// ... |
OpenMPClause.h | //===- OpenMPClause.h - Classes for OpenMP clauses --------------*- 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
//
//===---------------------------... |
serialized.c | // RUN: %libomp-compile-and-run | %sort-threads | FileCheck %s
// REQUIRES: ompt
// UNSUPPORTED: gcc-4, gcc-5, gcc-6, gcc-7
#define TEST_NEED_PRINT_FRAME_FROM_OUTLINED_FN
#include "callback.h"
#include <omp.h>
#include <math.h>
int main() {
omp_set_nested(0);
print_frame(0);
#pragma omp parallel num_threads(2)
{... |
stencil.c | /* Copyright (c) 2015 The University of Edinburgh. */
/*
* This software was developed as part of the
* EC FP7 funded project Adept (Project ID: 610490)
* www.adept-project.eu
*/
/* Licensed under the Apache License, Version 2.0 (the... |
DRB031-truedepfirstdimension-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... |
atoms-2.c | #include <omp.h>
int atom()
{
int i=0;
#pragma omp parallel
if (omp_get_thread_num() ==10 )
{
i =10;
}
return i;
}
|
GB_binop__div_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-... |
GB_binop__pow_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:... |
mxnet_op.h | /*!
* Copyright (c) 2017 by Contributors
* \file mxnet_op.h
* \brief
* \author Junyuan Xie
*/
#ifndef MXNET_OPERATOR_MXNET_OP_H_
#define MXNET_OPERATOR_MXNET_OP_H_
#include <mxnet/base.h>
#include <algorithm>
namespace mxnet {
namespace op {
namespace mxnet_op {
#ifdef __CUDA_ARCH__
__constant__ const float PI = ... |
GxB_Global_Option_get.c | //------------------------------------------------------------------------------
// GxB_Global_Option_get: get a global default option for all future matrices
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.... |
elastic_kernel_3d_so4.c | #define _POSIX_C_SOURCE 200809L
#include "stdlib.h"
#include "math.h"
#include "sys/time.h"
#include "xmmintrin.h"
#include "pmmintrin.h"
#include <stdio.h>
#include "omp.h"
#define min(a, b) (((a) < (b)) ? (a) : (b))
#define max(a, b) (((a) > (b)) ? (a) : (b))
struct dataobj
{
void *restrict data;
int *size;
in... |
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... |
QuadNode.h | /*
* QuadNode.h
*
* Created on: 21.05.2014
* Author: Moritz v. Looz (moritz.looz-corswarem@kit.edu)
*/
#ifndef QUADNODE_H_
#define QUADNODE_H_
#include <vector>
#include <algorithm>
#include <functional>
#include <assert.h>
#include "../../auxiliary/Log.h"
#include "../../auxiliary/Parallel.h"
#include "..... |
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... |
sptree.h | /*
*
* Copyright (c) 2014, Laurens van der Maaten (Delft University of Technology)
* 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 the above ... |
yescrypt-opt.c | /*-
* Copyright 2009 Colin Percival
* Copyright 2013,2014 Alexander Peslyak
* 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 the above copy... |
shear.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_unop__isfinite_bool_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... |
GB_unop__abs_uint16_uint16.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... |
rose_v1_true_l2.c | /*
* Outer loop: no dependence:
* Inner loop: loop-carried dependence
*
* final dependence graph:
* dep SgExprStatement:(a[i])[j] =(((a[i])[j - 1]) + 1);
* SgExprStatement:(a[i])[j] =(((a[i])[j - 1]) + 1);
* 2*2TRUE_DEP; commonlevel = 2 +precise CarryLevel = 1
* SgPntrArrRefExp:(a[i])[j]
* SgP... |
omp_testlock.c | #include <stdio.h>
#include <omp.h>
#include "omp_testsuite.h"
int
check_omp_testlock (FILE * logFile)
{
omp_lock_t lck;
int nr_threads_in_single = 0;
int result = 0;
int nr_iterations = 0;
int i;
omp_init_lock (&lck);
#pragma omp parallel shared(lck)
{
#pragma omp for
for (i = 0; i < LOOPCOUNT; i+... |
munit.c | /* Copyright (c) 2013-2018 Evan Nemerson <evan@nemerson.com>
*
* Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use, copy... |
GB_unop__round_fc64_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... |
GB_unaryop__ainv_fp32_fp64.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http... |
QuadNodeCartesianEuclid.h | /*
* QuadNodePolarEuclid.h
*
* Created on: 21.05.2014
* Author: Moritz v. Looz (moritz.looz-corswarem@kit.edu)
*
* Note: This is similar enough to QuadNode.h that one could merge these two classes.
*/
#ifndef QUADNODECARTESIANEUCLID_H_
#define QUADNODECARTESIANEUCLID_H_
#include <vector>
#include <algor... |
lotus85_fmt_plug.c | /*
* This software is Copyright (c) 2013 Sébastien Kaczmarek <skaczmarek@quarkslab.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.
*
* Fixed the format to crack multiple hashes + ... |
conv_dw_kernel_x86.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_unop__frexpe_fp64_fp64.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... |
GB_dense_subassign_06d_template.c | //------------------------------------------------------------------------------
// GB_dense_subassign_06d_template: C<A> = A
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX-License-Identifier: Apac... |
DRB111-linearmissing-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... |
H2ERI_matvec.c | #include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <assert.h>
#include <omp.h>
#include "H2Pack_matvec.h"
#include "H2Pack_utils.h"
#include "H2ERI_typedef.h"
#include "H2ERI_matvec.h"
#include "H2ERI_utils.h"
#include "utils.h" // In H2Pack
// Perform bi-matvec for a B or D block blk... |
MatrixProjection.c | /*
** Matrix Projection,
** Ref: Lohmann, Loktyushin, Stelzer, Scheffler (2018) bioRXiv
**
** G.Lohmann, MPI-KYB, Nov 2018
*/
#include <viaio/Vlib.h>
#include <viaio/VImage.h>
#include <viaio/mu.h>
#include <viaio/option.h>
#include <gsl/gsl_matrix.h>
#include <gsl/gsl_vector.h>
#include <gsl/gsl_errno.h>
#includ... |
matrix.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_binop__islt_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... |
openmpSample.c | //
// openmpSample.c
// pstock
//
// Created by takayoshi on 2016/01/21.
// Copyright © 2016年 pgostation. All rights reserved.
//
#include <stdio.h>
#include <sys/time.h>
#include <libiomp/omp.h>
int xmain(int argc, const char * argv[])
{
short a[60000];
struct timeval startTime, endTime;
#ifdef _OP... |
disparity_utils.h | /*
Copyright (c) 2013, Kai Klindworth
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 the above copyright notice, this
list of conditions and the... |
revert_kernel_c.c | /*Crown Copyright 2012 AWE.
*
* This file is part of CloverLeaf.
*
* CloverLeaf 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.
*
* Clo... |
GB_unop__identity_int8_int64.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... |
symmetry.h | // Copyright (c) 2013-2015 Anton Kozhevnikov, Thomas Schulthess
// 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 the above copyright notic... |
test77.c | int main() {
#pragma omp parallel
{
int i, j, k;
for (i = 0; i < 100000; i++)
for (j = 0; j < 100000; j++) {
//#pragma omp barrier
}
}
}
|
GB_unop__bnot_uint8_uint8.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://... |
templatemath.h | /*
* ******************************************************************************
* *
* *
* * 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.
* *
* * See the NOT... |
mid_point_predictorcorrector.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 Stasche... |
test.c | #include <stdio.h>
#include "../utilities/check.h"
#define N 100
int main()
{
check_offloading();
int a[N], aa[N];
int i, error = 0;
// initialize
for(i=0; i<N; i++)
aa[i] = a[i] = -1;
// offload
#pragma omp target map(tofrom: a[0:100])
{
#pragma omp teams
#pragma omp distribute simd
... |
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... |
ten_tusscher_2004_epi_S1_11.c | //Original Ten Tusscher
#include <assert.h>
#include <stdlib.h>
#include "ten_tusscher_2004_epi_S1_11.h"
GET_CELL_MODEL_DATA(init_cell_model_data) {
assert(cell_model);
if(get_initial_v)
cell_model->initial_v = INITIAL_V;
if(get_neq)
cell_model->number_of_ode_equations = NEQ;
}
//TODO... |
GB_AxB_saxpy3_template.c | //------------------------------------------------------------------------------
// GB_AxB_saxpy3_template: C=A*B, C<M>=A*B, or C<!M>=A*B via saxpy3 method
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
//... |
RingSettlementCircuit.h | #ifndef _RINGSETTLEMENTCIRCUIT_H_
#define _RINGSETTLEMENTCIRCUIT_H_
#include "Circuit.h"
#include "../Utils/Constants.h"
#include "../Utils/Data.h"
#include "../Utils/Utils.h"
#include "../Gadgets/MatchingGadgets.h"
#include "../Gadgets/AccountGadgets.h"
#include "../Gadgets/TradingHistoryGadgets.h"
#include "../Gadge... |
convolution_1x1_pack16to8.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 ... |
orphan1.c | #include <stdio.h>
#include <stdlib.h>
#include <omp.h>
#include "update.c"
double val1,val2;
int update(int n, int iter);
int main(int argc, char **argv) {
int n=10;
int max, locmax;
max = -999;
int count = 0;
#pragma omp parallel num_threads(4) default(none) shared(n, max,count) private(loc... |
kernel.cl.openmp.h | #include <brisbane/brisbane_openmp.h>
static void saxpy0(float* Z, float A, float* X, BRISBANE_OPENMP_KERNEL_ARGS) {
size_t _id;
#pragma omp parallel for shared(Z, A, X) private(_id)
BRISBANE_OPENMP_KERNEL_BEGIN
Z[_id] = A * X[_id];
BRISBANE_OPENMP_KERNEL_END
}
static void saxpy1(float* Z, float* Y, BRISBANE_... |
4.data_sharing.c | #include <stdio.h>
#include <omp.h>
/* Q1: Which is the value of x after the execution of each */
/* parallel region with different data-sharing attribute */
/* (shared, private and firstprivate)? */
/* Q2: Change the first directive to ensure that the value */
/* after the fi... |
dropout-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 ... |
polygonalsurface_texcoordparameterization_accel_ops.h | #ifdef _MSC_VER
#define PSTCPAOPS_INLINE __inline
#include <float.h>
#define PSTCPAOPS_ISNAN _isnan
#define PSTCPAOPS_ALLOCA _alloca
#else
#define PSTCPAOPS_INLINE inline
#define PSTCPAOPS_ISNAN isnan
#define PSTCPAOPS_ALLOCA alloca
#endif
static PSTCPAOPS_INLINE size_t enclosed_or_intersecting_polygons_2d_c(int32_t... |
9741.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... |
convolutiondepthwise_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 ... |
pr89235.c | /* { dg-require-effective-target fopenmp } */
/* { dg-options "-S -fopenmp -fsave-optimization-record -ftree-parallelize-loops=2 -fno-tree-vectorize --param ggc-min-expand=0" } */
int a1, dr, xm, ly, zb, g9, il;
long int wt;
unsigned int mq;
int br, e7, rm, t4, jb, ry;
int
fi (void);
int
z5 (int fl)
{
while (br <... |
radix_hash_map.h | #pragma once
#include <new>
#include <malloc.h>
#include "omp.h"
#include <util/search_util.h>
inline uint32_t get_log_size(int x) {
int cnt = 0;
for (; x > 0; cnt++) {
x >>= 1;
}
return cnt;
}
inline uint32_t get_part_size(int i) {
return i == 0 ? 0 : 1 << (get_log_size(i) - 1);
}
class... |
ICP.h | ///////////////////////////////////////////////////////////////////////////////
/// "Sparse Iterative Closest Point"
/// by Sofien Bouaziz, Andrea Tagliasacchi, Mark Pauly
/// Copyright (C) 2013 LGG, EPFL
///////////////////////////////////////////////////////////////////////////////
/// 1) This file contains ... |
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:... |
OpenMP_galaxyproblem.c |
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <sys/time.h>
float *real_rasc, *real_decl, *rand_rasc, *rand_decl;
float pif;
long int MemoryAllocatedCPU = 0L;
int main(int argc, char* argv[])
{
int parseargs_readinput(int argc, char *argv[]);
struct timeval _ttime;
struct timezone... |
minimize-whitespace.c | // RUN: %clang_cc1 -fminimize-whitespace -E %s 2>&1 | FileCheck %s --strict-whitespace --check-prefix=MINCOL
// RUN: %clang_cc1 -fminimize-whitespace -E -C %s 2>&1 | FileCheck %s --strict-whitespace --check-prefix=MINCCOL
// RUN: %clang_cc1 -fminimize-whitespace -E -P %s 2>&1 | FileCheck %s --strict-whitespace --check-... |
GB_unaryop__abs_uint64_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... |
todo.c | // Calculate the maximum score attainable from a state in num turns
// May overestimate
// XXX: Sometimes underestimates. Fix that!
int max_score_simple(state *s, int num_turns) {
int bins[NUM_COLORS - 1];
for (int k = 0; k < NUM_COLORS - 1; ++k) {
puyos_t component[2] = {s->floors[0][k], s->floors[1][... |
inv.c | /* Copyright (c) 2016 Drew Schmidt
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 the above copyright notice,
this list of conditions ... |
conv_dw_kernel_fp16_arm82.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... |
task1.c | #include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <omp.h>
#define ITERATIONS 200000000
/*
kompiliert mit:
gcc -std=c99 -fopenmp -O3 -o task1 task1.c
(module load gcc/8.2.0)
ausgeführt als Job mit:
export OMP_NUM_THREADS=4
export OMP_PLACES=cores
export OMP_PROC_BIN=close
./task1
export OMP_... |
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_int16_fp64.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_unaryop__abs_fp32_uint8.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http... |
outofbounds-var-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... |
omp-low.c | /* Lowering pass for OMP directives. Converts OMP directives into explicit
calls to the runtime library (libgomp), data marshalling to implement data
sharing and copying clauses, offloading to accelerators, and more.
Contributed by Diego Novillo <dnovillo@redhat.com>
Copyright (C) 2005-2017 Free Software... |
DRACC_OMP_011_Counter_wrong_critical_Inter_yes.c | /*
Concurrent access on a counter with the wrong lock, by utilising OpenMP critical directives. Atomicity Violation.
Two locks are used to ensure that addition and substraction cannot be interrupted by themselfes on other teams.
Although they are able to interrupt each other leading to a wrong result. Inter Region.
*... |
wyhash.h | /* Author: Wang Yi <godspeed_china@yeah.net> */
#ifndef wyhash_version_1
#define wyhash_version_1
#include <string.h>
#include <math.h>
#if defined(_MSC_VER) && defined(_M_X64)
#include <intrin.h>
#pragma intrinsic(_umul128)
#endif
const unsigned long long _wyp0=0xa0761d6478bd642full, _wyp1=0xe7037ed1a0b428dbull, _wy... |
main.c | #include <getopt.h>
#include <omp.h>
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <math.h>
#include <limits.h>
typedef double **matrix_t;
struct qr_result_t
{
int q_size;
matrix_t q;
int r_size;
matrix_t r;
};
struct arguments_t
{
int size;
int max_number;
int display... |
pooling.c | #include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include <string.h>
#include <float.h>
#define DTYPE float
// define structures
typedef struct layer
{
char *name;
struct layer* next;
// basic
DTYPE *input;
DTYPE *output;
int input_count;
int ndim;
int *input_shape;
int ... |
GB_subassign_03.c | //------------------------------------------------------------------------------
// GB_subassign_03: C(I,J) += scalar ; using S
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://suitesparse.com Se... |
bt-brisbane.c | //-------------------------------------------------------------------------//
// //
// This benchmark is a serial C version of the NPB BT code. This C //
// version is developed by the Center for Manycore Programming at Seoul //
// Nati... |
factorize_gmp_primes.c | /*****************************************************************************************************************
* Compiling: mpicc fattor.c -lgmp -fopenmp -o fattor
* Running: mpirun -n PROCNUM --bind-to none fattor NUMBER
* Note: PROCNUM is the number of processes that will be ran, and it must be >=2, NUMBER is the... |
GB_unaryop__abs_int16_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... |
DRB008-indirectaccess4-orig-yes.c | /*
Copyright (C) 1991-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it andor
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the L... |
Example_target_unstructured_data.1.c | /*
* @@name: target-unstructured-data.1.c
* @@type: C
* @@compilable: yes
* @@linkable: no
* @@expect: success
*/
#include <stdlib.h>
typedef struct {
double *A;
int N;
} Matrix;
void init_matrix(Matrix *mat, int n)
{
mat->A = (double *)malloc(n*sizeof(double));
mat->N = n;
#prag... |
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... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.