6,400 reputation
1641
bio website
location Los Angeles, CA
age
visits member for 4 years, 3 months
seen 5 hours ago

I love strange shrimp.

eh, string stream.


5h
comment New frameworks vs Sticking with & getting really good in existing /old technology
Try ask at workplace.stackexchange.com because career questions are too localized - too narrowly applicable to few people who are in the exact same situation, geographical and cyclical job market condition and had the exact same background, work experience. The general advice is to devote some time to both old and new technologies - on one hand to hone in your everyday work skill, but on the other hand to selectively invest in a few promising new technologies which you find beneficial. Something like 80-20.
7h
answered Ideas on Model of simple Traffic Simulation
16h
comment Why is close() implemented in InputStream/OutputStream?
If there is a programming language that imposes a single-ownership requirement for objects that require Closeable, (that is, the same owner object must create, own, and close the closeable object), then close() would become part of the language, and then there would be no need to include this method on the stream interface. But Java is not such a language.
16h
comment Why is close() implemented in InputStream/OutputStream?
@overexchange you have not yet provided any convincing argument that close() is peripheral and not core.
16h
comment Why is close() implemented in InputStream/OutputStream?
@overexchange I agree that traits would be more suitable for adding common peripheral behaviors to concrete implementations of an interface.
17h
revised Why is close() implemented in InputStream/OutputStream?
added 681 characters in body
17h
answered Why is close() implemented in InputStream/OutputStream?
Dec
17
comment Performance and other issues with using floating point types in C++
Also, the Wikipedia article on Loss of significance (floating point) is a recommended read for everyone who uses floating point, even if one is not interested in numerical processing.
Dec
17
comment Performance and other issues with using floating point types in C++
For graphics, it is often recommended to use doubles (if possible) for geometries, and floats for pixel values. This is because geometries often require more than 20 bits of significant figures, whereas human eyes and the computer displays they watch do not care much about 6-8 bits per color.
Dec
17
comment Performance and other issues with using floating point types in C++
@Sjoerd As CodesInChaos has pointed out, there are several inaccuracies in your claim. A fundamental reason is that: while addition-subtractions are mostly single-cycle operations (as their carry logic are optimizable), floating point transcendental, inverse and square root functions are mostly iterative via the Newton-Raphson method. As these iterative methods refine their answers, a high-precision floating point value will take more iterations to arrive at the full precision, and thus will certainly take more time to get there.
Dec
16
comment Maintenance cost of SIMD programming code base
@DocBrown what we meant is that the test code (along with one of the unoptimized version or the optimized version) tend to be deleted by people who under-appreciate (or misunderstand) the value or the complexity of these auxiliary code.
Dec
16
comment Maintenance cost of SIMD programming code base
In some sense, SIMD programming require a prerequisite of DSP and embedded numerical processing knowledge, which is uncommon among software developers. This missing knowledge leads to some dangerous assumptions about the perceived (lack of) importance of the SIMD unit tests.
Dec
16
comment Maintenance cost of SIMD programming code base
@gnat: In general, the average software engineer's attitude toward SIMD unit-testing is detrimental. Firstly, a unit test programmer will think that "you only need to test the boundary conditions ala INT_MAX", and delete 90% of the test vectors from a SIMD unit test project, without understanding that SIMD boundary conditions can happen in many scattered places. Then, the test manager will complain that SIMD unit tests run too slow. Finally, the project manager will say that "Well it seems SIMD unit tests are passing with green. It seems safe to skip the tests for now to save time".
Dec
16
answered Client vs Creator in Factory Method and Abstract Factory patterns
Dec
16
comment Passing parameters that need to be copied by value or const reference
Passing non-retained input arguments as const reference is very idiomatic in C++. If you don't like that style, it would be necessary to overcome that personal taste because it's used by everyone else who write in C++. One must also learn its limitations - what it actually guarantees and what it doesn't.
Dec
15
comment Is it misleading to label code as a particular design pattern if it only loosely fits the definition?
The claim that naming a pattern can greatly enhance the brevity of communication is extremely exaggerated. Most of the time, the mentioning of a pattern in source code is the case of a "Koan", meaning: if you don't comprehend the code below, try read about that pattern, and when you come back you'll understand.
Dec
15
comment Is it misleading to label code as a particular design pattern if it only loosely fits the definition?
To begin with, try summarize each pattern in your own words. Sometimes your summary is even more understandable than the original pattern name. Say, in your example it is might have been a static instance (if it actually is). See how simple it is?
Dec
14
comment Implicit Conversion Operators for Value Types in C#
What does "conversion" mean? See Eric Lippert's blog post on Representation and Identity to find out.
Dec
14
comment “Design patterns”, “Reactive programming”, etc…How do these terms fit together?
(Info for moderation: per meta discussion, questions on software development methodologies are on-topic.)
Dec
14
revised “Design patterns”, “Reactive programming”, etc…How do these terms fit together?
added 267 characters in body