Align with HC Next.

Dieser Commit ist enthalten in:
Alex Voicu
2018-09-17 11:50:29 +03:00
Ursprung cb348421d7
Commit c6720e882b
15 geänderte Dateien mit 149 neuen und 51 gelöschten Zeilen
@@ -28,6 +28,7 @@ THE SOFTWARE.
#include <hip/hip_runtime.h>
#include <hip/device_functions.h>
#include <hip/math_functions.h>
#include "test_common.h"
#pragma GCC diagnostic ignored "-Wall"
+1
Datei anzeigen
@@ -27,6 +27,7 @@ THE SOFTWARE.
*/
#include "test_common.h"
#include <hip/math_functions.h>
#include <hip/device_functions.h>
#define LEN 512
@@ -31,6 +31,10 @@ THE SOFTWARE.
#include <hip/device_functions.h>
#include "test_common.h"
#include <algorithm>
using namespace std;
#pragma GCC diagnostic ignored "-Wall"
#pragma clang diagnostic ignored "-Wunused-variable"
@@ -27,6 +27,7 @@ THE SOFTWARE.
*/
#include "hip/hip_runtime.h"
#include "hip/math_functions.h"
#include "test_common.h"
#if __HIP_ARCH_GFX803__ || __HIP_ARCH_GFX900__ || __HIP_ARCH_GFX906__
@@ -215,6 +215,7 @@ template<
typename T,
typename enable_if<
is_same<T, int>{} || is_same<T, unsigned int>{}>::type* = nullptr>
__device__
void testKernelSub(T* g_odata) {
// Atomic subtraction (final should be 0)
atomicSub(&g_odata[1], 10);
@@ -27,6 +27,8 @@ THE SOFTWARE.
#include <hip/hip_runtime.h>
#include <hip/device_functions.h>
#include <hip/math_functions.h>
#include "test_common.h"
#pragma GCC diagnostic ignored "-Wall"
+3 -1
Datei anzeigen
@@ -28,9 +28,11 @@ THE SOFTWARE.
#include <hip/hip_runtime_api.h>
#include <hip/hip_runtime.h>
#include <iostream>
#include "test_common.h"
#include <hip/device_functions.h>
#include <hip/math_functions.h>
#include <iostream>
#define LEN 512
#define SIZE LEN << 2
+2 -6
Datei anzeigen
@@ -31,7 +31,7 @@ THE SOFTWARE.
#include <test_common.h>
#ifdef __HCC__
#include <amp.h>
#include <hc.hpp>
#endif
// cudaA
@@ -93,11 +93,7 @@ __global__ void vectorADD(const hipLaunchParm lp, T __restrict__* A_d, T* B_d, T
int b = threadIdx.x;
int c;
// TODO - move to HIP atomics when ready.
concurrency ::atomic_fetch_add(&c, b);
// Concurrency::atomic_add_unsigned (&x, a);
// concurrency ::atomic_add_ (x, a);
atomicAdd(&c, b);
#endif
__syncthreads();
@@ -26,11 +26,15 @@ THE SOFTWARE.
#include "hip/hip_runtime.h"
#include "test_common.h"
#include <algorithm>
#include <vector>
unsigned p_streams = 16;
int p_repeat = 10;
int p_db = 0;
using namespace std;
template <typename T>
__global__ void vectorADDRepeat(hipLaunchParm lp, const T* A_d, const T* B_d, T* C_d, size_t NELEM,