Deleted Added
sdiff udiff text old ( 13567:08896772e474 ) new ( 13757:79c0e02258d1 )
full compact
1/*
2 * Copyright (c) 2015, 2018 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

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

469 showParam(os, param[0]);
470 for (unsigned i = 1; i < size; ++i) {
471 os << " ";
472 showParam(os, param[i]);
473 }
474 os << "\n";
475}
476
477
478template <class T>
479void
480arrayParamIn(CheckpointIn &cp, const std::string &name,
481 T *param, unsigned size)
482{
483 const std::string &section(Serializable::currentSection());
484 std::string str;
485 if (!cp.find(section, name, str)) {

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

491
492 std::vector<std::string> tokens;
493
494 tokenize(tokens, str, ' ');
495
496 // Need this if we were doing a vector
497 // value.resize(tokens.size());
498
499 if (tokens.size() != size) {
500 fatal("Array size mismatch on %s:%s'\n", section, name);
501 }
502
503 for (std::vector<std::string>::size_type i = 0; i < tokens.size(); i++) {
504 // need to parse into local variable to handle vector<bool>,
505 // for which operator[] returns a special reference class
506 // that's not the same as 'bool&', (since it's a packed
507 // vector)
508 T scalar_value;
509 if (!parseParam(tokens[i], scalar_value)) {

--- 173 unchanged lines hidden ---