html

package
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 4, 2022 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AsmBlockHTML

func AsmBlockHTML(b *asm.Block) string

func AsmFuncHTML

func AsmFuncHTML(f *asm.Func) string

func BlockHTML

func BlockHTML(b *ir.Block) string

func FuncHTML

func FuncHTML(f *ir.Func, phase string) string

func LongAsmInstrHTML

func LongAsmInstrHTML(v *asm.Instr) string

func LongBlockHTML

func LongBlockHTML(b *ir.Block) string

func LongValueHTML

func LongValueHTML(v *ir.Value) string

Types

type ByTopo

type ByTopo []FuncLines

ByTopo sorts topologically: target function is on top, followed by inlined functions sorted by filename and line numbers.

func (ByTopo) Len

func (x ByTopo) Len() int

func (ByTopo) Less

func (x ByTopo) Less(i, j int) bool

func (ByTopo) Swap

func (x ByTopo) Swap(i, j int)

type FuncLines

type FuncLines struct {
	Filename    string
	StartLineno uint
	Lines       []string
}

FuncLines contains source code for a function to be displayed in sources column.

type HTMLWriter

type HTMLWriter struct {
	Func *ir.Func
	// contains filtered or unexported fields
}

func NewHTMLWriter

func NewHTMLWriter(path string, f *ir.Func) *HTMLWriter

func (*HTMLWriter) Close

func (w *HTMLWriter) Close()

func (*HTMLWriter) Fatalf

func (w *HTMLWriter) Fatalf(msg string, args ...interface{})

Fatalf reports an error and exits.

func (*HTMLWriter) Logf

func (w *HTMLWriter) Logf(msg string, args ...interface{})

Logf calls the (w *HTMLWriter).Func's Logf method passing along a msg and args.

func (*HTMLWriter) Printf

func (w *HTMLWriter) Printf(msg string, v ...interface{})

func (*HTMLWriter) WriteAST

func (w *HTMLWriter) WriteAST(phase string, buf *bytes.Buffer)

func (*HTMLWriter) WriteAsm

func (w *HTMLWriter) WriteAsm(phase string, fn *asm.Func)

func (*HTMLWriter) WriteAsmBuf

func (w *HTMLWriter) WriteAsmBuf(phase string, buf *bytes.Buffer)

func (*HTMLWriter) WriteColumn

func (w *HTMLWriter) WriteColumn(phase, title, class, html string)

WriteColumn writes raw HTML in a column headed by title. It is intended for pre- and post-compilation log output.

func (*HTMLWriter) WriteMultiTitleColumn

func (w *HTMLWriter) WriteMultiTitleColumn(phase string, titles []string, class, html string)

func (*HTMLWriter) WritePhase

func (w *HTMLWriter) WritePhase(phase, title string)

WritePhase writes f in a column headed by title. phase is used for collapsing columns and should be unique across the table.

func (*HTMLWriter) WriteSources

func (w *HTMLWriter) WriteSources(phase string, fn string, lines []string, startline int)

WriteSources writes lines as source code in a column headed by title. phase is used for collapsing columns and should be unique across the table.

func (*HTMLWriter) WriteString

func (w *HTMLWriter) WriteString(s string)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL