Hi Ben et al
I can confirm that I have no segfault with the new version of snl
I tried different combinations and for me sounds ok
I also had the same messages as mentioned below when compiling the code but this time it is on a RH 5.5 64-bits so ok.
/usr/bin/gcc -x c -E -D_POSIX_C_SOURCE=199506L -D_POSIX_THREADS -D_XOPEN_SOURCE=500 -D_X86_64_ -DUNIX -D_BSD_SOURCE -Dlinux -D_REENTRANT -I. -I../O.Common -I. -I.. -I../../../include/os/Linux -I../../../include -I/opt/codac-2.0/epics/base/include/os/Linux -I/opt/codac-2.0/epics/base/include -I/opt/codac-2.0/epics/base/include/os/Linux -I/opt/codac-2.0/epics/base/include ../tooLong.st > tooLong.i
converting tooLong.i
../../../bin/linux-x86_64/snc +m tooLong.i -o tooLong.c.tmp
line 17: cannot assign variable >l< because on this architecture its (base) type is larger than 4 bytes. Such variables cannot be faithfully mapped to any of the Channel Access base types.
Try declaring the variable as 'int' or, if that is still too large on your system, as 'short'.
line 20: cannot assign variable >ul< because on this architecture its (base) type is larger than 4 bytes. Such variables cannot be faithfully mapped to any of the Channel Access base types.
Try declaring the variable as 'int' or, if that is still too large on your system, as 'short'.
mv tooLong.c.tmp tooLong.c
Thanks a lot for your useful help!
Lana
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Benjamin Franksen
Sent: 19 April 2011 00:47
To: [email protected]
Subject: Re: ioc segfault if - c seq flag is not set or +c?
Am Montag, 18. April 2011, um 22:42:12 schrieb Andrew Johnson:
> On Monday 18 April 2011 14:24:12 J. Lewis Muir wrote:
> > FYI, there were a few warnings when building seq 2.0.13-rc1.
(BTW, the other warnings (from the C compiler) are ok.)
> This section of Lewis' output is illuminating:
> >preprocessing ../tooLong.st
> >/opt/vxworks-tornado-2.0.2/host/x86-linux/bin/ccppc -x c -E -DCPU=PPC603
> >
> > -DvxWorks -I. -I../O.Common -I. -I.. -I../../../include/os/vxWorks
> > -I../../../include
> > -I/home/jlmuir/tmp/opt/epics-3.14.11/include/os/vxWorks
> > -I/home/jlmuir/tmp/opt/epics-3.14.11/include
> > -I/opt/vxworks-tornado-2.0.2/target/h ../tooLong.st > tooLong.i
> >
> >converting tooLong.i
> >../../../bin/linux-x86_64/snc tooLong.i -o tooLong.c.tmp
> >line 17: cannot assign variable >l< because on this architecture its
> >(base)
> >
> > type is larger than 4 bytes. Such variables cannot be faithfully mapped
> > to any of the Channel Access base types. Try declaring the variable as
> > 'int' or, if that is still too large on your system, as 'short'.
> >
> >line 20: cannot assign variable >ul< because on this architecture its
> >(base)
> >
> > type is larger than 4 bytes. Such variables cannot be faithfully mapped
> > to any of the Channel Access base types. Try declaring the variable as
> > 'int' or, if that is still too large on your system, as 'short'.
>
> Unfortunately those warnings from snc are wrong, since this is a
> cross-build for the vxWorks-ppc603 architecture where long is 32 bits so
> is legal.
Yes. Sigh.
> Since snc doesn't know what architecture the target will be
> compiled for or what the characteristics of that target are, I think it
> has to defer those size checks to the C compiler when someone uses a long
> variable. It can do that by generating code like this:
>
> #include <limits.h>
> #if LONG_MAX > 2147483647L
> # error Cannot assign ...
> #endif
>
> C doesn't allow the use of sizeof in a #if condition, but using LONG_MAX
> like this works fine.
This should be workable. I'll make another pre-release with this fixed.
Thanks
Ben
________________________________
Helmholtz-Zentrum Berlin für Materialien und Energie GmbH
Mitglied der Hermann von Helmholtz-Gemeinschaft Deutscher Forschungszentren e.V.
Aufsichtsrat: Vorsitzender Prof. Dr. Dr. h.c. mult. Joachim Treusch, stv. Vorsitzende Dr. Beatrix Vierkorn-Rudolph
Geschäftsführer: Prof. Dr. Anke Rita Kaysser-Pyzalla, Prof. Dr. Dr. h.c. Wolfgang Eberhardt, Dr. Ulrich Breuer
Sitz Berlin, AG Charlottenburg, 89 HRB 5583
Postadresse:
Hahn-Meitner-Platz 1
D-14109 Berlin
http://www.helmholtz-berlin.de
- References:
- ioc segfault if - c seq flag is not set or +c? Abadie Lana
- Re: ioc segfault if - c seq flag is not set or +c? J. Lewis Muir
- Re: ioc segfault if - c seq flag is not set or +c? Andrew Johnson
- Re: ioc segfault if - c seq flag is not set or +c? Benjamin Franksen
- Navigate by Date:
- Prev:
RE: Does EPICS Base support multi-thread on vxWorks 6.3? lorna . zhang
- Next:
RE: Does EPICS Base support multi-thread on vxWorks 6.3? Jeff Hill
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
<2011>
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Re: ioc segfault if - c seq flag is not set or +c? Benjamin Franksen
- Next:
Re: ca.py - Throws error - workaround Matt Newville
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
<2011>
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|