DateToStr in arm does not work!

classic Classic list List threaded Threaded
38 messages Options
12
Reply | Threaded
Open this post in threaded view
|

DateToStr in arm does not work!

josepascual (almudi)
Hi Everyone;

Please, can someone test this program and write to the list if it works in
arm-linux.

program datetostr_test;

uses sysutils;

begin

writeln(datetostr(now));

end.

I always receive

An unhandled exception occurred at $BEED89C8 :
EAccessViolation : Access violation
  $BEED89C8


if for someone this program work, please write me with your Fpc for arm
version.

thank you in advanced

best regards

Jose Pascual

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Henry Vermaak
On 03/07/07, josepascual <[hidden email]> wrote:

> Hi Everyone;
>
> Please, can someone test this program and write to the list if it works in
> arm-linux.
>
> program datetostr_test;
>
> uses sysutils;
>
> begin
>
> writeln(datetostr(now));
>
> end.

works for me, using svn 7929, compiled for arm little endian with soft float.

>
> I always receive
>
> An unhandled exception occurred at $BEED89C8 :
> EAccessViolation : Access violation
>   $BEED89C8
>
>
> if for someone this program work, please write me with your Fpc for arm
> version.
>
> thank you in advanced
>
> best regards
>
> Jose Pascual
>

henry
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

RE: DateToStr in arm does not work!

josepascual (almudi)
Thank you henry,

I have downloaded svn version 7943 how can I donwload svn 7929?

How are you build fpc for arm? make clean crossall CPU_TARGET=arm
OS_TARGET=linux ....?
Which version of binutils do you have? (eabi?)
Is SOFTFLOAT in freepascal the equivalent to EABI in c?

thank you!
Jose Pascual



> -----Mensaje original-----
> De: [hidden email] [mailto:fpc-pascal-
> [hidden email]] En nombre de Henry Vermaak
> Enviado el: martes, 03 de julio de 2007 18:15
> Para: FPC-Pascal users discussions
> Asunto: Re: [fpc-pascal] DateToStr in arm does not work!
>
> On 03/07/07, josepascual <[hidden email]> wrote:
> > Hi Everyone;
> >
> > Please, can someone test this program and write to the list if it
> works in
> > arm-linux.
> >
> > program datetostr_test;
> >
> > uses sysutils;
> >
> > begin
> >
> > writeln(datetostr(now));
> >
> > end.
>
> works for me, using svn 7929, compiled for arm little endian with soft
> float.
>
> >
> > I always receive
> >
> > An unhandled exception occurred at $BEED89C8 :
> > EAccessViolation : Access violation
> >   $BEED89C8
> >
> >
> > if for someone this program work, please write me with your Fpc for
> arm
> > version.
> >
> > thank you in advanced
> >
> > best regards
> >
> > Jose Pascual
> >
>
> henry
> _______________________________________________
> fpc-pascal maillist  -  [hidden email]
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
>
> __________ InformaciĆ³n de NOD32, revisiĆ³n 2374 (20070703) __________
>
> Este mensaje ha sido analizado con NOD32 antivirus system
> http://www.nod32.com


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Felipe Monteiro de Carvalho
On 7/3/07, josepascual <[hidden email]> wrote:
> I have downloaded svn version 7943 how can I donwload svn 7929?

svn update -r 7929

--
Felipe Monteiro de Carvalho
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Luca Olivetti-2
In reply to this post by josepascual (almudi)
En/na josepascual ha escrit:

> I always receive
>
> An unhandled exception occurred at $BEED89C8 :
> EAccessViolation : Access violation
>   $BEED89C8

same here (only at a different address), though I have many funky errors
under arm that nobody else has.
Using self-built native fpc-2.1.4

luca@lspro:~$ uname -a
Linux lspro 2.6.12.6-arm1 #77 Tue Dec 5 22:23:46 CST 2006 armv5tejl
GNU/Linux
luca@lspro:~$ cat /proc/cpuinfo
Processor       : ARM926EJ-Sid(wb) rev 0 (v5l)
BogoMIPS        : 266.24
Features        : swp half thumb fastmult edsp java
CPU implementer : 0x41
CPU architecture: 5TEJ
CPU variant     : 0x0
CPU part        : 0x926
CPU revision    : 0
Cache type      : write-back
Cache clean     : cp15 c7 ops
Cache lockdown  : format C
Cache format    : Harvard
I size          : 32768
I assoc         : 1
I line length   : 32
I sets          : 1024
D size          : 32768
D assoc         : 1
D line length   : 32
D sets          : 1024

Hardware        : MV-88fxx81
Revision        : 0000
Serial          : 0000000000000000

Bye
--
Luca
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Henry Vermaak
In reply to this post by josepascual (almudi)
On 03/07/07, josepascual <[hidden email]> wrote:
> Thank you henry,
>
> I have downloaded svn version 7943 how can I donwload svn 7929?
>
> How are you build fpc for arm? make clean crossall CPU_TARGET=arm
> OS_TARGET=linux ....?
> Which version of binutils do you have? (eabi?)
> Is SOFTFLOAT in freepascal the equivalent to EABI in c?
>

soft float just means that the compiler needs to emulate the floating
point unit if it doesn't exist in your hardware (like some arm
processors).  if you have an fpu, then you don't have to worry about
soft float.  the following assumes that you need soft float in you
compiler.

passing OPT='-CfSOFT' doesn't work anymore, so you have to edit your
Makefile.fpc and look for the line BUILDOPTS=...  add your extra
options there (i usually add OPT='-gl -CfSOFT').  then you will have
to go fpcmake -rTall.

then you can do make clean crossall with the usual suspects passed to
it, like CPU_TARGET, OS_TARGET, BINUTILSPREFIX, etc).

use the binutils that came with your device, or use something that
someone else used successfully.

make crossinstall still fails towards the end, but that's o.k.  your
cross compiler will be there and ready to use.

sorry if i'm making any mistakes here, it's off the top of my head.  i
haven't got my build machine here...

> thank you!
> Jose Pascual

henry
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Luca Olivetti-2
En/na Henry Vermaak ha escrit:

>
> soft float just means that the compiler needs to emulate the floating
> point unit if it doesn't exist in your hardware (like some arm
> processors).  if you have an fpu, then you don't have to worry about
> soft float.  the following assumes that you need soft float in you
> compiler.

If this program compiles and works fine:
program floattest;

uses sysutils;
var a,b:double;

begin
a:=0.5;
b:=0.3;
writeln(format('%5.3f',[a*b]));

end.



can I assume that either my compiler has been built with the right
options or I have a working fpu?
I'm asking because jose original test program fails here, while the
above program correctly prints out 0.150

Bye
--
Luca
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Henry Vermaak
On 03/07/07, Luca Olivetti <[hidden email]> wrote:

>
> If this program compiles and works fine:
> program floattest;
>
> uses sysutils;
> var a,b:double;
>
> begin
> a:=0.5;
> b:=0.3;
> writeln(format('%5.3f',[a*b]));
>
> end.
>
>
>
> can I assume that either my compiler has been built with the right
> options or I have a working fpu?

yes.

> I'm asking because jose original test program fails here, while the
> above program correctly prints out 0.150

does the above work if you set a or be to a negative number?  my
softfloat crashes with writeln(negative number).

maybe you should try fpc 2.3.1, since that's the one i'm using and my
datetostr is working...

>
> Bye
> --
> Luca

cheers
henry
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Bernd Mueller-3
In reply to this post by Henry Vermaak
Henry Vermaak wrote:

> On 03/07/07, josepascual <[hidden email]> wrote:
>> Thank you henry,
>>
>> I have downloaded svn version 7943 how can I donwload svn 7929?
>>
>> How are you build fpc for arm? make clean crossall CPU_TARGET=arm
>> OS_TARGET=linux ....?
>> Which version of binutils do you have? (eabi?)
>> Is SOFTFLOAT in freepascal the equivalent to EABI in c?
>>
>
> soft float just means that the compiler needs to emulate the floating
> point unit if it doesn't exist in your hardware (like some arm
> processors).  if you have an fpu, then you don't have to worry about
> soft float.  
Are you sure? If I remember right, using softfloat in conjunction with
fpc means, that the compiler never emits floating point operations. All
the floating point is going through the softfpu unit. This means, *if*
you have a fpu, you waste speed.

Regards, Bernd.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Luca Olivetti-2
In reply to this post by Henry Vermaak
En/na Henry Vermaak ha escrit:

>> I'm asking because jose original test program fails here, while the
>> above program correctly prints out 0.150
>
> does the above work if you set a or be to a negative number?  my
> softfloat crashes with writeln(negative number).

Yes

>
> maybe you should try fpc 2.3.1, since that's the one i'm using and my
> datetostr is working...

Maybe I'll try (I supposed it can be compiled natively), but then,
what's the purpose of a "stable" and "beta" fpc release if we have to
leapfrog to the next devel version? (or I'm just confused by the release
numbering and 2.3.1 is not the next devel version?).

Bye
--
Luca

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Henry Vermaak
In reply to this post by Bernd Mueller-3
On 03/07/07, Bernd Mueller <[hidden email]> wrote:
> Are you sure? If I remember right, using softfloat in conjunction with
> fpc means, that the compiler never emits floating point operations. All
> the floating point is going through the softfpu unit. This means, *if*
> you have a fpu, you waste speed.
>

that's right.  i've got two arm devices without fpus, though...

> Regards, Bernd.

henry
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Marc Santhoff
In reply to this post by Bernd Mueller-3
Am Dienstag, den 03.07.2007, 21:49 +0200 schrieb Bernd Mueller:

> Henry Vermaak wrote:
> > On 03/07/07, josepascual <[hidden email]> wrote:
> >> Thank you henry,
> >>
> >> I have downloaded svn version 7943 how can I donwload svn 7929?
> >>
> >> How are you build fpc for arm? make clean crossall CPU_TARGET=arm
> >> OS_TARGET=linux ....?
> >> Which version of binutils do you have? (eabi?)
> >> Is SOFTFLOAT in freepascal the equivalent to EABI in c?
> >>
> >
> > soft float just means that the compiler needs to emulate the floating
> > point unit if it doesn't exist in your hardware (like some arm
> > processors).  if you have an fpu, then you don't have to worry about
> > soft float.  
> Are you sure? If I remember right, using softfloat in conjunction with
> fpc means, that the compiler never emits floating point operations. All
> the floating point is going through the softfpu unit. This means, *if*
> you have a fpu, you waste speed.

The ARM926EJ-S core does not have a FPU but an interface for
coprocessors. So if there is floating point hardware built in depends on
the chip manufacturer.

Not having FPU hardware is currently the most possible case for ARM7 and
ARM9, the only chip I know of having a VFP9 FPU is the LPC3180 from
Phillips. This may change, at least Fujitsu has some designs in the
pipeline for 3rd or 4th quarter of this year IIRC.

Marc


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Bernd Mueller-3
In reply to this post by josepascual (almudi)
josepascual wrote:

> Hi Everyone;
>
> Please, can someone test this program and write to the list if it works in
> arm-linux.
>
> program datetostr_test;
>
> uses sysutils;
>
> begin
>
> writeln(datetostr(now));
>
> end.
>
> I always receive
>
> An unhandled exception occurred at $BEED89C8 :
> EAccessViolation : Access violation
>   $BEED89C8
>
>
> if for someone this program work, please write me with your Fpc for arm
> version.
the program works for me.

FPC 2.1.4 compiler built without softfloat option, running on an (little
endian) ARM processor without fpu on Linux,  kernel version 2.6.21.1 (OABI).

ppcrossarm -gl datetostr_test.pas

Regards, Bernd.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Luca Olivetti-2
En/na Bernd Mueller ha escrit:

>
> FPC 2.1.4 compiler built without softfloat option, running on an (little
> endian) ARM processor without fpu on Linux,  kernel version 2.6.21.1
> (OABI).
>
> ppcrossarm -gl datetostr_test.pas

could you check bug 9191?

http://www.freepascal.org/mantis/view.php?id=9191

Bye.
--
Luca

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Bernd Mueller-3
Luca,


<color><param>7F00,0000,0000</param>> could you check bug 9191?

>

> http://www.freepascal.org/mantis/view.php?id=9191


</color>if I try to compile, the  linker complaints about not finding the object
dl, though dl.o and dl.ppu are present in the rtl/units/arm-linux
directory.


D:\FPC214\B1\BINUTI~3\arm-linux-ld.exe: cannot find -ldl
pippo.pas(47,6) Error: Error while linking

pippo.pas(47,6) Fatal: There were 1 errors compiling module,
stopping

Fatal: Compilation aborted


How do you call the compiler? And please show me your fpc.cfg
file.


Regards, Bernd.<FontFamily><param>Courier New</param>


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Luca Olivetti-2
En/na [hidden email] ha escrit:

> Luca,
>
>  > could you check bug 9191?
>  >
>  > http://www.freepascal.org/mantis/view.php?id=9191
>
> if I try to compile, the linker complaints about not finding the object
> dl, though dl.o and dl.ppu are present in the rtl/units/arm-linux
> directory.
>
> D:\FPC214\B1\BINUTI~3\arm-linux-ld.exe: cannot find -ldl pippo.pas(47,6)
> Error: Error while linking
> pippo.pas(47,6) Fatal: There were 1 errors compiling module, stopping
> Fatal: Compilation aborted
>
> How do you call the compiler? And please show me your fpc.cfg file.
I do simply an "fpc pippo.pas" (or "fpc pippo2.pas"), I'm running it
directly on the arm, I'm not cross-compiling (that's why I asked you, I
wanted to see if cross-compiling makes a difference). My fpc.cfg is what
the installer for 2.1.3 generated, manually amended for 2.1.4 (consider
that fpc is installed under /home/luca/fpc-2.1.4). It's attached.

Bye
--
Luca


#
# Example fpc.cfg for Free Pascal Compiler
#

# ----------------------
# Defines (preprocessor)
# ----------------------

#
# nested #IFNDEF, #IFDEF, #ENDIF, #ELSE, #DEFINE, #UNDEF are allowed
#
# -d is the same as #DEFINE
# -u is the same as #UNDEF
#

#
# Some examples (for switches see below, and the -? helppages)
#
# Try compiling with the -dRELEASE or -dDEBUG on the commandline
#

# For a release compile with optimizes and strip debuginfo
#IFDEF RELEASE
  -O2
  -Xs
  #WRITE Compiling Release Version
#ENDIF

# For a debug version compile with debuginfo and all codegeneration checks on
#IFDEF DEBUG
  -g
  -Crtoi
  #WRITE Compiling Debug Version
#ENDIF

# set binutils prefix
#DEFINE NEEDCROSSBINUTILS


#IFDEF FPC_CROSSCOMPILING
#IFDEF NEEDCROSSBINUTILS
  -XP$fpctarget-
#ENDIF NEEDCROSSBINUTILS
#ENDIF

# ----------------
# Parsing switches
# ----------------

# Pascal language mode
#      -Mfpc      free pascal dialect (default)
#      -Mobjfpc   switch some Delphi 2 extensions on
#      -Mdelphi   tries to be Delphi compatible
#      -Mtp       tries to be TP/BP 7.0 compatible
#      -Mgpc      tries to be gpc compatible
#      -Mmacpas   tries to be compatible to the macintosh pascal dialects
#
# Turn on Object Pascal extensions by default
#-Mobjfpc

# Assembler reader mode
#      -Rdefault  use default assembler
#      -Ratt      read AT&T style assembler
#      -Rintel    read Intel style assembler
#
# All assembler blocks are AT&T styled by default
#-Ratt

# Semantic checking
#      -S2        same as -Mobjfpc
#      -Sc        supports operators like C (*=,+=,/= and -=)
#      -Sa        include assertion code.
#      -Sd        same as -Mdelphi
#      -Se<x>     error options. <x> is a combination of the following:
#         <n> : compiler stops after the <n> errors (default is 1)
#         w : compiler stops also after warnings
#         n : compiler stops also after notes
#         h : compiler stops also after hints
#      -Sg        allow LABEL and GOTO
#      -Sh        Use ansistrings
#      -Si        support C++ styled INLINE
#      -Sk        load fpcylix unit
#      -SI<x>     set interface style to <x>
#         -SIcom     COM compatible interface (default)
#         -SIcorba   CORBA compatible interface
#      -Sm        support macros like C (global)
#      -So        same as -Mtp
#      -Sp        same as -Mgpc
#      -Ss        constructor name must be init (destructor must be done)
#      -St        allow static keyword in objects
#      -Sx        enable exception keywords (default in Delphi/ObjFPC modes)
#
# Allow goto, inline, C-operators, C-vars
-Sgic

# ---------------
# Code generation
# ---------------

# Uncomment the next line if you always want static/dynamic units by default
# (can be overruled with -CD, -CS at the commandline)
#-CS
#-CD

# Set the default heapsize to 8Mb
#-Ch8000000

# Set default codegeneration checks (iocheck, overflow, range, stack)
#-Ci
#-Co
#-Cr
#-Ct

# Optimizer switches
# -Os        generate smaller code
# -O1        level 1 optimizations (quick optimizations, debuggable)
# -O2        level 2 optimizations (-O1 + optimizations which make debugging more difficult)
# -O3        level 3 optimizations (-O2 + optimizations which also may make the program slower rather than faster)
# -Op<x>     set target cpu for optimizing, see fpc -i for possible values
#
# See "fpc -i" also for more fine-grained control over which optimizations
# to perform

# -----------------------
# Set Filenames and Paths
# -----------------------

# Slashes are also allowed under dos

# path to the messagefile, not necessary anymore but can be used to override
# the default language
#-Fr/home/luca/fpc-2.1.4/lib/$fpcversion/msg/errore.msg
#-Fr/home/luca/fpc-2.1.4/lib/$fpcversion/msg/errorn.msg

# searchpath for includefiles
#-Fi/pp/inc;/pp/rtl/inc

# searchpath for units and other system dependent things
-Fu/home/luca/fpc-2.1.4/lib/fpc/$fpcversion/units/$fpctarget
-Fu/home/luca/fpc-2.1.4/lib/fpc/$fpcversion/units/$fpctarget/*
-Fu/home/luca/fpc-2.1.4/lib/fpc/$fpcversion/units/$fpctarget/rtl
#-Fu~/fpc/packages/base/*/units/;~/fpc/fcl/units/;~/fpc/rtl/units/

# searchpath for libraries
-Fl/usr/lib/gcc/arm-linux-gnu/4.1.2



#-Fl/pp/lib
#-Fl/lib;/usr/lib


# -------------
# Linking
# -------------

# generate always debugging information for GDB (slows down the compiling
# process)
#      -gc        generate checks for pointers
#      -gd        use dbx
#      -gg        use gsym
#      -gh        use heap trace unit (for memory leak debugging)
#      -gl        use line info unit to show more info for backtraces
#      -gv        generates programs tracable with valgrind
#      -gw        generate dwarf debugging info
#
# Enable debuginfo and use the line info unit by default
#-gl

# always pass an option to the linker
#-k-s

# Always strip debuginfo from the executable
-Xs


# -------------
# Miscellaneous
# -------------

# Write always a nice FPC logo ;)
-l

# Verbosity
#      e : Show errors (default)       d : Show debug info
#      w : Show warnings               u : Show unit info
#      n : Show notes                  t : Show tried/used files
#      h : Show hints                  c : Show conditionals
#      i : Show general info           d : Show debug info
#      l : Show linenumbers            r : Rhide/GCC compatibility mode
#      a : Show everything             x : Executable info (Win32 only)
#      b : Write file names messages with full path
#      v : write fpcdebug.txt with     p : Write tree.log with parse tree
#          lots of debugging info
#
# Display Info, Warnings and Notes
-viwn
# If you don't want so much verbosity use
#-vw

#
# That's all folks
#

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Jonas Maebe-2
In reply to this post by Bernd Mueller-3

On 03 Jul 2007, at 23:45, [hidden email] wrote:

> Luca,
>
> > could you check bug 9191?
> >
> > http://www.freepascal.org/mantis/view.php?id=9191
>
> if I try to compile, the  linker complaints about not finding the  
> object  dl, though dl.o and dl.ppu are present in the rtl/units/arm-
> linux  directory.
>
> D:\FPC214\B1\BINUTI~3\arm-linux-ld.exe: cannot find -ldl  pippo.pas
> (47,6) Error: Error while linking
> pippo.pas(47,6) Fatal: There were 1 errors compiling module,  stopping
> Fatal: Compilation aborted

The -ldl refers to libdl.so, not to dl.o. You have to copy it from  
your ARM system to your Windows machine, and add the directory with  
all your ARM libraries to the linker's search path, like Luca did:
-Fl/usr/lib/gcc/arm-linux-gnu/4.1.2

(or wherever the libraries are located on your system)


Jonas
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

RE: DateToStr in arm does not work!

josepascual (almudi)
In reply to this post by Luca Olivetti-2
> >
> > soft float just means that the compiler needs to emulate the floating
> > point unit if it doesn't exist in your hardware (like some arm
> > processors).  if you have an fpu, then you don't have to worry about
> > soft float.  the following assumes that you need soft float in you
> > compiler.
>
> If this program compiles and works fine:
> program floattest;
>
> uses sysutils;
> var a,b:double;
>
> begin
> a:=0.5;
> b:=0.3;
> writeln(format('%5.3f',[a*b]));
>
> end.
>
>
>
> can I assume that either my compiler has been built with the right
> options or I have a working fpu?
> I'm asking because jose original test program fails here, while the
> above program correctly prints out 0.150

I have a ARM920T (without fpu, kernel OABI)

I have (always in linux) a fpcrossarm compiler version 2.1.4 and one 2.3.1
(I don't know release).

I can compile with 2.1.4 with and without softfloat but 2.3.1 only without
softfloat.

I have compiled floattest with :

a) ppcrossarm 2.1.4 without CfSOFT --> result 0.150
b) ppcrossarm 2.1.4 with CfSOFT --> result 0.000
c) ppcrossarm 2.3.1 without CfSOFT --> result 0.150

but I can run datetostr_test without error.





_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

RE: DateToStr in arm does not work!

josepascual (almudi)
In reply to this post by Henry Vermaak
> > I have downloaded svn version 7943 how can I donwload svn 7929?
> >
> > How are you build fpc for arm? make clean crossall CPU_TARGET=arm
> > OS_TARGET=linux ....?
> > Which version of binutils do you have? (eabi?)
> > Is SOFTFLOAT in freepascal the equivalent to EABI in c?
> >
>
> soft float just means that the compiler needs to emulate the floating
> point unit if it doesn't exist in your hardware (like some arm
> processors).  if you have an fpu, then you don't have to worry about
> soft float.  the following assumes that you need soft float in you
> compiler.
>
> passing OPT='-CfSOFT' doesn't work anymore, so you have to edit your
> Makefile.fpc and look for the line BUILDOPTS=...  add your extra
> options there (i usually add OPT='-gl -CfSOFT').  then you will have
> to go fpcmake -rTall.
>
> then you can do make clean crossall with the usual suspects passed to
> it, like CPU_TARGET, OS_TARGET, BINUTILSPREFIX, etc).
>
> use the binutils that came with your device, or use something that
> someone else used successfully.
>
> make crossinstall still fails towards the end, but that's o.k.  your
> cross compiler will be there and ready to use.
>
> sorry if i'm making any mistakes here, it's off the top of my head.  i
> haven't got my build machine here...
>

Hi henry et all,

I have a little confused, Could you or someone help me with some question?

I have a ARM920T (without fpu, kernel OABI) .
Which version of gcc are you using 3.4.1? 4.1.2?
Which libc version? (2.3.2 2.3.6)
Is your gcc for EABI?
Have you used same crosstools to generate fpc 2.3.1 libraries and to
compiling your final freepascal programs?
Can I Use a FPC for ARM (cross or not) with softfloat option for arm kernel
EABI and not EABI (OABI)?
What Freepascal only use from ARM binutils? (as, ld, ar, ranlib, ... Whats
()? (gcc is not necesary,  is it?)



_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: DateToStr in arm does not work!

Henry Vermaak
On 04/07/07, josepascual <[hidden email]> wrote:
>
> Hi henry et all,
>
> I have a little confused, Could you or someone help me with some question?
>
> I have a ARM920T (without fpu, kernel OABI) .
> Which version of gcc are you using 3.4.1? 4.1.2?

4.1.1 (this is the first gcc that supports eabi).

> Which libc version? (2.3.2 2.3.6)

2.3.90.

> Is your gcc for EABI?

yes.

> Have you used same crosstools to generate fpc 2.3.1 libraries and to
> compiling your final freepascal programs?

yes.

> Can I Use a FPC for ARM (cross or not) with softfloat option for arm kernel
> EABI and not EABI (OABI)?

i dunno.  only kernel 2.6.16 onwards support eabi, afaik, and the two
aren't compatible, although you might be able to make it work if you
know which settings to change in i_linux.pas, but i think it's not
that simple.

i know that ld have complained about linking my fpc programs with
libraries, but i suspect that's an interworking-related thing.
luckily ld does have some options to control this.

any fpc developer care to comment?

> What Freepascal only use from ARM binutils? (as, ld, ar, ranlib, ... Whats
> ()? (gcc is not necesary,  is it?)

only as and ld, i think?

i urge you to read this:

http://wiki.debian.org/ArmEabiPort
http://www.codesourcery.com/gnu_toolchains/arm/faq.html

i haven't completely read it (hence i can't answer your questions that
well, sorry).

henry
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
12