From mboxrd@z Thu Jan 1 00:00:00 1970 From: "windy" To: "Jonathan Larmour" Cc: Subject: Re: [ECOS] Help! Date: Sat, 07 Apr 2001 04:46:00 -0000 Message-id: <006a01c0bf58$63d90c50$cd4e66ca@wdy> References: <200104060641.XAA13189@cygnus.com> <3ACDDD24.AEC8EB55@redhat.com> X-SW-Source: 2001-04/msg00063.html > > We have ported ecos to our arm7 system.It seems work well,But division fail always confuses us. > > > > the function which list below is my thread entry,I will create and execute it in cyg_user_start > > > > void our_app1(int argc,char* argv[]) > > { > > float numerator,denominator; > > numerator = 4000; > > denominator = 100; > > numerator /= denominator; ==>every time step over here,gdb will report "bus error",Why? > > } > > Who can tell me why the gdb alway report bus error,and what should I do? > > Where exactly does it fail? If you are using an arm7di (i.e. with no fast > multiplier) are you compiling with -mcpu=arm7di? > > Jifl > -- Today I have traced into __divsf3 . The bus error is reported when executing the instruction like "LDR R2, [R1,#2]". When 'LDR' is used to load data which is not word align ,it will always cause bus error. It seems arm7 on Samsung S3C44 box couldn't execute this type instruction correctly, although the manual book says support. So strange! Windy