Граф коммитов

86 Коммитов

Автор SHA1 Сообщение Дата
Aditya Atluri 01b66dd998 Fixed Hawaii link issues
1. Split hip_ir.ll to hip_hc.ll and hip_hc_gfx803.ll
 a. hip_hc.ll contains arch generic ir implementations
 b. hip_hc_gfx803.ll contains gfx803 (fiji, polaris) specific ir
2. HIPCC can now parse --amdgpu-target=*.
 a. Usage: hipcc --amdgpu-target=gfx803 --amdgpu-target=gfx701
 b. TODO: Convert to --amdgpu-target=gfx803,gfx701
3. With LLC in HCC able to generate native f16 isa, removed inline half asm math ops
4. Fixed threadfence and threadfence_block to use functions in rocdl

Change-Id: Ic9a9e3e04139b0d75d2c2a263c030ca77adc1019
2017-02-08 12:04:05 -06:00
Ben Sander 0dabdeb01f Move core env var processing to env.cpp 2017-01-23 22:34:41 -06:00
Aditya Atluri b723169ee9 Moved device code to mimic cuda header behavior
1. All fp32, fp64 math device/host functions should be in math_functions.h/.cpp
2. All fp32, fp64 fast math intrinsics for device/host functions should be in device_functions.h/.cpp
3. All the device code implementations should be in device_util.h/.cpp
4. Hence, made changes appropriately by moving code and creating new header files
5. Added math_functions.cpp/.h
6. Changed #ifndef signature to make sure no conflicts between headers with same names in hip/hip_runtime.h and hip/hcc_detail/hip_runtime.h
7. Changed tests to fit the code changes, making them to include appropriate headers
8. Added math_functions.cpp to CMakeLists.txt
9. Some of the tests are still broken, mostly host math functions will fix them in next commit
10. TODO: FIX compilation issues for host math functions

Change-Id: I7a17637d7e294a7d224ffba932c1a08668febd26
2017-01-17 14:57:51 -06:00
scchan 4fd48084a6 [cmake] add library dependencies to hip_hcc libraries 2017-01-05 18:26:54 -05:00
Maneesh Gupta 9b6d1588ba hip_hcc package changes
- updated hip_hcc package creation dependencies
- support build hip_hcc package for HCC-1.0

Change-Id: Idf23e415eff8cb352a8906191c79bd822c7618e7
2016-12-22 15:30:38 +05:30
Aditya Atluri 04ab5f7f56 added few type reinterpret cast device functions
1. __int_as_float
2. __hiloint2double

Change-Id: Id247c196887b24a12090f0521bf91e13afeec733
2016-12-13 14:41:36 -06:00
Maneesh Gupta ef046c7098 Improve shared and static library support
hipcc accepts new parameter -use-staticlib and -use-sharedlib to
control linking behavior. Default is still static library.

Change-Id: I28fb9a939f8177c75abefd8b77d8118a6666d1f4
2016-12-01 15:33:12 +05:30
Maneesh Gupta c0419cc749 Refactor for building HIP as dynamic library
Change-Id: I65a3d9d589c4fdbbdcf1611e5427224253be8260
2016-11-18 14:33:20 +05:30
scchan 3d6bf5e799 Add extra linker flags to the shared library build
Change-Id: I19e569d566fb5e25e343e364a3053a3f12659361
2016-11-18 14:18:29 +05:30
pensun 50867efa10 Add direct test case for threadfence_system workaround
Change-Id: I5b21b590e957c901044741ac94e816cd8b1426f9
2016-11-11 15:09:43 -06:00
Maneesh Gupta a12d5a8989 CMakeLists.txt: Cascade CMAKE_BUILD_TYPE to tests
Change-Id: I53a3ea951c1fd57e43a02381a457c1dedc1a34f7
2016-11-10 21:26:34 +05:30
pensun 4d7ac1e091 resolve conflicts for git pull
Change-Id: Ie353b831e2241bc28042069b6cc7405257e871e1
2016-11-09 21:38:43 -06:00
Maneesh Gupta c5a2ad4964 CMakeLists.txt: Update include paths needed for Fedora support
Change-Id: Ib84f9dba30d2c64f344d6f8e85ddbe15f30af1a0
2016-10-28 14:12:53 +05:30
Maneesh Gupta feffd829ed Update packaging scripts to handle updated HCC package versioning
Change-Id: Id93267b7cf9fd05e60004cc6c45b5fc7d10b3130
2016-10-17 12:48:05 +05:30
Maneesh Gupta 1329be958a .buildInfo -> .hipInfo & .version -> .hipVersion
Change-Id: I8023f4349621fd81c58615737b7e897649e0f7ca
2016-10-11 11:13:41 +05:30
Aditya Atluri dc1042ce6d added threadfence feature for hcc
1. Added feature for __threadfence and __threadfence_block
2. Added feature for using LLVM IR files directly while compilation
3. Added test for threadfence and threadfence_block

Change-Id: Ib7e5d89b4cca1a135952b317e5809cd05b56a3c9
2016-10-10 15:29:50 -05:00
Maneesh Gupta 78307edb01 Add packaging steps for hipify-clang
Change-Id: I0ed916d5fcb4fc4734f1d92e686fc053e4680052
2016-10-05 22:34:42 +05:30
Maneesh Gupta 798d4be080 clang-hipify -> hipify-clang. Also attempt to build it by default
Change-Id: I694e6c772f5347c820d9bd6c9aa61d6d9696911e
2016-10-05 13:06:22 +05:30
Maneesh Gupta b951cc99ed Move include/* to include/hip/*
Change-Id: I7a7b2839b4df59c7a4c503550f99fdc9e45c0f54
2016-10-04 22:17:18 +05:30
Maneesh Gupta 14f4c3856d cmake: Fix identations
Change-Id: Iecc79f030968a2b67bfa41218d0a4edbd2594f63
2016-10-03 22:52:23 +05:30
Maneesh Gupta 96e8027d81 Rebuild hip_hcc if hcc version changes
And also force rebuild of .buildInfo & .version everytime

Change-Id: I97e0d3c24fd693366a293803088014d13ca640cc
2016-09-29 10:29:35 +05:30
Maneesh Gupta 0d850c32df make test: Build tests in parallel
Change-Id: If7b9d0519554226d09d8e6264eb248cd2dd53a2e
2016-09-27 17:21:18 +05:30
Maneesh Gupta f7b0540c80 Add target test that uses HIT to the top-level HIP cmake
Change-Id: Idae1c0b39e6c4deb9f8fdb192bab17b0904941d7
2016-09-23 14:46:48 +05:30
Maneesh Gupta deb7493ca1 CMakeLists.txt: No need to define HIP_HCC
Change-Id: I0aa149bf3ffd4ee665bf3b822e178b3d74efe2af
2016-09-23 10:44:39 +05:30
Ben Sander c645e53fdd Remove unpinned_copy code. Other cleanup.
Change-Id: Ie3f71439cf1ba729ef223d078917c403d3de879a
2016-09-22 14:21:19 -05:00
Maneesh Gupta de402d7372 Fix bug in defining HIP_VERSION_*
Change-Id: I52fcd78386ee4b5035aba4c9bced3372b7894650
2016-09-22 16:32:05 +05:30
Maneesh Gupta a5e951e3d9 Expose HIP_VERSION_* to HIP source and HIP applications
Change-Id: I6fb0d6711642c4fad2cd89b98707ee4b548b7243
2016-09-22 12:27:07 +05:30
Maneesh Gupta 87d7e95693 CMakeLists.txt: Change default to HIP static library
Change-Id: I9b233c6873d0a69d9aedeb1f9f3773e4258c6f44
2016-09-07 19:22:38 +05:30
Maneesh Gupta 295df9e006 CMakeLists.txt: install cmake folder
Change-Id: I5367281c62529b4b832c77ea93e3994a5f9133f4
2016-09-02 15:08:36 +05:30
Maneesh Gupta 1d12e8cb1c Make it easier to switch between HIP library formats
Change-Id: Id16406795a81f4bb64dbcb76b9b8763ffe59aac6
2016-08-19 13:07:22 +05:30
Maneesh Gupta e6993e5e3d CMakeLists: use macro for appending to config file
Change-Id: I71ca3769b58b146f95368c2a2f6615c1eb47e121
2016-08-19 12:17:00 +05:30
Maneesh Gupta d9a2af3a12 Fix version related bug in CMakeLists.txt
Change-Id: I31c567575185a4e85f5f24d3f105f7cb1beed425
2016-08-18 13:56:25 +05:30
Aditya Atluri 3d27bbd3db Added kernel compilation driver apis
1. Added 2 new driver apis, hipModuleLoad, hipModuleGetFunction

Change-Id: If464a7fad178121e3da791c7ac9e17ebc01a9cd0
Issues: When a sample written with them shows Aborted (core dumped) when exiting
2016-08-16 14:36:25 -05:00
Maneesh Gupta cd8c8171b7 Several improvements to hipcc, hipconfig and CMakeLists.txt
- moved hip base version information back to hipconfig
 - fixed bug in hip patch version generation
 - renamed .hipconfig to .buildInfo
 - HCC_HOME is logged to .buildInfo only when HIP_DEVELOPER environment
 - variable is defined
 - hipcc and hipconfig require perl 5.10.1 or above
 - replaced unless defined with logic-defined or
 - added ROCM_TARGET for carrizo
 - moved config parsing to a subroutine
 - config parsing does not set VALID key anymore
 - hipcc honors HCC_HOME environment variable above buildInfo
 - hip_base package now bundles .version in bin directory

Change-Id: Iaeea6d7529671220b02e07337946aaee0af90310
2016-08-14 16:22:25 +05:30
Maneesh Gupta 0827e44a90 Updates to HIP version string format
HIP patch version is now a monotonically increasing number

Change-Id: Ia6e35794b702bbd2018c502564d0a65997819687
2016-08-12 23:21:37 +05:30
Maneesh Gupta 76eeaf4fbb Fix build issues due to refactoring changes
Change-Id: I0a709ff4864244ba1b49e1a25327e3901ed6e17f
2016-08-09 22:49:32 +05:30
Ben Sander 8f402132ba Add initial context implementation.
APIs: hipInit, hipCtxCreate.
Track TLS default ctx.  Set deviceID now changes the ctx.
Add first context test.

Change-Id: If1cb9989b5a04a36147e25e84904336c7b6f3d88
2016-08-08 17:49:02 -05:00
Maneesh Gupta bc394505cc .hipconfig now lives in lib
Also moved reading .hipconfig to begining of hipcc

Change-Id: Ibb9d32bef64a79f189aa037c36814759c8cc8052
2016-08-03 12:01:48 +05:30
scchan 2f6ac8c36e compile all hip objects with -fPIC so that they work in a shared library
Change-Id: I1f8355d4a81dbd5f408062c317c16a5efc668876
2016-08-03 11:48:46 +05:30
Maneesh Gupta c38d0466b8 Only create .hipconfig on install
Change-Id: I9c20440023401f5794b33a0165e0918372783a68
2016-08-03 11:25:59 +05:30
Aditya Atluri 9c45d9eaed Added configuration file to be used by hipcc
1. CMake will create .hip-config file in bin directory
Future Work: Need to make changes to hipcc to read the file

Change-Id: Ia7dc48d43787921d5af4ab07d7a5befbcf904465
2016-08-02 15:45:46 -05:00
Maneesh Gupta b23fad53cc Fix using ATP markers
Change-Id: If2d04f80b580237426c569737551e2001a8cd35a
2016-07-21 16:02:51 +05:30
Maneesh Gupta 779502e4a2 Set cmake policy CMP0037 to old behavior for newer cmake versions
Change-Id: Ib2a7da53a238a489e73d6c006c50f12f07f866a1
2016-07-19 06:52:38 +05:30
Maneesh Gupta 9e5f5c79c8 Fix whitespace in cmakefile
Change-Id: Ide671e19ea15d57cc8619ec57ad10bca615b3858
2016-07-12 13:00:42 +05:30
Maneesh Gupta 723e0def03 cmake queries hip version from hipconfig
Change-Id: I8c65ca508ddc288111eaa1d818213c72ef27ac1b
2016-07-12 12:40:35 +05:30
Aditya Atluri 5633cc34cc moved half support to a source file
Change-Id: I7c09b41877e22c1b743dea25a585e5307427dafd
2016-06-30 18:23:29 +05:30
Rahul Garg 3029be78b8 Included code to calculate value of maxThreadsPerMultiprocessor property
Change-Id: Ie7cad7442f36a7163e715048de5a309febc28664
2016-06-24 15:10:11 +05:30
Maneesh Gupta 39ae4c25c1 Add target 'make doc' to cmakelists.txt
Change-Id: I382201b02cf3cc66bc64bd305d7f8549e25c2bb9
2016-06-21 08:13:19 +05:30
Maneesh Gupta 01032b91d9 cmake picks HIP version from hipcc
Change-Id: I334d9573bb6d60fe907a13083486f06504a621e4
2016-06-14 14:57:56 +05:30
Maneesh Gupta 6d2c763b26 dynamically compute HCC version dependency for hip_hcc package
Change-Id: I5eca934826f12ee002416b299fd562db0f60056c
2016-05-09 06:01:33 -04:00