Project

General

Profile

Actions

Bug #6592

closed

test_call_double(DL::TestDL) fails on ARM HardFP

Added by vo.x (Vit Ondruch) almost 12 years ago. Updated over 9 years ago.

Status:
Closed
Target version:
ruby -v:
ruby 2.0.0dev (2012-06-05 trunk 35922) [armv7hl-linux]
Backport:
[ruby-core:45647]

Description

Hi,

I am observing following test suite error on armv7hl Fedora 17 [1] (but it seems that Debian suffers the same issues [3]):

  1. Failure:
    test_call_double(DL::TestDL) [/builddir/build/BUILD/ruby-2.0.0-r35922/test/dl/test_dl2.rb:90]:
    Expected |0.1 - 2.1638932342073e-311| (0.1) to be < 0.001.

I was digging a bit deeper and I identified issue in this part of code [2]. I tried a bit to unfold the macros and found, that the issue is because of variadic arguments. If the function prototype is declared without them (novar.disasm), the test passes, if they are in use (variadic.disasm), the test fails. The attached files shows the code with partially unfolded marcos and their disassembly. The atof.disasm contains the disassembly of the atof call if it might be of help.

I am not sure if it might be compiler bug (GCC 4.7) or if it should be fixed in Ruby. Any help appreciated

[1] http://arm.koji.fedoraproject.org/koji/getfile?taskID=904523&name=build.log
[2] https://github.com/ruby/ruby/blob/v1_9_3_195/ext/dl/cfunc.c#L464
[3] https://buildd.debian.org/status/fetch.php?pkg=ruby1.9.1&arch=armhf&ver=1.9.3.194-1&stamp=1338887114


Files

novar.disasm (659 Bytes) novar.disasm atof called without variadic arguments vo.x (Vit Ondruch), 06/14/2012 05:12 PM
variadic.disasm (699 Bytes) variadic.disasm atof called with variadic arguments vo.x (Vit Ondruch), 06/14/2012 05:12 PM
atof.disasm (695 Bytes) atof.disasm atof disassembly vo.x (Vit Ondruch), 06/14/2012 05:12 PM
noname (500 Bytes) noname Anonymous, 06/21/2012 01:53 AM
noname (500 Bytes) noname Anonymous, 06/22/2012 02:23 AM

Related issues 1 (0 open1 closed)

Blocked by Ruby master - Feature #5458: DL should be removed Closedtenderlovemaking (Aaron Patterson)10/18/2011Actions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0