1/* 2 * Copyright (c) 2015 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 --- 58 unchanged lines hidden (view full) --- 67class SimObjectResolver; 68 69typedef std::ostream CheckpointOut; 70 71 72template <class T> 73void paramOut(CheckpointOut &cp, const std::string &name, const T ¶m); 74 |
75template <typename T> 76void 77paramOut(CheckpointOut &cp, const std::string &name, const BitUnionType<T> &p) |
78{ |
79 paramOut(cp, name, static_cast<BitUnionBaseType<T> >(p)); |
80} 81 82template <class T> 83void paramIn(CheckpointIn &cp, const std::string &name, T ¶m); 84 |
85template <typename T> 86void 87paramIn(CheckpointIn &cp, const std::string &name, BitUnionType<T> &p) |
88{ |
89 BitUnionBaseType<T> b; 90 paramIn(cp, name, b); 91 p = b; |
92} 93 94template <class T> 95bool optParamIn(CheckpointIn &cp, const std::string &name, T ¶m, 96 bool warn = true); 97 |
98template <typename T> 99bool 100optParamIn(CheckpointIn &cp, const std::string &name, 101 BitUnionType<T> &p, bool warn = true) |
102{ |
103 BitUnionBaseType<T> b; 104 if (optParamIn(cp, name, b, warn)) { 105 p = b; 106 return true; 107 } else { 108 return false; 109 } |
110} 111 112template <class T> 113void arrayParamOut(CheckpointOut &cp, const std::string &name, 114 const T *param, unsigned size); 115 116template <class T> 117void arrayParamOut(CheckpointOut &cp, const std::string &name, --- 282 unchanged lines hidden --- |