Bug 171626

Summary: trace of 32bit binary shows wrong syscall parameters
Product: [Fedora] Fedora Reporter: Ulrich Drepper <drepper>
Component: straceAssignee: Roland McGrath <roland>
Status: CLOSED CURRENTRELEASE QA Contact: Brian Brock <bbrock>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: djuran, ldv
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: 4.5.15-1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-01-17 03:05:20 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ulrich Drepper 2005-10-24 15:20:37 UTC
Description of problem:
On an x86-64 system, compile this code as a 32bit binary and run strace on it:

#include <time.h>
#include <stdio.h>
int
main (void)
{
  struct timespec tv;
  clock_getres (CLOCK_THREAD_CPUTIME_ID, &tv);
  printf ("%ld.%09ld s\n", (long) tv.tv_sec, (long) tv.tv_nsec);
  return 0;
}


Version-Release number of selected component (if applicable):


How reproducible:
strace-4.5.13-1.x86_64

Steps to Reproduce:
1.compile above code as 32bit binary
2.run strace
3.
  
Actual results:
clock_getres(0xfffffffe /* CLOCK_??? */, {4294967296, 15082069717662888}) = 0


Expected results:
clock_getres(0xfffffffe /* CLOCK_??? */, {0, 1}) = 0


Additional info:
The handling of the CLOCK_ values is not questioned here.

Comment 1 Dmitry V. Levin 2006-03-30 00:28:17 UTC
There is a discussion on similar issue (#173050).

Comment 2 Dmitry V. Levin 2006-12-13 21:35:38 UTC
Fixed upstream.

Comment 3 Roland McGrath 2007-01-11 11:14:27 UTC
these bugs are fixed upstream in the coming 4.5.15 release

Comment 4 Roland McGrath 2007-01-17 03:05:20 UTC
4.5.15 in rawhide and in updates for fc5 and fc6 fixes this.