Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
zvrba
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
65 ms
·
631.
▲
by
zvrba
13y ago
What you're describing sounds more like a combination of better HW (bus, components) and SW (operating system). I agree, IBM delivers superb systems. However: are there any inherent limitations in the x64 architecture which would make
632.
▲
by
zvrba
13y ago
What can today POWER do that neither Intel nor ARM can? What is its relevance?
633.
▲
by
zvrba
13y ago
I've described what's usually known as asymmetric coroutines or semicoroutines. "Asymmetric" because [as claimed by Lua manual at least] there are two separate calls for control transfer (yield and resume). Generators ar
634.
▲
by
zvrba
13y ago
> I'm pretty sure you could add a function pointer argument to printNTriples and replace the printf() You could , but the control is still driven by printNTriples. What if you had to break early, before generating all N triples? In
635.
▲
by
zvrba
13y ago
Well, almost. A coroutine is created once and it yields control to its "caller" each time it produces an item. To implement a coroutine, you only need to save its stack (local variables, instruction pointer). He created a lazy s
636.
▲
by
zvrba
13y ago
> a lot of people are seeing reduction in triglycerides or cholesterol I suspect that the powder may be oat-based. Oats is a very nutritient-rich cereal, and does in fact lower cholesterol. It has high carbohydrate content, but it is als
637.
▲
by
zvrba
13y ago
Ideally, you would have a parsing and validation routine which fills in a struct. Afterwards, you manipulate only the struct instead of raw byte representation. > But there comes a point at which further complexity produces more confusio
638.
▲
by
zvrba
13y ago
Couldn't you expose machine-dependent stuff in a subclass? SSE has a bunch of other useful instructions like PMOVMSKB (useful for fetching the result of vectorized comparisons, yay!), then there are string instructions (sometimes also
639.
▲
by
zvrba
13y ago
It's hard to define semantics. Here, you have potentially copied less than dst->len bytes into dst->data. Is the remaining data (up to dst->len) still valid, is it garbage, should you have adjusted dst->len, etc? When does
640.
▲
by
zvrba
13y ago
Oncoming Intel memory protection extensions: http://software.intel.com/en-us/articles/introduction-to-int... "Intel MPX is a set of processor features which, with compiler, runtime library and OS support, br
641.
▲
Thank You, Croatia: All Hail Mandatory Vaccinations
(thedailybeast.com)
1 points
by
zvrba
13y ago
|
0 comments
642.
▲
by
zvrba
13y ago
This is not a "source code" review. There are no comments on the overall practices that developers must deal with when writing C: resource management, string handling, general error handling and its coverage (e.g., is EVERY system
643.
▲
by
zvrba
13y ago
I get this too, and only on this site. In Chrome, FF and IE. Maybe the site is infected, and the presence of the spam depends on the visitor's country. EDIT: The spam is present also when browsing from a Linux VM.
644.
▲
by
zvrba
13y ago
Re Mel Gorman's details in http://article.gmane.org/gmane.linux.kernel/1663694 I don't understand why PostgreSQL people don't want to write their own IO scheduler and buffer management. It's not tha
645.
▲
by
zvrba
13y ago
Ditch Linux and port PgSQL to run on top of raw Xen interfaces. You get to control your own buffering, worker thread scheduling, and talk directly to the (virtual) disk driver. I believe it'd be a win.
646.
▲
by
zvrba
13y ago
> I don't know what you could call the root case of this one. Bad software engineering. Their internal routines return negative value to indicate failure, but to the caller they translate it to true/false.
647.
▲
by
zvrba
13y ago
OK, we agree then.
648.
▲
by
zvrba
13y ago
> What if you have a bug in your destructor then? This is a straw-man. A bug in the destructor would lead to resource leaks and to eventual program failure. "Slightly" different from a complete and silent failure to perform a c
649.
▲
by
zvrba
13y ago
> What do you think of C++ and timing attacks? Same underlying machine model => same mitigation techniques apply as in C. > surface area of the C++ runtime itself No RTTI and no exceptions => no runtime. (By "runtime"
650.
▲
by
zvrba
13y ago
> That's not going to help. Many Windows users don't upgrade not because they fear the price of Windows 8, but because they can't stand it and prefer XP, as simple as that. Or they don't want to bother with buying new
651.
▲
by
zvrba
13y ago
For all C++ haters and C defenders: the cleanup/fail labels set result to 0 and perform a bunch of _gnutls_free_datum calls. This would not have happened in a properly designed C++ program because you could have just written "retu
652.
▲
by
zvrba
13y ago
> You really have very little chance of success unless you're doing this full time Heh. I also wanted to play with algorithmic trading, but before doing so, I got a book "Trading and exchanges" by Harris, which was recomme
653.
▲
by
zvrba
13y ago
> What if the architecture doesn't have a carry? Then the compiler has to generate one when needed. Adding two N-bit numbers produces N+1-bit result, and C gives you no direct means of accessing the full result. IMO, this is a langu
654.
▲
Optimizing Big Number Arithmetic Without SSE
(accu.org)
56 points
by
zvrba
13y ago
|
33 comments
655.
▲
by
zvrba
13y ago
> At the time you're writing the Vehicle class, it seems perfectly reasonable to define a setPropulsionDevice() method Are you claiming that it seems reasonable to be able to replace a car engine with a jet engine without changing
656.
▲
by
zvrba
13y ago
The circle vs ellipse problem is rather artificial and, if anything, it shows that modeling with types and everyday intuition are two different things. If the rest of your program can handle general ellipses, it should also be able to handl
657.
▲
by
zvrba
13y ago
In engineering applications, it's perfectly sensible to use float for world modelling, which give you precision of about 1 in 10 million. Then you can use double for intermediate results and lose less precision in a long calculation, p
658.
▲
by
zvrba
13y ago
Actually, 2^53 different mantissas, plus a few different exponents, depending on the function under test. Also, there's a huge number of NaNs, all of which are equivalent. For ceil/floor, it wouldn't make sense to test expone
659.
▲
by
zvrba
13y ago
> Its harder to get published if you release all of the data prior to publication. IF you succeed (and I hope you will).. just think how AWESOME would it be that the authors of one of the most significant achievements of the 21st century
660.
▲
by
zvrba
13y ago
And part 2: http://theinvisiblethings.blogspot.no/2013/09/thoughts-on-in...
More ›