MCPcopy Create free account
hub / github.com/clMathLibraries/clBLAS / checkTimeOutPut2

Function checkTimeOutPut2

src/scripts/perf/measurePerformance.py:159–169  ·  view source on GitHub ↗
(args)

Source from the content-addressed store, hash-verified

157#This function is defunct now
158@timeout(5, "fileName") # timeout is 15 minutes, 15*60 = 300 secs
159def checkTimeOutPut2(args):
160 global currCommandProcess
161 #ret = subprocess.check_output(args, stderr=subprocess.STDOUT)
162 #return ret
163 currCommandProcess = subprocess.Popen(args, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
164 printLog("Curr Command Process id = "+str(currCommandProcess.pid))
165 ret = currCommandProcess.communicate()
166 if(ret[0] == None or ret[0] == ''):
167 errCode = currCommandProcess.poll()
168 raise subprocess.CalledProcessError(errCode, args, output=ret[1])
169 return ret[0]
170
171#Spawns a separate thread to execute the library command and wait for that thread to complete
172#This wait is of 900 seconds (15 minutes). If still the thread is alive then we kill the thread

Callers

nothing calls this directly

Calls 1

printLogFunction · 0.85

Tested by

no test coverage detected