1/* 2 * Copyright 2018 Google, Inc. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are 6 * met: redistributions of source code must retain the above copyright 7 * notice, this list of conditions and the following disclaimer; 8 * redistributions in binary form must reproduce the above copyright --- 785 unchanged lines hidden (view full) --- 794 while (s.read() == sc_dt::Log_1) 795 wait(); 796} 797 798const char * 799sc_gen_unique_name(const char *seed) 800{ 801 auto mod = sc_gem5::pickParentModule(); |
802 if (mod) 803 return mod->uniqueName(seed); 804 sc_gem5::Process *p = sc_gem5::scheduler.current(); 805 if (p) 806 return p->uniqueName(seed); 807 return ::sc_gem5::nameGen.gen(seed); |
808} 809 810bool 811sc_hierarchical_name_exists(const char *name) 812{ 813 return sc_gem5::findEvent(name) != sc_gem5::allEvents.end() || 814 ::sc_gem5::findObject(name, sc_gem5::allObjects); 815} --- 22 unchanged lines hidden --- |