Este sitio web requiere JavaScript.
Explorar
Ayuda
Iniciar sesión
AI
/
rocm-systems
Seguir
2
Destacar
0
Fork
0
Ya ha forkeado rocm-systems
Código
Incidencias
Pull Requests
Acciones
Paquetes
Proyectos
Lanzamientos
Wiki
Actividad
2.150
Commits
3
Ramas
0
Etiquetas
2e395343779d1ff2ea9a4e78352bde063b45991a
Gráfico de commits
6 Commits
Autor
SHA1
Mensaje
Fecha
Alex Voicu
6a0efb7ed2
Re-sync with upstream and re-factor platform global management for texture references.
2017-11-28 19:15:29 +00:00
Alex Voicu
fb1021cc0a
This corrects how addresses are formed for symbols which reside in shared objects. For this case, the .value component of an ELF symbol holds the offset from the base VA where the shared object was loaded. Thus, to correctly obtain the VA of the object refered by the symbol, we must add the offset to the VA where the shared object is loaded. We were already doing this correctly for symbols denoting functions, but we were incorrect for those denoting objects.
2017-11-21 13:15:13 +00:00
Alex Voicu
f8c1c1b38e
Refactor the __device__ versions of memset and memcpy to be less awkward i.e. not return nullptr as opposed to the destination pointer (it can only be assumed it was done for maximum confusion) and actually unroll as they claim to. Change all of the {to, from}Symbol functions to use hipModuleGetGlobal, as opposed to hc::accelerator::get_symbol_address which is no longer valid with module based dispatch.
2017-11-21 02:40:34 +00:00
Alex Voicu
24f8a93ff7
Clean-up some remaining noise in program_state.cpp.
2017-11-20 22:41:46 +00:00
Alex Voicu
4693c5e56c
Correctly deal with functions from shared objects, wherein the program visible VA == so_base_va + st_value(function_symbol). Remove quaint usage of pfe for hipMemset (which is actually fill_n).
2017-11-01 22:33:13 +00:00
Alex Voicu
28f87f7d2e
This switches HIP from its currently convoluted macro + pfe based dispatch mechanism to a more natural one partially based on the existing module API. The basic idea is that HCC will always correctly emit __global__ functions: as empty-bodied stubs, on host, and as kernels, on device. It then becomes trivial to obtain the mangled name on host, at dispatch, from the function's address, and then to use the mangled name to retrieve the kernel. This should address all problems stemming from serialisation, dubious mismatches due to the manufactured functor, macro-isms et al. It also immediately enables support for generalised globals as a consequence of that being available in the module API. Finally, it will make debug much easier, since the actual names of the __global__ functions will automatically be used in traces etc. One detail is that due to how dispatch works now (hipLaunchKernel and hipLaunchKernelGGL are themselves variadic function templates which deduce the function type of the callee), in certain cases it may be necesssary to insert explicit casts to ensure that the variadic argument list selects a viable overload - this can be observed in some unit tests. Eventually we may be able to remove this limitation, but for now it does not appear terribly onerous. The code is not extremely HIPpie, nor is it fully optimised, but rather is intended as a starting point for the HIP team to make its own.
2017-11-01 15:09:59 +00:00