Convert notes into blockquotes
This commit is contained in:
parent
832fb15e54
commit
8ed9dea394
105 changed files with 884 additions and 411 deletions
18
17-03.md
18
17-03.md
|
|
@ -58,9 +58,13 @@ state of our Game of Life implementation, the only areas worth looking
|
|||
at for possible optimizations are **cell\_state()** and
|
||||
**next\_generation().**
|
||||
|
||||
------------------- ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
 *It's worth noting, though, that one reason **draw\_pixel()** doesn't much affect performance is that in Listing 17.1, we're smart enough to redraw pixels only when their states change, rather than during every generation. Detecting and eliminating redundant operations is part of knowing the nature of your data, and is a potent optimization technique that will be extremely useful a little later in this chapter.*
|
||||
------------------- ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
> 
|
||||
> It's worth noting, though, that one reason **draw\_pixel()** doesn't
|
||||
> much affect performance is that in Listing 17.1, we're smart enough to
|
||||
> redraw pixels only when their states change, rather than during every
|
||||
> generation. Detecting and eliminating redundant operations is part of
|
||||
> knowing the nature of your data, and is a potent optimization technique
|
||||
> that will be extremely useful a little later in this chapter.
|
||||
|
||||
### The Hazards and Advantages of Abstraction {#Heading6}
|
||||
|
||||
|
|
@ -81,9 +85,11 @@ know the cell storage format! This is a wonderful thing, in general; it
|
|||
saves programming time and bugs, and frees you to work on the
|
||||
application's needs, rather than implementation details.
|
||||
|
||||
------------------- ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
 *However, if you never look beneath the surface of the abstract model at the implementation details, you have no idea of what the true performance cost of various operations* *is, and, without that, you have largely surrendered control over performance.*
|
||||
------------------- ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
> 
|
||||
> However, if you never look beneath the surface of the abstract model at
|
||||
> the implementation details, you have no idea of what the true performance
|
||||
> cost of various operations is, and, without that, you have largely
|
||||
> surrendered control over performance.
|
||||
|
||||
Having said that, let me hasten to add that algorithmic improvements can
|
||||
make a big difference even when working at a purely abstract level. For
|
||||
|
|
|
|||
Loading…
Reference in a new issue