Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Shitaibin/golang_step_by_step
/ functions
Functions
617 in github.com/Shitaibin/golang_step_by_step
⨍
Functions
617
◇
Types & classes
84
↓ 14 callers
Function
DoJob
var data [DataSize]int 计算密集型任务 限制Go routine的数量,完成并发任务
concurrent/cpucore/core_test.go:16
↓ 12 callers
Function
PipelineFan
(bufSize int)
golang_pipeline_step_by_step/buffer_size/hi_fan_buffered.go:74
↓ 7 callers
Function
sleep
()
gc/top_pprof/demo.go:38
↓ 7 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/buffer_size/hi_fan_buffered.go:18
↓ 6 callers
Method
AddPeer
(p *Peer)
first_class_function/host_v3/host/host.go:53
↓ 6 callers
Function
printValue
使用Value.Interface()获取真实值并打印
reflect/law_of_reflect/to_interface.go:9
↓ 6 callers
Function
printValue
使用Value.Kind()类型判断,并获取真实值进行打印
reflect/law_of_reflect/to_reflect.go:9
↓ 6 callers
Function
quickSortSlow
(nums []int, a, b int)
isort/sort_test.go:80
↓ 5 callers
Method
AddPeer
(p *Peer)
first_class_function/host_v2/host/host.go:61
↓ 5 callers
Method
AddPeer
(p *Peer)
first_class_function/host_v1/host/host.go:32
↓ 5 callers
Method
Do
(f func())
problems/concurrent/once0.go:14
↓ 5 callers
Method
GetPeer
GetPeer 当前Peer不存在时返回nil。
first_class_function/host_v3/host/host.go:78
↓ 5 callers
Method
Hello
(ctx context.Context, in *String, opts ...grpc.CallOption)
grpc/server/hello.pb.go:174
↓ 5 callers
Function
printMemStats
(tag string)
gc/top_pprof/demo.go:42
↓ 4 callers
Method
Put
(key, value int)
problems/concurrent/map1.go:17
↓ 4 callers
Function
doTest
(addFunc func(*peer.Peer), rmFunc func(string), getFunc func(string) *peer.Peer)
sync_atomic/atomic_test.go:76
↓ 4 callers
Function
genData
(n int)
isort/sort_test.go:239
↓ 4 callers
Function
insertionSort
(nums []int, a, b int)
isort/sort_test.go:30
↓ 4 callers
Function
test
(id int, done chan struct{}, n int, f func(chan int))
scheduler/gomaxprocs/simple.go:29
↓ 3 callers
Method
Get
(key int)
problems/concurrent/map1.go:10
↓ 3 callers
Method
GetPeer
GetPeer 当前Peer不存在时返回nil。
first_class_function/host_v2/host/host.go:74
↓ 3 callers
Method
GetPeer
GetPeer 当前Peer不存在时返回nil。
first_class_function/host_v1/host/host.go:47
↓ 3 callers
Method
Query
Query 查询余额
sync_pkg/mutex.go:49
↓ 3 callers
Method
Recv
()
grpc/server/hello.pb.go:206
↓ 3 callers
Method
RemovePeer
(pid string)
first_class_function/host_v3/host/host.go:60
↓ 3 callers
Method
Send
(*String)
grpc/server/hello.pb.go:205
↓ 3 callers
Method
Start
()
sync_atomic/channel/host.go:21
↓ 3 callers
Method
Start
()
first_class_function/host_v3/host/host.go:32
↓ 3 callers
Method
Stop
()
first_class_function/host_v3/host/host.go:36
↓ 3 callers
Method
String
()
unsafe/cast.go:14
↓ 3 callers
Function
f
()
problems/concurrent/once/once1.go:78
↓ 3 callers
Function
producer
(n int)
golang_pipeline_step_by_step/buffer_size/hi_fan_buffered.go:7
↓ 3 callers
Function
quickSortFast
sort range [a,b] func quickSortFast(nums []int, a, b int) { for a < b { pivot := doPivot(nums, a, b) if pivot-1 > a { quickSortFast(nums, a, p
isort/sort_test.go:61
↓ 3 callers
Function
readData
(n int)
isort/sort_test.go:276
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/hi_fan.go:20
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/hi_fan_example.go:19
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/optimize_fan_model/hi_fan.go:20
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/optimize_fan_model/hi_fan_buffered.go:20
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/optimize_fan_model/hi_fan_example.go:19
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/master/hi_fan.go:20
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/master/hi_fan_example.go:19
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/fan_model_slow/hi_fan.go:20
↓ 3 callers
Function
square
(inCh <-chan int)
golang_pipeline_step_by_step/fan_model_slow/hi_fan_example.go:19
↓ 3 callers
Function
swap
go test -bench=. -benchmem ./... 样例函数 两种交互写法性能并无显著差别
benchmark/bechmark_test.go:9
↓ 2 callers
Method
Deposit
Deposit 存款
sync_pkg/no_mutex.go:20
↓ 2 callers
Method
Deposit
Deposit 存款
sync_pkg/mutex.go:22
↓ 2 callers
Method
Deposit
Deposit 存款
sync_pkg/rwmutex.go:22
↓ 2 callers
Method
Do
(op Operation)
first_class_function/03_high_order_func2_result.go:25
↓ 2 callers
Method
Do
(op Operation, a int)
first_class_function/02_high_order_func1_param.go:19
↓ 2 callers
Function
Entrance
()
pprof/test/pprof_test.go:11
↓ 2 callers
Method
GetValue
()
grpc/client/hello.pb.go:72
↓ 2 callers
Method
GetValue
()
grpc/server/hello.pb.go:72
↓ 2 callers
Method
HiStream
(ctx context.Context, opts ...grpc.CallOption)
grpc/server/hello.pb.go:175
↓ 2 callers
Method
Len
()
problems/concurrent/map1.go:23
↓ 2 callers
Function
LockAndSleep
(mu *sync.Mutex, wg *sync.WaitGroup)
pprof/test/pprof_test.go:26
↓ 2 callers
Function
NewHost
()
first_class_function/host_v3/host/host.go:24
↓ 2 callers
Method
Query
Query 查询余额
sync_pkg/no_mutex.go:41
↓ 2 callers
Function
ReadWithSelect
select结构实现通道读
channel/unblock_channel/select_timer_unblock.go:45
↓ 2 callers
Function
ReadWithSelect
select结构实现通道读
channel/unblock_channel/select_unblock.go:44
↓ 2 callers
Method
RemovePeer
(pid string)
first_class_function/host_v2/host/host.go:65
↓ 2 callers
Method
RemovePeer
(pid string)
first_class_function/host_v1/host/host.go:39
↓ 2 callers
Method
Start
()
first_class_function/host_v2/host/host.go:34
↓ 2 callers
Method
Stop
()
sync_atomic/channel/host.go:25
↓ 2 callers
Method
Stop
()
first_class_function/host_v2/host/host.go:38
↓ 2 callers
Method
String
()
protobuf/helloworld1/types/request.pb.go:32
↓ 2 callers
Method
String
()
protobuf/helloworld2/types/request.pb.go:31
↓ 2 callers
Function
WriteChWithSelect
select结构实现通道写
channel/unblock_channel/select_timer_unblock.go:85
↓ 2 callers
Function
WriteChWithSelect
select结构实现通道写
channel/unblock_channel/select_unblock.go:82
↓ 2 callers
Method
WriteMsg
(msg string)
first_class_function/host_v3/host/host.go:12
↓ 2 callers
Function
changeToSeven
Can not set, if you set a non-setability Value, it will panic
reflect/law_of_reflect/setable.go:52
↓ 2 callers
Function
doPivot
doPivot returns the index of pivot`
isort/sort_test.go:91
↓ 2 callers
Function
empty
()
scheduler/preempt/demo3_normal.go:23
↓ 2 callers
Function
f
()
problems/concurrent/once0.go:40
↓ 2 callers
Function
gcBeforeUse
(p *Person)
sync_pkg/pool/pool_test.go:13
↓ 2 callers
Function
genFileName
(n int)
isort/sort_test.go:298
↓ 2 callers
Function
goMin
从testing/benchmark.go看到了这种奇怪的写法 逻辑上来讲,性能应没有差异。 测试结果也是如此。
minmax/benchmark_test.go:22
↓ 2 callers
Function
handle
handle 处理请求,耗时随机模拟
channel/practice/demo.go:34
↓ 2 callers
Function
insertionSortFast
conclusion: insertion sort fast ~= slow shell sort > insertion sort
isort/sort_test.go:18
↓ 2 callers
Function
merge
(bufSize int, cs ...<-chan int)
golang_pipeline_step_by_step/buffer_size/hi_fan_buffered.go:30
↓ 2 callers
Function
min
(x, y int)
minmax/benchmark_test.go:5
↓ 2 callers
Function
processRequest
(size int)
problems/concurrent/pool.go:34
↓ 2 callers
Function
shellSort
(nums []int, a, b int)
isort/sort_test.go:38
↓ 2 callers
Function
swapT
(i, j int)
benchmark/bechmark_test.go:13
↓ 2 callers
Function
waitResp
waitResp 等待请求响应req, expVal是查询时使用的期待值
channel_plus_sync/channel_map.go:178
↓ 2 callers
Function
waitTimer
()
pprof/timer/demo1_test.go:9
↓ 2 callers
Function
write
(name string)
file/multi-write/main.go:19
↓ 1 callers
Function
Add
(b int)
first_class_function/03_high_order_func2_result.go:7
↓ 1 callers
Method
BroadcastMsg
(msg string)
first_class_function/host_v2/host/host.go:69
↓ 1 callers
Method
BroadcastMsg
(msg string)
first_class_function/host_v3/host/host.go:67
↓ 1 callers
Method
BroadcastMsg
(msg string)
first_class_function/host_v1/host/host.go:54
↓ 1 callers
Function
Date2Time
()
date/main.go:8
↓ 1 callers
Method
Deposit
Deposit 存款
channel_plus_sync/channel_map.go:81
↓ 1 callers
Method
Do
(f func())
problems/concurrent/once/once1.go:13
↓ 1 callers
Method
DoFast
(f func())
problems/concurrent/once/once1.go:38
↓ 1 callers
Method
DoSlow
(f func())
problems/concurrent/once/once1.go:25
↓ 1 callers
Method
GetTag
()
build_tag/interface.go:4
↓ 1 callers
Function
Hello
()
gomod/hello.go:5
↓ 1 callers
Method
Hello
(ctx context.Context, in *String, opts ...grpc.CallOption)
grpc/client/hello.pb.go:174
↓ 1 callers
Method
HiStream
(ctx context.Context, opts ...grpc.CallOption)
grpc/client/hello.pb.go:175
↓ 1 callers
Method
Loop
Loop 银行处理客户请求
channel_plus_sync/channel_map.go:57
next →
1–100 of 617, ranked by callers