Date: Fri, 28 Jan 2005 11:08:39 -0500 (EST) From: Rob Watt <rob@hudson-trading.com> To: Joseph Koshy <joseph.koshy@gmail.com> Cc: freebsd-amd64@freebsd.org Subject: Re: 32-bit binary compatibility on 5.3-amd64 Message-ID: <20050128105930.V54223@daemon.mistermishap.net> In-Reply-To: <84dead72050127201552e14c04@mail.gmail.com> References: <20050127100818.M46092@daemon.mistermishap.net> <84dead72050127201552e14c04@mail.gmail.com>
index | next in thread | previous in thread | raw e-mail
[-- Attachment #1 --]
On Fri, 28 Jan 2005, Joseph Koshy wrote:
> > I've run the /usr/src/tools/lib32/build32.sh script, and applied some
> > other changes that people have reccomended, but basically our 32-bit
> > applications all segfault when run on the amd64 machines.
>
> Exactly what is the segfault? Could you post the output of ktrace on an example
> process?
>
a ktrace is attached for this sample code:
#include <stdio.h>
int main(int argc, char *argv[])
{
printf("char* %d\n", sizeof(char*));
printf("int* %d\n", sizeof(int*));
printf("void* %d\n", sizeof(void*));
printf("long %d\n", sizeof(long));
printf("double %d\n", sizeof(double));
printf("int %d\n", sizeof(int));
return 0;
}
this was compiled on a 5.3 i386 machine with: g++ -g
-
Rob Watt
[-- Attachment #2 --]
: ktrace o`A { - : ktrace o`A &| . ; 7 : ktrace o`A /| ./test-i386-53-native : ktrace o`A v 6g /libexec/ld-elf32.so.1 4: test-i386-53-native o`A ; H 4: test-i386-53-native o`A @Q 0 : test-i386-53-native o`A ( : test-i386-53-native o`A *: I ( 0 4: test-i386-53-native o`A I 8 4: test-i386-53-native o`A [6
l( : test-i386-53-native o`A - H 4: test-i386-53-native o`A 3 @T6
: test-i386-53-native o`A < ( : test-i386-53-native o`A U 4: test-i386-53-native o`A Z 4: test-i386-53-native o`A } @6g ( : test-i386-53-native o`A 6g /etc/libmap32.conf : test-i386-53-native o`A 4: test-i386-53-native o`A b #( : test-i386-53-native o`A 6g /var/run/ld-elf32.so.hints : test-i386-53-native o`A : test-i386-53-native o`A 0 ! @( : test-i386-53-native o`A 6g /lib32/libstdc++.so.4 4: test-i386-53-native o`A ɀ ! : test-i386-53-native o`A Ѐ 0 ! @( : test-i386-53-native o`A ` /usr/lib32/libstdc++.so.4 : test-i386-53-native o`A ! : test-i386-53-native o`A f @( , : test-i386-53-native o`A @6g /usr/lib32/libstdc++.so.4 $: test-i386-53-native o`A
: test-i386-53-native o`A
!: : test-i386-53-native o`A 4: test-i386-53-native o`A @ ( : test-i386-53-native o`A F D ELF pW 4 n
4 ( XM
XM
XM
^
r =
8
r
l
o : H 8 { _
J
_
P
#
$ W
.
(
C
j
A 7 Y
^ W
X
E / Q
A
k B ! R
g
& o
5 $
d q _ e M i
D m g ~ &
m A 3
"
"
e }
C o
g ?
0 o S \ Y F (
b . * >
s
a = ` q W /
m
0 P
t $
*
N e
? D S K
8 n
)
N
^
n s
Z
" L 1 2 Z L
, z l
x =
f
Z i
p < d b
U f
=
L ]
; ;
&
/
k
) P '
|
`
*
{ ~
u z
n N %
C
a \ w
'
;
1
D
z ) U
|
6 f r T
l ,
a g N g
9 k B 5 ?
2 ` S % `
^
Y t
k
h y
Y +
e M (
Z | U
w C j } 4
\ ; V I
8 @ [
i
Q =
8 ( 3 5 {
t
U
E
s
v a
r i W m
g I
| q
F j
1
4
R
I
| 5 ) b
q <
/
\ Y / u [
2
; ! %
` F ,
| z G # ] d " /
P x G
@ > 1
6
|
x L S i
2
@
|
% +
F
?
N
- 8 9
@
K _ O \ D A O
K ) & [
L C > -
O \ M
$ 1
< 8 t
l
5
: test-i386-53-native o`A G H : test-i386-53-native o`A M #
: test-i386-53-native o`A V ( $: test-i386-53-native o`A Y @6g J P( : test-i386-53-native o`A ^ J : test-i386-53-native o`A y 6g J P( : test-i386-53-native o`A } J H : test-i386-53-native o`A V `( 4: test-i386-53-native o`A `( H $: test-i386-53-native o`A V ( ` : test-i386-53-native o`A ( : test-i386-53-native o`A Ɂ C : test-i386-53-native o`A $: test-i386-53-native o`A @0 ! @( : test-i386-53-native o`A p': /lib32/libm.so.3 : test-i386-53-native o`A ! : test-i386-53-native o`A =N ! @( $: test-i386-53-native o`A
/usr/lib32/libm.so.3 4: test-i386-53-native o`A ! : test-i386-53-native o`A k `( , : test-i386-53-native o`A & /usr/lib32/libm.so.3 : test-i386-53-native o`A . : test-i386-53-native o`A 1 0$: : test-i386-53-native o`A 5 : test-i386-53-native o`A 8 ( 4: test-i386-53-native o`A C _ ELF p( 4 4 ( W W ` ` ` = = P P P o Q w n 6 M j [ C v &