Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Learning Java Lambdas

You're reading from   Learning Java Lambdas An in-depth look at one of the most important features of modern Java

Arrow left icon
Product type Paperback
Published in Mar 2017
Publisher
ISBN-13 9781787282087
Length 114 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Toby Weston Toby Weston
Author Profile Icon Toby Weston
Toby Weston
Arrow right icon
View More author details
Toc

Bytecode recap


To start with, let's recap on what we know about bytecode.

To get from source code to machine runnable code. The Java compiler produces bytecode. This is either interpreted by the JVM or re-compiled by the Just-in-time compiler.

When it's interpreted, the bytecode is turned into machine code on the fly and executed. This happens each time the bytecode is encountered but he JVM.

When it's Just-in-time compiled, the JVM compiles it directly into machine code the first time it's encountered and then goes on to execute it.

Both happen at run-time but Just-in-time compilation offer lots of optimizations.

So, Java bytecode is the intermediate representation between source code and machine code.

Note

As a quick side bar: Java's JIT compiler has enjoyed a great reputation over the years. But going back full circle to our introduction, it was John McCarthy that first wrote about JIT compilation way back in 1960. So it's interesting to think that it's not just lambda support that was influenced...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime
Visually different images