use of com.dat3m.dartagnan.utils.printer.Printer in project Dat3M by hernanponcedeleon.
the class Simplifier method run.
@Override
public void run(Program program) {
Preconditions.checkArgument(!program.isUnrolled(), "Simplifying should be performed before unrolling.");
logger.info("pre-simplification: " + program.getEvents().size() + " events");
for (Thread t : program.getThreads()) {
if (simplify(t)) {
t.clearCache();
}
}
program.clearCache(false);
logger.info("post-simplification: " + program.getEvents().size() + " events");
if (print) {
System.out.println("===== Program after simplification =====");
System.out.println(new Printer().print(program));
System.out.println("========================================");
}
}
use of com.dat3m.dartagnan.utils.printer.Printer in project Dat3M by hernanponcedeleon.
the class PrinterTest method PrintLinux3.
@Test()
public void PrintLinux3() throws Exception {
Program p = new ProgramParser().parse(new File(ResourceHelper.LITMUS_RESOURCE_PATH + "litmus/C/manual/atomic/C-atomic-01.litmus"));
assertNotNull(new Printer().print(p));
assertNotNull(p.getAss().toString());
}
use of com.dat3m.dartagnan.utils.printer.Printer in project Dat3M by hernanponcedeleon.
the class PrinterTest method PrintLinux.
@Test()
public void PrintLinux() throws Exception {
Program p = new ProgramParser().parse(new File(ResourceHelper.TEST_RESOURCE_PATH + "litmus/C-rcu-link-after.litmus"));
assertNotNull(new Printer().print(p));
assertNotNull(p.getAss().toString());
}
use of com.dat3m.dartagnan.utils.printer.Printer in project Dat3M by hernanponcedeleon.
the class PrinterTest method PrintBpl1.
// Test to call toString() of most events
@Test()
public void PrintBpl1() throws Exception {
Program p = new ProgramParser().parse(new File(ResourceHelper.TEST_RESOURCE_PATH + "boogie/concurrency/fib_bench-1-O0.bpl"));
assertNotNull(new Printer().print(p));
LoopUnrolling.newInstance().run(p);
Compilation.newInstance().run(p);
assertNotNull(new Printer().print(p));
}
use of com.dat3m.dartagnan.utils.printer.Printer in project Dat3M by hernanponcedeleon.
the class PrinterTest method PrintAARCH64.
@Test()
public void PrintAARCH64() throws Exception {
Program p = new ProgramParser().parse(new File(ResourceHelper.TEST_RESOURCE_PATH + "litmus/MP+popl+poap.litmus"));
assertNotNull(new Printer().print(p));
assertNotNull(p.getAss().toString());
}
Aggregations