• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

There are two jre7 folders -- one in Program Files, one in Program Files (x86)

 
Greenhorn
Posts: 5
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have two jre7 folders. Can I delete one of them?

Here are the folders of interest:

C:\Program Files\Java\jre7 <-- This appeared when I downloaded jdk1.7.0_03
C:\Program Files\Java\jdk1.7.0_03

C:\Program Files (x86)\Java\jre7 <-- This appeared when I downloaded Java runtime environment so my computer can use Java

Can I delete the C:\Program Files\Java\jre7 folder without any consequence, because it appears to be the same thing as the other jre7 folder in Program Files (x86)? Just trying to de-clutter my computer. Thanks in advance.
 
Sheriff
Posts: 3837
66
Netbeans IDE Oracle Firefox Browser
  • Likes 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The "Program Files" folder contain 64-bit version of the JRE, and "Program Files (x86)" contains the 32-bit version. If you really don't need one of them, don't just delete the folder. Use proper Control Panel (Programs and Features, formely Add/Remove programs) to correctly uninstall it.
 
Griff Haldeman
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks. Also, are all files in the Program Files (x86) for 32-bit operating systems, and all in Program Files for 64-bit? And if I am running a 64-bit operating system, will I ever need the 32-bit version at some point?
 
Martin Vashko
Sheriff
Posts: 3837
66
Netbeans IDE Oracle Firefox Browser
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is no guarantee that a 32-bit application won't get installed into Program Files, or 64-bit into Program Files (x86). Firstly, users can override that manually with most installers, and secondly, some applications/installers are not coded according to MS specs and may get installed in the wrong place (most often the Program Files path is hardcoded, so a 32-bit app ends there, I don't think 64-bit app would end in (x86) folder by a simple mistake like this).

This separation is hardly useful IMO, it just allows you to have a 32-bit and 64-bit app installed into identically named folders (such as jre7) regardless of their architecture.

Only you can know whether you need a 32-bit and 64-bit version of the same application. Sometimes a functionality is not available in 32-bit or 64-bit version (eg. if an application uses a plugin which is a 32-bit DLL, it cannot be used with 64-bit application, and vice versa).

Speaking of Java, the situation is more complicated:

Firstly, if you have a Java application that calls native code and does not provide a DLL for both versions, you need to use the corresponding JRE. Period.

Secondly, although 64-bit JVM allows you to use much more memory, it comes at a price. A reference (pointer) takes 4 bytes in 32-bit JVM , but 8 bytes in 64-bit JVM. Since Java applications use so many references in general (everything is an object, right?), going 64-bit increases memory requirements significantly, by some 50%. Java actually mitigates this and uses compressed pointers when possible; compressed pointers take only 4 bytes, but need some decoding when actually using them, so there is a slight performance penalty instead of the memory overhead. See this article on HotSpot Performance Enhancements.
 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Most web browsers, notably Microsoft Internet Explorer, are still 32-bit, even if you are running a 64-bit version of Windows. To be able to use Java applets on websites in your 32-bit browser, you'll need to have the 32-bit version of Java installed.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic