2c2
< * Copyright (c) 2014-2015 Advanced Micro Devices, Inc.
---
> * Copyright (c) 2014-2017 Advanced Micro Devices, Inc.
17,19c17,19
< * 3. Neither the name of the copyright holder nor the names of its contributors
< * may be used to endorse or promote products derived from this software
< * without specific prior written permission.
---
> * 3. Neither the name of the copyright holder nor the names of its
> * contributors may be used to endorse or promote products derived from this
> * software without specific prior written permission.
33c33,34
< * Author: Sooraj Puthoor
---
> * Authors: Sooraj Puthoor,
> * Anthony Gutierrez
37a39,42
> #include "gpu-compute/of_scheduling_policy.hh"
> #include "gpu-compute/rr_scheduling_policy.hh"
> #include "params/ComputeUnit.hh"
>
40,43c45,48
< if (p->execPolicy == "OLDEST-FIRST") {
< schedPolicy = SCHED_POLICY::OF_POLICY;
< } else if (p->execPolicy == "ROUND-ROBIN") {
< schedPolicy = SCHED_POLICY::RR_POLICY;
---
> if (p->execPolicy == "OLDEST-FIRST") {
> schedPolicy = new OFSchedulingPolicy();
> } else if (p->execPolicy == "ROUND-ROBIN") {
> schedPolicy = new RRSchedulingPolicy();
45c50
< fatal("Unimplemented scheduling policy");
---
> fatal("Unimplemented scheduling policy.\n");
52,58c57
< if (schedPolicy == SCHED_POLICY::OF_POLICY) {
< return OFSchedPolicy.chooseWave();
< } else if (schedPolicy == SCHED_POLICY::RR_POLICY) {
< return RRSchedPolicy.chooseWave();
< } else {
< fatal("Unimplemented scheduling policy");
< }
---
> return schedPolicy->chooseWave(scheduleList);
62c61
< Scheduler::bindList(std::vector<Wavefront*> *list)
---
> Scheduler::bindList(std::vector<Wavefront*> *sched_list)
64,70c63
< if (schedPolicy == SCHED_POLICY::OF_POLICY) {
< OFSchedPolicy.bindList(list);
< } else if (schedPolicy == SCHED_POLICY::RR_POLICY) {
< RRSchedPolicy.bindList(list);
< } else {
< fatal("Unimplemented scheduling policy");
< }
---
> scheduleList = sched_list;