Distributing Sun server-vm

Re robilad

Note that I often use JFrame and Graphics2D for completely system independent look and feel. And note that I want my programs to differ completely from other programs on at least windoze and MAC. (So undecorated(true) is a common thing.)

Also note that until I could type in command prompt “GJC -recompileToWindoze program.jar -fullOptimalizations -safeArrays -Xmx 2G” I would consider GJC as worse alternative to Java 5.0 compatibile VM. Not to mention that I don’t like SWT.

Of course existence of a free (as free of charge) higly optimalizing 64 bit compiler would be nice addition, especially for system programming. This would however require cooperation of Sun, Intel, and AMD.

From what I seen with CIL it’s crap with the same problems as a bytecode. Also I seen talk about problems with compatibility between 1.0 1.1 2.0 and I think I would stay for at least 2 years away from this before they would make codebase changing less often. Also it looks like Mickerosoft would like to more support office applications with this, so it could have its own problems. (BTW did they finished problems with unloading assambly at runtime?) Additionally what would happen with IKVM if my game would change its own code at runtime? This is nice and effective way how to deal with the AI. It would be really bad thing if it would cause crash, or slow down a game by factor of 15 because of lack of inlining, and compilation.

Call me stupid, impatient, lazy, or incompetent (go on, feel free ;)) but I can’t figure out how to get any of those free VMs working properly. Is there not just a download that works on Windows somewhere? All I want is my miniVM, implemented using free code… none of this Swing rubbish.

Cas :slight_smile:

What are you talking about??? JDS SHIPS with a JRE.

WRT to the download size, I have stated my thoughts on this a million times: as Java distribution increases and, broadband penetration increases, this is a problem that will continue to diminish. 67% of current PCs have Java 1.4 or better. Java.Com is doing over 14 MILLION downloads of the JRE each month. If you were a console developer and you had the ability to write to a platform that enjoyed a 67% market share, would you write to it? You bet your life you would.

The argument left standing here today is from people who don’t want to take advantage of the distribution but want to do what they want with the platform because they know better. Could the download experience be better? Sure and we continue to work on improving it.

-Chris

The Swing implementation is a work in progress, so it has raw edges (and unimplemented classes like the HTML display widget). In my experience simple Swing widgets (JFrame, etc) work sufficiently well, in OpenOffice.org 2’s wizards, for example. If you are not going to make a game with lots of swing widgets and layouts, and inparticular if you design your own control elements, you should be going fine.

Graphics2D is a tougher story. It works using Cairo as its backend on GNU/Linux, but I have no idea whether anyone tried it out yet with the Cairo port to Win32. You’re in heavy alpha landscape on win32 wrt to that. You may want to check out Agile2D, which implements Graphics2D on top of OpenGL, and gives quite performance boost for some operations. See http://www.cs.umd.edu/hcil/agile2d/ for details.

On the other hand, JOGL should be working since a few months, according to http://www.spindazzle.org/green/index.php?p=50

Understood. Afaik, you can get the equivalent of that using gcj -O3 -fno-bounds-check -fno-store-check something.jar . See the manual for details. Come to the IRC channel #gcj on irc.oftc.net if you encounter problems, or drop by the gcj mailing list.

Also note that using anything from the undocumented sun.* class hierarchy will be deadly for ompiling to native code with gcj, since those classes can’t be reimplemeted as they aren’t documented by the specs.

gcj may get there eventually, as both Sun and Apple use gcc on some of their 64bit platforms, so they need to have a nicely optimizing gcc backend. Apple has done some nice work that went into 4.0 series, and I’d expect to see serious performance benefits from it in the 4.1 series. Since gcj uses gcc’s optimization backends, it gets to reuse all that work ‘gratis’.

A cooperation between Sun, Intel and AMD to create a gratis proprietary Java native compiler is, afaict, unlikely.

Sun has experiemented with AOT in the past, but dropped the approach, and resorted to resuing Apple’s approach to pre-jit the system class libraries upon installation, afaik. As far as I can guess, the lack of an official AOT compiler has less to do with technical problems, but more to do with business decisions.

Essentially, bundling such a compiler gratis by Sun would cause bad blood with their licensees who have commercial products doing the same thing (though not gratis, of course, as the comapnies pay a nice fee for licensing Sun’s sources and tests suites for commercial use, which, btw, is one of the ways how Sun makes money with their Java technology) and deprive Sun from the licensing income while requiring them to spend money developing and (in particular) maintaining the tools.

As you can imagine, it’d be unlikely for Sun’s management to agree to kill their licensing income in this sector, and spend some more money on reinventing the technology (Sun officially supports x86, x86_64, and sparc64, and they’d have to make AOT work on all of them to avoid deemphasing Solaris, which they make money with, over Windows, which they make no money with), only to create a highly optimised tool to give away gratis. The business side of it just does not add up for them, at the moment.

In particular if they end up with a great compiler on their hands that makes it very easy to publish fast, windows-only Java applications and relegates Java to being solely a programming language, rather than a platform. That’s precisely what Microsoft tried to do to them back in the 90s, and Sun did not like it very much, once they figured out Microsoft’s strategy.

Politically, that would mean Sun’d have to invest money to make and maintain a product that only increases the lock-in on Microsoft’s platform, and given that Sun make no money on Windows sales, and would not make money selling a gratis compiler … as I said, the business side just does not add up for Sun. At least at the moment.

That depends on how you do it. In dynamic execution mode, IKVM translates java bytecode on the fly into CIL code.

If you want to have in depth information about IKVM, I suggest posting to the IKVM developer mailing list on IKVM.net and asking for assistance with your specific application area.

cheers,
dalibor topic

In theory, http://sourceforge.net/project/showfiles.php?group_id=69637 should lead to an IKVM release that works on windows with either Mono or Microsoft’s .NET, and http://thisiscool.com/gcc_mingw.htm should lead to an gcj release with SWT and all that jazz that works on windows.

In practice, I am posting this from Ubuntu GNU/Linux, where it’s all just an apt-get away :wink:

cheers,
dalibor topic

Just for the record, I agree. I’ve argued the same point - that broadband has taken over and the download time is now (or in some areas is just becoming) a non-issue.

We always knew this problem would take care of itself in time… but it seems it happened a little too late.

[quote]67% of current PCs have Java 1.4 or better.
[/quote]
Define “current”. How does it compare to the # of PCs in use? Does "current mean the same thing in this context?

[quote]The argument left standing here today is from people who don’t want to take advantage of the distribution but want to do what they want with the platform because they know better. Could the download experience be better? Sure and we continue to work on improving it.
[/quote]
I only suggested the license tweak because Sun already allows bundling a private JRE. I dont see what Sun gets out of it in the case of bundling a private JRE. They don’t get the JRE distrubted in an externally recognizable way, they don’t get any acknowledgement at all that Java is used. They get no payment of any sort. Fragmentation of the JRE is a non-issue in this context because for all other intents and purposes Java isn’t even there. So it seemed like it would be a simple thing to do to satisfy those that still aren’t happy. If bundling a private JRE wasn’t already allowed in the license then I would never suggest anything like it.

There already is a branding program in place and anyone bundling the JRE in a private directory SHOULD be using the “Java Powered” logo. In fact, having Activision place it on their retail distribution of Vampire: The Masquerade 5 years ago was the first consumer product to ship with the logo. However, it is not something that has been actively enforced.

Chris - despite Sun thinking it’s a non-issue, the fact is that it is still a huge barrier for the online game markets, in particular the market that should be the most accessible for independent developers - casual games. Assuming 67% of PC’s have Java installed may be right overal, but is very wrong for the casual games audience (60% composed of women over the age of 30 primarily not working in technology industries - that’s probably 90+% of that missing 33% right there), that is a huge hit to take.

All of that is moot however, there is no way that the portals will accept a game that requires (even optionally) a second download of Java, because they will have to support it. End of story - no go… Why take my game when there are 50 other submissions to review that DON’T require Java? Especially when combined with the fact that OpenGL is our only option for 3D accelerated (has made me think of building a DX binding) is already a point against you in the eyes of the portals (they already don’t like supporting OpenGL games).

I don’t think I know better, I just want a smaller distro so my game has a fighting chance among the sea of casual games. It’s a very competitive market. I want my game to be on the portals and played. That’s all.

To be honest; this is really my own fault for using Java to make my game. I realize it’s not really Sun’s concern and Sun didn’t design Java for this purpose - but I also hope that Sun is open to making Java a viable option for casual games development. Java is already a black sheep technology for games development and this is one of the top (if not the top) issue for casual games developers.

I ask again: Where is the evidence for this? What are the figures?

You have dozens of people here who WILL spread this info if you just allow them to do so. Right now, we can’t go around peddling this figure “because Chris said so” - it leads to people smiling patronisingly and saying “sure, you can come up with any statistic you like if you just pluck it out of the air”.

Please … help us help you.

If we had infinite time to wait, most of us would be right behind you. The problem is that most of us don’t :(, and keep spotting little tiny things that Sun could do that would take a very small amount of time if someone suitably high up would simply say “make it so” and yet would do very well as stop-gaps until the glacial improvements percolate down to the actual produciton JVM’s installed on desktops.

This is why we seem to be arguing whilst agreeing with you: JVM dev often goes in the right direction, but it just takes far too long. There are one-off opportunities around for java today, and if we don’t seize them, it could be a long time before the next bunch come along :(.

Really? I can’t imagine why any portal would care at all about OpenGL vs. DirectX. Do they think they need to support the whole OS the game is running on?

As far as DX bindings, Java 3D already runs with OpenGL or DirectX bindings. So there is one solution already available for that problem. (supplied by Sun at no cost to you). I can’t say that I would be sympathetic to that particular complaint if I were Sun.

Every portal cares about Open GL - not because they will have to support the OS, but because many video cards have crappy support for OpenGL. I personally don’t see it as an issue because the major card manufacturers do support it. The portals however want support to be very very simple because they deal with thousands of customers - anything that can cause them or their customers any kind of pain is frowned upon (which is why they won’t have secondary downloads of Java).

As for using Java 3D - I have used it but it fails in the performance department - again these games have to work on as low end a machine as possible - target machines start at 300Mhz (again…beating this dead horse for clarity…unsavvy customers). If your game requires even a 1.5Mhz machine you will be frowned upon by the portals.

This is a very particular development domain - the business model depends on getting as many downloads as possible with the least amount of support. Two things that Java by it’s licensing and nature tend to conflict with.

[edit] On second thought Java3D would be ok for some games - just not what I am building. Though it would also increse the DL size…yet again[/edit]

Here are the rules for portal games:

  1. No additional downloads. Under any circumstances.

  2. Size under 10mb

  3. Mac not currently relevant (may change soon)

  4. Rules out any kind of system JRE dependency. It also counts heavily against OpenGL, although it’s been heard of to be successful with OpenGL - but those that are successful with OpenGL always provide a pure software renderer as a fallback, something plain old Java isn’t particularly fast at.

  5. Rules out any kind of embedded JRE. Although once again it has been known that games can be bigger; but generally this is because they are packed with content.

What are you left with?

Cas :slight_smile:

So, no one ever publishes a game through a major portal (Yahoo, PopCap, Pogo, etc.) without ever requiring an additional download? How does Pogo, for example, then carry games that are developed in Java, Flash, Shockwave and Wild Tangent? Are all of these technologies shipping with new systems? No, only Java is.

While writing this, I went to Pogo.Com. Ah! Here’s a game I want to try: Freakstyle Crash Pad. Click the link and OOPS!:

[i]The following error has occurred:
Installation Required

Explanation:
This game requires WildTangent in order to run in your browser.

How to Fix the Problem:
Download the WildTangent installer from the following page and run it.
WildTangent installer page

Note: This is only supported on Windows platforms.[/i]

Hmmm…seems that EA does not know about the “No additional Downloads rule” :slight_smile:

WRT to portals supporting Java: Read this section from EA/Pogo’s support site:

[i]What is Java? Why do I need it to run Pogo games?

Java is a programming language created by Sun Microsystems. It’s unique among other programming languages because it was built to run on any 
operating system  (Windows, Linux, Mac, etc.) Almost all of Pogo's games are created with Java, and are constructed in a way that they can run right
 inside your web browser, using the Java Virtual Machine installed with your browser.[/i]

[quote]2. Size under 10mb
[/quote]
Game can be under 10mb, no problem. After a ONE TIME download for those that need it, there is no issue. Same goes for updates to Flash, Shockwave and WildTangent or DirectX.

[quote]3. Mac not currently relevant (may change soon)
[/quote]
Mac is not currently relevant because developers have choosen not to make it relevant. Just as EA chose to make the Sega Dreamcast irrelevant by not developing for it despite the millions of consoles sold.

[quote]1. Rules out any kind of system JRE dependency. It also counts heavily against OpenGL, although it’s been heard of to be successful with OpenGL - but those that are successful with OpenGL always provide a pure software renderer as a fallback, something plain old Java isn’t particularly fast at.
[/quote]
Does not rule it out. I believe this over and over and over again: If your game is compelling enough, people will get the download. If people want to have access to a portal with a bunch of free games but have to do a 16M download first, they will.

[quote]2. Rules out any kind of embedded JRE. Although once again it has been known that games can be bigger; but generally this is because they are packed with content.
[/quote]
Just point them to the automated JRE download at Java.Com. Again, you will have to do this less and less over time.

Here is a question for Cas, after embedding the JRE and stripping out the bits you don’t want, has your download for Alien Flux changed dramatically? Are you getting into many more portals than you had before? If you have, that’s awesome. If not, why?

[quote]What are you left with?
[/quote]
Hmmm… how about the most widely adopted programming language with C performance shipping on more PC’s than any other non-Microsoft application AND freely available tools and free distribution license, all of which is built in a community process and allows for anyone to submit changes/improvements? :slight_smile: Tell me, what other technology offers all of that with the same distribution that Java has? None that I can think of.

I don’t want to sound unappreciative. I appreciate everything this community has to offer. I RESPECT you developers out there making a living (or trying to) though game development. I am concerned about your issues and want to help make things the best they can be for developers and users. But some of the old assumptions about the market are just wrong. Do a lot of portans still believe that you HAVE to use Java 1.1? Absolutely. But, we are workign really hard to educate these companies and show them just how many desktops are running a modern VM and will continue to push this.

WRT Blah3’s request for more information about installs. You are completely right. Why should you just trust my word? Here is what I will do. This week I will talk to the gentleman who runs all of Sun’s web properties and has access to the stats and see if I can publish official numbers and, perhaps, even assemble a one-page “slick” detailing these stats. I appreciate the offer that this community is offering to help us help you by getting the install base moved up.

Lastly, WRT Vorax’s comments about us not caring: Jeff and I have been killing ourselves for almost 5 years to make Java better for games. Through pusing internally, building community, education internally and externally, etc. I think we have done a pretty good job. One question that always comes up is how do we balance work between efforts that produce revenue and ones that don’t? Always a huge fight in any company, but one that Jeff and I continually fight for. I mean, we could adopt a model like Flash, which would include a stripped VM and development tools and charge you $1400 per seat, but we don’t. Java continues to be free for those who want to delpoy on the desktop.

Thanks again everyone for your time, support, effort and community :slight_smile:

-Chris

Chris, you are confusing online games portals (ad revenue) with online distribution portals (pay and download). Many sites are both - free games have little or no support - pay and download are supported.

  • Yahoo (Does both) only deals with free Java, Flash, WT, SW for FREE online games (in the browser) free online games are done in various technolgoies - they also sell full games - I have never seen additional downloads required for purchasable games. Support for free online - is limited to none - purchased games are supported.

  • PopCap is not a portal they are an indy developer - the games they distribute on portals (the “deluxe” versions) do not require additional downloads

  • Pogo (Does both) same as Yahoo. None of their offline games (Click the download and play link - purchasable versions) that you pay for have additional downloads required. When the customer has paid for the product, they expect support. Pogo provides limited to no support for the free games and supports purchased games.

That is a small sampling of the portals - many use the same models though - Indy developers are interested in and chasing the “Purchase and download” - PopCap does the free in browser games as a means of marketing their real product - the full downloads.

Vorax,

So, how much of the casueal makret you are going after wants the pay and download model vs. the pure web browser portal games? You are saying, then, that thses non technical 35+ year old women are whipping out their credit cards to pay and download a version of solitare vs. playing the free portal version? If you are getting someone to actively go through the trouble of getting out their credit card, typing in their information and waiting for the download, then I can’t believe that the game being an extra 12MB in size is an issue. They are ALREADY going to great lengths to get the content, waiting an additional 15 min is not a deterrent.

-Chris

Actually, the way it typically works is the users download the game to play the “deluxe” ish type version - Solitaire with 40 different configurations, save games, full screen graphics, more music for example - then they click a button in game to purchase a code that unlocks it without any additional download. This is why the games should be small. To get them to download it in the first place, knowing it will only allow them to play for 1 hour without purchasing it.

They can try dozens of games this way, that is why size becomes critical - if the user can download 3 games in the time it takes to download my one game they probably will.

Try some of the purchasable games to see what I mean - most are smaller then the Java distro is. They will have a demo version that can be unlocked by a code (very rarely do they require the user to download the full version).

The thing to keep in mind is that the user can download any of these demos’ they want to try them out - in the time it will take to download my game with Java, they could have downloaded 3 others from the hundreds out there.

Or, they do it the popcap way. Try the web game all they want then download the “premium” version with a credit card. And again, if people are interested enough in the content, they will wait though thte download. OR, why not do a check to see if they have a current VM installed? Offer 2 downloads, one with the JRE and one without?

-Chris

oh :o post is already 10 pages long.

i have to say i appreciate what you SUN guys are doing for the java game communtity but its happening at a very slow pace, which is IMO harming java in the long run as its a big a oppertunity(games market is huge, i’m sure sun’d like a piece of it). IMO the issue soundn’t be whats wrong but how we can go by to solving it!

why not propose a mini jre that is bundled with the game but asks the user if he’d like to install a full jre or use the stripped jre, clearly this has benefit for both sides:-

Developer

  1. it can get the java game size down
  2. avoid including the full jre if its already on the system.

SUN

  1. help sun promote its jre to computers that don’t have it,
  2. mini jre can remain on the computer and if a user later tries to run a java app/applet, it can again offer to install the full jre.

The portals won’t go for the optional download so we are back to the start - we are forced to embed the JRE and increase our download size by 12MB - thus the request to be allowed to strip down the JRE to just the parts that are needed. For LWJGL games, the remainder can be as little as 1.5MB. If my game is 5MB without the JRE, then it’s 6.5MB with a stripped down or 17.5MB without. That 12MB will effect how many people download it.

The thing to understand here is the failure rate of Indy games is extremely high. Very few actually make money. In order to be sucessful you have to get your game on the top 10 lists to keep up it’s visibility. If 11 games come out that are all high quality and 10 of them are half the download size as mine - you can almost guarantee that I will not be on the top 10 list even if only 10% of the people had a problem with the download size.

Failure of indie games is high, but I don’t think that really relates to downloads that much. If a game is good the few people that initially download it will tell their friends - and a friend’s recommendation generally supports a much longer time to wait for the download.

Portals are important - but they don’t seem to be the be all and end all.

Kev