💻 Sitemap - Golang
-
1. Goroutine vs Thread • 2. Channels — безопасный обмен данными • 3. Unbuffered vs Buffered Channels • 4. Select — ожидание нескольких каналов • 5. Timeout / Deadline • Сравнение Go и Java по основам параллельности • Контекст для отмены и таймаутов: `context.Context` vs Java • Пример на Go • Как это решается в Java • Советы и нюансы • Сложные кейсы повышенной сложности • 1. Worker Pool (пул воркеров) • 2. Fan-In / Fan-Out • 3. Timeout / Отмена цепочки задач • Итог
-
atomic.CompareAndSwap • stack vs heap escape • sync.Pool • goroutine stack splitting • memory consistency model • scheduler preemption • unsafe basics • cache locality • allocation cost optimization • runtime.Gosched • runtime.LockOSThread • runtime.GC • High-Concurrency Patterns • GMP Scheduler Model • Output / Conclusion
-
unsafe.Pointer • Struct field alignment (alignment of fields) • Pointer arithmetic (pointer arithmetic) • Zero-copy techniques • iota • Interface internals (itab, dynamic dispatch) • runtime.SetFinalizer • runtime.KeepAlive • Overview of Topics • Key Differences Between Go ↔ Java Philosophy • Comparative table of all terms • How to choose the approach (Go vs Java) • Conclusion
-
Goroutine parking / unparking • Work stealing • Syscall blocking behavior • Local run queue • Global run queue • Network poller (netpoller) • Cooperative vs async preemption • Goroutine blocking on IO • Scheduler + IO interaction • Netpoller (epoll + kqueue) • General Comparison Table • Output / Result
-
Build Tags • Dead Code Elimination • Package Init Order • Linker Behavior • Go Vet • Go Test -bench • Go Tool PProf • Go Tool Trace • Escape Analysis Flags • General comparison logic: how to think about Go ↔ Java • General comparison table of terms • Common Schemas and Mental Models • Practical Conclusion
Useful Articles:
Hello! This is Vitaly Lesnykh. Today we will continue the course “Java Basics for Beginners” and discuss one of the most important topics in programming — loops. A loop is the repetition of code exe...
In this article, we will examine the internal structure of maps / hash tables in Go and Java. If you are a Java developer used to HashMap, you will be interested in how differently Go thinks. If you a...
Introduction Architecture is more than just a way to arrange classes and modules. It is the language a system uses to communicate time. Today, Java developers live in a world where the boundaries bet...
New Articles:
Zero Allocation — is an approach to writing code in which no unnecessary objects are created in heap memory during runtime. The main idea: fewer objects → less GC → higher stability and performance. ...
In Java, performance is often determined not by the "beauty of the code," but by how it interacts with memory, the JIT compiler, and CPU cache. Let s analyze why the usual for is often faster than Str...
This article is dedicated to a general overview of how the compiler, build, and tooling practices are arranged in Go, and how to better understand them through comparison with Java. We will not delve ...