Can you tell us a bit more about what processing the program is doing? It sounds very slow.
I guess what you mean is to make sure that the program stops after an hour of processing?
You could use a *DTAARA or a database file, which you check occasionally in the program to see whether the program should now stop. At the same time as your program starts, submit another job with a DLYJOB of 60 minutes, which after the 60 minutes will change the *DTAARA or database file to indicate that your program should stop.
Hope this helps. It’s not a marvellous solution.