Ejemplo n.º 1
0
def rtl_dump_svg(dmuid, filename):

    rtlmanager = project.getRTLM()

    uid = DMUID.parse(dmuid)

    rtlm = rtlmanager.findModule(Toplevel(uid, None))

    if rtlm == None:
        printf('RTLM %s not found', dmuid)
    else:
        printf('Dumping %s...', rtlm)

        out = PrintWriter(BufferedWriter(FileWriter(filename)))

        gc = VGGCSVG(out)

        contentProvider = RTLVisualGraphContentProvider(rtlm)

        labelProvider = RTLVisualGraphLabelProvider(rtlm)

        selectionProvider = RTLVisualGraphSelectionProvider()

        layout = VGLayout(contentProvider, labelProvider, gc)

        layout.paint(selectionProvider)

        out.close()

        printf("python: wrote svg file to %s", filename)
Ejemplo n.º 2
0
def ig_dump_dot(dmuid, filename):

    igm = project.getIGM()

    uid = DMUID.parse(dmuid)

    module = igm.findModule(Toplevel(uid, None))

    if module == None:
        printf('DM %s not found', dmuid)
    else:
        printf('Dumping %s...', module)

        dot = IG2DOT(module)

        dot.blacklistField("fImportedLibs")
        dot.blacklistField("fImportedPackages")
        dot.blacklistField("fZPrjID")
        dot.blacklistField("fSFDBID")
        dot.blacklistField("fLine")
        dot.blacklistField("fCol")
        dot.blacklistField("fScore")
        dot.blacklistField("fFailed")
        dot.blacklistField("fReject")
        dot.blacklistField("fInertial")
        dot.blacklistField("fDelay")

        out = PrintWriter(BufferedWriter(FileWriter(filename)))

        dot.convert(out)
        out.close()

        printf("python: wrote dot file to %s", filename)
Ejemplo n.º 3
0
def dm_dump_dot(dmuid, filename):

    dmm = project.getDUM()

    uid = DMUID.parse(dmuid)

    dm = dmm.getDM(uid)

    if dm == None:
        printf('DM %s not found', dmuid)
    else:
        printf('Dumping %s...', dm)

        dot = AST2DOT(dm, project.getZDB())

        dot.blacklistField("fParent")
        #    dot.blacklistField("fSource")
        #    dot.blacklistField("fStartCol")
        #    dot.blacklistField("fStartLine")
        dot.blacklistField("fEndCol")
        dot.blacklistField("fEndLine")
        dot.blacklistField("fDeclarationMap")

        out = PrintWriter(BufferedWriter(FileWriter(filename)))

        dot.convert(out)
        out.close()

        printf("python: wrote dot file to %s", filename)
Ejemplo n.º 4
0
def rtl_dump_svg(dmuid,filename):

  rtlmanager = project.getRTLM()

  uid = DMUID.parse(dmuid)

  rtlm = rtlmanager.findModule(Toplevel(uid, None))

  if rtlm == None:
    printf('RTLM %s not found', dmuid)
  else:
    printf('Dumping %s...', rtlm)

    out = PrintWriter(BufferedWriter(FileWriter(filename)))

    gc = VGGCSVG(out)

    contentProvider = RTLVisualGraphContentProvider(rtlm)

    labelProvider = RTLVisualGraphLabelProvider(rtlm)

    selectionProvider = RTLVisualGraphSelectionProvider()

    layout = VGLayout(contentProvider, labelProvider, gc)

    layout.paint(selectionProvider);

    out.close()

    printf("python: wrote svg file to %s", filename)
Ejemplo n.º 5
0
def ig_dump_dot(dmuid,filename):

  igm = project.getIGM()

  uid = DMUID.parse(dmuid)

  module = igm.findModule(Toplevel(uid, None))

  if module == None:
    printf('DM %s not found', dmuid)
  else:
    printf('Dumping %s...', module)

    dot = IG2DOT(module);

    dot.blacklistField("fImportedLibs");
    dot.blacklistField("fImportedPackages");
    dot.blacklistField("fZPrjID");
    dot.blacklistField("fSFDBID");
    dot.blacklistField("fLine");
    dot.blacklistField("fCol");
    dot.blacklistField("fScore");
    dot.blacklistField("fFailed");
    dot.blacklistField("fReject");
    dot.blacklistField("fInertial");
    dot.blacklistField("fDelay");

    out = PrintWriter(BufferedWriter(FileWriter(filename)));

    dot.convert(out);
    out.close()

    printf("python: wrote dot file to %s", filename)
Ejemplo n.º 6
0
def dm_dump_dot(dmuid,filename):

  dmm = project.getDUM()

  uid = DMUID.parse(dmuid)

  dm = dmm.getDM(uid)

  if dm == None:
    printf('DM %s not found', dmuid)
  else:
    printf('Dumping %s...', dm)

    dot = AST2DOT(dm, project.getZDB())

    dot.blacklistField("fParent")
#    dot.blacklistField("fSource")
#    dot.blacklistField("fStartCol")
#    dot.blacklistField("fStartLine")
    dot.blacklistField("fEndCol")
    dot.blacklistField("fEndLine")
    dot.blacklistField("fDeclarationMap")

    out = PrintWriter(BufferedWriter(FileWriter(filename)));

    dot.convert(out);
    out.close()

    printf("python: wrote dot file to %s", filename)