157,159c157,159
< std::ostream *os = simout.create(csprintf("profile.%s.dat",
< baseCpu->name()));
< profile->dump(tc, *os);
---
> OutputStream *os(simout.create(csprintf("profile.%s.dat", baseCpu->name())));
> profile->dump(tc, *os->stream());
> simout.close(os);