Java Byte Code Compiler & New objects

Posted on 2006-04-09
Last Modified: 2013-11-23
1. I would like to know how does the Java Byte Code Compiler work,
whats the difference between "JIT just-in-time compiler" & intepreted methods?
How does Hotspot VM compiler come in?

2. Whats the difference between using new() to create new objects
and Class.newInstance();

Question by:jedistar
    LVL 35

    Accepted Solution

    1) Nice bytecode explanation:

    Nice JIT vs Interpreted explanation:

    Hotspot was the name for the JIT JVM.

    2) Class.newInstance is using reflection

    new Object() is the normal way of doing it, but you have to know what class of object you're going to be creating beforehand...

    LVL 13

    Expert Comment

    >> 2. Whats the difference between using new() to create new objects and Class.newInstance();
    new <class>()  is faster than using reflection Class.newInstance()

    Featured Post

    Why You Should Analyze Threat Actor TTPs

    After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

    Join & Write a Comment

    For customizing the look of your lightweight component and making it look lucid like it was made of glass. Or: how to make your component more Apple-ish ;) This tip assumes your component to be of rectangular shape and completely opaque. (COD…
    Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
    Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
    Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now