You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
124 lines
5.3 KiB
124 lines
5.3 KiB
11 months ago
|
<!DOCTYPE html>
|
||
|
<html lang="en">
|
||
|
<head>
|
||
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||
|
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||
|
|
||
|
<!-- Enable responsiveness on mobile devices-->
|
||
|
<!-- viewport-fit=cover is to support iPhone X rounded corners and notch in landscape-->
|
||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1, viewport-fit=cover">
|
||
|
|
||
|
<title>Julio Biason .Me 4.3</title>
|
||
|
|
||
|
<!-- CSS -->
|
||
|
<link rel="stylesheet" href="https://blog.juliobiason.me/print.css" media="print">
|
||
|
<link rel="stylesheet" href="https://blog.juliobiason.me/poole.css">
|
||
|
<link rel="stylesheet" href="https://blog.juliobiason.me/hyde.css">
|
||
|
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=PT+Sans:400,400italic,700|Abril+Fatface">
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
</head>
|
||
|
|
||
|
<body class=" ">
|
||
|
|
||
|
<div class="sidebar">
|
||
|
<div class="container sidebar-sticky">
|
||
|
<div class="sidebar-about">
|
||
|
|
||
|
<a href="https://blog.juliobiason.me"><h1>Julio Biason .Me 4.3</h1></a>
|
||
|
|
||
|
<p class="lead">Old school dev living in a 2.0 dev world</p>
|
||
|
|
||
|
|
||
|
</div>
|
||
|
|
||
|
<ul class="sidebar-nav">
|
||
|
|
||
|
|
||
|
<li class="sidebar-nav-item"><a href="/">English</a></li>
|
||
|
|
||
|
<li class="sidebar-nav-item"><a href="/pt">Português</a></li>
|
||
|
|
||
|
<li class="sidebar-nav-item"><a href="/tags">Tags (EN)</a></li>
|
||
|
|
||
|
<li class="sidebar-nav-item"><a href="/pt/tags">Tags (PT)</a></li>
|
||
|
|
||
|
|
||
|
</ul>
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
|
||
|
<div class="content container">
|
||
|
|
||
|
<div class="post">
|
||
|
<h1 class="post-title">Write Great Code: Volume I: Understanding the Machine - Randall Hyde</h1>
|
||
|
<span class="post-date">
|
||
|
2016-10-05
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/books/">#books</a>
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/randall-hyde/">#randall hyde</a>
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/reviews/">#reviews</a>
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/coding/">#coding</a>
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/computer-architecture/">#computer architecture</a>
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/it/">#it</a>
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/stars-1/">#stars:1</a>
|
||
|
|
||
|
<a href="https://blog.juliobiason.me/tags/published-2014/">#published:2014</a>
|
||
|
|
||
|
</span>
|
||
|
<p><a href="https://www.goodreads.com/book/show/35873018-write-great-code">GoodReads Summary</a>:
|
||
|
Write Great Code, Volume 1 teaches machine organization, including numeric
|
||
|
representation; binary arithmetic and bit operations; floating point
|
||
|
representation; system and memory organization; character representation;
|
||
|
constants and types; digital design; CPU, instruction set, and memory
|
||
|
architecture; input and output; and how compilers work.</p>
|
||
|
<span id="continue-reading"></span><div>
|
||
|
★☆☆☆☆
|
||
|
</div>
|
||
|
<p>"Great code" is machine dependent and written in assembly. Or, at least,
|
||
|
that's what this book makes you believe till the very last chapter, when it
|
||
|
starts backtracking about writing code directly into CPU code.</p>
|
||
|
<p>Now, don't get me wrong, it's not a terrible book -- it's a damn complete book
|
||
|
about <em>computer architecture</em>, even being so out-of-date that there is no word
|
||
|
about SSDs (when talking about storage), no mention about MP3s (when
|
||
|
discussing about audio hardware), the top CPU discussed is Pentium, there is
|
||
|
no word about UTF-8 (and mentions ASCII is used all around) and recommending
|
||
|
search things on AltaVista. </p>
|
||
|
<p>The problem is discussing all this when the topic is "great code": Great code
|
||
|
is not machine dependent; great code is not highly optimized code that runs
|
||
|
extremely fast and uses very little memory; there are trade offs that you have
|
||
|
to take in account when coding: Sure, you don't write something that uses all
|
||
|
the available memory, but you write in a language that allows you to easily
|
||
|
extend the code later and which your code reads exactly what you meant it to
|
||
|
say. That's great code, not code that uses some multimedia extensions that is
|
||
|
available since a very specific generation of CPUs.</p>
|
||
|
<p>The book also goes into great lengths to explain stuff that is hardly useful.
|
||
|
For example, there is a whole implementation of the floating point standard
|
||
|
(IEEE 754), which is not optimized -- so, no great code -- and that's
|
||
|
absolutely unnecessary, since this is done directly into the CPU (and, if it
|
||
|
isn't, you have libraries ready for that).</p>
|
||
|
<p>It could be that the "Great Code" will come in the later volumes, but ignoring
|
||
|
what <em>is</em> great code (I mean, <em>real</em> great code) and just building a base for
|
||
|
later is plainly greedy.</p>
|
||
|
|
||
|
</div>
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
</div>
|
||
|
|
||
|
</body>
|
||
|
|
||
|
</html>
|