source
stringlengths
3
92
c
stringlengths
26
2.25M
XSHA_fmt_plug.c
/* * This file is part of John the Ripper password cracker, * Copyright (c) 2008,2011 by Solar Designer * * Intrinsics support added by magnum 2011. */ #if FMT_EXTERNS_H extern struct fmt_main fmt_XSHA; #elif FMT_REGISTERS_H john_register_one(&fmt_XSHA); #else #include <string.h> #include "arch.h" #ifdef SIMD_...
kmeans.c
/** * @file kmeans.c * @author Sylvan Brocard (sbrocard@upmem.com) * @brief Main file for the KMeans algorithm. */ #include <dpu.h> #include <dpu_log.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <limits.h> #include <math.h> #include <fcntl.h> #include <omp.h> #include <getopt.h> #include ...
par_multi_interp.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) **************************************...
cpu_rnnt.h
#pragma once #include <tuple> #include <cmath> #include <cstring> #include <limits> #include <algorithm> #include <numeric> #if !defined(RNNT_DISABLE_OMP) && !defined(APPLE) #include <omp.h> #endif #include "rnnt.h" #include "rnnt_helper.h" namespace warp_rnnt { template<typename ProbT> class CpuRNNT { public: ...
rad_utils.c
/****************************************************************************** * * * RAD_UTILS.C * * * ...
IcgNablaT.c
// Copyright (C) 2016 Gernot Riegler // Institute for Computer Graphics and Vision (ICG) // Graz University of Technology (TU GRAZ) // 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 m...
residual_based_adjoint_bossak_scheme.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: // #if !defined(KRATOS_RESIDUAL_...
Mod-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...
builder.h
// Copyright (c) 2015, The Regents of the University of California (Regents) // See LICENSE.txt for license details #ifndef BUILDER_H_ #define BUILDER_H_ #include <algorithm> #include <cinttypes> #include <fstream> #include <functional> #include <type_traits> #include <utility> #include "command_line.h" #include "ge...
detection.c
//for ssd output detection fprop //conf is a matrix with len*4*bs //loc is a matrix with len*num_class*bs //result is a matrix with bs #include <stdlib.h> #include <math.h> #include <stdio.h> #include <stdlib.h> #include <mkl_trans.h> #include <omp.h> //self.bbox_transform_inv(prior_boxes, loc_view[:, :, k], self.prop...
utils.h
/** * * @file utils.h * * @copyright 2018 King Abdullah University of Science and Technology (KAUST). * All rights reserved. * * @author Mustafa Abduljabbar [mustafa.abduljabbar@kaust.edu.sa] and Mohammed Al Farhan [mohammed.farhan@kaust.edu.sa]. * **/ #ifndef UTILS #define UTILS #include ...
test5.c
typedef signed char __int8_t; typedef unsigned char __uint8_t; typedef short __int16_t; typedef unsigned short __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; typedef long long __int64_t; typedef unsigned long long __uint64_t; typedef long __darwin_intptr_t; typedef unsigned int __darwin_natural_t; ...
core_sgemm.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_zgemm.c, normal z -> s, Fri Sep 28 17:38:18 2018 * **/ #include <plasma_core_blas.h> #include "plas...
GB_binop__max_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...
target_update-1.c
/* { dg-do run } */ #include <stdlib.h> const int MAX = 1800; void check (int *a, int *b, int N) { int i; for (i = 0; i < N; i++) if (a[i] != b[i]) abort (); } void init (int *a1, int *a2, int N) { int i, s = -1; for (i = 0; i < N; i++) { a1[i] = s; a2[i] = i; s = -s; } }...
DRB050-functionparameter-orig-no.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...
rawBLAKE2_512_fmt_plug.c
/* * This file is part of John the Ripper password cracker, * Copyright (c) 2012 by Solar Designer * based on rawMD4_fmt.c code, with trivial changes by groszek. * * Re-used for BLAKE2 by Dhiru Kholia (dhiru at openwall.com) */ #if FMT_EXTERNS_H extern struct fmt_main fmt_rawBLAKE2; #elif FMT_REGISTERS_H john_re...
zipmonster_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 ...
GB_unop__identity_int32_int8.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-Li...
pacset_gb_regressor.h
#ifndef PACSET_GB_REG #define PACSET_GB_REG #include <vector> #include <unordered_set> #include <fstream> #include "pacset_base_model.h" #include "packer.h" #include "config.h" #include "json_reader.h" #include "utils.h" #include "node.h" #include "MemoryMapped.h" #define NUM_FILES 10 #define BLOCK_LOGGING 1 #define ...
vector_batched.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) **************************************...
omp-maxof-elements-critical.c
/*********************************************************************************** Example 3.1 : omp-maxof-elements-critical.c Objective : Write an OpenMP program to print Largest of an element in an array This example demonstrates the use of omp_critical se...
solve.c
#include <stdio.h> #include <stdarg.h> #include <string.h> #include <inttypes.h> #include <stdlib.h> #include <sys/time.h> #include <omp.h> #define N_MAX_MOVES 255 // max solution moves (using uint8_t, 0 - zero moves, 255 - no moves) #define N_MAX_MS_MOVES 31 // max move-set moves (+1 to store length) #define N_MOVES_...
maxpool_with_mask.h
// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. /* * Highly specialized code, only works for TP3 L1 */ #pragma once #include "core/common/common.h" #include "core/framework/op_kernel.h" #include "core/framework/tensor.h" #include "core/providers/cpu/nn/pool_base.h" nam...
edge_vol_int.c
/****************************************************************************** ** Copyright (c) 2016-2019, Intel Corporation ** ** All rights reserved. ** ** ** ...
GB_unaryop__one_uint64_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...
parallel_reduction_messages.c
// RUN: %clang_cc1 -verify -fopenmp -fopenmp-version=50 -ferror-limit 150 -o - %s int incomplete[]; void test(int *p) { int a; #pragma omp parallel reduction( // expected-error {{expected identifier}} expected-error {{expected ')'}} expected-warning {{missing ':' after reduction identifier - ignoring}} expected-not...
cache.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
atax.c
/** * atax.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...
main.c
/// /// @copyright Copyright (c) 2016-, Issam SAID <said.issam@gmail.com> /// 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 abov...
HashmapCPU.h
// ---------------------------------------------------------------------------- // - Open3D: www.open3d.org - // ---------------------------------------------------------------------------- // The MIT License (MIT) // // Copyright (c) 2018 www.open3d.org // // Permissio...
mlp_mnist_bf16_avx512_numa.c
/****************************************************************************** * Copyright (c) Intel Corporation - All rights reserved. * * This file is part of the LIBXSMM library. * * * ...
convolution_1x1.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 ...
cg.c
#include <stdio.h> #include <stdlib.h> #include <math.h> #include "globals.h" #include "randdp.h" #include "timers.h" #include <omp.h> //--------------------------------------------------------------------- #define CACHE_LINE_SIZE_PAD 16 #define INT_PAD_SIZE CACHE_LINE_SIZE_PAD/sizeof(int) #define DOUBLE_PAD_SIZE CA...
CLHelper.h
//------------------------------------------ //--cambine:helper function for OpenCL //--programmer: Jianbin Fang //--date: 27/12/2010 //------------------------------------------ #ifndef _CL_HELPER_ #define _CL_HELPER_ #include <CL/cl.h> #include <fstream> #include <iostream> #include <string> #include <ve...
aux_functions.c
#include "aux_functions.h" #include "rt/rt_alloc.h" #define ROUND(num) ((num - floorf(num) > 0.5f) ? ceilf(num) : floorf(num)) int max_dist_hamm(int distances[classes]){ /************************************************************************* DESCRIPTION: computes the maximum Hamming Distance. INPUTS: distan...
fused_rowwise_nbitfake_conversion_ops.h
#pragma once #ifdef _OPENMP #include <omp.h> #endif #include "caffe2/core/context.h" #include "caffe2/core/logging.h" #include "caffe2/core/operator.h" #include "caffe2/operators/reducer_functors.h" #include "caffe2/utils/math.h" namespace caffe2 { namespace internal { inline bool is_little_endian() { constexpr s...
collision_matrix.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...
cgetri.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/compute/zgetri.c, normal z -> c, Fri Sep 28 17:38:06 2018 * **/ #include "plasma.h" #include "plasma_async.h" #inc...
otfft_mixedradix.h
// Copyright (c) 2015, OK おじさん(岡久卓也) // Copyright (c) 2015, OK Ojisan(Takuya OKAHISA) // Copyright (c) 2017 to the present, DEWETRON GmbH // OTFFT Implementation Version 9.5 // based on Stockham FFT algorithm // from OK Ojisan(Takuya OKAHISA), source: http://www.moon.sannet.ne.jp/okahisa/stockham/stockham.html #pragma...
GB_unop__identity_int32_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...
zmath.c
/* Some simple mathematical functions. Don't look for some logic in the function names :-) */ #include "zmath.h" #include <stdlib.h> #include <string.h> /* ******* Gestion des matrices 4x4 ****** */ void gl_M4_Id(M4* a) { /* GLint i, j; #pragma omp simd collapse(2) for (i = 0; i < 4; i++) for (j = 0; j ...
GB_binop__div_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...
ZMQComm.h
/*! @brief Flag for checking if this header has already been included. */ #ifndef YGGZMQCOMM_H_ #define YGGZMQCOMM_H_ #include <CommBase.h> #include "../datatypes/datatypes.h" #ifdef ZMQINSTALLED #include <czmq.h> #endif #ifdef __cplusplus /* If this is a C++ compiler, use C linkage */ extern "C" { #endif #ifdef ZM...
ccsd_grad.c
/* * Author: Qiming Sun <osirpt.sun@gmail.com> * */ #include <stdlib.h> #include <string.h> //#include <omp.h> #include "config.h" #include "vhf/fblas.h" #include "ao2mo/nr_ao2mo.h" #define OUTPUTIJ 1 #define INPUT_IJ 2 /* * a = reduce(numpy.dot, (mo_coeff, vin, mo_coeff.T)) * numpy.tril(a + a.T) ...
3d7pt_var.c
/* * Order-1, 3D 7 point stencil with variable 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) > (b) ? a : b) #...
parallelfmm.h
#include "serialfmm.h" class ParallelFMM : public SerialFMM { private: int EXTERNAL; MPI_Request *requests; #if PRINT_COMM std::ofstream fid; #endif void gatherMultipoles() { int i = getGlobKey(IX[gatherLevel],gatherLevel) + globLevelOffset[gatherLevel]; for_m sendMultipole[0][m] = globMultipole[i][m]...
openmp-ex09.c
#include <stdio.h> #include <unistd.h> #include <omp.h> int main(void) { int num_threads, my_thread; num_threads = omp_get_num_threads(); my_thread = omp_get_thread_num(); printf ("\"You're all individuals!\" said %d of %d.\n", my_thread, num_threads); /* we can initialize the variables with the shadowed...
scramble_edges.c
/* Copyright (C) 2010 The Trustees of Indiana University. */ /* */ /* Use, modification and distribution is subject to the Boost Software */ /* License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at */ /* http:...
OMP-Jacobi-2D-Sliced-Diamond-Tiling.test.c
// COMPILE-TIME OPTIONS: // BOUNDING_BOX_FOR_PARALLEL_LOOPS (also automatically on if PARALLEL) --- execute extra iterations of parallel loops to un-confuse OMP // PARALLEL use bounding box (above) and #pragma omp parallel on appropriate for loops // CHATTY pr...
linux_printaff.c
#include "typesf2c.h" #ifndef linux Integer linux_printaff_(){ return (Integer) 0; } int linux_setffaff_(){ return (Integer) 0; } #else #ifdef MPI #include <mpi.h> #else #include "ga.h" #include "macdecls.h" #endif #define __USE_GNU #include <stdio.h> #include <unistd.h> #include <string.h> #include <sched.h> #ifd...
PhysicManager.h
/* * Runs simulation of rigidbodies (should be independent of everything non physic related) */ #pragma #include <assert.h> #include <math.h> #include <glm/glm.hpp> #include <glm/gtc/matrix_transform.hpp> #include <glm/gtc/type_ptr.hpp> using namespace glm; #include <vector> #include <list> #include <unordered_map>...
solve.c
// solve.c - finds the optimal route for a level #include "chore.h" static _Atomic i32 simulated_beats; static _Atomic i32 best_cost; static GameState initial_state; static i32 initial_cost; static i32 initial_distance; void animation(UNUSED Animation id, UNUSED Coords pos, UNUSED Coords dir) { } // Returns the co...
SceneGraphConverterOCC.h
/* -*-c++-*- IfcQuery www.ifcquery.com * MIT License Copyright (c) 2017 Fabian Gerold 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 ...
DRB113-default-orig-no.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...
rawSHA1_ng_fmt_plug.c
// // Alternative SSE2 optimised raw SHA-1 implementation for John The Ripper. // // This plugin requires -msse4 in CFLAGS. // // Copyright (C) 2012 Tavis Ormandy <taviso@cmpxchg8b.com> // Copyright (c) 2015 magnum (AVX2/AVX512 support) // // This library is free software; you can redistribute it and/or // modify it un...
scheduling_time_cluster.h
/* Copyright (c) 2020, VSB - Technical University of Ostrava and Graz 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: * Redistributions of source code must retain the above copyr...
matmult-omp.c
/* * Copyright (c) 2014-2016, Sebastien Vincent * * Distributed under the terms of the BSD 3-clause License. * See the LICENSE file for details. */ /** * \file matmult-omp.c * \brief Matrix multiplication in C/OpenMP. * \author Sebastien Vincent * \date 2014-2016 */ #include <stdio.h> #include <stdlib.h> #i...
execution_log.h
/* Algorithm for Steiner Problem in Graphs Copyright (c) Microsoft Corporation All rights reserved. MIT License 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, in...
softmax-inl.h
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
syrk.c
/** * syrk.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...
rawMD5flat_fmt_plug.c
/* * Raw-MD5 "flat intrinsics" experimental format * * This software is Copyright (c) 2011-2015 magnum, * 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. * */ #include "arch.h" #if US...
3d7pt_var.lbpar.c
#include <omp.h> #include <math.h> #define ceild(n,d) ceil(((double)(n))/((double)(d))) #define floord(n,d) floor(((double)(n))/((double)(d))) #define max(x,y) ((x) > (y)? (x) : (y)) #define min(x,y) ((x) < (y)? (x) : (y)) /* * Order-1, 3D 7 point stencil with variable coefficients * Adapted from PLUTO and Po...
rnn_impl.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 ...
3d.np.c
#include <stdio.h> #include <stdlib.h> #include <sys/time.h> #include <omp.h> #define ceild(n,d) ceil(((double)(n))/((double)(d))) #define max(x,y) ((x) > (y)? (x) : (y)) #define min(x,y) ((x) < (y)? (x) : (y)) #define myabs(x,y) (((x) > (y))? ((x)-(y)) : ((y)-(x))) #if !defined(point) #define point 7 #endif...
HYPRE_struct_pcg.c
/*BHEADER********************************************************************** * Copyright (c) 2008, Lawrence Livermore National Security, LLC. * Produced at the Lawrence Livermore National Laboratory. * This file is part of HYPRE. See file COPYRIGHT for details. * * HYPRE is free software; you can redistribute...
nsgaii.h
#if defined(__posix) || defined(__unix) || defined(__linux) || defined(__APPLE__) // #pragma GCC diagnostic ignored "-Wreorder" // #pragma GCC diagnostic ignored "-Wunused-variable" #pragma GCC diagnostic ignored "-Wformat=" #pragma GCC diagnostic ignored "-Wsign-compare" #endif #ifndef __NSGAII_H__ #define __NS...
ZMQComm.h
/*! @brief Flag for checking if this header has already been included. */ #ifndef YGGZMQCOMM_H_ #define YGGZMQCOMM_H_ #include <CommBase.h> #include "../datatypes/datatypes.h" #ifdef ZMQINSTALLED #include <czmq.h> #endif #ifdef __cplusplus /* If this is a C++ compiler, use C linkage */ extern "C" { #endif #ifdef ZM...
GB_unaryop__identity_uint16_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...
fclaw2d_domain.c
/* Copyright (c) 2012 Carsten Burstedde, Donna Calhoun 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 conditions a...
workgroup_size.c
#include <stdio.h> #include <omp.h> int main() { int num_threads = 0; int N = 100000; int a[N]; int b[N]; int c[N]; int i; #pragma omp target map(from: num_threads) { num_threads = omp_get_num_threads(); } printf("num_threads = %d\n", num_threads); for (i=0; i<N; i++) a[i]=0; for (...
mediancut.c
/* ** © 2009-2018 by Kornel Lesiński. ** © 1989, 1991 by Jef Poskanzer. ** © 1997, 2000, 2002 by Greg Roelofs; based on an idea by Stefan Schneider. ** ** See COPYRIGHT file for license. */ #include <stdlib.h> #include <stddef.h> #include "libimagequant.h" #include "pam.h" #include "mediancut.h" #define index_of_cha...
convolution_omp.c
// // convolution.c // // Base code created by Josep Lluis Lerida on 11/03/15. // Base code updated by Vitor da Silva on 17/04/2021 // // Created by Josep Lluis Lerida on 11/03/15. // Updated by Vitor da Silva on 17/04/2021 // OMP solution implemented by Albert Pérez & Francesc Contreras 17/05/2021 // // This progra...
cp-tree.h
/* Definitions for C++ parsing and type checking. Copyright (C) 1987-2020 Free Software Foundation, Inc. Contributed by Michael Tiemann (tiemann@cygnus.com) This file is part of GCC. GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by ...
mandel_avx.c
#include <immintrin.h> #include "mandel.h" void mandel_avx(unsigned char *image, const struct spec *s) { __m256 xmin = _mm256_set1_ps(s->xlim[0]); __m256 ymin = _mm256_set1_ps(s->ylim[0]); __m256 xscale = _mm256_set1_ps((s->xlim[1] - s->xlim[0]) / s->width); __m256 yscale = _mm256_set1_ps((s->ylim[1] -...
SampleAlongProbes.h
/* * SampleAlongProbes.h * Copyright (C) 2009-2017 by MegaMol Team * Alle Rechte vorbehalten. */ #ifndef SAMPLE_ALONG_PROBES_H_INCLUDED #define SAMPLE_ALONG_PROBES_H_INCLUDED #include "mmcore/CalleeSlot.h" #include "mmcore/CallerSlot.h" #include "mmcore/Module.h" #include "ProbeCollection.h" #include "kdtree.h"...
GB_binop__pair_fp32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
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...
workgroup_size_option2.c
#include <stdio.h> #include <omp.h> int main() { int num_threads = 0; int N = 100000; int a[N]; int b[N]; int c[N]; int i; #pragma omp target map(from: num_threads) { num_threads = omp_get_num_threads(); } printf("num_threads = %d\n", num_threads); for (i=0; i<N; i++) a[i]=0; for (...
update_ops_matrix_diagonal_multi.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <assert.h> #include "constant.h" #include "update_ops.h" #include "utility.h" #ifdef _OPENMP #include <omp.h> #endif #ifdef _USE_SIMD #ifdef _MSC_VER #include <intrin.h> #else #include <x86intrin.h> #endif #endif void multi_qubit_diagonal_matrix_ga...
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...
ten_tusscher_2004_epi_S1.c
//Original Ten Tusscher #include <assert.h> #include <stdlib.h> #include "ten_tusscher_2004_epi_S1.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: th...
monotonic-1.c
/* { dg-do run } */ #ifndef MONOTONIC_TYPE #include <omp.h> #include <stdlib.h> #define MONOTONIC_TYPE int #define MONOTONIC_UNDEF -1 #define MONOTONIC_END(n) n #endif int main () { MONOTONIC_TYPE i; #pragma omp parallel { int cnt = omp_get_num_threads (); int thr = omp_get_thread_num (); MONOTONIC_...
GB_unop__erfc_fp32_fp32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http://...
composite.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
convolution_2x2.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 ...
divsufsort.c
/* * divsufsort.c for libdivsufsort-lite * Copyright (c) 2003-2008 Yuta Mori All Rights Reserved. * * 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 wit...
GB_Matrix_diag.c
//------------------------------------------------------------------------------ // GB_Matrix_diag: construct a diagonal matrix from a vector //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-License-...
polybench.c
/** * This version is stamped on May 10, 2016 * * Contact: * Louis-Noel Pouchet <pouchet.ohio-state.edu> * Tomofumi Yuki <tomofumi.yuki.fr> * * Web address: http://polybench.sourceforge.net */ /* polybench.c: this file is part of PolyBench/C */ #include <stdio.h> #include <string.h> #include <stdlib.h> #in...
enhance.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
zmath.c
/* Some simple mathematical functions. Don't look for some logic in the function names :-) */ #include "zmath.h" #include <stdlib.h> #include <string.h> /* ******* Gestion des matrices 4x4 ****** */ void gl_M4_Id(M4* a) { /* GLint i, j; #pragma omp simd collapse(2) for (i = 0; i < 4; i++) for (j = 0; j ...
Moments.h
#ifndef MOMENTS_H #define MOMENTS_H #include "../ImageChannel.h" #include "../../geo/Point2.h" #include "../../geo/Size2.h" namespace K { class Moments { public: template <int p, int q> static float get(const ImageChannel& img, const Point2i center, const Size2i window) { const int x1 = - halfL(window.w); ...
3D.c
#include <stdio.h> #include <time.h> #include <assert.h> #include <stdlib.h> #include <math.h> #include <sys/time.h> #include <string.h> #define STR_SIZE (256) #define MAX_PD (3.0e6) /* required precision in degrees */ #define PRECISION 0.001 #define SPEC_HEAT_SI 1.75e6 #define K_SI 100 /* capacitance fitting factor...
simd-2.c
/* { dg-do run { target vect_simd_clones } } */ /* { dg-additional-options "-msse2" { target sse2_runtime } } */ /* { dg-additional-options "-mavx" { target avx_runtime } } */ #define N 100 #define EPS 0.0000000000000001 #include <stdlib.h> void init(double *a, double *a_ref, double *b, int n) { int i; for ( i...
test30.c
#include<stdio.h> #include<omp.h> int g = 10; void foo() { int x; x = 10; } int main () { int x = 0; #pragma omp parallel private(x) { int i; i = x + i + g; foo(); for (i = 0; i < 4; i++) { #pragma omp critical { printf("Iteration %d by Thread %d\n", i, omp_get_thread_num()); } #pragma omp single ...
distort.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
valid.res9.src.h
#pragma once #include "ukr.h" #include "omp.h" #include "transpose.h" #include "gen_ukr_A6B2gemm_1_256_14_14_256_3_3.h" #include "gen_ukr_A4B2gemm_1_256_14_14_256_3_3.h" void testrun(float* A ,float*B, float*C, float*oriB ){ int tid = omp_get_thread_num(); int Nx = 14; int Ny = 14; int Nh = 3; long long...
distributiongenerator.h
//================================================================================== // BSD 2-Clause License // // Copyright (c) 2014-2022, NJIT, Duality Technologies Inc. and other contributors // // All rights reserved. // // Author TPOC: contact@openfhe.org // // Redistribution and use in source and binary forms, wi...
pi.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> int main( int argc, char **argv ) { long i, num_steps = 1000000000; double step, x, sum, pi, taken; double start, stop; int num_threads = omp_get_max_threads(); if (argc > 1) { num_steps = atol(argv[1]); } printf("Calculating PI...
testrun_openmp.h
/*** ------------------------------------------------------------------------ Copyright 2017 Markus Toepfer 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 ...