Deleted Added
sdiff udiff text old ( 9944:4ff1c5c6dcbc ) new ( 9954:72a72649a156 )
full compact
1/*
2 * Copyright (c) 2012 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 35 unchanged lines hidden (view full) ---

44#ifndef __CPU_O3_ROB_IMPL_HH__
45#define __CPU_O3_ROB_IMPL_HH__
46
47#include <list>
48
49#include "cpu/o3/rob.hh"
50#include "debug/Fetch.hh"
51#include "debug/ROB.hh"
52#include "params/DerivO3CPU.hh"
53
54using namespace std;
55
56template <class Impl>
57ROB<Impl>::ROB(O3CPU *_cpu, DerivO3CPUParams *params)
58 : cpu(_cpu),
59 numEntries(params->numROBEntries),
60 squashWidth(params->squashWidth),
61 numInstsInROB(0),
62 numThreads(params->numThreads)
63{
64 std::string policy = params->smtROBPolicy;
65
66 //Convert string to lowercase
67 std::transform(policy.begin(), policy.end(), policy.begin(),
68 (int(*)(int)) tolower);
69
70 //Figure out rob policy
71 if (policy == "dynamic") {
72 robPolicy = Dynamic;

--- 14 unchanged lines hidden (view full) ---

87 for (ThreadID tid = 0; tid < numThreads; tid++) {
88 maxEntries[tid] = part_amt;
89 }
90
91 } else if (policy == "threshold") {
92 robPolicy = Threshold;
93 DPRINTF(Fetch, "ROB sharing policy set to Threshold\n");
94
95 int threshold = params->smtROBThreshold;;
96
97 //Divide up by threshold amount
98 for (ThreadID tid = 0; tid < numThreads; tid++) {
99 maxEntries[tid] = threshold;
100 }
101 } else {
102 assert(0 && "Invalid ROB Sharing Policy.Options Are:{Dynamic,"
103 "Partitioned, Threshold}");

--- 463 unchanged lines hidden ---