system stringclasses 7
values | input stringlengths 10 94.5k | output stringlengths 14 55.5k |
|---|---|---|
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include <iostream>
using namespace std;
// Derived class
class Rectangle
{
public:
Rectangle()
{
width = (int *)malloc(sizeof(int));
height = (int *)malloc(sizeof(int));
}
int getArea()
{
return (*width * *height);
}
int* width;
int* height;
};
// Base class
class Shape
{
public:
Shape... | .text
.file "class_test.hip"
# Start of file scope inline assembly
.globl _ZSt21ios_base_library_initv
# End of file scope inline assembly
.globl main # -- Begin function main
.p2align 4, 0x90
.type main,@function
m... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80 | .text
.p2alignl 7, 3214868480
.fill 96, 4, 3214868480
.type __hip_cuid_,@object
.section .bss,"aw",@nobits
.globl __hip_cuid_
__hip_cuid_:
.byte 0
.size __hip_cuid_, 1
.ident "AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_000255e8_00000000-6_class_test.cudafe1.cpp"
.text
#APP
.globl _ZSt21ios_base_library_initv
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB3679:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cud... | .text
.file "class_test.hip"
# Start of file scope inline assembly
.globl _ZSt21ios_base_library_initv
# End of file scope inline assembly
.globl main # -- Begin function main
.p2align 4, 0x90
.type main,@function
m... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | //Based on the work of Andrew Krepps
// C
#include <stdio.h>
// C++
#include <chrono>
#include <functional>
#include <initializer_list>
#include <vector>
///////////////////////////////////////////////////////////////////////////////
// Constants
/////////////////////////////////////////////////////////////////////////... | code for sm_80
Function : _Z6moduloPKiS0_Pi
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x0000000000007919 */
/* 0x000e22000... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | //Based on the work of Andrew Krepps
// C
#include <stdio.h>
// C++
#include <chrono>
#include <functional>
#include <initializer_list>
#include <vector>
///////////////////////////////////////////////////////////////////////////////
// Constants
/////////////////////////////////////////////////////////////////////////... | .file "tmpxft_00067499_00000000-6_assignment.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZNSt17_Function_handlerIFvvEZ4mainEUlvE_E10_M_managerERSt9_Any_dataRKS3_St18_Manager_operation, @function
_ZNSt17_Function_handlerIFvvEZ4mainEUlvE_E10_M_managerERSt9_Any_dataRKS3_St18_Manager_operation:
.LFB4160:
.cfi_startproc
endbr64
... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | //Based on the work of Andrew Krepps
// C
#include <stdio.h>
// C++
#include <chrono>
#include <functional>
#include <initializer_list>
#include <vector>
///////////////////////////////////////////////////////////////////////////////
// Constants
/////////////////////////////////////////////////////////////////////////... | //Based on the work of Andrew Krepps
// C
#include <hip/hip_runtime.h>
#include <stdio.h>
// C++
#include <chrono>
#include <functional>
#include <initializer_list>
#include <vector>
///////////////////////////////////////////////////////////////////////////////
// Constants
////////////////////////////////////////////... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | //Based on the work of Andrew Krepps
// C
#include <hip/hip_runtime.h>
#include <stdio.h>
// C++
#include <chrono>
#include <functional>
#include <initializer_list>
#include <vector>
///////////////////////////////////////////////////////////////////////////////
// Constants
////////////////////////////////////////////... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z3addPKiS0_Pi
.globl _Z3addPKiS0_Pi
.p2align 8
.type _Z3addPKiS0_Pi,@function
_Z3addPKiS0_Pi:
s_clause 0x2
s_load_b32 s2, s[0:1], 0x24
s_load_b128 s[4:7], s[0:1], 0x0
s_load_b64 s[0:1], s[0:1], 0x10
s_waitcnt lgkmcnt(0)
s_a... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | //Based on the work of Andrew Krepps
// C
#include <hip/hip_runtime.h>
#include <stdio.h>
// C++
#include <chrono>
#include <functional>
#include <initializer_list>
#include <vector>
///////////////////////////////////////////////////////////////////////////////
// Constants
////////////////////////////////////////////... | .text
.file "assignment.hip"
.globl _Z9randRangeii # -- Begin function _Z9randRangeii
.p2align 4, 0x90
.type _Z9randRangeii,@function
_Z9randRangeii: # @_Z9randRangeii
.cfi_startproc
# %bb.0:
pushq %rbp
.cfi_def_cfa_offset 16
pushq %rbx
.cfi_def_cfa_offset 24
pushq %rax
.cfi_def... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z6moduloPKiS0_Pi
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x0000000000007919 */
/* 0x000e22000... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z3addPKiS0_Pi
.globl _Z3addPKiS0_Pi
.p2align 8
.type _Z3addPKiS0_Pi,@function
_Z3addPKiS0_Pi:
s_clause 0x2
s_load_b32 s2, s[0:1], 0x24
s_load_b128 s[4:7], s[0:1], 0x0
s_load_b64 s[0:1], s[0:1], 0x10
s_waitcnt lgkmcnt(0)
s_a... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include "includes.h"
__global__ void to_float(float *out, int *in, int size) {
int element = threadIdx.x + blockDim.x * blockIdx.x;
if (element >= size) return;
out[element] = float(in[element]);
} | code for sm_80
Function : _Z8to_floatPfPii
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R4, SR_TID.X ; /* 0x0000000000047919 */
/* 0x000e280000002100 */
/*0020*/ ... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "includes.h"
__global__ void to_float(float *out, int *in, int size) {
int element = threadIdx.x + blockDim.x * blockIdx.x;
if (element >= size) return;
out[element] = float(in[element]);
} | .file "tmpxft_0017d8d3_00000000-6_to_float.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "includes.h"
__global__ void to_float(float *out, int *in, int size) {
int element = threadIdx.x + blockDim.x * blockIdx.x;
if (element >= size) return;
out[element] = float(in[element]);
} | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void to_float(float *out, int *in, int size) {
int element = threadIdx.x + blockDim.x * blockIdx.x;
if (element >= size) return;
out[element] = float(in[element]);
} |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void to_float(float *out, int *in, int size) {
int element = threadIdx.x + blockDim.x * blockIdx.x;
if (element >= size) return;
out[element] = float(in[element]);
} | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z8to_floatPfPii
.globl _Z8to_floatPfPii
.p2align 8
.type _Z8to_floatPfPii,@function
_Z8to_floatPfPii:
s_clause 0x1
s_load_b32 s2, s[0:1], 0x24
s_load_b32 s3, s[0:1], 0x10
s_waitcnt lgkmcnt(0)
s_and_b32 s2, s2, 0xffff
s_delay_al... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void to_float(float *out, int *in, int size) {
int element = threadIdx.x + blockDim.x * blockIdx.x;
if (element >= size) return;
out[element] = float(in[element]);
} | .text
.file "to_float.hip"
.globl _Z23__device_stub__to_floatPfPii # -- Begin function _Z23__device_stub__to_floatPfPii
.p2align 4, 0x90
.type _Z23__device_stub__to_floatPfPii,@function
_Z23__device_stub__to_floatPfPii: # @_Z23__device_stub__to_floatPfPii
.cfi_startproc
# %bb.0:
subq $104, %rsp
.cfi_def_cfa_offse... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z8to_floatPfPii
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R4, SR_TID.X ; /* 0x0000000000047919 */
/* 0x000e280000002100 */
/*0020*/ ... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z8to_floatPfPii
.globl _Z8to_floatPfPii
.p2align 8
.type _Z8to_floatPfPii,@function
_Z8to_floatPfPii:
s_clause 0x1
s_load_b32 s2, s[0:1], 0x24
s_load_b32 s3, s[0:1], 0x10
s_waitcnt lgkmcnt(0)
s_and_b32 s2, s2, 0xffff
s_delay_al... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_0017d8d3_00000000-6_to_float.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp... | .text
.file "to_float.hip"
.globl _Z23__device_stub__to_floatPfPii # -- Begin function _Z23__device_stub__to_floatPfPii
.p2align 4, 0x90
.type _Z23__device_stub__to_floatPfPii,@function
_Z23__device_stub__to_floatPfPii: # @_Z23__device_stub__to_floatPfPii
.cfi_startproc
# %bb.0:
subq $104, %rsp
.cfi_def_cfa_offse... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <iostream>
#include <time.h>
#include <cstdlib>
using namespace std;
#define N 2048
#define Iteration 100
__global__ void matrixTranspose(int *a, int *b)
{
int i = blockIdx.y * blockDim.y + threadIdx.y; // row
int j = blockIdx.x... | code for sm_80
Function : _Z15matrixTransposePiS_
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R0, SR_CTAID.Y ; /* 0x0000000000007919 */
/* 0x000e220000002600 */
... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <iostream>
#include <time.h>
#include <cstdlib>
using namespace std;
#define N 2048
#define Iteration 100
__global__ void matrixTranspose(int *a, int *b)
{
int i = blockIdx.y * blockDim.y + threadIdx.y; // row
int j = blockIdx.x... | .file "tmpxft_000c4f06_00000000-6_Naive.cudafe1.cpp"
.text
#APP
.globl _ZSt21ios_base_library_initv
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB3672:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnre... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <iostream>
#include <time.h>
#include <cstdlib>
using namespace std;
#define N 2048
#define Iteration 100
__global__ void matrixTranspose(int *a, int *b)
{
int i = blockIdx.y * blockDim.y + threadIdx.y; // row
int j = blockIdx.x... | #include "hip/hip_runtime.h"
#include <stdio.h>
#include <iostream>
#include <time.h>
#include <cstdlib>
using namespace std;
#define N 2048
#define Iteration 100
__global__ void matrixTranspose(int *a, int *b)
{
int i = blockIdx.y * blockDim.y + threadIdx.y; // row
int j = blockIdx.x * blockDim.x + threadIdx.x; // col... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include "hip/hip_runtime.h"
#include <stdio.h>
#include <iostream>
#include <time.h>
#include <cstdlib>
using namespace std;
#define N 2048
#define Iteration 100
__global__ void matrixTranspose(int *a, int *b)
{
int i = blockIdx.y * blockDim.y + threadIdx.y; // row
int j = blockIdx.x * blockDim.x + threadIdx.x; // col... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z15matrixTransposePiS_
.globl _Z15matrixTransposePiS_
.p2align 8
.type _Z15matrixTransposePiS_,@function
_Z15matrixTransposePiS_:
s_load_b32 s2, s[0:1], 0x1c
v_bfe_u32 v1, v0, 10, 10
v_and_b32_e32 v0, 0x3ff, v0
s_waitcnt lgkmcnt(0)
s_lshr_b3... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include "hip/hip_runtime.h"
#include <stdio.h>
#include <iostream>
#include <time.h>
#include <cstdlib>
using namespace std;
#define N 2048
#define Iteration 100
__global__ void matrixTranspose(int *a, int *b)
{
int i = blockIdx.y * blockDim.y + threadIdx.y; // row
int j = blockIdx.x * blockDim.x + threadIdx.x; // col... | .text
.file "Naive.hip"
# Start of file scope inline assembly
.globl _ZSt21ios_base_library_initv
# End of file scope inline assembly
.globl _Z30__device_stub__matrixTransposePiS_ # -- Begin function _Z30__device_stub__matrixTransposePiS_
.p2... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z15matrixTransposePiS_
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R0, SR_CTAID.Y ; /* 0x0000000000007919 */
/* 0x000e220000002600 */
... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z15matrixTransposePiS_
.globl _Z15matrixTransposePiS_
.p2align 8
.type _Z15matrixTransposePiS_,@function
_Z15matrixTransposePiS_:
s_load_b32 s2, s[0:1], 0x1c
v_bfe_u32 v1, v0, 10, 10
v_and_b32_e32 v0, 0x3ff, v0
s_waitcnt lgkmcnt(0)
s_lshr_b3... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_000c4f06_00000000-6_Naive.cudafe1.cpp"
.text
#APP
.globl _ZSt21ios_base_library_initv
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB3672:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnre... | .text
.file "Naive.hip"
# Start of file scope inline assembly
.globl _ZSt21ios_base_library_initv
# End of file scope inline assembly
.globl _Z30__device_stub__matrixTransposePiS_ # -- Begin function _Z30__device_stub__matrixTransposePiS_
.p2... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include "includes.h"
__global__ void cudaSSaturation_propagate_kernel(float* x, float* y, unsigned int size, int shifting, float threshold)
{
const unsigned int index = blockIdx.x * blockDim.x + threadIdx.x;
const unsigned int stride = blockDim.x * gridDim.x;
for (unsigned int i = index; i < size; i += stride) {
float... | code for sm_80
Function : _Z32cudaSSaturation_propagate_kernelPfS_jif
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x00000000... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "includes.h"
__global__ void cudaSSaturation_propagate_kernel(float* x, float* y, unsigned int size, int shifting, float threshold)
{
const unsigned int index = blockIdx.x * blockDim.x + threadIdx.x;
const unsigned int stride = blockDim.x * gridDim.x;
for (unsigned int i = index; i < size; i += stride) {
float... | .file "tmpxft_0016c592_00000000-6_cudaSSaturation_propagate_kernel.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFat... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "includes.h"
__global__ void cudaSSaturation_propagate_kernel(float* x, float* y, unsigned int size, int shifting, float threshold)
{
const unsigned int index = blockIdx.x * blockDim.x + threadIdx.x;
const unsigned int stride = blockDim.x * gridDim.x;
for (unsigned int i = index; i < size; i += stride) {
float... | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void cudaSSaturation_propagate_kernel(float* x, float* y, unsigned int size, int shifting, float threshold)
{
const unsigned int index = blockIdx.x * blockDim.x + threadIdx.x;
const unsigned int stride = blockDim.x * gridDim.x;
for (unsigned int i = index; i... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void cudaSSaturation_propagate_kernel(float* x, float* y, unsigned int size, int shifting, float threshold)
{
const unsigned int index = blockIdx.x * blockDim.x + threadIdx.x;
const unsigned int stride = blockDim.x * gridDim.x;
for (unsigned int i = index; i... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z32cudaSSaturation_propagate_kernelPfS_jif
.globl _Z32cudaSSaturation_propagate_kernelPfS_jif
.p2align 8
.type _Z32cudaSSaturation_propagate_kernelPfS_jif,@function
_Z32cudaSSaturation_propagate_kernelPfS_jif:
s_clause 0x1
s_load_b32 s4, s[0:1], 0x2c
s_loa... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void cudaSSaturation_propagate_kernel(float* x, float* y, unsigned int size, int shifting, float threshold)
{
const unsigned int index = blockIdx.x * blockDim.x + threadIdx.x;
const unsigned int stride = blockDim.x * gridDim.x;
for (unsigned int i = index; i... | .text
.file "cudaSSaturation_propagate_kernel.hip"
.globl _Z47__device_stub__cudaSSaturation_propagate_kernelPfS_jif # -- Begin function _Z47__device_stub__cudaSSaturation_propagate_kernelPfS_jif
.p2align 4, 0x90
.type _Z47__device_stub__cudaSSaturation_propagate_kernelPfS_jif,@function
_Z47__device_stub__cudaSSaturati... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z32cudaSSaturation_propagate_kernelPfS_jif
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x00000000... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z32cudaSSaturation_propagate_kernelPfS_jif
.globl _Z32cudaSSaturation_propagate_kernelPfS_jif
.p2align 8
.type _Z32cudaSSaturation_propagate_kernelPfS_jif,@function
_Z32cudaSSaturation_propagate_kernelPfS_jif:
s_clause 0x1
s_load_b32 s4, s[0:1], 0x2c
s_loa... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_0016c592_00000000-6_cudaSSaturation_propagate_kernel.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFat... | .text
.file "cudaSSaturation_propagate_kernel.hip"
.globl _Z47__device_stub__cudaSSaturation_propagate_kernelPfS_jif # -- Begin function _Z47__device_stub__cudaSSaturation_propagate_kernelPfS_jif
.p2align 4, 0x90
.type _Z47__device_stub__cudaSSaturation_propagate_kernelPfS_jif,@function
_Z47__device_stub__cudaSSaturati... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <stdlib.h>
#include <cstring>
#include <time.h>
__global__ void mem_trd_test(int *input)
{
int gid = blockIdx.x * blockDim.x + threadIdx.x;
printf("threadIdx.x : %d, gid : %d - data : %d \n",threadIdx.x , gid, input[gid]);
}
int... | code for sm_80
Function : _Z12mem_trd_testPi
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R11, SR_CTAID.X ; /* 0x00000000000b7919 */
/* 0x000e220... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <stdlib.h>
#include <cstring>
#include <time.h>
__global__ void mem_trd_test(int *input)
{
int gid = blockIdx.x * blockDim.x + threadIdx.x;
printf("threadIdx.x : %d, gid : %d - data : %d \n",threadIdx.x , gid, input[gid]);
}
int... | .file "tmpxft_0018e74e_00000000-6_cuda_4.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2060:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp
.... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <stdlib.h>
#include <cstring>
#include <time.h>
__global__ void mem_trd_test(int *input)
{
int gid = blockIdx.x * blockDim.x + threadIdx.x;
printf("threadIdx.x : %d, gid : %d - data : %d \n",threadIdx.x , gid, input[gid]);
}
int... | #include "hip/hip_runtime.h"
#include <stdio.h>
#include <stdlib.h>
#include <cstring>
#include <time.h>
__global__ void mem_trd_test(int *input)
{
int gid = blockIdx.x * blockDim.x + threadIdx.x;
printf("threadIdx.x : %d, gid : %d - data : %d \n",threadIdx.x , gid, input[gid]);
}
int main()
{
int size = 128;
int byte_... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include "hip/hip_runtime.h"
#include <stdio.h>
#include <stdlib.h>
#include <cstring>
#include <time.h>
__global__ void mem_trd_test(int *input)
{
int gid = blockIdx.x * blockDim.x + threadIdx.x;
printf("threadIdx.x : %d, gid : %d - data : %d \n",threadIdx.x , gid, input[gid]);
}
int main()
{
int size = 128;
int byte_... | .text
.file "cuda_4.hip"
.globl _Z27__device_stub__mem_trd_testPi # -- Begin function _Z27__device_stub__mem_trd_testPi
.p2align 4, 0x90
.type _Z27__device_stub__mem_trd_testPi,@function
_Z27__device_stub__mem_trd_testPi: # @_Z27__device_stub__mem_trd_testPi
.cfi_startproc
# %bb.0:
subq $72, %rsp
.cfi_def_cfa_offs... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_0018e74e_00000000-6_cuda_4.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2060:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp
.... | .text
.file "cuda_4.hip"
.globl _Z27__device_stub__mem_trd_testPi # -- Begin function _Z27__device_stub__mem_trd_testPi
.p2align 4, 0x90
.type _Z27__device_stub__mem_trd_testPi,@function
_Z27__device_stub__mem_trd_testPi: # @_Z27__device_stub__mem_trd_testPi
.cfi_startproc
# %bb.0:
subq $72, %rsp
.cfi_def_cfa_offs... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include <cuda.h>
#include <stdio.h>
#include <stdlib.h>
const int size = 1000;
void fillVectors(float *A);
void printVector(float *V);
void sumVectors(float *A, float *B, float *C);
//void vecAddKernel(float *A, float *B, float *C);
int main(int argc, char const *argv[]) {
float *A = (float *) malloc(size * sizeof(flo... | code for sm_80
Function : _Z12vecAddKernelPfS_S_
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R6, SR_TID.X ; /* 0x0000000000067919 */
/* 0x000e280000002100 */
/*0... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include <cuda.h>
#include <stdio.h>
#include <stdlib.h>
const int size = 1000;
void fillVectors(float *A);
void printVector(float *V);
void sumVectors(float *A, float *B, float *C);
//void vecAddKernel(float *A, float *B, float *C);
int main(int argc, char const *argv[]) {
float *A = (float *) malloc(size * sizeof(flo... | .file "tmpxft_00102ad9_00000000-6_addVectors.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2063:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %r... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include <cuda.h>
#include <stdio.h>
#include <stdlib.h>
const int size = 1000;
void fillVectors(float *A);
void printVector(float *V);
void sumVectors(float *A, float *B, float *C);
//void vecAddKernel(float *A, float *B, float *C);
int main(int argc, char const *argv[]) {
float *A = (float *) malloc(size * sizeof(flo... | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <stdlib.h>
const int size = 1000;
void fillVectors(float *A);
void printVector(float *V);
void sumVectors(float *A, float *B, float *C);
//void vecAddKernel(float *A, float *B, float *C);
int main(int argc, char const *argv[]) {
float *A = (float *) malloc(size *... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <stdlib.h>
const int size = 1000;
void fillVectors(float *A);
void printVector(float *V);
void sumVectors(float *A, float *B, float *C);
//void vecAddKernel(float *A, float *B, float *C);
int main(int argc, char const *argv[]) {
float *A = (float *) malloc(size *... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z12vecAddKernelPfS_S_
.globl _Z12vecAddKernelPfS_S_
.p2align 8
.type _Z12vecAddKernelPfS_S_,@function
_Z12vecAddKernelPfS_S_:
s_load_b32 s2, s[0:1], 0x24
s_waitcnt lgkmcnt(0)
s_and_b32 s2, s2, 0xffff
s_delay_alu instid0(SALU_CYCLE_1) | ins... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <stdlib.h>
const int size = 1000;
void fillVectors(float *A);
void printVector(float *V);
void sumVectors(float *A, float *B, float *C);
//void vecAddKernel(float *A, float *B, float *C);
int main(int argc, char const *argv[]) {
float *A = (float *) malloc(size *... | .text
.file "addVectors.hip"
.globl main # -- Begin function main
.p2align 4, 0x90
.type main,@function
main: # @main
.cfi_startproc
# %bb.0:
pushq %r15
.cfi_def_cfa_offset 16
pushq %r14
.cfi_def_cfa_offset 24
pushq %r12
.cfi_def_cfa_offset 32
pushq %rbx
.cfi... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z12vecAddKernelPfS_S_
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R6, SR_TID.X ; /* 0x0000000000067919 */
/* 0x000e280000002100 */
/*0... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z12vecAddKernelPfS_S_
.globl _Z12vecAddKernelPfS_S_
.p2align 8
.type _Z12vecAddKernelPfS_S_,@function
_Z12vecAddKernelPfS_S_:
s_load_b32 s2, s[0:1], 0x24
s_waitcnt lgkmcnt(0)
s_and_b32 s2, s2, 0xffff
s_delay_alu instid0(SALU_CYCLE_1) | ins... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_00102ad9_00000000-6_addVectors.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2063:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %r... | .text
.file "addVectors.hip"
.globl main # -- Begin function main
.p2align 4, 0x90
.type main,@function
main: # @main
.cfi_startproc
# %bb.0:
pushq %r15
.cfi_def_cfa_offset 16
pushq %r14
.cfi_def_cfa_offset 24
pushq %r12
.cfi_def_cfa_offset 32
pushq %rbx
.cfi... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include <cuda.h>
#include <stdio.h>
#include <dlfcn.h>
#include <stdlib.h>
CUresult cuDeviceTotalMem(size_t* bytes, CUdevice dev) {
void *handle;
handle = dlopen("/usr/lib/x86_64-linux-gnu/libcuda.so.1", RTLD_LAZY);
printf("%s\n", "I just want to tell you that cuDeviceTotalMem is STILL hijacked!");
CUresult (*ori_cu_... | code for sm_80 |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include <cuda.h>
#include <stdio.h>
#include <dlfcn.h>
#include <stdlib.h>
CUresult cuDeviceTotalMem(size_t* bytes, CUdevice dev) {
void *handle;
handle = dlopen("/usr/lib/x86_64-linux-gnu/libcuda.so.1", RTLD_LAZY);
printf("%s\n", "I just want to tell you that cuDeviceTotalMem is STILL hijacked!");
CUresult (*ori_cu_... | .file "tmpxft_00165c5f_00000000-6_hijack.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2060:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp
.... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include <cuda.h>
#include <stdio.h>
#include <dlfcn.h>
#include <stdlib.h>
CUresult cuDeviceTotalMem(size_t* bytes, CUdevice dev) {
void *handle;
handle = dlopen("/usr/lib/x86_64-linux-gnu/libcuda.so.1", RTLD_LAZY);
printf("%s\n", "I just want to tell you that cuDeviceTotalMem is STILL hijacked!");
CUresult (*ori_cu_... | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <dlfcn.h>
#include <stdlib.h>
hipError_t hipDeviceTotalMem(size_t* bytes, hipDevice_t dev) {
void *handle;
handle = dlopen("/usr/lib/x86_64-linux-gnu/libcuda.so.1", RTLD_LAZY);
printf("%s\n", "I just want to tell you that hipDeviceTotalMem is STILL hijacked!");
... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <dlfcn.h>
#include <stdlib.h>
hipError_t hipDeviceTotalMem(size_t* bytes, hipDevice_t dev) {
void *handle;
handle = dlopen("/usr/lib/x86_64-linux-gnu/libcuda.so.1", RTLD_LAZY);
printf("%s\n", "I just want to tell you that hipDeviceTotalMem is STILL hijacked!");
... | .text
.p2alignl 7, 3214868480
.fill 96, 4, 3214868480
.type __hip_cuid_,@object
.section .bss,"aw",@nobits
.globl __hip_cuid_
__hip_cuid_:
.byte 0
.size __hip_cuid_, 1
.ident "AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <dlfcn.h>
#include <stdlib.h>
hipError_t hipDeviceTotalMem(size_t* bytes, hipDevice_t dev) {
void *handle;
handle = dlopen("/usr/lib/x86_64-linux-gnu/libcuda.so.1", RTLD_LAZY);
printf("%s\n", "I just want to tell you that hipDeviceTotalMem is STILL hijacked!");
... | .text
.file "hijack.hip"
.globl hipDeviceTotalMem # -- Begin function hipDeviceTotalMem
.p2align 4, 0x90
.type hipDeviceTotalMem,@function
hipDeviceTotalMem: # @hipDeviceTotalMem
.cfi_startproc
# %bb.0:
pushq %r15
.cfi_def_cfa_offset 16
pushq %r14
.cfi_def_cfa_offset 24
pushq %rbx
.cf... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80 | .text
.p2alignl 7, 3214868480
.fill 96, 4, 3214868480
.type __hip_cuid_,@object
.section .bss,"aw",@nobits
.globl __hip_cuid_
__hip_cuid_:
.byte 0
.size __hip_cuid_, 1
.ident "AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_00165c5f_00000000-6_hijack.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2060:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp
.... | .text
.file "hijack.hip"
.globl hipDeviceTotalMem # -- Begin function hipDeviceTotalMem
.p2align 4, 0x90
.type hipDeviceTotalMem,@function
hipDeviceTotalMem: # @hipDeviceTotalMem
.cfi_startproc
# %bb.0:
pushq %r15
.cfi_def_cfa_offset 16
pushq %r14
.cfi_def_cfa_offset 24
pushq %rbx
.cf... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include "includes.h"
__global__ void bcnn_op_cuda_ramp_kernel(int n, float *x, float *y) {
int i = (blockIdx.x + blockIdx.y * gridDim.x) * blockDim.x + threadIdx.x;
if (i < n) {
y[i] = x[i] * (x[i] > 0) + 0.1 * x[i];
}
return;
} | code for sm_80
Function : _Z24bcnn_op_cuda_ramp_kerneliPfS_
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x0000000000007919 */
/* 0x000e280000... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "includes.h"
__global__ void bcnn_op_cuda_ramp_kernel(int n, float *x, float *y) {
int i = (blockIdx.x + blockIdx.y * gridDim.x) * blockDim.x + threadIdx.x;
if (i < n) {
y[i] = x[i] * (x[i] > 0) + 0.1 * x[i];
}
return;
} | .file "tmpxft_0015c52a_00000000-6_bcnn_op_cuda_ramp_kernel.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@P... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "includes.h"
__global__ void bcnn_op_cuda_ramp_kernel(int n, float *x, float *y) {
int i = (blockIdx.x + blockIdx.y * gridDim.x) * blockDim.x + threadIdx.x;
if (i < n) {
y[i] = x[i] * (x[i] > 0) + 0.1 * x[i];
}
return;
} | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void bcnn_op_cuda_ramp_kernel(int n, float *x, float *y) {
int i = (blockIdx.x + blockIdx.y * gridDim.x) * blockDim.x + threadIdx.x;
if (i < n) {
y[i] = x[i] * (x[i] > 0) + 0.1 * x[i];
}
return;
} |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void bcnn_op_cuda_ramp_kernel(int n, float *x, float *y) {
int i = (blockIdx.x + blockIdx.y * gridDim.x) * blockDim.x + threadIdx.x;
if (i < n) {
y[i] = x[i] * (x[i] > 0) + 0.1 * x[i];
}
return;
} | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z24bcnn_op_cuda_ramp_kerneliPfS_
.globl _Z24bcnn_op_cuda_ramp_kerneliPfS_
.p2align 8
.type _Z24bcnn_op_cuda_ramp_kerneliPfS_,@function
_Z24bcnn_op_cuda_ramp_kerneliPfS_:
s_clause 0x2
s_load_b32 s2, s[0:1], 0x18
s_load_b32 s3, s[0:1], 0x24
s_load_b32 s... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void bcnn_op_cuda_ramp_kernel(int n, float *x, float *y) {
int i = (blockIdx.x + blockIdx.y * gridDim.x) * blockDim.x + threadIdx.x;
if (i < n) {
y[i] = x[i] * (x[i] > 0) + 0.1 * x[i];
}
return;
} | .text
.file "bcnn_op_cuda_ramp_kernel.hip"
.globl _Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_ # -- Begin function _Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_
.p2align 4, 0x90
.type _Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_,@function
_Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_: # @_Z39__device_stub... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z24bcnn_op_cuda_ramp_kerneliPfS_
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ MOV R1, c[0x0][0x28] ; /* 0x00000a0000017a02 */
/* 0x000fe40000000f00 */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x0000000000007919 */
/* 0x000e280000... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z24bcnn_op_cuda_ramp_kerneliPfS_
.globl _Z24bcnn_op_cuda_ramp_kerneliPfS_
.p2align 8
.type _Z24bcnn_op_cuda_ramp_kerneliPfS_,@function
_Z24bcnn_op_cuda_ramp_kerneliPfS_:
s_clause 0x2
s_load_b32 s2, s[0:1], 0x18
s_load_b32 s3, s[0:1], 0x24
s_load_b32 s... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_0015c52a_00000000-6_bcnn_op_cuda_ramp_kernel.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@P... | .text
.file "bcnn_op_cuda_ramp_kernel.hip"
.globl _Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_ # -- Begin function _Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_
.p2align 4, 0x90
.type _Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_,@function
_Z39__device_stub__bcnn_op_cuda_ramp_kerneliPfS_: # @_Z39__device_stub... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | /***************************************************************************//**
* \file LHS1.cu
* \author Christopher Minar (minarc@oregonstate.edu)
* \brief kernels to generate the left hand side for the intermediate velocity solve
*/
#include "LHS1.h"
namespace kernels
{
/*
* calculates the boundary terms for the le... | .file "tmpxft_001b099e_00000000-6_LHS1.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp
.cf... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | /***************************************************************************//**
* \file LHS1.cu
* \author Christopher Minar (minarc@oregonstate.edu)
* \brief kernels to generate the left hand side for the intermediate velocity solve
*/
#include "LHS1.h"
namespace kernels
{
/*
* calculates the boundary terms for the le... | /***************************************************************************//**
* \file LHS1.cu
* \author Christopher Minar (minarc@oregonstate.edu)
* \brief kernels to generate the left hand side for the intermediate velocity solve
*/
#include <hip/hip_runtime.h>
#include "LHS1.h"
namespace kernels
{
/*
* calculates ... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | /***************************************************************************//**
* \file LHS1.cu
* \author Christopher Minar (minarc@oregonstate.edu)
* \brief kernels to generate the left hand side for the intermediate velocity solve
*/
#include <hip/hip_runtime.h>
#include "LHS1.h"
namespace kernels
{
/*
* calculates ... | .text
.file "LHS1.hip"
.globl _ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii # -- Begin function _ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii
.p2align 4, 0x90
.type _ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii,@function
_ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii: # @_ZN7kernels23... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_001b099e_00000000-6_LHS1.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rsp
.cf... | .text
.file "LHS1.hip"
.globl _ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii # -- Begin function _ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii
.p2align 4, 0x90
.type _ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii,@function
_ZN7kernels23__device_stub__LHS_BC_XEPiS0_PdS1_S1_ddii: # @_ZN7kernels23... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include "includes.h"
__global__ void knapsackGPU2(int* dp, int* d_value, int* d_weight, int capacity,int n)
{
int in = threadIdx.x + (blockDim.x * blockIdx.x);
for (int row = 0;row <= n;row++)
{
if (row != 0)
{
int ind = in + (row * (capacity + 1));
if (in <= (capacity + 1) && in > 0)
{
if (in >= d_weight[row - 1])
{
... | code for sm_80
Function : _Z12knapsackGPU2PiS_S_ii
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R7, SR_CTAID.X ; /* 0x0000000000077919 */
/* 0x00... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "includes.h"
__global__ void knapsackGPU2(int* dp, int* d_value, int* d_weight, int capacity,int n)
{
int in = threadIdx.x + (blockDim.x * blockIdx.x);
for (int row = 0;row <= n;row++)
{
if (row != 0)
{
int ind = in + (row * (capacity + 1));
if (in <= (capacity + 1) && in > 0)
{
if (in >= d_weight[row - 1])
{
... | .file "tmpxft_0018eb9a_00000000-6_knapsackGPU2.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, ... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "includes.h"
__global__ void knapsackGPU2(int* dp, int* d_value, int* d_weight, int capacity,int n)
{
int in = threadIdx.x + (blockDim.x * blockIdx.x);
for (int row = 0;row <= n;row++)
{
if (row != 0)
{
int ind = in + (row * (capacity + 1));
if (in <= (capacity + 1) && in > 0)
{
if (in >= d_weight[row - 1])
{
... | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void knapsackGPU2(int* dp, int* d_value, int* d_weight, int capacity,int n)
{
int in = threadIdx.x + (blockDim.x * blockIdx.x);
for (int row = 0;row <= n;row++)
{
if (row != 0)
{
int ind = in + (row * (capacity + 1));
if (in <= (capacity + 1) && in > 0)
{
if... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void knapsackGPU2(int* dp, int* d_value, int* d_weight, int capacity,int n)
{
int in = threadIdx.x + (blockDim.x * blockIdx.x);
for (int row = 0;row <= n;row++)
{
if (row != 0)
{
int ind = in + (row * (capacity + 1));
if (in <= (capacity + 1) && in > 0)
{
if... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z12knapsackGPU2PiS_S_ii
.globl _Z12knapsackGPU2PiS_S_ii
.p2align 8
.type _Z12knapsackGPU2PiS_S_ii,@function
_Z12knapsackGPU2PiS_S_ii:
s_load_b32 s10, s[0:1], 0x1c
s_mov_b32 s8, 0
s_waitcnt lgkmcnt(0)
s_cmp_lt_i32 s10, 0
s_cbranch_scc1 .LBB0_1... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
__global__ void knapsackGPU2(int* dp, int* d_value, int* d_weight, int capacity,int n)
{
int in = threadIdx.x + (blockDim.x * blockIdx.x);
for (int row = 0;row <= n;row++)
{
if (row != 0)
{
int ind = in + (row * (capacity + 1));
if (in <= (capacity + 1) && in > 0)
{
if... | .text
.file "knapsackGPU2.hip"
.globl _Z27__device_stub__knapsackGPU2PiS_S_ii # -- Begin function _Z27__device_stub__knapsackGPU2PiS_S_ii
.p2align 4, 0x90
.type _Z27__device_stub__knapsackGPU2PiS_S_ii,@function
_Z27__device_stub__knapsackGPU2PiS_S_ii: # @_Z27__device_stub__knapsackGPU2PiS_S_ii
.cfi_startproc
# %bb.0:
s... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z12knapsackGPU2PiS_S_ii
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R7, SR_CTAID.X ; /* 0x0000000000077919 */
/* 0x00... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z12knapsackGPU2PiS_S_ii
.globl _Z12knapsackGPU2PiS_S_ii
.p2align 8
.type _Z12knapsackGPU2PiS_S_ii,@function
_Z12knapsackGPU2PiS_S_ii:
s_load_b32 s10, s[0:1], 0x1c
s_mov_b32 s8, 0
s_waitcnt lgkmcnt(0)
s_cmp_lt_i32 s10, 0
s_cbranch_scc1 .LBB0_1... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_0018eb9a_00000000-6_knapsackGPU2.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, ... | .text
.file "knapsackGPU2.hip"
.globl _Z27__device_stub__knapsackGPU2PiS_S_ii # -- Begin function _Z27__device_stub__knapsackGPU2PiS_S_ii
.p2align 4, 0x90
.type _Z27__device_stub__knapsackGPU2PiS_S_ii,@function
_Z27__device_stub__knapsackGPU2PiS_S_ii: # @_Z27__device_stub__knapsackGPU2PiS_S_ii
.cfi_startproc
# %bb.0:
s... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | __global__ void JacobiSVD(int* S, int* V, int m, int n)
{
const int iterations = 30;
int tid_x = threadIdx.x;
int bsz_x = blockDim.x;
int tid_y = threadIdx.y;
int gid_y = blockIdx.y * blockDim.y + tid_y;
__shared__ int acc[512];
int* acc1 = acc;
int* acc2 = acc + 256;
__shared__ int s_S[16*81];
__shared__ int s_V[16*81... | .file "tmpxft_0000ec55_00000000-6_JacobiSVD.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rs... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | __global__ void JacobiSVD(int* S, int* V, int m, int n)
{
const int iterations = 30;
int tid_x = threadIdx.x;
int bsz_x = blockDim.x;
int tid_y = threadIdx.y;
int gid_y = blockIdx.y * blockDim.y + tid_y;
__shared__ int acc[512];
int* acc1 = acc;
int* acc2 = acc + 256;
__shared__ int s_S[16*81];
__shared__ int s_V[16*81... | #include <hip/hip_runtime.h>
__global__ void JacobiSVD(int* S, int* V, int m, int n)
{
const int iterations = 30;
int tid_x = threadIdx.x;
int bsz_x = blockDim.x;
int tid_y = threadIdx.y;
int gid_y = blockIdx.y * blockDim.y + tid_y;
__shared__ int acc[512];
int* acc1 = acc;
int* acc2 = acc + 256;
__shared__ int s_S[16*... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
__global__ void JacobiSVD(int* S, int* V, int m, int n)
{
const int iterations = 30;
int tid_x = threadIdx.x;
int bsz_x = blockDim.x;
int tid_y = threadIdx.y;
int gid_y = blockIdx.y * blockDim.y + tid_y;
__shared__ int acc[512];
int* acc1 = acc;
int* acc2 = acc + 256;
__shared__ int s_S[16*... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z9JacobiSVDPiS_ii
.globl _Z9JacobiSVDPiS_ii
.p2align 8
.type _Z9JacobiSVDPiS_ii,@function
_Z9JacobiSVDPiS_ii:
s_mov_b32 s0, 9
.LBB0_1:
s_delay_alu instid0(SALU_CYCLE_1) | instskip(NEXT) | instid1(SAL... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
__global__ void JacobiSVD(int* S, int* V, int m, int n)
{
const int iterations = 30;
int tid_x = threadIdx.x;
int bsz_x = blockDim.x;
int tid_y = threadIdx.y;
int gid_y = blockIdx.y * blockDim.y + tid_y;
__shared__ int acc[512];
int* acc1 = acc;
int* acc2 = acc + 256;
__shared__ int s_S[16*... | .text
.file "JacobiSVD.hip"
.globl _Z24__device_stub__JacobiSVDPiS_ii # -- Begin function _Z24__device_stub__JacobiSVDPiS_ii
.p2align 4, 0x90
.type _Z24__device_stub__JacobiSVDPiS_ii,@function
_Z24__device_stub__JacobiSVDPiS_ii: # @_Z24__device_stub__JacobiSVDPiS_ii
.cfi_startproc
# %bb.0:
subq $120, %rsp
.cfi_def_... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_0000ec55_00000000-6_JacobiSVD.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %rs... | .text
.file "JacobiSVD.hip"
.globl _Z24__device_stub__JacobiSVDPiS_ii # -- Begin function _Z24__device_stub__JacobiSVDPiS_ii
.p2align 4, 0x90
.type _Z24__device_stub__JacobiSVDPiS_ii,@function
_Z24__device_stub__JacobiSVDPiS_ii: # @_Z24__device_stub__JacobiSVDPiS_ii
.cfi_startproc
# %bb.0:
subq $120, %rsp
.cfi_def_... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | //16CO212 16CO249
//Computer Architecture Lab Assignment 0
//Question 1
#include <stdio.h>
//Printing Properties of the device
void printDevProp(cudaDeviceProp device_properties)
{
printf("\tMajor revision number: %d\n", device_properties.major);
printf("\tMinor revision number: %d\n", device_properties.minor);
print... | code for sm_80 |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | //16CO212 16CO249
//Computer Architecture Lab Assignment 0
//Question 1
#include <stdio.h>
//Printing Properties of the device
void printDevProp(cudaDeviceProp device_properties)
{
printf("\tMajor revision number: %d\n", device_properties.major);
printf("\tMinor revision number: %d\n", device_properties.minor);
print... | .file "tmpxft_00104779_00000000-6_A0-Q1-212-249.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2061:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8,... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | //16CO212 16CO249
//Computer Architecture Lab Assignment 0
//Question 1
#include <stdio.h>
//Printing Properties of the device
void printDevProp(cudaDeviceProp device_properties)
{
printf("\tMajor revision number: %d\n", device_properties.major);
printf("\tMinor revision number: %d\n", device_properties.minor);
print... | //16CO212 16CO249
//Computer Architecture Lab Assignment 0
//Question 1
#include <hip/hip_runtime.h>
#include <stdio.h>
//Printing Properties of the device
void printDevProp(hipDeviceProp_t device_properties)
{
printf("\tMajor revision number: %d\n", device_properties.major);
printf("\tMinor revision number: %d\n", de... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | //16CO212 16CO249
//Computer Architecture Lab Assignment 0
//Question 1
#include <hip/hip_runtime.h>
#include <stdio.h>
//Printing Properties of the device
void printDevProp(hipDeviceProp_t device_properties)
{
printf("\tMajor revision number: %d\n", device_properties.major);
printf("\tMinor revision number: %d\n", de... | .text
.p2alignl 7, 3214868480
.fill 96, 4, 3214868480
.type __hip_cuid_,@object
.section .bss,"aw",@nobits
.globl __hip_cuid_
__hip_cuid_:
.byte 0
.size __hip_cuid_, 1
.ident "AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | //16CO212 16CO249
//Computer Architecture Lab Assignment 0
//Question 1
#include <hip/hip_runtime.h>
#include <stdio.h>
//Printing Properties of the device
void printDevProp(hipDeviceProp_t device_properties)
{
printf("\tMajor revision number: %d\n", device_properties.major);
printf("\tMinor revision number: %d\n", de... | .text
.file "A0-Q1-212-249.hip"
.globl _Z12printDevProp20hipDeviceProp_tR0600 # -- Begin function _Z12printDevProp20hipDeviceProp_tR0600
.p2align 4, 0x90
.type _Z12printDevProp20hipDeviceProp_tR0600,@function
_Z12printDevProp20hipDeviceProp_tR0600: # @_Z12printDevProp20hipDeviceProp_tR0600
.cfi_startproc
# %bb.0:
pushq... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80 | .text
.p2alignl 7, 3214868480
.fill 96, 4, 3214868480
.type __hip_cuid_,@object
.section .bss,"aw",@nobits
.globl __hip_cuid_
__hip_cuid_:
.byte 0
.size __hip_cuid_, 1
.ident "AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_00104779_00000000-6_A0-Q1-212-249.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2061:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8,... | .text
.file "A0-Q1-212-249.hip"
.globl _Z12printDevProp20hipDeviceProp_tR0600 # -- Begin function _Z12printDevProp20hipDeviceProp_tR0600
.p2align 4, 0x90
.type _Z12printDevProp20hipDeviceProp_tR0600,@function
_Z12printDevProp20hipDeviceProp_tR0600: # @_Z12printDevProp20hipDeviceProp_tR0600
.cfi_startproc
# %bb.0:
pushq... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include "includes.h"
/* This file is copied from https://github.com/jzbonter/mc-cnn */
extern "C" {
}
#define TB 128
#define DISP_MAX 256
__global__ void remove_white(float *x, float *y, int size)
{
int id = blockIdx.x * blockDim.x + threadIdx.x;
if (id < size) {
if (x[id] == 255) {
y[id] = 0;
}
}
} | code for sm_80
Function : _Z12remove_whitePfS_i
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x0000000000007919 */
/* 0x000e2... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "includes.h"
/* This file is copied from https://github.com/jzbonter/mc-cnn */
extern "C" {
}
#define TB 128
#define DISP_MAX 256
__global__ void remove_white(float *x, float *y, int size)
{
int id = blockIdx.x * blockDim.x + threadIdx.x;
if (id < size) {
if (x[id] == 255) {
y[id] = 0;
}
}
} | .file "tmpxft_000eb6ae_00000000-6_remove_white.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, ... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "includes.h"
/* This file is copied from https://github.com/jzbonter/mc-cnn */
extern "C" {
}
#define TB 128
#define DISP_MAX 256
__global__ void remove_white(float *x, float *y, int size)
{
int id = blockIdx.x * blockDim.x + threadIdx.x;
if (id < size) {
if (x[id] == 255) {
y[id] = 0;
}
}
} | #include <hip/hip_runtime.h>
#include "includes.h"
/* This file is copied from https://github.com/jzbonter/mc-cnn */
extern "C" {
}
#define TB 128
#define DISP_MAX 256
__global__ void remove_white(float *x, float *y, int size)
{
int id = blockIdx.x * blockDim.x + threadIdx.x;
if (id < size) {
if (x[id] == 255) {
y[id] ... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
/* This file is copied from https://github.com/jzbonter/mc-cnn */
extern "C" {
}
#define TB 128
#define DISP_MAX 256
__global__ void remove_white(float *x, float *y, int size)
{
int id = blockIdx.x * blockDim.x + threadIdx.x;
if (id < size) {
if (x[id] == 255) {
y[id] ... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z12remove_whitePfS_i
.globl _Z12remove_whitePfS_i
.p2align 8
.type _Z12remove_whitePfS_i,@function
_Z12remove_whitePfS_i:
s_clause 0x1
s_load_b32 s2, s[0:1], 0x24
s_load_b32 s3, s[0:1], 0x10
s_waitcnt lgkmcnt(0)
s_and_b32 s2, s2, 0xffff
... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include "includes.h"
/* This file is copied from https://github.com/jzbonter/mc-cnn */
extern "C" {
}
#define TB 128
#define DISP_MAX 256
__global__ void remove_white(float *x, float *y, int size)
{
int id = blockIdx.x * blockDim.x + threadIdx.x;
if (id < size) {
if (x[id] == 255) {
y[id] ... | .text
.file "remove_white.hip"
.globl _Z27__device_stub__remove_whitePfS_i # -- Begin function _Z27__device_stub__remove_whitePfS_i
.p2align 4, 0x90
.type _Z27__device_stub__remove_whitePfS_i,@function
_Z27__device_stub__remove_whitePfS_i: # @_Z27__device_stub__remove_whitePfS_i
.cfi_startproc
# %bb.0:
subq $104, %rs... |
You are a helpful coding assistant specialized in converting from CUDA device assembly to AMD device assembly. | code for sm_80
Function : _Z12remove_whitePfS_i
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R0, SR_CTAID.X ; /* 0x0000000000007919 */
/* 0x000e2... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z12remove_whitePfS_i
.globl _Z12remove_whitePfS_i
.p2align 8
.type _Z12remove_whitePfS_i,@function
_Z12remove_whitePfS_i:
s_clause 0x1
s_load_b32 s2, s[0:1], 0x24
s_load_b32 s3, s[0:1], 0x10
s_waitcnt lgkmcnt(0)
s_and_b32 s2, s2, 0xffff
... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_000eb6ae_00000000-6_remove_white.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2029:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, ... | .text
.file "remove_white.hip"
.globl _Z27__device_stub__remove_whitePfS_i # -- Begin function _Z27__device_stub__remove_whitePfS_i
.p2align 4, 0x90
.type _Z27__device_stub__remove_whitePfS_i,@function
_Z27__device_stub__remove_whitePfS_i: # @_Z27__device_stub__remove_whitePfS_i
.cfi_startproc
# %bb.0:
subq $104, %rs... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <unistd.h>
#include <vector>
#include <iostream>
//#include <Windows.h>
//#include <direct.h>
using namespace std;
#ifndef __CUDACC__
#define __CUDACC__
#endif
__device__ int minIndex(double* data,double* centers,bool* centerfl... | .file "tmpxft_0008db6b_00000000-6_kernel.cudafe1.cpp"
.text
#APP
.globl _ZSt21ios_base_library_initv
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB4060:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnr... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <stdio.h>
#include <unistd.h>
#include <vector>
#include <iostream>
//#include <Windows.h>
//#include <direct.h>
using namespace std;
#ifndef __CUDACC__
#define __CUDACC__
#endif
__device__ int minIndex(double* data,double* centers,bool* centerfl... | #include "hip/hip_runtime.h"
#include <stdio.h>
#include <unistd.h>
#include <vector>
#include <iostream>
//#include <Windows.h>
//#include <direct.h>
using namespace std;
#ifndef __HIPCC__
#define __HIPCC__
#endif
__device__ int minIndex(double* data,double* centers,bool* centerflags,int kCenter,int dimension)
{
int ... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include "hip/hip_runtime.h"
#include <stdio.h>
#include <unistd.h>
#include <vector>
#include <iostream>
//#include <Windows.h>
//#include <direct.h>
using namespace std;
#ifndef __HIPCC__
#define __HIPCC__
#endif
__device__ int minIndex(double* data,double* centers,bool* centerflags,int kCenter,int dimension)
{
int ... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z16updatebelonging4iPdiiS_PiiPbS1_
.globl _Z16updatebelonging4iPdiiS_PiiPbS1_
.p2align 8
.type _Z16updatebelonging4iPdiiS_PiiPbS1_,@function
_Z16updatebelonging4iPdiiS_PiiPbS1_:
s_clause 0x2
s_load_b32 s2, s[0:1], 0x4c
s_load_b32 s3, s[0:1], 0x0
s_load_... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <iostream>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#define N 5
#define BLOCK_DIM 10
using namespace std;
__global__
void adicion_Matrices (int *a, int *b, int *c) {
int col = blockIdx.x * blockDim.x + threadIdx.x;
int fila = blockIdx.y ... | code for sm_80
Function : _Z25adicion_matrices_ColumnasPiS_S_
.headerflags @"EF_CUDA_TEXMODE_UNIFIED EF_CUDA_64BIT_ADDRESS EF_CUDA_SM80 EF_CUDA_VIRTUAL_SM(EF_CUDA_SM80)"
/*0000*/ IMAD.MOV.U32 R1, RZ, RZ, c[0x0][0x28] ; /* 0x00000a00ff017624 */
/* 0x000fe400078e00ff */
/*0010*/ S2R R2, SR_CTAID.Y ; /* 0x0000000000027919... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <iostream>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#define N 5
#define BLOCK_DIM 10
using namespace std;
__global__
void adicion_Matrices (int *a, int *b, int *c) {
int col = blockIdx.x * blockDim.x + threadIdx.x;
int fila = blockIdx.y ... | .file "tmpxft_0016fe02_00000000-6_main.cudafe1.cpp"
.text
#APP
.globl _ZSt21ios_base_library_initv
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB3675:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnreg... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <iostream>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#define N 5
#define BLOCK_DIM 10
using namespace std;
__global__
void adicion_Matrices (int *a, int *b, int *c) {
int col = blockIdx.x * blockDim.x + threadIdx.x;
int fila = blockIdx.y ... | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <iostream>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#define N 5
#define BLOCK_DIM 10
using namespace std;
__global__
void adicion_Matrices (int *a, int *b, int *c) {
int col = blockIdx.x * blockDim.x + thread... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <iostream>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#define N 5
#define BLOCK_DIM 10
using namespace std;
__global__
void adicion_Matrices (int *a, int *b, int *c) {
int col = blockIdx.x * blockDim.x + thread... | .text
.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
.protected _Z16adicion_MatricesPiS_S_
.globl _Z16adicion_MatricesPiS_S_
.p2align 8
.type _Z16adicion_MatricesPiS_S_,@function
_Z16adicion_MatricesPiS_S_:
s_load_b32 s2, s[0:1], 0x24
v_and_b32_e32 v2, 0x3ff, v0
v_bfe_u32 v3, v0, 10, 10
s_waitcnt lgkmcnt(0)
... |
You are a helpful coding assistant specialized in converting HIP source code to AMD host assembly. | #include <hip/hip_runtime.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <iostream>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#define N 5
#define BLOCK_DIM 10
using namespace std;
__global__
void adicion_Matrices (int *a, int *b, int *c) {
int col = blockIdx.x * blockDim.x + thread... | .text
.file "main.hip"
# Start of file scope inline assembly
.globl _ZSt21ios_base_library_initv
# End of file scope inline assembly
.globl _Z31__device_stub__adicion_MatricesPiS_S_ # -- Begin function _Z31__device_stub__adicion_MatricesPiS_S... |
You are a helpful coding assistant specialized in converting from CUDA host assembly to AMD host assembly. | .file "tmpxft_0016fe02_00000000-6_main.cudafe1.cpp"
.text
#APP
.globl _ZSt21ios_base_library_initv
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB3675:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnreg... | .text
.file "main.hip"
# Start of file scope inline assembly
.globl _ZSt21ios_base_library_initv
# End of file scope inline assembly
.globl _Z31__device_stub__adicion_MatricesPiS_S_ # -- Begin function _Z31__device_stub__adicion_MatricesPiS_S... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | /*
Programming on Massively Parallel Systems
Fall 2018
Project # 3
Student: Patricia Wilthew
Compile: nvcc proj3.cu -o proj3
Usage: ./proj3 {#of_elements_in_array1} {#of_elements_in_array2}
*/
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <sys/time.h>
#include <assert.h>
#include <thrust/scan.h>
#de... | /*
Programming on Massively Parallel Systems
Fall 2018
Project # 3
Student: Patricia Wilthew
Compile: nvcc proj3.cu -o proj3
Usage: ./proj3 {#of_elements_in_array1} {#of_elements_in_array2}
*/
#include <hip/hip_runtime.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <sys/time.h>
#include <assert.h>... |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA device assembly. | // includes, system
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#if defined(__unix) || defined(__linux)
#include <sys/time.h>
#endif
// includes, project
#include <cuda.h>
#include <cuda_runtime.h>
#include <cufft.h>
extern "C" void NewCUDAFFT(float *input, int dim[3], int forward, int doComplex, int tim... | code for sm_80 |
You are a helpful coding assistant specialized in converting CUDA source code to CUDA host assembly. | // includes, system
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#if defined(__unix) || defined(__linux)
#include <sys/time.h>
#endif
// includes, project
#include <cuda.h>
#include <cuda_runtime.h>
#include <cufft.h>
extern "C" void NewCUDAFFT(float *input, int dim[3], int forward, int doComplex, int tim... | .file "tmpxft_001004ae_00000000-6_NewCUDAFFT.cudafe1.cpp"
.text
#APP
#NO_APP
.type _ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB2083:
.cfi_startproc
endbr64
subq $8, %rsp
.cfi_def_cfa_offset 16
movq _ZL20__cudaFatCubinHandle(%rip), %rdi
call __cudaUnregisterFatBinary@PLT
addq $8, %r... |
You are a helpful coding assistant specialized in converting CUDA source code to HIP/AMD source code. | // includes, system
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#if defined(__unix) || defined(__linux)
#include <sys/time.h>
#endif
// includes, project
#include <cuda.h>
#include <cuda_runtime.h>
#include <cufft.h>
extern "C" void NewCUDAFFT(float *input, int dim[3], int forward, int doComplex, int tim... | // includes, system
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#if defined(__unix) || defined(__linux)
#include <sys/time.h>
#endif
// includes, project
#include <hip/hip_runtime.h>
#include <hipfft/hipfft.h>
extern "C" void NewCUDAFFT(float *input, int dim[3], int forward, int doComplex, int time)
{
#i... |
You are a helpful coding assistant specialized in converting HIP source code to AMD device assembly. | // includes, system
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#if defined(__unix) || defined(__linux)
#include <sys/time.h>
#endif
// includes, project
#include <hip/hip_runtime.h>
#include <hipfft/hipfft.h>
extern "C" void NewCUDAFFT(float *input, int dim[3], int forward, int doComplex, int time)
{
#i... | .text
.p2alignl 7, 3214868480
.fill 96, 4, 3214868480
.type __hip_cuid_,@object
.section .bss,"aw",@nobits
.globl __hip_cuid_
__hip_cuid_:
.byte 0
.size __hip_cuid_, 1
.ident "AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.