In this study, a new feature is added to the smart message passing interface (SMPI) approach (SMPIA) based on the prioritization method, which can completely eliminate the task starvation and lack of sufficient resources problems through prioritizing the tasks. The proposed approach is based on prioritizing the tasks and the urgency of implementation. Tasks are prioritized based on execution time, workload, the task with a more sensitive priority is executed earlier by the free source. The idea of demand-bound functions (DBFs) was extended to the SMPIA setting based on partitions and caps. For each task, two DBFs are constructed, DBFLO and DBFHI, for the LO and HI criticality modes, respectively. The simulation results returned by MATLAB showed that with the optimized SMPIA (O-SMPIA), the parameters of maximum service execution time, response time, delay time, and throughput improved in this work. In addition, the results confirmed that the reduction of execution time, completion time, and resource consumption time did not affect the response time and throughput of workflow tasks and did not cause inefficient use of resources in virtual machines (VMs) and data centers (DCs). The evaluation of performance metrics showed that the delay, response time of the Greedy algorithm was less than that of Max-Min and Min-Min. At the same time, the execution time of Max-Min was less than the others and the throughput of the Greedy was longer. The effect and throughput of O-SMPIA became more obvious as change to the job count and the number of cloud workloads increased. It is also worth mentioning that one of the main advantages of the O-SMPIA to other methods is the efficient use of time to execute all the defined tasks by CPU.