 Better x86 Assembly Generation with GoFile 2695 internal/x/crypto/.../chacha20poly1305_amd64.s 2348 crypto/elliptic/p256_asm_amd64.s 1632 runtime/asm_amd64.s 1500 crypto/sha1/sha1block_amd64.s 1468 crypto/sha512/sha512block_amd64.s 1377 File 2695 internal/x/crypto/.../chacha20poly1305_amd64.s 2348 crypto/elliptic/p256_asm_amd64.s 1632 runtime/asm_amd64.s 1500 crypto/sha1/sha1block_amd64.s 1468 crypto/sha512/sha512block_amd64.s 13770 码力 | 155 页 | 13.54 MB | 1 年前3 Better x86 Assembly Generation with GoFile 2695 internal/x/crypto/.../chacha20poly1305_amd64.s 2348 crypto/elliptic/p256_asm_amd64.s 1632 runtime/asm_amd64.s 1500 crypto/sha1/sha1block_amd64.s 1468 crypto/sha512/sha512block_amd64.s 1377 File 2695 internal/x/crypto/.../chacha20poly1305_amd64.s 2348 crypto/elliptic/p256_asm_amd64.s 1632 runtime/asm_amd64.s 1500 crypto/sha1/sha1block_amd64.s 1468 crypto/sha512/sha512block_amd64.s 13770 码力 | 155 页 | 13.54 MB | 1 年前3
 5.cgo 原理解析及优化实践Wrapper C 代码  调用目标 C 函数  cgo_import_static 申明导入 C 函数  方便后续链接器寻址 常规编译  三种源码,分别编译,最终链接为一个可执行文件  asm 可以手写,C 不可以  go build -v -x -work cgo 调度机制 第三部分 GMP 调度模型 来源:https://learnku.com/articles/41728 兼容性处理:十来个 CPU,好几个 OS • 搞懂混合编译:Go,ASM ,C dropm 的判断条件 1. 有些操作系统,比如 Windows,不支持 pthread 来注册 destructor 2. pthread_key_create 执行成功才跳过 ① C 申明变量 & 赋值 ② Go 申明 import ③ ASM 中可以直接使用 revert 三次 3 月 25 日,第一次合入0 码力 | 45 页 | 5.74 MB | 1 年前3 5.cgo 原理解析及优化实践Wrapper C 代码  调用目标 C 函数  cgo_import_static 申明导入 C 函数  方便后续链接器寻址 常规编译  三种源码,分别编译,最终链接为一个可执行文件  asm 可以手写,C 不可以  go build -v -x -work cgo 调度机制 第三部分 GMP 调度模型 来源:https://learnku.com/articles/41728 兼容性处理:十来个 CPU,好几个 OS • 搞懂混合编译:Go,ASM ,C dropm 的判断条件 1. 有些操作系统,比如 Windows,不支持 pthread 来注册 destructor 2. pthread_key_create 执行成功才跳过 ① C 申明变量 & 赋值 ② Go 申明 import ③ ASM 中可以直接使用 revert 三次 3 月 25 日,第一次合入0 码力 | 45 页 | 5.74 MB | 1 年前3
 The Go frontend for GCCa function declaration. This uses syntax similar to what gcc sup- ports for C. func close(int) __asm__ ("close") This may only be used for a function declaration, not a definition. The expectation is will avoid the name mangling described above and simply result in a call to the name given in the __asm__ declaration. This is used to make it easier for Go code to call C code directly. 4 Passes The gccgo system calls directly. The gccgo library instead calls the appropriate C functions, using gccgo’s __asm__ extension. 7.3 Interfaces Go supports values of interface type. An interface type is simply a set0 码力 | 14 页 | 122.25 KB | 1 年前3 The Go frontend for GCCa function declaration. This uses syntax similar to what gcc sup- ports for C. func close(int) __asm__ ("close") This may only be used for a function declaration, not a definition. The expectation is will avoid the name mangling described above and simply result in a call to the name given in the __asm__ declaration. This is used to make it easier for Go code to call C code directly. 4 Passes The gccgo system calls directly. The gccgo library instead calls the appropriate C functions, using gccgo’s __asm__ extension. 7.3 Interfaces Go supports values of interface type. An interface type is simply a set0 码力 | 14 页 | 122.25 KB | 1 年前3
 Exporting Go........242.......26 11% cmd/api.....................................39305....10368 26% cmd/asm/internal/arch.......................27732.....7939 29% … unicode/utf16.........................0 码力 | 34 页 | 2.29 MB | 1 年前3 Exporting Go........242.......26 11% cmd/api.....................................39305....10368 26% cmd/asm/internal/arch.......................27732.....7939 29% … unicode/utf16.........................0 码力 | 34 页 | 2.29 MB | 1 年前3
 The fuzzy tale of an x/crypto vulnerabilityimplementation. github.com/mmcloughlin/cryptofuzz func Fuzz(data []byte) int { if purego(data) != asm(data) { panic("mismatch") } return 0 }  crypto/aes (GCM mode)  crypto/elliptic (P256)  crypto/sha10 码力 | 74 页 | 2.99 MB | 1 年前3 The fuzzy tale of an x/crypto vulnerabilityimplementation. github.com/mmcloughlin/cryptofuzz func Fuzz(data []byte) int { if purego(data) != asm(data) { panic("mismatch") } return 0 }  crypto/aes (GCM mode)  crypto/elliptic (P256)  crypto/sha10 码力 | 74 页 | 2.99 MB | 1 年前3
 Golang 101(Go语言101 中文版)  v1.21.a。当一个值被复制时,只有它 的直接部分(第17章)被复制了。 不含函数体的函数声明 我们可以使用Go汇编(Go assembly)(https://golang.google.cn/doc/asm)来实 现一个Go函数。 Go汇编代码放在后缀为.a的文件中。 一个使用Go汇编实现的函数 依旧必须在一个*.go文件中声明,但是它的声明必须不能含有函数体。 换句话 说,一个使用Go汇编实现的函数的声明中只含有它的原型。 Go汇编汇编常用来实现一些对性能要求很高的函数。 更多详情,请阅读下列文章: Go汇编快速导读(https://golang.google.cn/doc/asm) Go汇编的设计(https://talks.golang.org/2016/asm.slide) cgo 通过cgo机制,我们可以在Go代码中调用C代码,或者反之。 请阅读下列链接获取详 情: cgo官方文档(https://blog0 码力 | 591 页 | 21.40 MB | 1 年前3 Golang 101(Go语言101 中文版)  v1.21.a。当一个值被复制时,只有它 的直接部分(第17章)被复制了。 不含函数体的函数声明 我们可以使用Go汇编(Go assembly)(https://golang.google.cn/doc/asm)来实 现一个Go函数。 Go汇编代码放在后缀为.a的文件中。 一个使用Go汇编实现的函数 依旧必须在一个*.go文件中声明,但是它的声明必须不能含有函数体。 换句话 说,一个使用Go汇编实现的函数的声明中只含有它的原型。 Go汇编汇编常用来实现一些对性能要求很高的函数。 更多详情,请阅读下列文章: Go汇编快速导读(https://golang.google.cn/doc/asm) Go汇编的设计(https://talks.golang.org/2016/asm.slide) cgo 通过cgo机制,我们可以在Go代码中调用C代码,或者反之。 请阅读下列链接获取详 情: cgo官方文档(https://blog0 码力 | 591 页 | 21.40 MB | 1 年前3
 Go 入门指南(The way to Go)main+0xa5 E:/Go/GoBoek/code examples/chapter 13/panic.go:8 main.main() runtime.mainstart+0xf 386/asm.s:84 runtime.mainstart() runtime.goexit /go/src/pkg/runtime/proc.c:148 runtime.goexit()0 码力 | 380 页 | 2.97 MB | 1 年前3 Go 入门指南(The way to Go)main+0xa5 E:/Go/GoBoek/code examples/chapter 13/panic.go:8 main.main() runtime.mainstart+0xf 386/asm.s:84 runtime.mainstart() runtime.goexit /go/src/pkg/runtime/proc.c:148 runtime.goexit()0 码力 | 380 页 | 2.97 MB | 1 年前3
 The Way To Go - 2012main+0xa5 E:/Go/GoBoek/code examples/chapter 13/panic.go:8 main.main() runtime.mainstart+0xf 386/asm.s:84 runtime.mainstart() runtime.goexit /go/src/pkg/runtime/proc.c:148 runtime.goexit() ----0 码力 | 629 页 | 4.85 MB | 1 年前3 The Way To Go - 2012main+0xa5 E:/Go/GoBoek/code examples/chapter 13/panic.go:8 main.main() runtime.mainstart+0xf 386/asm.s:84 runtime.mainstart() runtime.goexit /go/src/pkg/runtime/proc.c:148 runtime.goexit() ----0 码力 | 629 页 | 4.85 MB | 1 年前3
 Go 入门指南(The way to Go)E:/Go/GoBoek/code examples/chapter 13/panic.go:8 7. main.main() 8. runtime.mainstart+0xf 386/asm.s:84 9. runtime.mainstart() 10. runtime.goexit /go/src/pkg/runtime/proc.c:148 11.0 码力 | 466 页 | 4.44 MB | 1 年前3 Go 入门指南(The way to Go)E:/Go/GoBoek/code examples/chapter 13/panic.go:8 7. main.main() 8. runtime.mainstart+0xf 386/asm.s:84 9. runtime.mainstart() 10. runtime.goexit /go/src/pkg/runtime/proc.c:148 11.0 码力 | 466 页 | 4.44 MB | 1 年前3
 Golang Manual By AstaXie-20120522instance of c in s, or -1 if c is not present in s. 8 func IndexByte(s []byte, c byte) int // asm_$GOARCH.s Build version go1.0.1. Except as noted, the content of this page is licensed under the Creative Policy Source file src/pkg/syscall/zsysnum_linux_amd64.go 1 // mksysnum_linux.pl /usr/include/asm/unistd_64.h 2 // MACHINE GENERATED BY THE ABOVE COMMAND; DO NOT EDIT 3 4 package syscall0 码力 | 6205 页 | 12.83 MB | 1 年前3 Golang Manual By AstaXie-20120522instance of c in s, or -1 if c is not present in s. 8 func IndexByte(s []byte, c byte) int // asm_$GOARCH.s Build version go1.0.1. Except as noted, the content of this page is licensed under the Creative Policy Source file src/pkg/syscall/zsysnum_linux_amd64.go 1 // mksysnum_linux.pl /usr/include/asm/unistd_64.h 2 // MACHINE GENERATED BY THE ABOVE COMMAND; DO NOT EDIT 3 4 package syscall0 码力 | 6205 页 | 12.83 MB | 1 年前3
共 10 条
- 1













