# HG changeset patch # User goetz # Date 1433770828 -7200 # Node ID 3e80be30d5eace0583fd9fac2aee09a6079893d4 # Parent 431b1333b1c187c642871849604d1b3427fb3273 8085975: Fix warning "converting to jlong from double" of gcc 4.1.2 after 8079561 diff --git a/src/share/vm/runtime/timer.cpp b/src/share/vm/runtime/timer.cpp --- a/src/share/vm/runtime/timer.cpp +++ b/src/share/vm/runtime/timer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -59,7 +59,7 @@ } jlong elapsedTimer::milliseconds() const { - return TimeHelper::counter_to_millis(_counter); + return (jlong)TimeHelper::counter_to_millis(_counter); } jlong elapsedTimer::active_ticks() const { @@ -89,7 +89,7 @@ jlong TimeStamp::milliseconds() const { assert(is_updated(), "must not be clear"); jlong new_count = os::elapsed_counter(); - return TimeHelper::counter_to_millis(new_count - _counter); + return (jlong)TimeHelper::counter_to_millis(new_count - _counter); } jlong TimeStamp::ticks_since_update() const {