From aeb86755c35a0a5b818eeedffe82c0aa8d65c83d Mon Sep 17 00:00:00 2001 From: Aditya Avinash Atluri Date: Fri, 26 Feb 2016 13:47:58 -0600 Subject: [PATCH] Null argument handling HIPCC This change makes hipcc handle no-arguments passed to it. It solves https://github.com/AMDComputeLibraries/HIP-privatestaging/issues/1 --- hipamd/bin/hipcc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hipamd/bin/hipcc b/hipamd/bin/hipcc index 1ab4cf2759..ee58ba535a 100755 --- a/hipamd/bin/hipcc +++ b/hipamd/bin/hipcc @@ -19,6 +19,10 @@ use File::Basename; # HCC_HOME : Path to HCC SDK (default /opt/hcc). Used on AMD platforms only. # HSA_PATH : Path to HSA dir (default /opt/hsa). Used on AMD platforms only. +if(scalar @ARGV == 0){ +print "No Arguments passed, exiting ...\n"; +exit(-1); +} $verbose = $ENV{'HIPCC_VERBOSE'}; $verbose = 0 unless defined $verbose;