25#include "ir/visitor.h"
28void dump(std::ostream &out,
const IR::Node *n);
29void dump(std::ostream &out,
const IR::Node *n,
unsigned maxdepth);
31void dump(
const IR::Node *n,
unsigned maxdepth);
33void dump(
const IR::INode *n,
unsigned maxdepth);
34void dump(uintptr_t p);
35void dump(uintptr_t p,
unsigned maxdepth);
37void dump_notype(
const IR::Node *n,
unsigned maxdepth);
39void dump_notype(
const IR::INode *n,
unsigned maxdepth);
40void dump_notype(uintptr_t p);
41void dump_notype(uintptr_t p,
unsigned maxdepth);
45std::string dumpToString(
const IR::Node *n);
51 friend std::ostream &operator<<(std::ostream &,
const Dump &);
54 explicit Dump(
const IR::Node *n,
unsigned maxdepth = ~0U) : n(n), maxdepth(maxdepth) {}
58inline std::ostream &operator<<(std::ostream &out,
const Dump &d) {
60 dump(out, d.n, d.maxdepth);