Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×

Comment Re:Redistribution (Score 1) 739

Hmm, I hear what you say, but it wasn't generally stand-alone IT that would be much use outside finance, and I was the CTO of the virtual credit card start-up.

But I assure you that there is no gold-filled vault, no not even slightly full of warm lovely glowing metal; nothing to see here, move along.

Rgds

Damon

Comment Re:You shouldn't need insurance for most things (Score 1) 739

For most things maybe you just shouldn't be paying, at all denying treatment to those who happen not to have spare cash, eg students and young adults in general getting going in their jobs. I couldn't have paid anything much as a teenager for my epilepsy diagnosis and treatment; should I have just rotted before I even got to uni? I had left home, BTW.

(In the UK I do pay for a few things at point of use under the NHS, but often even then fairly small fixed/tiered charges.)

Rgds

Damon

Comment Re:Just don't try to write an OS in Java (Score 1) 511

Hi,

That is a different and also interesting case, and just by bringing it up you'd pass my test.

No, I meant something like:

public static final String CRITICAL_ID = "whatever"

in a secure API. If I use char[] instead what happens if a miscreant overwrites the content of the array; what BadThings might happen?

Rgds

Damon

Comment Re:Performance improvements have helped it survive (Score 2) 511

Except that once JIT/Hotspot is involved all or most of the executions *are* of compiled machine code, optimised to the particular CPU on hand and the particular data set for this particular job. So things like dynamic inlining *for this particular job* can allow the JVM to produce *better* machine code which will execute more quickly than statically-compiled code.

The translation takes time, but for long-running tasks that may well be easily amortised away.

So single-threaded Java can beat single-threaded C++.

But I can also bring more CPUs to bear on the code safely with Java for a given level of code complexity (well, now C++ finally has some sensible volatile semantics, that's a little less true).

And there are other factors such as the generally forced synchronous nature of C++ heap handling which can work against it.

Rgds

Damon

Comment Re:Performance improvements have helped it survive (Score 1) 511

I promise you that it was worth saving many MB in the .WAR and associated thumb-twiddling time, plus showing me in the logs which library and other routines were actually being used. I never felt the need to time stuff (since performance was at least not visibly worse). Shame on me!

If I get a chance I'll do as you suggest, though it'll be tricky with all the many things going on concurrently.

Rgds

Damon

Comment Re:Just don't try to write an OS in Java (Score 1) 511

My favourite related Java question to ask in the context of security is: "What's the difference between char[] and String, eg if I have one in a critical API as a public static?"

I'm quite happy to hear slightly 'wrong' answers as long as someone understands a little about wrapping/immutability and so on...

Rgds

Damon

Comment Re:Performance improvements have helped it survive (Score 2) 511

"WILL NEVER": gosh, not true and never has been unless you know the exact CPU and execution paths and data sets that you are compiling for, for all executions of the statically-compiled code. Please don't regurgitate this stuff.

When maintaining a C++ build system used internationally by a large bank I had to guess what the optimal target instruction set variant, cache line size, etc, would be over the lifetime of the output code, which was always a compromise over London/NYC/TOK/etc and a huge range of dev and production hosts of various ages. And with most/much of the library stack unsafe for C/C++ threading even though almost none of our machines (eg desktop or server-farm) where single CPU you could not then and could not now say whether C++ or Java would be necessarily faster on a given machine, given all the CPU- and run- specific optimisations the JVM has available to it that C++ does not.

I currently work on a Java low-latency high-frequency trading platform in the day job and an ASM/C/C++ based microcontroller platform for my start-up. And I think that I've been using C++ and Java for most of their existences, amongst other languages (I've been writing ASM for >30y); I have a fair idea of what is fast and what is productive.

Rgds

Damon

Slashdot Top Deals

Real Programmers don't eat quiche. They eat Twinkies and Szechwan food.

Working...