tuhdo | 5 years ago | on: Ryzen 5800X vs. M1: Programming benchmarks
tuhdo's comments
tuhdo | 5 years ago | on: Ryzen 5800X vs. M1: Programming benchmarks
The Mac Mini is $699 with only 8GB RAM, that runs out after a few browser tabs. So, for a work machine, you would need at least the 16GB model and add $200 to that. Though the build quality and the panel is excellent.
You could opt for the 5600X. The core count is not relevant in the article, as the benchmarks are mainly single-threaded.
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
About the sentence, sadly, but it is the trend.
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
I used Lyx because it enabled me to focus on the content without all the markup text. Writing Latex in Emacs can reduce the distraction, but not enough. I just wanted to focus on the content at the time. Learning Latex is difficult enough, learning how to use the major mode at the same time doubles the difficulty.
Obviously, I still use Emacs daily for writing code and other things. Just not for writing book.
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
"In protected mode, the IA-32 architecture provides a normal physical address space of 4 GBytes (2 32 bytes). This is the address space that the processor can address on its address bus. This address space is flat (unsegmented), with addresses ranging continuously from 0 to FFFFFFFFH. This physical address space can be mapped to read- write memory, read-only memory, and memory mapped I/O. The memory mapping facilities described in this chapter can be used to divide this physical memory up into segments and/or pages."
It correlates to my experience of developing in protected mode in QEMU. Once entered protected mode, I can access to any address above 0x10000 without being wrapped around. When I was writing my first kernel (https://github.com/tuhdo/os-study) in real-mode, indeed A20 must be enabled.
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
The problem is that the guide is out of date in terms of toolchain, and you need to figure out many things by yourself, especially if you want to develop on Linux. My book helps you to understand how to learn and write x86 with Intel manuals (this is really important!), understand how to craft a custom ELF binary that is debuggable on bare metal, which in turn requires you to understand a bit of how debugger works.
Once you get gdb working, it is much easier to learn how to write an operating system.
tuhdo | 9 years ago | on: Operating Systems: From 0 to 1
The book not only teaches x86, but how to use the official resources from the hardware manufacturer to write the OS. In sum, a reader when reaching part 3 for writing the OS, he will need to use the official document, in this case, the "System Programming Guide" manual from Intel to write C code that complies with the documents. Once he learned how to do so, learning other platforms will be much easier given how complex x86 is.
tuhdo | 11 years ago | on: Spacemacs – Emacs advanced kit focused on Evil
tuhdo | 11 years ago | on: Spacemacs – Emacs advanced kit focused on Evil
What is "make do"? Do you mean running make? Btw, Spacemacs can do the same with the feature I listed above. The different is just it doesn't display the tab by default and only show you when you need it. That said, if you want to try, open .spacemacs file, search "dotspacemacs-configuration-layers" and add "perspectives" (without double quotes) below any layer there. Then, use "SPC L s" to switch between "tabs" (the default one is "@spacemacs". Enter a non-existent name and you have a new "tab". The "tabs" are collections of related buffers. If you create any new buffer, it is local in an active "tab" only.
"SPC L n" to go to next "tab". "SPC L p" to go to previous "tab". "SPC L k" to close current "tab". "SPC L a" to add a buffer to current "tab".
> Oh, that's pretty neat. Actually, still not the same thing as command mode, because it seems there's some convention to chose the command first, and after pressing Enter passing any arguments interactively. Not that it's bad, but a bit different from how it's generally done in shells.
Well you need to forgo Vim for awhile and concentrating on Spacemacs way. Then going back and compare.
> Really? Uhm, no, not really. Actually you have to type :map (as in "key map"), and if you don't know what to type you type in :h whatever.
That's not the same thing. Try pressing "Control-h k", then press "SPC b s" you will get a command that is bound to the key binding. If you want similar thing to ":map", then press "C-h b" to show the interactive cheatsheet. If you are in a major mode, it shows all the key bindings belong to that major mode first and foremost, than maps of other modes (such as minor modes) below.
tuhdo | 11 years ago | on: Spacemacs – Emacs advanced kit focused on Evil
tuhdo | 11 years ago | on: Spacemacs – Emacs advanced kit focused on Evil
If you are looking for workspaces i.e. organizing buffers into logical group, use Perspective: https://github.com/syl20bnr/spacemacs/tree/master/contrib/pe....
> And it doesn't even look for them in the cwd, but does I-haven't-figured-out-what-yet instead.
As another commenter suggested, you can use :cd. However, you can use a better interactive interface and use "SPC f f" or "SPC f h". Spacemacs is, after all, Vim + Emacs.
Emacs has that kind of visual tabs but Spacemacs does not integrate it since it gets in the way more than being useful.
> If you are wondering why that SPC stuff isn't the equivalent to command-mode with ":" bound to SPC: commands are easy to define even in vim, they can have descriptive names due to their nature and I don't have to remember them, as I can use auto-complete! For example, I have :Rename and :Remove. Actually, I don't even remember if it's :Remove or :Delete, I just use autocompletion every time I need it and find out.
That kind of auto-complete is really bare. If you want something like that, try pressing "SPC :" or "Alt-x" in Spacemacs. You can search in any order you like, not prefix, i.e. if you look for command "list-package", either "list pa" or "pa list" gives you the command.
I mean, in Vim, to get help for a key binding, I have to type something like "Ctrl+W". Really? In Emacs, you get it by pressing "C-h k" then press the key binding you don't know which command is bound to it. You even get a cheatsheet like style in Emacs. For example, if you don't know what the commands in "SPC f" does, simply press "SPC f ?" and you get an interactive cheatsheet that you can easily narrow donw. Press "C-z" to open its description.