docs(twitter): add 1736161886079533186 corpus (NOTimothyLottes VK engine retrospective)
10-post single-author walkthrough of his old Vulkan pipeline: warm-all-pages startup, auto-relaunch on crash, single-SPIR-V plus spec-constants, Bind- Everything-Once, SSBO-as-4-types aliasing, GPU-side game logic, hardware- style fixed resources. High engagement (36 likes, 3778 views). Closes with the ruthless-anti-complexity thesis.
|
After Width: | Height: | Size: 5.5 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 15 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 10 KiB |
|
After Width: | Height: | Size: 8.9 KiB |
@@ -0,0 +1,71 @@
|
||||
---
|
||||
title: "If there is anything to learn for programming, it is to be more critical of your"
|
||||
author: "NOTimothyLottes"
|
||||
handle: "@NOTimothyLottes"
|
||||
post_url: "https://x.com/NOTimothyLottes/status/1736161886079533186"
|
||||
post_id: "1736161886079533186"
|
||||
timestamp: "2023-12-16 23:10:24"
|
||||
post_count: 10
|
||||
reply_count: 0
|
||||
repost_count: 5
|
||||
like_count: 36
|
||||
view_count: 3778
|
||||
---
|
||||
|
||||
# @NOTimothyLottes — If there is anything to learn for programming, it is to be more critical of your
|
||||
|
||||
## Post 1 (2023-12-16 22:14:30)
|
||||
|
||||
Inspecting my old VK engines. On start I would warm all the pages. Code pages get a read, and data pages got an atomic add of a non-compiler known zero. An attempt to improve initial load time. But in the end nothing helps the 2.6 seconds or so required to just open the VK device
|
||||
|
||||

|
||||
|
||||
## Post 2 (2023-12-16 22:19:37) — reply to Post 1
|
||||
|
||||
Since I almost never get crashes I forgot about this, but had written a system to auto relaunch the app on crash or special case exit. No complex error handling, just bank on fast relaunch instead.
|
||||
|
||||

|
||||
|
||||
## Post 3 (2023-12-16 22:28:46) — reply to Post 2
|
||||
|
||||
The hope of single PSO in VK was scrapped because IHV compile times explode. However I did maintain single SPIR-V file, and use spec constants to choose individual shaders. The threads doing compile dump compile times and disassembly in DEV mode.
|
||||
|
||||

|
||||
|
||||
## Post 4 (2023-12-16 22:36:29) — reply to Post 3
|
||||
|
||||
I'm a fan of single file applications. So when not in DEV mode the one SPIR-V file gets pulled from the EXE. Compiling PSOs is always the critical path, the moment the "bind everything once" layout is done, PSO compile goes wide on the machine.
|
||||
|
||||

|
||||
|
||||
## Post 5 (2023-12-16 22:42:44) — reply to Post 4
|
||||
|
||||
"Bind-Everything-Once" in Vulkan looks like this. Bindings {1}=CPU pushing to GPU, {2}=buffer (more on that next), {3}=as UAVs, {4}=as TEX ... No binding logic at runtime ever. Access anything in the most efficient way any time.
|
||||
|
||||

|
||||
|
||||
## Post 6 (2023-12-16 22:48:55) — reply to Post 5
|
||||
|
||||
Did something silly but fast for buffers. Here is an example from a dummy test app. The main SSBO gets aliased as 4 structures, each with the same data accessable with four types {uint, uint4, float, float4}. So same binding layout aliasing chooses load type and K$ or V$ access.
|
||||
|
||||

|
||||
|
||||
## Post 7 (2023-12-16 22:52:19) — reply to Post 6
|
||||
|
||||
Literally the CPU does almost nothing. All game input gets pushed to the GPU for game logic. Some major advantages in input latency to do player logic on the GPU instead. And it's dead easy.
|
||||
|
||||

|
||||
|
||||
## Post 8 (2023-12-16 22:57:51) — reply to Post 7
|
||||
|
||||
This requires context, I build programs in a hardware style, fixed resources, fixed shaders, and all logic expressed in the data itself. No code or resource variation, no runtime issues period. So another dummy program example, I can just list my resources on load in a table ...
|
||||
|
||||

|
||||
|
||||
## Post 9 (2023-12-16 23:03:01) — reply to Post 8
|
||||
|
||||
Radically simplicity is how I roll personally. Easy to confuse the idea that one needs complexity to express a complex system. It's more like one needs complexity to express a complex solution -> abstractions and hierachical meta feeds on itself until tech debt freezes progess.
|
||||
|
||||
## Post 10 (2023-12-16 23:10:24) — reply to Post 9
|
||||
|
||||
If there is anything to learn for programming, it is to be more critical of your own ideas than all else, be ruthless, trim until what is left is only what is actually required, question everything constantly.
|
||||
@@ -0,0 +1,182 @@
|
||||
{
|
||||
"root_post_id": "1736161886079533186",
|
||||
"posts": [
|
||||
{
|
||||
"post_id": "1736147815829565624",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "Inspecting my old VK engines. On start I would warm all the pages. Code pages get a read, and data pages got an atomic add of a non-compiler known zero. An attempt to improve initial load time. But in the end nothing helps the 2.6 seconds or so required to just open the VK device",
|
||||
"timestamp": "2023-12-16 22:14:30",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgHT_2WIAAKuNq?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": null,
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 3,
|
||||
"repost_count": 3,
|
||||
"like_count": 64,
|
||||
"view_count": 15137
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736149104269344962",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "Since I almost never get crashes I forgot about this, but had written a system to auto relaunch the app on crash or special case exit. No complex error handling, just bank on fast relaunch instead.",
|
||||
"timestamp": "2023-12-16 22:19:37",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgJ1y5W0AArwSt?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": "1736147815829565624",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 1,
|
||||
"repost_count": 0,
|
||||
"like_count": 7,
|
||||
"view_count": 2315
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736151406703214631",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "The hope of single PSO in VK was scrapped because IHV compile times explode. However I did maintain single SPIR-V file, and use spec constants to choose individual shaders. The threads doing compile dump compile times and disassembly in DEV mode.",
|
||||
"timestamp": "2023-12-16 22:28:46",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgMbMEWkAAOd_d?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": "1736149104269344962",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 1,
|
||||
"repost_count": 0,
|
||||
"like_count": 6,
|
||||
"view_count": 2222
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736153352096882847",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "I'm a fan of single file applications. So when not in DEV mode the one SPIR-V file gets pulled from the EXE. Compiling PSOs is always the critical path, the moment the \"bind everything once\" layout is done, PSO compile goes wide on the machine.",
|
||||
"timestamp": "2023-12-16 22:36:29",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgOQRiXoAAX2k6?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": "1736151406703214631",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 1,
|
||||
"repost_count": 0,
|
||||
"like_count": 7,
|
||||
"view_count": 2220
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736154923408953499",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "\"Bind-Everything-Once\" in Vulkan looks like this. Bindings {1}=CPU pushing to GPU, {2}=buffer (more on that next), {3}=as UAVs, {4}=as TEX ... No binding logic at runtime ever. Access anything in the most efficient way any time.",
|
||||
"timestamp": "2023-12-16 22:42:44",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgPDhAWUAAzhEi?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": "1736153352096882847",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 3,
|
||||
"repost_count": 1,
|
||||
"like_count": 12,
|
||||
"view_count": 3311
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736156478354903216",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "Did something silly but fast for buffers. Here is an example from a dummy test app. The main SSBO gets aliased as 4 structures, each with the same data accessable with four types {uint, uint4, float, float4}. So same binding layout aliasing chooses load type and K$ or V$ access.",
|
||||
"timestamp": "2023-12-16 22:48:55",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgQ0xlWQAA7Yks?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": "1736154923408953499",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 1,
|
||||
"repost_count": 0,
|
||||
"like_count": 6,
|
||||
"view_count": 2255
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736157335058300999",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "Literally the CPU does almost nothing. All game input gets pushed to the GPU for game logic. Some major advantages in input latency to do player logic on the GPU instead. And it's dead easy.",
|
||||
"timestamp": "2023-12-16 22:52:19",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgRu3wXoAAp_K7?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": "1736156478354903216",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 2,
|
||||
"repost_count": 0,
|
||||
"like_count": 11,
|
||||
"view_count": 2452
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736158727370154157",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "This requires context, I build programs in a hardware style, fixed resources, fixed shaders, and all logic expressed in the data itself. No code or resource variation, no runtime issues period. So another dummy program example, I can just list my resources on load in a table ...",
|
||||
"timestamp": "2023-12-16 22:57:51",
|
||||
"media_urls": [
|
||||
"https://pbs.twimg.com/media/GBgTCgJXsAEPH3W?format=png&name=orig"
|
||||
],
|
||||
"reply_to_id": "1736157335058300999",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 3,
|
||||
"repost_count": 0,
|
||||
"like_count": 45,
|
||||
"view_count": 14697
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736160027755360495",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "Radically simplicity is how I roll personally. Easy to confuse the idea that one needs complexity to express a complex system. It's more like one needs complexity to express a complex solution -> abstractions and hierachical meta feeds on itself until tech debt freezes progess.",
|
||||
"timestamp": "2023-12-16 23:03:01",
|
||||
"media_urls": [],
|
||||
"reply_to_id": "1736158727370154157",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 1,
|
||||
"repost_count": 1,
|
||||
"like_count": 18,
|
||||
"view_count": 3672
|
||||
}
|
||||
},
|
||||
{
|
||||
"post_id": "1736161886079533186",
|
||||
"author": "NOTimothyLottes",
|
||||
"handle": "NOTimothyLottes",
|
||||
"text": "If there is anything to learn for programming, it is to be more critical of your own ideas than all else, be ruthless, trim until what is left is only what is actually required, question everything constantly.",
|
||||
"timestamp": "2023-12-16 23:10:24",
|
||||
"media_urls": [],
|
||||
"reply_to_id": "1736160027755360495",
|
||||
"quote_of_id": null,
|
||||
"metrics": {
|
||||
"reply_count": 0,
|
||||
"repost_count": 5,
|
||||
"like_count": 36,
|
||||
"view_count": 3778
|
||||
}
|
||||
}
|
||||
],
|
||||
"source_url": "https://x.com/NOTimothyLottes/status/1736161886079533186"
|
||||
}
|
||||