OS Arch Details

1,293 views
Skip to first unread message

kid_wonder

unread,
Aug 3, 2015, 7:51:39 PM8/3/15
to OOO Libs
This article actually explained why I was doing OS Arch stuff wrong: http://mark.koli.ch/javas-osarch-system-property-is-the-bitness-of-the-jre-not-the-operating-system -- and thought it might be good to put out for others

Running on Windows 7 - 64 bit OS machine and
Running Java 1.6 32 bit JVM -  launcher.log shows: 

2015/08/03 14:40:55:567 INFO m.a: -- OS Name: Windows 7
2015/08/03 14:40:55:567 INFO m.a: -- OS Arch: x86
2015/08/03 14:40:55:567 INFO m.a: -- OS Vers: 6.1
2015/08/03 14:40:55:567 INFO m.a: -- Java Vers: 1.6.0_45


Running Java 1.8 64 bit JVM -  launcher.log shows:

2015/08/03 15:30:17:540 INFO m.a: -- OS Name: Windows 7
2015/08/03 15:30:17:540 INFO m.a: -- OS Arch: amd64
2015/08/03 15:30:17:540 INFO m.a: -- OS Vers: 6.1
2015/08/03 15:30:17:540 INFO m.a: -- Java Vers: 1.8.0_45



Like I said, this caused me a bit of confusion - perhaps a little note on the getdown-dot-txt page would be helpful for others:

The above configuration uses only the platform identifier, returned by System.getProperty("os.name"). It is also possible to use the architecture identifier, returned by System.getProperty("os.arch"). This is done by following the platform identifier with a - and then adding the desired architecture. 

[NOTE: Read this article http://mark.koli.ch/javas-osarch-system-property-is-the-bitness-of-the-jre-not-the-operating-system. These are usually properties of the JRE/JDK itself, and not necessarily the real properties of the underlying OS or architecture.]

Also, at https://github.com/threerings/getdown/wiki/Getdown-Dot-Text it uses the following notation in the examples: [windows-i386] which does not seem to work for me, I am using [windows-x86]
Not sure how out of date this is: http://lopica.sourceforge.net/os.html since it is webstart related, but this is what I referenced.


- kw

Michael Bayne

unread,
Aug 3, 2015, 8:23:45 PM8/3/15
to ooo-...@googlegroups.com
On Mon, Aug 3, 2015 at 4:51 PM, kid_wonder <kscot...@gmail.com> wrote:
Also, at https://github.com/threerings/getdown/wiki/Getdown-Dot-Text it uses the following notation in the examples: [windows-i386] which does not seem to work for me, I am using [windows-x86]

Thanks: I updated the wiki to reflect the latest values I could find. It looks like Linux may still report i386 for 32-bit JVMs, and both Windows and Linux report amd64 for 64-bit JVMs.

Incidentally, if you're using this to filter native libraries, it's the bit-size of the JVM you care about, not the OS, because if the user is running a 32-bit JVM on 64-bit Windows, you still need 32-bit versions of the DLLs to link with the 32-bit JVM.

If you're using this for some other reason, then you're kind of on your own. This filtering mechanism was mainly implemented so that one could download the appropriate flavor of native libraries for the JVM.


kid_wonder

unread,
Aug 3, 2015, 8:35:57 PM8/3/15
to OOO Libs

On Monday, August 3, 2015 at 5:23:45 PM UTC-7, Michael Bayne wrote:
Incidentally, if you're using this to filter native libraries, it's the bit-size of the JVM you care about, not the OS, because if the user is running a 32-bit JVM on 64-bit Windows, you still need 32-bit versions of the DLLs to link with the 32-bit JVM.


Yes! Monday, apparently, is not the best day to have to sit down and figure this out. Hopefully, that will help someone down the line.

Aha! See, that makes total sense about the amd64 -- didn't connect it all together until I read that. My work machine is Intel, my home machine is AMD but Oracle just chooses what to hard code into their 64bit property value. More cobwebs removed!


thanks
kw

Nicolas Barbier

unread,
Aug 4, 2015, 9:06:37 AM8/4/15
to ooo-...@googlegroups.com
Hello,

2015-08-04 kid_wonder <kscot...@gmail.com>:

> Aha! See, that makes total sense about the amd64 -- didn't connect it all
> together until I read that. My work machine is Intel, my home machine is AMD
> but Oracle just chooses what to hard code into their 64bit property value.
> More cobwebs removed!

“amd64” or “AMD64” is a common identifier for the 64-bit version of
the x86 architecture (sometimes also called “x86-64”, “x86_64” or
(mostly by Intel) “EM64T” or “Intel 64” or (by Microsoft) “x64”) as
originally defined by AMD; It has nothing to do with the actual
manufacturer of the CPU. For example, I have an Intel CPU, but Debian
calls my architecture „amd64” while my kernel (Linux) calls it
“x86_64”. Conversely, Debian calls the 32-bit version of that
architecture “i386” (where the “i” stands for Intel) even if the
actual CPU may be manufactured by AMD or others.

Greetings,

Nicolas

--
A. Because it breaks the logical sequence of discussion.
Q. Why is top posting bad?

kid_wonder

unread,
Aug 4, 2015, 3:14:39 PM8/4/15
to OOO Libs
Wow, that is crazy, thanks Nicolas. Cobwebs are back :) 
Reply all
Reply to author
Forward
0 new messages