8 ms·
I chuckled at this: "In schools and colleges that use Office 365, students will be able to log on to Minecraft using their Office credentials." Because everyone
by ChuckMcM 11y ago
I chuckled at this: "In schools and colleges that use Office 365, students will be able to log on to Minecraft using their Office credentials." Because everyone things "how can I log into this game? Oh yeah, with my office credentials." :-)
That aaid, one of the more interesting debates I participated in at Sun was Bill Joy's insistence that interpreted Java would be "faster than C++." From what I recall of his argument, it was that understanding the semantics of the program and just in time compilation would allow the JVM to run only the code that was needed in a smaller resident set with fewer context switches. At the time I was arguing against that, saying that a compiled version of Java could be a useful systems language but the interpreted version would not.
And even with some really really amazing hotspot technology on the JIT compiler, I don't think Java was ever faster outside of a few synthetic test cases that did no useful work.
So it really doesn't surprise me that a C++ version of minecraft would out perform a Java version, but it would be much more interesting if they included a JVM for the mods, so that the core was fast and the mods were portable.
- jdmichal 11y ago> I chuckled at this: "In schools and colleges that use Office 365, students will be able to log on to Minecraft using their Office credentials." Because everyone things "how can I log into this game? Oh yeah, with my office credentials." :-) I know this was meant to be a joke, but this was more an issue in wording by Schofield (the writer) than anything else. A Microsoft account is pretty much global across all their products. So it's also their email account, their OneDrive account, their Azure account... I'm assuming he picked Office 365 simply because that's the product he thinks is most likely to be already used in the school. As for the optimization; the JIT's main optimization from what I've researched is inlining. Which is really beneficial for Java because you tend to end up with a nest of getter method calls all to get a single field somewhere, and wouldn't it be nice if the JIT could just inline that field for you? I suspect that, especially if performance is at stake, it's less typical to end up with patterns like that in a C++ codebase.
- ganeumann 11y agoYes, this is a good strategic move by Microsoft. All of my kids have Google apps accounts that their schools set up for them. They are required to use Google docs, etc., so they can work on stuff at school and at home. I assume that a good portion of those kids will continue to use Google apps as a default for a long time. Similar to a strategy Microsoft used to keep Office a standard: the dirt-cheap student version. If Microsoft can get schools to use Office 365 instead of Google apps, then $2.5 billion for Minecraft was cheap.
- iLoch 11y agoSure but first MS needs a Google Classroom competitor because that's probably the other major Google product that schools are using.
- kbenson 11y agoNot that it's a fair comparison, but I wonder if you took a Java from today and compared it to a C++ compiler from then, would the optimization differences make Java faster for a larger subset of algorithms? I wonder if this was just the classic problem of assuming your competition is static, and planning to eventually surpass their current capabilities while ignoring that by that time their capabilities may have evolved as well.
- vvanders 11y agoNope, it has to do with the fundamental memory models of Java vs C/C++. In C++ you can arrange your access patterns so you don't cache miss, much harder to do that in Java.
- pjmlp 11y agoTrue, but it will hopefully change in Java 10.
- vvanders 11y agoGiven the ~3-5 year release cycle trend(plus the fact that android is still Java 7) I'm sure we can expect it by 2025 ;)
- pjmlp 11y agoMost likely Google will never update beyond Java 7, if their attitude at Google IO is anything to go by. For me what counts is the official Java, not forks.
- bitmapbrother 11y agoThey've already updated to Java 8 with the switch to the OpenJDK so whenever Java 9, 10, 11, etc come out they'll be in sync.
- 11y ago
- pnathan 11y agoTo be honest, a lot of people have slammed the Minecraft codebase, claiming it's badly written and kind of a slow mess. I can't recall the citations, but based on the discussions when I read those aspects, I wouldn't put aspersions on Java alone in this case.
- looki 11y agoI remember reading a blog post where somebody talked about how they severely decreased Minecraft's performance after refactoring and replacing function calls with separate X, Y and Z parameters to using a single Position object, which would of course in many instances have to be allocated on the fly. I can't seem to find it anymore, though.
- wtallis 11y agoYes, something that should have at a minimum caused no harm to performance (and possibly helped, such as by allowing for SIMD) and been a win for code readability instead introduced an extra layer of pointer chasing and heap allocation, because Java doesn't have structs. See https://news.ycombinator.com/item?id=8485180 https://news.ycombinator.com/item?id=8485180
- mike_hearn 11y agoIndeed. They are adding value types though. It'll take years but once done, this kind of problem shouldn't crop up again. They've also been doing work on better escape analysis. The JVM can do a lot of optimisations C++ apps don't benefit from, but I think the loss from not having value types more than drowns them out.
- looki 11y agoThat's the one, thank you.
- Macha 11y agoIt was a one-man hobby project turned into one of the biggest video games. I doubt many codebases would work well after growing so far past their original aspirations.
- jayd16 11y agoCompiled versions of Java libraries and apps would ruin the whole ecosystem and basically the best thing about Java. The CLR is a good compromise but in the end its not that much better. Hindsight is always 20/20 so it really doesn't surprise me any rewrite is faster than the previous version.
- uxcn 11y agoNot that I prefer Java where performance is important, but profile based optimization combined with optimizing across translation units is non-trivial. C/C++ compilers have been increasing support for these more recently. Jan Hubicka's blog has a good example [1]. I have to wonder if they plan to keep the codebase portable though. One of the major benefits of Java was that nearly everything has a JVM. [1] http://hubicka.blogspot.com/2014/04/linktime-optimization-in-gcc-2-firefox.html http://hubicka.blogspot.com/2014/04/linktime-optimization-in...
- pjmlp 11y ago> One of the major benefits of Java was that nearly everything has a JVM. This was a big deal in the late 90's as C compilers were still catching up with ANSI C and ANSI C++ wasn't done, with each compiler supporting a different flavour of the ongoing work.
- uxcn 11y agoI would guess a lot of stuff wasn't completely POSIX either (still kinda true). It's really only recently C++ added a standard memory model, portable threading, etc... POSIX is even kind of falling behind for this stuff IMHO.
- pjmlp 11y agoPOSIX is basically what should have been the official C runtime, but they didn't want to make it a richer runtime. At least as I see it.
- pjmlp 11y agoI read somewhere that it was a religious issue not providing AOT compilation. It always saddned me not to have this option in the reference JDK, only on commercial JDKs. Whereas we already had Java like safe languages with Eiffel, Oberon and Modula-3 compiling AOT to native code, and with JIT also available before 1996. Oh and with value types and proper generics as well. Now maybe Java 10 will become what Java 1.0 should have been.
- mike_hearn 11y agoThey're adding AOT compilation to Hotspot. However it'll be a commercial feature. The main reason being, they think it only really matters to rich trading houses that want to hit full speed when the market opens at exactly 9am. The tricky part is that there'll still be JIT compilation happening, because otherwise the program runs quite a bit slower, as the adaptive optimisations can make a big difference.
- pjmlp 11y agoI saw the JLS 2015 presentation about it. Which is sad, because if I want to pay for it I don't need to wait for Oracle, almost all comercial JVMs already do it. When I got into Java, I always expected it to eventually support AOT on the standard compiler.
- scholia 11y ago> I chuckled at this: "In schools and colleges that use Office 365, students will be able to log on to Minecraft using their Office credentials." Because everyone things "how can I log into this game? Oh yeah, with my office credentials." :-) If you're a teacher, it's a huge boon to be able to re-use existing accounts. You really don't want to make dozens of classes of kids set up and remember new IDs and passwords for a single application.
- SeanDav 11y agoRight now many trading houses with huge IT budgets are choosing Java for their high frequency trading systems. This is an arena where microseconds matter and the fact that Java is a viable choice, says a lot about the speed and power of modern Java.
- riskable 11y agoActually, they've moved beyond that now. The trend in high speed trading is towards FPGAs. "Java don't play that." (not in any serious way). Java in finance is actually slowly eroding overall. Performance-critical logic is being moved into Python modules written in C. "That's how we do it" anyway. The trouble is that Java code development is too slow and just getting your code deployed into a test environment is often ridiculously complicated (lots of middleware) whereas with Python "you write, you run, you're done."
- w8rbt 11y agoBoost Python is great for C++ shops too.
- uxcn 11y agoIt's still popular. For example, LMAX still uses Java. There were a number of things you needed to avoid if you wanted to use it where latency mattered though. GC pauses are fairly detrimental. Where latency is really critical, things are implemented in FPGA though.
- pjmlp 11y agoAlthough I guess that is telling that one of LMAX authors (Martin Thompson) has moved back to support C++ alongside Java on his newer product. http://mechanical-sympathy.blogspot.de/ http://mechanical-sympathy.blogspot.de/ I guess C++ progress in the last years has helped this.
- uxcn 11y agoEven before 0x, a there was definitely a genuine performance need that drove a lot of stuff from Java to C++. A lot of people I know would write Javaish code with Boost. A lot of the stuff that makes Java great for building high level systems quickly is still kind of missing from formal C++ though (IoC, JMX, etc...), and it would have been nice to see some of the internal stuff get open sourced. I wonder if people are starting to avoid Java because of Oracle (e.g. vs Google).
- zamalek 11y agoThe real reason for chuckling here is the implication that anyone would use O365 for personal use. I'm stupid enough to use it and have almost decided to write-off the money I paid and go elsewhere. This is what $70/yr gets you: 1. ActiveSync! This is the only reason I'm still putting up with this garbage. 2. My company also uses O365, extensively. We have a wiki of sorts in OneNote. I can't contribute to it. Logging into the corp account and clicking "open in desktop" results in an error that claims that I don't have a license. I do. On an on-premise licensed domain-joined machine. I don't on my own O365 account but I didn't log on with that. 3. No layman interface. Want to disable password expiry for your 89yr old father? You'll need to download and install a powershell plugin before you can start reading documentation. 4. Inexplicable login problems. No UI to enter my login email because I had logged into a temporary SP online site I was debugging with. Later I found a "forget this login" link under the temporary login; restoring my access to any other account. 5. "Live login? Microsoft login? We don't know, tell us every time. Oh! You can't use Live with this service anyway!" I no longer know which of the two accounts my stuff is on. TLDR; O365 is great for corporate/business. I'd recommend it. For personal stuff stay the hell away. They really want to give O365 to kids?
- Sanddancer 11y agoThey're giving it to /schools/. Schools have pretty much the same needs as corporations/businesses, in terms of security levels, etc.
- mavhc 11y agoBut usually only 1/10th the budget for people to run it. I've set up both O365 and Google Apps for schools, Google LDAP sync is way easier to work with, although the syncing of passwords is harder. MS's AD sync is complex, and ended up filling one server with debug log files.
- tomcam 11y agoStunning that Bill Joy ever thought interpreted Java could be faster than C++. I thought he knew more than that...
- rch 11y agoHe may have simply overestimated the availability of Bill-Joy-like programmers.
- tomcam 11y agoKindly explain the downvotes? I have nothing against Java. But C++ has direct control over memory and/or memory allocators, the option of allocating things on the stack, no garbage collection, etc.
- AaronFriel 11y agoWhat the author means, and is significant for the market (Minecraft Education Edition) is that it will work with any "Azure Active Directory" credentials. Every school I've worked with either uses active directory or has another directory service that exposes endpoints (usually SAML based). Read that line instead as: Good news! Your teachers and their students won't need yet another password to be able to use this application.
- Mikeb85 11y ago> That aaid, one of the more interesting debates I participated in at Sun was Bill Joy's insistence that interpreted Java would be "faster than C++." Today, with JDK8, that's almost true. With JDK9 it might be. There's no reason Java can't be faster, it just hasn't happened yet.
- on_and_off 11y ago>So it really doesn't surprise me that a C++ version of Minecraft would out perform a Java version I am not sure it is a fair comparison. had Minecraft been written in C++ with the same dev cycle, a complete rewrite in Java would also allow to improve its perfs ...