diff --git a/hipamd/tests/src/deviceLib/hipDoublePrecisionIntrinsics.cpp b/hipamd/tests/src/deviceLib/hipDoublePrecisionIntrinsics.cpp index 1b087118b8..a3a302a3ef 100644 --- a/hipamd/tests/src/deviceLib/hipDoublePrecisionIntrinsics.cpp +++ b/hipamd/tests/src/deviceLib/hipDoublePrecisionIntrinsics.cpp @@ -19,6 +19,13 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ + +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include #include "test_common.h" @@ -62,3 +69,9 @@ __global__ void compileDoublePrecisionIntrinsics(hipLaunchParm lp, int ignored) { double_precision_intrinsics(); } + +int main() +{ + hipLaunchKernel(compileDoublePrecisionIntrinsics, dim3(1,1,1), dim3(1,1,1), 0, 0, 1); + passed(); +} diff --git a/hipamd/tests/src/deviceLib/hipDoublePrecisionMathDevice.cpp b/hipamd/tests/src/deviceLib/hipDoublePrecisionMathDevice.cpp index e5d57b4dce..df5dad3968 100644 --- a/hipamd/tests/src/deviceLib/hipDoublePrecisionMathDevice.cpp +++ b/hipamd/tests/src/deviceLib/hipDoublePrecisionMathDevice.cpp @@ -19,6 +19,13 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ + +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include #include "test_common.h" @@ -124,3 +131,9 @@ __global__ void compileDoublePrecisionMathOnDevice(hipLaunchParm lp, int ignored { double_precision_math_functions(); } + +int main() +{ + hipLaunchKernel(compileDoublePrecisionMathOnDevice, dim3(1,1,1), dim3(1,1,1), 0, 0, 1); + passed(); +} diff --git a/hipamd/tests/src/deviceLib/hipDoublePrecisionMathHost.cpp b/hipamd/tests/src/deviceLib/hipDoublePrecisionMathHost.cpp index af923da3aa..bfdf874c6d 100644 --- a/hipamd/tests/src/deviceLib/hipDoublePrecisionMathHost.cpp +++ b/hipamd/tests/src/deviceLib/hipDoublePrecisionMathHost.cpp @@ -19,6 +19,13 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ + +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include #include "test_common.h" @@ -130,3 +137,9 @@ static void compileOnHost() { double_precision_math_functions(); } + +int main() +{ + compileOnHost(); + passed(); +} diff --git a/hipamd/tests/src/deviceLib/hipFloatMathPrecise.cpp b/hipamd/tests/src/deviceLib/hipFloatMathPrecise.cpp index 12f7875949..78fe47cfe8 100644 --- a/hipamd/tests/src/deviceLib/hipFloatMathPrecise.cpp +++ b/hipamd/tests/src/deviceLib/hipFloatMathPrecise.cpp @@ -19,6 +19,13 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ + +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include #include "test_common.h" @@ -120,4 +127,5 @@ __global__ void FloatMathPrecise(hipLaunchParm lp) int main() { hipLaunchKernel(FloatMathPrecise, dim3(1,1,1), dim3(1,1,1), 0, 0); + passed(); } diff --git a/hipamd/tests/src/deviceLib/hipIntegerIntrinsics.cpp b/hipamd/tests/src/deviceLib/hipIntegerIntrinsics.cpp index d712c5a93b..6bf13a0809 100644 --- a/hipamd/tests/src/deviceLib/hipIntegerIntrinsics.cpp +++ b/hipamd/tests/src/deviceLib/hipIntegerIntrinsics.cpp @@ -19,6 +19,14 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ + +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + + #include #include #include "test_common.h" @@ -57,3 +65,9 @@ __global__ void compileIntegerIntrinsics(hipLaunchParm lp, int ignored) { integer_intrinsics(); } + +int main() +{ + hipLaunchKernel(compileIntegerIntrinsics, dim3(1,1,1), dim3(1,1,1), 0, 0, 1); + passed(); +} diff --git a/hipamd/tests/src/deviceLib/hipMathFunctions.cpp b/hipamd/tests/src/deviceLib/hipMathFunctions.cpp index ed62120613..450b6126b0 100644 --- a/hipamd/tests/src/deviceLib/hipMathFunctions.cpp +++ b/hipamd/tests/src/deviceLib/hipMathFunctions.cpp @@ -20,15 +20,6 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -/* HIT_START - * BUILD: %tHost %s hipSinglePrecisionMathHost.cpp hipDoublePrecisionMathHost.cpp ../test_common.cpp - * BUILD: %tDevice %s hipSinglePrecisionMathDevice.cpp hipDoublePrecisionMathDevice.cpp ../test_common.cpp - * BUILD: hipIntrinsics %s hipSinglePrecisionIntrinsics.cpp hipDoublePrecisionIntrinsics.cpp hipIntegerIntrinsics.cpp ../test_common.cpp - * RUN: %tHost - * RUN: %tDevice - * RUN: hipIntrinsics - * HIT_END - */ #include "hip/hip_runtime.h" #include "test_common.h" diff --git a/hipamd/tests/src/deviceLib/hipSinglePrecisionIntrinsics.cpp b/hipamd/tests/src/deviceLib/hipSinglePrecisionIntrinsics.cpp index 6737c6ee9d..3407748437 100644 --- a/hipamd/tests/src/deviceLib/hipSinglePrecisionIntrinsics.cpp +++ b/hipamd/tests/src/deviceLib/hipSinglePrecisionIntrinsics.cpp @@ -19,6 +19,12 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include #include "test_common.h" @@ -78,3 +84,10 @@ __global__ void compileSinglePrecisionIntrinsics(hipLaunchParm lp, int ignored) { single_precision_intrinsics(); } + + +int main() +{ + hipLaunchKernel(compileSinglePrecisionIntrinsics, dim3(1,1,1), dim3(1,1,1), 0, 0, 1); + passed(); +} diff --git a/hipamd/tests/src/deviceLib/hipSinglePrecisionMathDevice.cpp b/hipamd/tests/src/deviceLib/hipSinglePrecisionMathDevice.cpp index 4576faed93..53ccd2251f 100644 --- a/hipamd/tests/src/deviceLib/hipSinglePrecisionMathDevice.cpp +++ b/hipamd/tests/src/deviceLib/hipSinglePrecisionMathDevice.cpp @@ -19,6 +19,13 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ + +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include #include "test_common.h" @@ -125,3 +132,9 @@ __global__ void compileSinglePrecisionMathOnDevice(hipLaunchParm lp, int ignored { single_precision_math_functions(); } + +int main() +{ + hipLaunchKernel(compileSinglePrecisionMathOnDevice, dim3(1,1,1), dim3(1,1,1), 0, 0, 1); + passed(); +} diff --git a/hipamd/tests/src/deviceLib/hipSinglePrecisionMathHost.cpp b/hipamd/tests/src/deviceLib/hipSinglePrecisionMathHost.cpp index d48cea5ff6..933a51074f 100644 --- a/hipamd/tests/src/deviceLib/hipSinglePrecisionMathHost.cpp +++ b/hipamd/tests/src/deviceLib/hipSinglePrecisionMathHost.cpp @@ -19,6 +19,13 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ + +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include #include "test_common.h" @@ -133,3 +140,9 @@ static void compileOnHost() { single_precision_math_functions(); } + +int main() +{ + compileOnHost(); + passed(); +} diff --git a/hipamd/tests/src/deviceLib/hipTestDeviceSymbol.cpp b/hipamd/tests/src/deviceLib/hipTestDeviceSymbol.cpp index 1158bf3f9d..f90ed38967 100644 --- a/hipamd/tests/src/deviceLib/hipTestDeviceSymbol.cpp +++ b/hipamd/tests/src/deviceLib/hipTestDeviceSymbol.cpp @@ -17,8 +17,15 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/* HIT_START + * BUILD: %t %s ../test_common.cpp + * RUN: %t + * HIT_END + */ + #include #include +#include"test_common.h" #include #define NUM 1024 @@ -72,4 +79,5 @@ int main() for(unsigned i=0;i #include #include +#include"test_common.h" #define NUM 1024 #define SIZE NUM*sizeof(float) @@ -65,5 +72,5 @@ int main(){ hipLaunchKernel(vAdd, dim3(32,1,1), dim3(32,1,1), 0, 0, In1d, In2d, In3d, In4d, Outd); hipMemcpy(Out, Outd, SIZE, hipMemcpyDeviceToHost); assert(Out[10] == 2*In1[10] + 2*In2[10] + In3[10]); - + passed(); }