Fastest way to parse a YYYYMMdd date in Java
When parsing a YYYYMMdd date, e.g. 20120405 for 5th April 2012, what is the fastest method?

    int year = Integer.parseInt(dateString.substring(0, 4));
    int month = Integer.parseInt(dateString.substring(4, 6));
    int day = Integer.parseInt(dateString.substring(6));

vs.

    int date = Integer.parseInt(dateString)
    int year = date / 1000
    int month = (date mod 1000) / 100 
    int day = date mod 10000

mod 1000 for month would be because mod 1000 results in MMdd and the result / 100 is MM

In the first example we do 3 String operations and 3 "parse to int", in the second example we do many things via modulo.

What is faster? Is there an even faster method?
Fastest way to parse a YYYYMMdd date in Java
===

When parsing a YYYYMMdd date, e.g. 20120405 for 5th April 2012, what is the fastest method?

    int year = Integer.parseInt(dateString.substring(0, 4));
    int month = Integer.parseInt(dateString.substring(4, 6));
    int day = Integer.parseInt(dateString.substring(6));

vs.

    int date = Integer.parseInt(dateString)
    int year = date / 1000
    int month = (date mod 1000) / 100 
    int day = date mod 10000

mod 1000 for month would be because mod 1000 results in MMdd and the result / 100 is MM

In the first example we do 3 String operations and 3 "parse to int", in the second example we do many things via modulo.

What is faster? Is there an even faster method?