Lines Matching refs:asm
51 asm := &bytes.Buffer{}
56 fmt.Fprintln(asm, ".globl __dlwrap_linker_offset")
57 fmt.Fprintf(asm, ".set __dlwrap_linker_offset, 0x%x\n", baseLoadAddr)
74 fmt.Fprintf(asm, ".section %s, \"a%s\"\n", sectionName, flags)
76 fmt.Fprintf(asm, ".globl %s\n%s:\n\n", symName, symName)
84 bytesToAsm(asm, buffer)
93 fmt.Fprintf(asm, ".fill 0x%x, 1, 0\n", prog.Memsz-prog.Filesz)
95 fmt.Fprintln(asm)
101 if err := ioutil.WriteFile(asmPath, asm.Bytes(), 0777); err != nil {
114 func bytesToAsm(asm io.Writer, buf []byte) {
118 fmt.Fprint(asm, "\n")
120 fmt.Fprint(asm, ".byte ")
122 fmt.Fprint(asm, ",")
124 fmt.Fprintf(asm, "%d", b)
126 fmt.Fprintln(asm)