[LLVMbugs] [Bug 11629] New: SingleSource/Benchmarks/BenchmarkGame/puzzle use of rand() + golden file is not libc agnostic

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Dec 20 15:09:58 PST 2011


http://llvm.org/bugs/show_bug.cgi?id=11629

             Bug #: 11629
           Summary: SingleSource/Benchmarks/BenchmarkGame/puzzle use of
                    rand() + golden file is not libc agnostic
           Product: Test Suite
           Version: trunk
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Programs Tests
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: jvoung at google.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


The "puzzle" test uses rand() and rand() is not standardized (only an "example
of an implementation" is given in the manpage). Thus, if a system uses a
different libc (e.g., newlib), then the output will not match the golden file.

If the benchmark is changed to use a fixed "myrand()" and "mysrand()", then the
benchmark will be consistent on different systems. If myrand() is the exact
example given in the manpage, then the golden file would not need to be
changed. Hopefully the performance numbers don't change much either.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list