From 24079dda3a2893640ceeabb6d11eae5d47bb7e2a Mon Sep 17 00:00:00 2001 From: "svenpanne@chromium.org" Date: Wed, 5 Nov 2014 10:41:43 +0000 Subject: [PATCH] Don't use C++11's std::trunc and std::round, use the traditional C functions. R=bmeurer@chromium.org Review URL: https://codereview.chromium.org/703893002 Cr-Commit-Position: refs/heads/master@{#25140} git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@25140 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/arm/simulator-arm.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/arm/simulator-arm.cc b/src/arm/simulator-arm.cc index aeb35c8..972fd07 100644 --- a/src/arm/simulator-arm.cc +++ b/src/arm/simulator-arm.cc @@ -2960,7 +2960,7 @@ void Simulator::DecodeTypeVFP(Instruction* instr) { } else if (((instr->Opc2Value() == 0x6)) && (instr->Opc3Value() == 0x3)) { // vrintz - truncate double dm_value = get_double_from_d_register(vm); - double dd_value = std::trunc(dm_value); + double dd_value = trunc(dm_value); dd_value = canonicalizeNaN(dd_value); set_d_register_from_double(vd, dd_value); } else { @@ -3624,7 +3624,7 @@ void Simulator::DecodeSpecialCondition(Instruction* instr) { int rounding_mode = instr->Bits(17, 16); switch (rounding_mode) { case 0x0: // vrinta - round with ties to away from zero - dd_value = std::round(dm_value); + dd_value = round(dm_value); break; case 0x1: { // vrintn - round with ties to even dd_value = std::floor(dm_value); -- 2.7.4