tcljava-user Mailing List for Tcl/Java (Page 10)
Brought to you by:
mdejong
You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
(23) |
Dec
(9) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(12) |
Feb
(10) |
Mar
(16) |
Apr
(10) |
May
(40) |
Jun
(13) |
Jul
(18) |
Aug
(4) |
Sep
(6) |
Oct
(3) |
Nov
|
Dec
(3) |
2002 |
Jan
(15) |
Feb
(19) |
Mar
(1) |
Apr
(11) |
May
(12) |
Jun
(10) |
Jul
(2) |
Aug
(22) |
Sep
|
Oct
(3) |
Nov
(9) |
Dec
(20) |
2003 |
Jan
(32) |
Feb
(5) |
Mar
(26) |
Apr
(30) |
May
(10) |
Jun
(8) |
Jul
(17) |
Aug
(7) |
Sep
(24) |
Oct
(7) |
Nov
(6) |
Dec
|
2004 |
Jan
(5) |
Feb
|
Mar
|
Apr
(7) |
May
(8) |
Jun
(12) |
Jul
(3) |
Aug
(11) |
Sep
(8) |
Oct
(4) |
Nov
(2) |
Dec
(6) |
2005 |
Jan
(8) |
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
(19) |
Jul
(8) |
Aug
(22) |
Sep
(12) |
Oct
(35) |
Nov
(12) |
Dec
(4) |
2006 |
Jan
(20) |
Feb
(14) |
Mar
(23) |
Apr
(10) |
May
(11) |
Jun
(1) |
Jul
(1) |
Aug
(1) |
Sep
|
Oct
(4) |
Nov
(17) |
Dec
(10) |
2007 |
Jan
(41) |
Feb
(6) |
Mar
(23) |
Apr
(15) |
May
(34) |
Jun
(5) |
Jul
(18) |
Aug
(13) |
Sep
(8) |
Oct
(9) |
Nov
(7) |
Dec
(2) |
2008 |
Jan
|
Feb
(1) |
Mar
(18) |
Apr
(1) |
May
(1) |
Jun
(10) |
Jul
(3) |
Aug
|
Sep
(10) |
Oct
(3) |
Nov
(13) |
Dec
(3) |
2009 |
Jan
(4) |
Feb
(10) |
Mar
(1) |
Apr
(11) |
May
(3) |
Jun
(7) |
Jul
(4) |
Aug
(9) |
Sep
(16) |
Oct
(3) |
Nov
(5) |
Dec
(2) |
2010 |
Jan
(3) |
Feb
|
Mar
|
Apr
(7) |
May
(1) |
Jun
|
Jul
|
Aug
(3) |
Sep
(3) |
Oct
(1) |
Nov
(1) |
Dec
|
2011 |
Jan
(3) |
Feb
|
Mar
(2) |
Apr
(17) |
May
(4) |
Jun
(17) |
Jul
(5) |
Aug
(7) |
Sep
|
Oct
|
Nov
|
Dec
|
2012 |
Jan
|
Feb
(12) |
Mar
|
Apr
(1) |
May
(1) |
Jun
(1) |
Jul
|
Aug
(3) |
Sep
(2) |
Oct
(6) |
Nov
|
Dec
(2) |
2013 |
Jan
|
Feb
(1) |
Mar
|
Apr
(1) |
May
(8) |
Jun
(1) |
Jul
|
Aug
(3) |
Sep
|
Oct
(3) |
Nov
|
Dec
|
2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
(1) |
Nov
|
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
(1) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2016 |
Jan
|
Feb
|
Mar
(2) |
Apr
(2) |
May
(1) |
Jun
(3) |
Jul
(3) |
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
2017 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
(1) |
Jul
|
Aug
(1) |
Sep
|
Oct
(1) |
Nov
|
Dec
|
2018 |
Jan
|
Feb
(1) |
Mar
|
Apr
(1) |
May
|
Jun
(1) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
(1) |
Jul
|
Aug
(1) |
Sep
(2) |
Oct
|
Nov
|
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
2021 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
From: Mo D. <mo...@mo...> - 2008-12-13 23:13:46
|
Saket Jha wrote: > Hi, > > To give a brief background, I am planning to build an application > based on WSDL-Java technology. I require to blend this with Tcl as all > my automation scripts are in Tcl. > > Basically, I have a simple requirement: > > I want to be able to use TclBlend from ActiveState Tcl on Windows. > Saket, I don't think it is such a good idea, but you should be able to make it work if you are really brave. The main thing you need to do is check that the Windows version of ActiveState Tcl is being built with thread support enabled. I think that thread support is enabled in the Windows build of ActiveState Tcl, but I don't remember off the top of my head. Then, you need to build a Tcl binary from the same release number that the ActiveState Tcl binary is built from. This is important because unlike other Tcl extensions, Tcl Blend needs to link to a specific Tcl dll and it needs to be exactly the same binary layout as the version it was compiled with. So, what I suggest is that you get a Windows build of Tcl, Thread, and TclBlend working in your own install location first. Then, copy the bin/tclblend.dll, and the library/tcljava1.4.1 files over to the install location where your ActiveState Tcl is. At that point, you will need to setup the env vars or copy over the jtclsh.bat script and setup the PATH values to work for your new install location. That is needed so that Tcl can load the Java shared libs at runtime. With the env vars setup properly, and the Tcl Blend library files copied to the correct location, you should be able to run "package require java" in the ActiveState Tcl shell. Just make sure you get the PATH settings right or it won't be able to find the Java shared libs. Tcl Blend build instructions under Mingw are located here: http://wiki.tcl.tk/9993 Mo DeJong |
From: Mo D. <mo...@mo...> - 2008-12-13 22:57:26
|
Mo DeJong wrote: > Fra...@ti... wrote: > >> Hi! >> >> Sorry but we can't get it work. >> Hey folks, I though I would post a quick note about the problem Frank was running into in case this bug was biting anyone else. The real cause of the problem is gcc 4.X and the strict-aliasing option enabled by -O2. This is one of those "is is a bug or a feature" things, the way to work around the problem is to either remove the -O2 option from the CFLAGS in the generated Makefile, or add -fno-strict-aliasing to the CFLAGS in the generated Makefile. I checked a patch (SF Patch 2424551) into the CVS to fix this issue (it should also fix other platforms where gcc is not the default compiler). so, if you are running into a crash when doing "package require java" in Tcl Blend, then make sure that gcc 4.X is building with this -fno-strict-aliasing flag. cheers Mo DeJong |
From: Saket J. <sj...@ya...> - 2008-11-16 19:22:07
|
Hi, To give a brief background, I am planning to build an application based on WSDL-Java technology. I require to blend this with Tcl as all my automation scripts are in Tcl. Basically, I have a simple requirement: I want to be able to use TclBlend from ActiveState Tcl on Windows. That is, I should be able to do something like: C:\>tclsh % package require java 1.4.0 % I have followed the steps on http://tcljava.sourceforge.net, which required me to download Mingw/Msys. It allows me to do 'package require java' from a 'jtclsh' shell or using 'jtclsh.bat'. Is there no way to install TclBlend in C:/Tcl/Lib, so that the 'java' package can be loaded from within a 'tclsh' shell just like Itcl, Expect etc? Any assistance will be much appreciated. Thanks in anticipation Regards Saket Jha Be the first one to try the new Messenger 9 Beta! Go to http://in.messenger.yahoo.com/win/ |
From: Mo D. <mo...@mo...> - 2008-11-14 23:53:05
|
Fra...@ti... wrote: > Hi! > > Sorry but we can't get it work. > > As far as we can see is all JAVA parameters set and point on our JAVA > 1.6 installation. > The ones to focus on are: JAVA_LIB_FLAGS = -L/local/tclblend/jdk/jre/lib/i386 -ljava -lverify -L/local/tclblend/jdk/jre/lib/i386/client -ljvm -L/local/tclblend/jdk/jre/lib/i386/native_threads -lhpi JAVA_LIB_RUNTIME_PATH = /local/tclblend/jdk/jre/lib/i386:/local/tclblend/jdk/jre/lib/i386/client :/local/tclblend/jdk/jre/lib/i386/native_threads These variables control where the system looks for shared libraries. I would bet that what is going on is the JDK 1.6 layout does not include one of these libs in the locations that are being searched. Could you try just running the following and see if you can get this working (these lib names might not be the exact ones on your system). % make shell load libhpi.so load libjvm.so load libjava.so load libtclblend.so If you can't load these libs at runtime, then the runtime lib search path is not correct. Also, check to make sure these libs actually exist in the jdk/jre/lib/i386/... or whatever dirs. Capture the output of the following and post it: cd /local/tclblend/jdk find . -name "*.so" cheers Mo DeJong |
From: Patrick F. <fin...@gm...> - 2008-11-14 14:43:01
|
Do you have to run on Linux? There is a windows binary available. No build required. |
From: <Fra...@ti...> - 2008-11-14 13:42:19
|
Hi! Sorry but we can't get it work. As far as we can see is all JAVA parameters set and point on our JAVA 1.6 installation. Parts of settings in the TclBlend and the TclThread Makefile: JAVA = /local/tclblend/jdk/bin/java JAVA_G = /local/tclblend/jdk/bin/java JAVAC = /local/tclblend/jdk/bin/javac JAVAH = /local/tclblend/jdk/bin/javah JAR = /local/tclblend/jdk/bin/jar JAVA_CLASSPATH = /local/tclblend/lib/tcljava/tcljava.jar:/local/tclblend/lib/tcljava/tclb lend.jar JAVA_INCLUDE_FLAGS = -I/local/tclblend/jdk/include -I/local/tclblend/jdk/include/linux JAVA_LIB_FLAGS = -L/local/tclblend/jdk/jre/lib/i386 -ljava -lverify -L/local/tclblend/jdk/jre/lib/i386/client -ljvm -L/local/tclblend/jdk/jre/lib/i386/native_threads -lhpi JAVA_LIB_RUNTIME_PATH = /local/tclblend/jdk/jre/lib/i386:/local/tclblend/jdk/jre/lib/i386/client :/local/tclblend/jdk/jre/lib/i386/native_threads By adding debug into the Tcl code it is possible to see that the CLASSPATH is correctly set when the tclblend.so file is loaded (short before the core dump): env(CLASSPATH) = /local/tclblend/lib/tcljava/tcljava.jar:/local/tclblend/lib/tcljava/tclb lend.jar Coredump with some debug lines added (may be some slight line missmatch). Core was generated by `/local/tclblend/bin/tclsh8.5'. Program terminated with signal 6, Aborted. #0 0xffffe410 in __kernel_vsyscall () (gdb) where #0 0xffffe410 in __kernel_vsyscall () #1 0xb7d588d0 in raise () from /lib/libc.so.6 #2 0xb7d59ff3 in abort () from /lib/libc.so.6 #3 0x0630ca7b in os::abort () from /local/tclblend/jdk/jre/lib/i386/client/libjvm.so #4 0x063cc541 in VMError::report_and_die () from /local/tclblend/jdk/jre/lib/i386/client/libjvm.so #5 0x06311d19 in JVM_handle_linux_signal () from /local/tclblend/jdk/jre/lib/i386/client/libjvm.so #6 0x0630e848 in signalHandler () from /local/tclblend/jdk/jre/lib/i386/client/libjvm.so #7 <signal handler called> #8 0xb7f6cae5 in Tcl_FindCommand (interp=0x8119000, name=0x8165b20 "java::new", contextNsPtr=0x0, flags=0) at /tmp/tclblend/tcl8.5.5/unix/../generic/tclNamesp.c:2388 #9 0xb7ed667b in Tcl_GetCommandInfo (interp=0x8119000, cmdName=0x8165b20 "java::new", infoPtr=0xbfda2b2c) at /tmp/tclblend/tcl8.5.5/unix/../generic/tclBasic.c:2522 #10 0xb7ea965e in Java_tcl_lang_Interp_getCommand () from /local/tclblend/lib/tcljava/libtclblend.so #11 0xb549ff4d in ?? () #12 0x08119114 in ?? () #13 0xbfda2bb0 in ?? () #14 0xbfda2bac in ?? () #15 0xbfda2b78 in ?? () #16 0x08119000 in ?? () #17 0x08119000 in ?? () #18 0x8c121fd8 in ?? () #19 0xbfda2b7c in ?? () #20 0x900d7304 in ?? () #21 0xbfda2bb0 in ?? () #22 0x900dd4b8 in ?? () #23 0x00000000 in ?? () (gdb) Additional information can be found in the attached dump file. Any suggestion how to move forward? BR Frank -----Original Message----- From: Mo DeJong [mailto:mo...@mo...] Sent: den 11 november 2008 22:41 To: A list for users of tcljava Subject: Re: [tcljava-user] make install - 'Testing installed program' fails Fra...@ti... wrote: > Hi! > > Tried to install the TclBlend on Linux (sled10). > > I come this far, now I'm thankful for some advice to how come around > this problem. I'm not an java expert so be open-minded in case I miss > some basic stuff. > I have included the following parts into the .cshrc file (maybe > something that is missing or maybe not needed): Hi Frank Well, I am not sure why you would put this stuff in .cshrc. This path related stuff goes in the jtclsh startup script. The point where you install fails is right after jtclsh is installed. The problems people always have with Tcl Blend are related to the PATH settings, you just need to make sure the path found by the script actually matches the library locations in your JDK install and it should work. The most likely cause of this problem is that your JDK 6.0 library has some path locations that differ from the ones that configure script knows about, so they are not getting detected correctly. I would suggest you run "make shell" from the build directory and see if you can load Tcl Blend (via "package require java") from the build directory. If you can't get it to load in the build directory then the paths in the Makefile can be updated to try to get it working. Mo DeJong ------------------------------------------------------------------------ - This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ tcljava-user mailing list tcl...@li... https://lists.sourceforge.net/lists/listinfo/tcljava-user |
From: Mo D. <mo...@mo...> - 2008-11-11 21:45:24
|
Fra...@ti... wrote: > Hi! > > I work as tester and we have a test environment (Linux) that is mainly > written in Tcl. > So far have only C-APIs been used in the applications and the tool > SWIG has been used a bridge from Tcl to C (SWIG builds a .so file that > is the loaded into the Tcl scripts to access different C-functions). > > In an upcoming project will JAVA support be added into the system, > that means also that during tests of some test objects will the C-API > be replaced of a JAVA-API (although the functionality below it will be > the same). > > The idea is to replace SWIG with Tcl Blend to achive this and by doing > this it is also possible to only perform minor changes in the existing > test framework (the test environment build and function calls will be > changed based on API used), but the existing tests of the > functionality (written in Tcl) can be left unchanged. > > Is Tcl Blend a possible solution for this? > Yes, Tcl Blend is useful as a way to invoke Java implementations of methods dynamically, finding them by name at runtime. Unlike SWIG with C, you won't need to generate code to invoke the Java code, Tcl Blend and the native Java invocation APIs take care of all of those details for you. Mo |
From: Mo D. <mo...@mo...> - 2008-11-11 21:44:28
|
Fra...@ti... wrote: > Hi! > > Tried to install the TclBlend on Linux (sled10). > > I come this far, now I'm thankful for some advice to how come around > this problem. I'm not an java expert so be open-minded in case I miss > some basic stuff. > I have included the following parts into the .cshrc file (maybe > something that is missing or maybe not needed): Hi Frank Well, I am not sure why you would put this stuff in .cshrc. This path related stuff goes in the jtclsh startup script. The point where you install fails is right after jtclsh is installed. The problems people always have with Tcl Blend are related to the PATH settings, you just need to make sure the path found by the script actually matches the library locations in your JDK install and it should work. The most likely cause of this problem is that your JDK 6.0 library has some path locations that differ from the ones that configure script knows about, so they are not getting detected correctly. I would suggest you run "make shell" from the build directory and see if you can load Tcl Blend (via "package require java") from the build directory. If you can't get it to load in the build directory then the paths in the Makefile can be updated to try to get it working. Mo DeJong |
From: Scott S. <ss...@am...> - 2008-11-11 15:51:02
|
Fra...@ti... wrote: > Hi! > > Tried to install the TclBlend on Linux (sled10). <snip> Hi Frank, I would make sure your environment isn't finding other Javas etc. I think the shell script below will help you and possibly others... #!/bin/bash set -e -v # Make sure we have all the variables we need... if [[ -z $DESTDIR || -z $BUILDDIR || -z $TARDIR ]]; then echo "Missing required variables..." exit 1 fi # #### TCL #### # cd $BUILDDIR tar -xzf $TARDIR/tcl8.4.19-src.tar.gz cd tcl8.4.19/unix ./configure --prefix=$DESTDIR --enable-threads make make install # #### TCL THREAD #### # cd $BUILDDIR tar -xzf $TARDIR/thread2.6.5.tar.gz cd thread2.6.5/unix ../configure --enable-threads # knows the prefix from the tcl src base config make make install # #### TclBlend #### # cd $BUILDDIR tar -xzf $TARDIR/tclBlend1.4.1.tar.gz cd tclBlend1.4.1 #patch -p1 < $TARDIR/tclblend-amd64.patch ./autogen.sh ./configure --with-jdk=$DESTDIR/jdk --with-tcl=$BUILDDIR/tcl8.4.19 \ --with-thread=$BUILDDIR/thread2.6.5/unix --prefix=$DESTDIR # gcc 4.1 and greater have an optimation bug that breaks tclblend sed -i "s/-O2//g" Makefile make make install # #### TclLib #### # cd $BUILDDIR tar -xjf $TARDIR/tcllib-1.10.tar.bz2 cd tcllib-1.10 ./configure --prefix=$DESTDIR make make install # convenience links cd $DESTDIR/lib ln -s tcl8.4 tcl ln -s tcljava1.4.1 tcljava cd $DESTDIR/bin ln -s tclsh8.4 tclsh |
From: <Fra...@ti...> - 2008-11-11 14:26:11
|
==15846== Memcheck, a memory error detector. ==15846== Copyright (C) 2002-2007, and GNU GPL'd, by Julian Seward et al. ==15846== Using LibVEX rev 1854, a library for dynamic binary translation. ==15846== Copyright (C) 2004-2007, and GNU GPL'd, by OpenWorks LLP. ==15846== Using valgrind-3.3.1, a dynamic binary instrumentation framework. ==15846== Copyright (C) 2000-2007, and GNU GPL'd, by Julian Seward et al. ==15846== For more details, rerun with: -v ==15846== ==15844== Conditional jump or move depends on uninitialised value(s) ==15844== at 0x4015103: (within /lib/ld-2.7.so) ==15844== by 0x40079D9: (within /lib/ld-2.7.so) ==15844== by 0x4001104: (within /lib/ld-2.7.so) ==15844== by 0x400D5D5: (within /lib/ld-2.7.so) ==15844== by 0x400107E: (within /lib/ld-2.7.so) ==15844== by 0x4003E04: (within /lib/ld-2.7.so) ==15844== by 0x40138EC: (within /lib/ld-2.7.so) ==15844== by 0x4000C3D: (within /lib/ld-2.7.so) ==15844== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15844== ==15844== Conditional jump or move depends on uninitialised value(s) ==15844== at 0x401510E: (within /lib/ld-2.7.so) ==15844== by 0x40079D9: (within /lib/ld-2.7.so) ==15844== by 0x4001104: (within /lib/ld-2.7.so) ==15844== by 0x400D5D5: (within /lib/ld-2.7.so) ==15844== by 0x400107E: (within /lib/ld-2.7.so) ==15844== by 0x4003E04: (within /lib/ld-2.7.so) ==15844== by 0x40138EC: (within /lib/ld-2.7.so) ==15844== by 0x4000C3D: (within /lib/ld-2.7.so) ==15844== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15844== ==15844== Conditional jump or move depends on uninitialised value(s) ==15844== at 0x4015119: (within /lib/ld-2.7.so) ==15846== by 0x40079D9: (within /lib/ld-2.7.so) ==15846== by 0x4001104: (within /lib/ld-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x400107E: (within /lib/ld-2.7.so) ==15846== by 0x4003E04: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x4015241: (within /lib/ld-2.7.so) ==15846== by 0x40079D9: (within /lib/ld-2.7.so) ==15846== by 0x4001104: (within /lib/ld-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x400107E: (within /lib/ld-2.7.so) ==15846== by 0x4003E04: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15844== ==15844== Conditional jump or move depends on uninitialised value(s) ==15844== at 0x4015241: (within /lib/ld-2.7.so) ==15846== by 0x4005C69: (within /lib/ld-2.7.so) ==15846== by 0x4007A97: (within /lib/ld-2.7.so) ==15846== by 0x4001104: (within /lib/ld-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x400107E: (within /lib/ld-2.7.so) ==15846== by 0x4003E04: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:* obj:* } ==15844== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400A65C: (within /lib/ld-2.7.so) ==15846== by 0x4003125: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400A692: (within /lib/ld-2.7.so) ==15846== by 0x4003125: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400B19D: (within /lib/ld-2.7.so) ==15846== by 0x4003125: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400A542: (within /lib/ld-2.7.so) ==15846== by 0x4003383: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400A54A: (within /lib/ld-2.7.so) ==15846== by 0x4003383: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400A692: (within /lib/ld-2.7.so) ==15846== by 0x4003383: (within /lib/ld-2.7.so) ==15846== by 0x40138EC: (within /lib/ld-2.7.so) ==15846== by 0x4000C3D: (within /lib/ld-2.7.so) ==15846== by 0x4000816: (within /lib/ld-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so } ==15844== ==15846== Invalid read of size 4 ==15846== at 0x4015209: (within /lib/ld-2.7.so) ==15846== by 0x4005C69: (within /lib/ld-2.7.so) ==15846== by 0x4007A97: (within /lib/ld-2.7.so) ==15846== by 0x4011543: (within /lib/ld-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x4010F5D: (within /lib/ld-2.7.so) ==15846== by 0x413F291: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x413F454: __libc_dlopen_mode (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x4119186: __nss_lookup_function (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411929F: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411AEC5: __nss_hosts_lookup (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== Address 0x41f8d74 is 36 bytes inside a block of size 37 alloc'd ==15846== at 0x40228E8: malloc (vg_replace_malloc.c:207) ==15846== by 0x4008031: (within /lib/ld-2.7.so) ==15846== by 0x4011543: (within /lib/ld-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x4010F5D: (within /lib/ld-2.7.so) ==15846== by 0x413F291: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x413F454: __libc_dlopen_mode (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x4119186: __nss_lookup_function (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411929F: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411AEC5: __nss_hosts_lookup (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411F782: gethostbyname_r (in /lib/tls/i686/cmov/libc-2.7.so) { <insert a suppression name here> Memcheck:Addr4 obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/tls/i686/cmov/libc-2.7.so obj:/lib/ld-2.7.so fun:__libc_dlopen_mode fun:__nss_lookup_function obj:/lib/tls/i686/cmov/libc-2.7.so fun:__nss_hosts_lookup } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400A65C: (within /lib/ld-2.7.so) ==15846== by 0x401167A: (within /lib/ld-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x4010F5D: (within /lib/ld-2.7.so) ==15846== by 0x413F291: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x413F454: __libc_dlopen_mode (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x4119186: __nss_lookup_function (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411929F: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411AEC5: __nss_hosts_lookup (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411F782: gethostbyname_r (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411EF57: gethostbyname (in /lib/tls/i686/cmov/libc-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/tls/i686/cmov/libc-2.7.so obj:/lib/ld-2.7.so fun:__libc_dlopen_mode fun:__nss_lookup_function obj:/lib/tls/i686/cmov/libc-2.7.so fun:__nss_hosts_lookup fun:gethostbyname_r fun:gethostbyname } ==15846== ==15846== Conditional jump or move depends on uninitialised value(s) ==15846== at 0x400A692: (within /lib/ld-2.7.so) ==15846== by 0x401167A: (within /lib/ld-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x4010F5D: (within /lib/ld-2.7.so) ==15846== by 0x413F291: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x400D5D5: (within /lib/ld-2.7.so) ==15846== by 0x413F454: __libc_dlopen_mode (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x4119186: __nss_lookup_function (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411929F: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411AEC5: __nss_hosts_lookup (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411F782: gethostbyname_r (in /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x411EF57: gethostbyname (in /lib/tls/i686/cmov/libc-2.7.so) { <insert a suppression name here> Memcheck:Cond obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/ld-2.7.so obj:/lib/tls/i686/cmov/libc-2.7.so obj:/lib/ld-2.7.so fun:__libc_dlopen_mode fun:__nss_lookup_function obj:/lib/tls/i686/cmov/libc-2.7.so fun:__nss_hosts_lookup fun:gethostbyname_r fun:gethostbyname } ==15846== ==15846== Invalid read of size 4 ==15846== at 0x807DA3B: EINSS7CpGetSendFact (ss7c.c:2664) ==15846== by 0x8098E84: EINSS7CpReceiveConReq (ss7tcpip.c:3386) ==15846== by 0x8093751: AcceptAnyConnections (ss7osdpn.c:3423) ==15846== by 0x8093E32: HandleAnyConRequests (ss7osdpn.c:3837) ==15846== by 0x80A465A: CpHandleSocketDataAvailable (ss7msgrecv.c:188) ==15846== by 0x80A4D09: MsgRecvEvent (ss7msgrecv.c:521) ==15846== by 0x80790CF: tecamMessageLoop (tecam_comm_cp.c:237) ==15846== by 0x8079FF3: main (te_main.c:327) ==15846== Address 0x163f8 is not stack'd, malloc'd or (recently) free'd { <insert a suppression name here> Memcheck:Addr4 fun:EINSS7CpGetSendFact fun:EINSS7CpReceiveConReq fun:AcceptAnyConnections fun:HandleAnyConRequests fun:CpHandleSocketDataAvailable fun:MsgRecvEvent fun:tecamMessageLoop fun:main } ==15846== ==15846== Invalid read of size 4 ==15846== at 0x807DA3B: EINSS7CpGetSendFact (ss7c.c:2664) ==15846== by 0x8096F16: CloseAllTCPIPServerSocketsForMPOwner (ss7tcpip.c:2070) ==15846== by 0x807E9BF: CloseAllSocketsForMPOwner (ss7c.c:3595) ==15846== by 0x807ECE8: MsgClose (ss7c.c:3677) ==15846== by 0x8082B6D: MsgCloseAll (ss7c.c:6330) ==15846== by 0x8094CD6: SigTermHandler (ss7osdpn.c:4793) ==15846== by 0x405C127: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x8098E84: EINSS7CpReceiveConReq (ss7tcpip.c:3386) ==15846== by 0x8093751: AcceptAnyConnections (ss7osdpn.c:3423) ==15846== by 0x8093E32: HandleAnyConRequests (ss7osdpn.c:3837) ==15846== by 0x80A465A: CpHandleSocketDataAvailable (ss7msgrecv.c:188) ==15846== by 0x80A4D09: MsgRecvEvent (ss7msgrecv.c:521) ==15846== Address 0x384c is not stack'd, malloc'd or (recently) free'd { <insert a suppression name here> Memcheck:Addr4 fun:EINSS7CpGetSendFact fun:CloseAllTCPIPServerSocketsForMPOwner fun:CloseAllSocketsForMPOwner fun:MsgClose fun:MsgCloseAll fun:SigTermHandler obj:/lib/tls/i686/cmov/libc-2.7.so fun:EINSS7CpReceiveConReq fun:AcceptAnyConnections fun:HandleAnyConRequests fun:CpHandleSocketDataAvailable fun:MsgRecvEvent } ==15846== ==15846== Process terminating with default action of signal 11 (SIGSEGV): dumping core ==15846== Access not within mapped region at address 0x384C ==15846== at 0x807DA3B: EINSS7CpGetSendFact (ss7c.c:2664) ==15846== by 0x8096F16: CloseAllTCPIPServerSocketsForMPOwner (ss7tcpip.c:2070) ==15846== by 0x807E9BF: CloseAllSocketsForMPOwner (ss7c.c:3595) ==15846== by 0x807ECE8: MsgClose (ss7c.c:3677) ==15846== by 0x8082B6D: MsgCloseAll (ss7c.c:6330) ==15846== by 0x8094CD6: SigTermHandler (ss7osdpn.c:4793) ==15846== by 0x405C127: (within /lib/tls/i686/cmov/libc-2.7.so) ==15846== by 0x8098E84: EINSS7CpReceiveConReq (ss7tcpip.c:3386) ==15846== by 0x8093751: AcceptAnyConnections (ss7osdpn.c:3423) ==15846== by 0x8093E32: HandleAnyConRequests (ss7osdpn.c:3837) ==15846== by 0x80A465A: CpHandleSocketDataAvailable (ss7msgrecv.c:188) ==15846== by 0x80A4D09: MsgRecvEvent (ss7msgrecv.c:521) ==15846== ==15846== ERROR SUMMARY: 25 errors from 16 contexts (suppressed: 0 from 0) ==15846== malloc/free: in use at exit: 7,464,140 bytes in 1,476 blocks. ==15846== malloc/free: 1,619 allocs, 143 frees, 7,500,985 bytes allocated. ==15846== For counts of detected errors, rerun with: -v ==15846== searching for pointers to 1,476 not-freed blocks. ==15846== checked 7,349,044 bytes. ==15846== ==15846== ==15846== 7,464,140 bytes in 1,476 blocks are still reachable in loss record 1 of 1 ==15846== at 0x40228E8: malloc (vg_replace_malloc.c:207) ==15846== by 0x808EEFA: CpMemMallocOsdpn (ss7memory.c:1294) ==15846== by 0x808EE7C: CpMemInitUsersOsdpn (ss7memory.c:974) ==15846== by 0x808ED59: CpMemInitUsers (ss7memory.c:888) ==15846== by 0x808E4C5: EINSS7CpMemInit (ss7memory.c:550) ==15846== by 0x807C5BD: EINSS7CpInitBasicStructs (ss7c.c:1496) ==15846== by 0x80A771F: EINSS7CpRegisterMPOwner (ss7cp_mgmt.c:1658) ==15846== by 0x807A3F2: modulesPrepare (te_main.c:476) ==15846== by 0x8079F04: main (te_main.c:281) { <insert a suppression name here> Memcheck:Leak fun:malloc fun:CpMemMallocOsdpn fun:CpMemInitUsersOsdpn fun:CpMemInitUsers fun:EINSS7CpMemInit fun:EINSS7CpInitBasicStructs fun:EINSS7CpRegisterMPOwner fun:modulesPrepare fun:main } ==15846== ==15846== LEAK SUMMARY: ==15846== definitely lost: 0 bytes in 0 blocks. ==15846== possibly lost: 0 bytes in 0 blocks. ==15846== still reachable: 7,464,140 bytes in 1,476 blocks. ==15846== suppressed: 0 bytes in 0 blocks. |
From: Georgios P. <pet...@ya...> - 2008-11-09 23:28:32
|
This looks more like a question for comp.lang.tcl, than the tcljava-user list. George O/H Eduard Polyakov ??????: > > Hello, > > > > I have created a new Tcl command, which starts Tftp server from loaded > DLL, and I am trying to link variables between C and Tcl, > > which supposed to count received blocks. > > I start the command in a separate Tcl thread in order to receive the > prompt back. Everything works but Tcl variable never changes its value. > > > > > > //Dll Staff > > > > extern int RcvBlocks; > > > > EXTERN_C int DECLSPEC_EXPORT Tftpsrvdll_Init ( Tcl_Interp* interp ) > > { > > > > #ifdef USE_TCL_STUBS > > Tcl_InitStubs(interp, "8.4", 0); > > #endif > > > > //link variables > > Tcl_LinkVar(interp, "env(rcvBlocks)", (char *)&RcvBlocks, > TCL_LINK_INT); > > > > //tftps > > Tcl_CreateCommand( interp, > > "tftps", > > (Tcl_CmdProc*) TftpSrv, > > (ClientData)NULL, > > (Tcl_CmdDeleteProc *)NULL); > > return 0; > > } > > > > > > //Tcl Staff > > > > % set env(rcvBlocks) 0 > > 0 > > % package require Thread > > 2.6.3 > > % thread::create { > > load TftpSrvDLL.dll > > tftps -v > > } > > tid00000E70 > > TFTP Server MultiThreaded Version 1.53 Windows Built 1530 > > accepting requests.. > > % #enter key > > % puts env(rcvBlocks) > > 0 > > % > > % puts env(rcvBlocks) > > 0 > > % > > % Client 192.168.10.152:2269 C:\Tcl\bin\DownloadFile.bin, 4201 Blocks > Served > > % #enter key > > % puts env(rcvBlocks) > > 0 > > % > > > > In addinion I can not get prompt immediately, but have to hit enter > each time. > > > > Am I missing something? > > > > Thanks in advance, > > Ed > > > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > ------------------------------------------------------------------------ > > _______________________________________________ > tcljava-user mailing list > tcl...@li... > https://lists.sourceforge.net/lists/listinfo/tcljava-user > |
From: <Fra...@ti...> - 2008-11-07 16:57:10
|
Hi! Tried to install the TclBlend on Linux (sled10). I come this far, now I'm thankful for some advice to how come around this problem. I'm not an java expert so be open-minded in case I miss some basic stuff. I have included the following parts into the .cshrc file (maybe something that is missing or maybe not needed): setenv PATH /tmp/jdk1.6.0_10/bin/:$PATH setenv PATH /proj/teprod/tools/gcc/4.3.2/sled10/bin//:$PATH setenv PATH /local/tclblend/bin:$PATH setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/tmp/tclblend/tclBlend1.4.1/unix setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/tmp/jdk1.6.0_10/jre/lib/i386/native_threads setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/local/tclblend/lib/tcljava1.4.1 Below is the stdout: # make install # # Installing tcljava # Installing tcljava.jar in /local/tclblend/lib/tcljava1.4.1 Installing tcljavasrc.jar in /local/tclblend/lib/tcljava1.4.1 # # Installing tclblend # Installing libtclblend.so in /local/tclblend/lib/tcljava1.4.1 Installing tclblend.jar in /local/tclblend/lib/tcljava1.4.1 Installing tclblendsrc.jar in /local/tclblend/lib/tcljava1.4.1 Installing pkgIndex.tcl in /local/tclblend/lib/tcljava1.4.1 Installing xputils package in /local/tclblend/lib Installing jtclsh in /local/tclblend/bin Installing jwish in /local/tclblend/bin Testing installed program # # An unexpected error has been detected by Java Runtime Environment: # # SIGSEGV (0xb) at pc=0xb7ecb88a, pid=31780, tid=3083544240 # # Java VM: Java HotSpot(TM) Client VM (11.0-b15 mixed mode, sharing linux-x86) # Problematic frame: # C [libtcl8.5.so+0x9788a] Tcl_FindCommand+0x24a # # An error report file with more information is saved as: # /tmp/tclblend/build_tclblend/tclblend_test/hs_err_pid31780.log # # If you would like to submit a bug report, please visit: # http://java.sun.com/webapps/bugreport/crash.jsp # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # /bin/sh: line 1: 31780 Aborted (core dumped) env /local/tclblend/bin/jtclsh Test.tcl jtclsh test failed due to a configuration error BR Frank |
From: Tom P. <tpo...@ny...> - 2008-11-07 14:06:42
|
On Fri, Nov 07, 2008 at 09:27:27AM +0100, Fra...@ti... wrote: > > The idea is to replace SWIG with Tcl Blend to achive this and by doing > this it is also possible to only perform minor changes in the existing > test framework (the test environment build and function calls will be > changed based on API used), but the existing tests of the functionality > (written in Tcl) can be left unchanged. > > Is Tcl Blend a possible solution for this? TclBlend does include the 'java' package, which allows dynamic access to Java objects, so I believe the answer is yes. See: http://tcljava.sourceforge.net/docs/TclJava/contents.html -- Tom Poindexter tpo...@ny... |
From: <Fra...@ti...> - 2008-11-07 08:44:05
|
Hi! I work as tester and we have a test environment (Linux) that is mainly written in Tcl. So far have only C-APIs been used in the applications and the tool SWIG has been used a bridge from Tcl to C (SWIG builds a .so file that is the loaded into the Tcl scripts to access different C-functions). In an upcoming project will JAVA support be added into the system, that means also that during tests of some test objects will the C-API be replaced of a JAVA-API (although the functionality below it will be the same). The idea is to replace SWIG with Tcl Blend to achive this and by doing this it is also possible to only perform minor changes in the existing test framework (the test environment build and function calls will be changed based on API used), but the existing tests of the functionality (written in Tcl) can be left unchanged. Is Tcl Blend a possible solution for this? BR Frank |
From: Eduard P. <edu...@ru...> - 2008-11-03 20:05:47
|
Hello, I have created a new Tcl command, which starts Tftp server from loaded DLL, and I am trying to link variables between C and Tcl, which supposed to count received blocks. I start the command in a separate Tcl thread in order to receive the prompt back. Everything works but Tcl variable never changes its value. //Dll Staff extern int RcvBlocks; EXTERN_C int DECLSPEC_EXPORT Tftpsrvdll_Init ( Tcl_Interp* interp ) { #ifdef USE_TCL_STUBS Tcl_InitStubs(interp, "8.4", 0); #endif //link variables Tcl_LinkVar(interp, "env(rcvBlocks)", (char *)&RcvBlocks, TCL_LINK_INT); //tftps Tcl_CreateCommand( interp, "tftps", (Tcl_CmdProc*) TftpSrv, (ClientData)NULL, (Tcl_CmdDeleteProc *)NULL); return 0; } //Tcl Staff % set env(rcvBlocks) 0 0 % package require Thread 2.6.3 % thread::create { load TftpSrvDLL.dll tftps -v } tid00000E70 TFTP Server MultiThreaded Version 1.53 Windows Built 1530 accepting requests.. % #enter key % puts env(rcvBlocks) 0 % % puts env(rcvBlocks) 0 % % Client 192.168.10.152:2269 C:\Tcl\bin\DownloadFile.bin, 4201 Blocks Served % #enter key % puts env(rcvBlocks) 0 % In addinion I can not get prompt immediately, but have to hit enter each time. Am I missing something? Thanks in advance, Ed |
From: Mo D. <mo...@mo...> - 2008-10-21 22:15:32
|
Fugate, Cris wrote: > > I am trying to optimize Jacl scripts inside an application called > Teamcenter. > > Unfortunately, I am not having any luck measuring the timing of code. > > I can use time in c-tcl. Can I expect the same relative performance > > Between Tcl commands in Jacl as in c-Tcl? > > > Hi Chris You might want to take a look at the TclBench test code inside the tcljava/tests directory. I used that to create the following comparison of C Tcl to TJC compiled Jacl: http://www.modejong.com/tcljava/tjc_results_6_20_2006/index.html The main thing is to make sure hotspot has warmed up and compiled your code before getting runtime numbers to compare. If you just grab some time via the time command, the results will be misleading unless hotspot has compiled the code. Also, make sure you use many thousands of iterations with the time command. If you need some more focused help with this project, I am available on a consulting basis for whatever optimization assistance you might need. Mo DeJong |
From: Fugate, C. <Cri...@Qi...> - 2008-10-21 17:15:38
|
I am trying to optimize Jacl scripts inside an application called Teamcenter. Unfortunately, I am not having any luck measuring the timing of code. I can use time in c-tcl. Can I expect the same relative performance Between Tcl commands in Jacl as in c-Tcl? Cris A. Fugate Senior Programmer Analyst Cri...@qi... <mailto:Cri...@qi...> 540.657.2519x139 QinetiQ North America |
From: Jared H. <ho...@mo...> - 2008-10-14 15:41:30
|
Hi all, So I am using jacl in our java code a lot like glue to hold the various pieces of java code together. I write all of the simple stuff in tcl and all of the stuff that needs to go fast goes into java. So anyway, I'm sometimes debugging java code by calling it in jacl. My question is, how do I get a useful stack trace out of a method I call this way? I've tried catching the TclException that gets called and printing out it's stack trace, but it always ends at: tcl.lang.ReflectException at tcl.lang.JavaInvoke.call(JavaInvoke.java:328) ... I've looked in the code, and it looks like the call method is catching the InvocationTargetException and wrapping it in a ReflectException. This would be fine and I would just call "getThrowable" and print it's stack trace if ReflectException was public. Is there any reason this class needs to not be public? Is there maybe another way to get to this? I don't want to have to mess with wrapping every call in "java::call" when I can simply put a java call in my code. -Jared |
From: Kristoffer L. <se...@fi...> - 2008-09-26 19:35:49
|
I've just spent practically the whole day trying to get it first to compile and now to run. After tweaking the tcljava.m4 file quite a bit (not quite sure if the tweaks were right, but it compiles) I am now getting a Bus error as soon as I load the package. This same situation occurred with the TclTkAqua Batteries Included package of old (no longer updated, I think?). I have a working jaclsh lying around, but now I'd really, really like to have TclBlend so it'd be nice to hear if anybody at all has managed to get it running on OS X. I might even be able to arrange a developer some shell access, if they want. This is the latest 1.4.1 release. / http://www.scred.com/ / http://www.fishpool.com/~setok/ |
From: Bruce J. <nm...@ma...> - 2008-09-25 21:07:58
|
Hi Maurice, Other's have expressed interest in this as well. I've basically been so busy that I haven't got around to really thinking about this. There is still so much to do with Swank/Jacl (like documentation, examples etc.) and fundamentally, for me at least, having things work well with Jacl is most important. But I think I will try to set aside some time soon to give some serious thought about this. To do it right I really need to think not just about JRuby, but whether the Swank code can be modified so it would be readily accessible from other Java based dynamic languages as well (like Jython). Since a lot of the Swank code is "automatically" written it should be possible to modify the generating code to rewrite the code in a more general way. I'll download the JRuby code and spend a little time just getting a feel for what would be involved. I can sort of imagine replacing the use of Tcl Interp class in Swank with a generalized script interpreter class that dispatched calls to get/set variables and execute scripts using whatever language was embedded. But, I'm not sure exactly how similar this paradigm is between Jacl and JRuby etc. cheers, Bruce On Sep 25, 2008, at 2:28 AM, Maurice Diamantini wrote: > > Le 24 sept. 08 à 21:44, Bruce Johnson a écrit : > >> Swank , the Tk-like GUI toolkit companion to Jacl, has a new home at: >> >> http://kenai.com/projects/swank >> >> Kenai is yet another open source repository (recently started by >> Sun). I was particularly interested in it because they support >> Mercurial (which I use) as the source code management system. I >> started a project there yesterday and uploaded the latest version of >> source into the mercurial repository. The Kenai site provides a >> Wiki, mailing lists and Bugzilla for bug tracking. They haven't yet >> added the ability to provide downloadable files (for latest or >> stable builds, for example) but that is supposed to be coming "real >> soon now". > > Bonjour Bruce, > > I'm glad you are keeping working on swank. > I've worked on a litle application witch use Ruby/Tk. But it seems > installing a Ruby/Tk sistribution is not as easy as just Tcl/Tk is ;-) > > So, instead of switching to of full Java application, I wonder if > Swank > would be usable with Jruby. > So the question is : can Swank be used as as Java independant GUI > library for Java? > > Thanks you very much. > > -- Maurice > http://www.ensta.fr/~diam/tcl/ > > > P.S. > I'm sorry if this question is relative to swank and not jacl > interpreter, but as swank repository switches to the same Sun > repository that some JRuby project, it would make sens... > > > >> I'll be adding more stuff to the site over the next week. >> >> cheers, >> >> Bruce >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's >> challenge >> Build the coolest Linux based applications with Moblin SDK & win >> great prizes >> Grand prize is a trip for two to an Open Source event anywhere in >> the world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/_______________________________________________ >> tcljava-user mailing list >> tcl...@li... >> https://lists.sourceforge.net/lists/listinfo/tcljava-user > > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > Build the coolest Linux based applications with Moblin SDK & win > great prizes > Grand prize is a trip for two to an Open Source event anywhere in > the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > tcljava-user mailing list > tcl...@li... > https://lists.sourceforge.net/lists/listinfo/tcljava-user |
From: Dan D. <dda...@ya...> - 2008-09-25 12:00:51
|
Martin and Mo, Thank you both for quick responses. The reason I was building up the TclList then just returning one item was because of a design decision to have lower layers build the list, then an upper/interface layer decide if we truly needed a list returned or just one item. I will take your advice (which I figured out on my own yesterday) and instead have the lower layers build a Java List, then the upper layer can decide if we need to return a TclList or just a TclObject and convert accordingly. I did read yesterday that when a list is released it releases ALL its contents too. I expected it to be more like Java where if there are still references to the members they would be left alone. I figured adding list.preserve() to prevent the crash was a memory leak, that's why I asked in the first place, I didn't want to leave the "fix-bug" in my code. :) Why does this not happen when the list is made up of just non-list TclObjects? Thanks again, Dan ----- Original Message ---- From: Martin Lemburg <mar...@gm...> To: A list for users of tcljava <tcl...@li...>; dda...@ya... Sent: Thursday, September 25, 2008 4:42:37 AM Subject: Re: [tcljava-user] (no subject) Hi Dan, the reason is, that you return an element from the just built list by pushing it into the interpreter. If the method is ending the list object is released and all its elements will be released, too. So the result list element won't be present anymore. In my eyes even a "list.preserve" call wouldn't solve the problem because it raises the question, when the list would be release again? I would say ... never! So I would duplicate the object I want to return! In C(++) I would do: Tcl_Obj* pList = Tcl_NewObj(); // building the list Tcl_Obj* pElement = NULL; Tcl_ListObjIndex(pInterp, pList, nIndex, &pElement); Tcl_SetObjResult(pInterp, Tcl_DuplicateObj(pElement)); By the way ... why do you build a tcl list to extract one element and to forget it? Why not using Java container objects, if container objects are really needed? Ok - I hope my suggestion helps. Best regards, Martin Lemburg Dan Diolosa wrote: Hi, I am wondering why I need to "preserve" a TclList that I don't return to TCL, nor need/use after the function returns. I am trying to return just one sub-list from a list of sub-lists. If I have just a list of normal TclObjects I can return one item without a problem. What is wrong with this: public void cmdProc(Interp interp, TclObject argv[]) throws TclException { TclObject list = TclList.newInstance(); //Create the first sublist TclObject list1 = TclList.newInstance(); TclList.append(interp, list1, TclString.newInstance("1.1")); TclList.append(interp, list1, TclString.newInstance("1.2")); //Create the second sublist TclObject list2 = TclList.newInstance(); TclList.append(interp, list2, TclString.newInstance("2.1")); TclList.append(interp, list2, TclString.newInstance("2.2")); //Add to main list TclList.append(interp, list, list1); TclList.append(interp, list1, list2); //list.preserve(); //return just the second sublist list interp.setResult(TclList.index(interp, list, 0)); } When I run it (without the preserve()), I get this: % ls_test alloc: invalid block: 009B3DF0: f8 0 0 This application has requested the Runtime to terminate it in an unusual way. Please contact the application's support team for more information. D:\ When I run a similar situation in my production code I get the error from JRE side, SIGSEGV on Linux and ACCESS_VIOLATION on Windows: # # An unexpected error has been detected by HotSpot Virtual Machine: # # SIGSEGV (0xb) at pc=0x4008eb78, pid=4098, tid=1074768448 # # Java VM: Java HotSpot(TM) Client VM (1.5.0_06-b05 mixed mode, sharing) # Problematic frame: # C [libtcl8.4.so+0x77b78] # # An error report file with more information is saved as hs_err_pid4098.log # # If you would like to submit a bug report, please visit: # http://java.sun.com/webapps/bugreport/crash.jsp # Aborted (core dumped) Thanks, Dan ________________________________ ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ ________________________________ _______________________________________________ tcljava-user mailing list tcl...@li... https://lists.sourceforge.net/lists/listinfo/tcljava-user -- ________________________________ Martin Lemburg Emdener Strasse 19A D-10551 Berlin Private: Phone: +49 30 39 03 72 05 Mobile: +49 179 395 40 95 Fax: +49 1805 40 02-26 86 05 Email: mar...@gm... Office: Phone: +49 30 46 77 75-22 Fax: +49 30 46 77 75-11 Email: mar...@si... ________________________________ "We are all individualists!" "No, Im the only non-individualist!" (Monty Pythons "Life of Brian") ________________________________ |
From: Martin L. <mar...@gm...> - 2008-09-25 09:08:39
|
Hi Dan, the reason is, that you return an element from the just built list by pushing it into the interpreter. If the method is ending the list object is released and all its elements will be released, too. So the result list element won't be present anymore. In my eyes even a "list.preserve" call wouldn't solve the problem because it raises the question, when the list would be release again? I would say ... never! So I would duplicate the object I want to return! In C(++) I would do: *Tcl_Obj** pList = *Tcl_NewObj*(); // building the list *Tcl_Obj** pElement = NULL; *Tcl_ListObjIndex*(pInterp, pList, nIndex, &pElement); *Tcl_SetObjResult*(pInterp, *Tcl_DuplicateObj*(pElement)); By the way ... why do you build a tcl list to extract one element and to forget it? Why not using Java container objects, if container objects are really needed? Ok - I hope my suggestion helps. Best regards, Martin Lemburg Dan Diolosa wrote: > > Hi, > > > I am wondering why I need to "preserve" a TclList that I don't return > to TCL, nor need/use after the function returns. > > I am trying to return just one sub-list from a list of sub-lists. If > I have just a list of normal TclObjects I can return one item without > a problem. What is wrong with this: > > > > public void cmdProc(Interp interp, TclObject argv[]) throws TclException > > { > > TclObject list = TclList.newInstance(); > > > > //Create the first sublist > > TclObject list1 = TclList.newInstance(); > > TclList.append(interp, list1, TclString.newInstance("1.1")); > > TclList.append(interp, list1, TclString.newInstance("1.2")); > > > > //Create the second sublist > > TclObject list2 = TclList.newInstance(); > > TclList.append(interp, list2, TclString.newInstance("2.1")); > > TclList.append(interp, list2, TclString.newInstance("2.2")); > > > > //Add to main list > > TclList.append(interp, list, list1); > > TclList.append(interp, list1, list2); > > > > //list.preserve(); > > > > //return just the second sublist list > > interp.setResult(TclList.index(interp, list, 0)); > > } > > > > When I run it (without the preserve()), I get this: > > % ls_test > > alloc: invalid block: 009B3DF0: f8 0 0 > > > > This application has requested the Runtime to terminate it in an > unusual way. > > Please contact the application's support team for more information. > > D:\ > > > > > > When I run a similar situation in my production code I get the error > from JRE side, SIGSEGV on Linux and ACCESS_VIOLATION on Windows: > > > > # > > # An unexpected error has been detected by HotSpot Virtual Machine: > > # > > # SIGSEGV (0xb) at pc=0x4008eb78, pid=4098, tid=1074768448 > > # > > # Java VM: Java HotSpot(TM) Client VM (1.5.0_06-b05 mixed mode, sharing) > > # Problematic frame: > > # C [libtcl8.4.so+0x77b78] > > # > > # An error report file with more information is saved as > hs_err_pid4098.log > > # > > # If you would like to submit a bug report, please visit: > > # http://java.sun.com/webapps/bugreport/crash.jsp > > # > > Aborted (core dumped) > > > Thanks, > > Dan > > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > ------------------------------------------------------------------------ > > _______________________________________________ > tcljava-user mailing list > tcl...@li... > https://lists.sourceforge.net/lists/listinfo/tcljava-user > -- ------------------------------------------------------------------------ Martin Lemburg Emdener Strasse 19A D-10551 Berlin Private: Phone: +49 30 39 03 72 05 Mobile: +49 179 395 40 95 Fax: +49 1805 40 02-26 86 05 Email: mar...@gm... <mailto:mar...@gm...> Office: Phone: +49 30 46 77 75-22 Fax: +49 30 46 77 75-11 Email: mar...@si... <mailto:mar...@si...> ------------------------------------------------------------------------ "We are all individualists!" "No, Im the only non-individualist!" (Monty Pythons "Life of Brian") ------------------------------------------------------------------------ |
From: Maurice D. <Mau...@en...> - 2008-09-25 06:45:55
|
Le 24 sept. 08 à 21:44, Bruce Johnson a écrit : > Swank , the Tk-like GUI toolkit companion to Jacl, has a new home at: > > http://kenai.com/projects/swank > > Kenai is yet another open source repository (recently started by > Sun). I was particularly interested in it because they support > Mercurial (which I use) as the source code management system. I > started a project there yesterday and uploaded the latest version of > source into the mercurial repository. The Kenai site provides a > Wiki, mailing lists and Bugzilla for bug tracking. They haven't yet > added the ability to provide downloadable files (for latest or > stable builds, for example) but that is supposed to be coming "real > soon now". Bonjour Bruce, I'm glad you are keeping working on swank. I've worked on a litle application witch use Ruby/Tk. But it seems installing a Ruby/Tk sistribution is not as easy as just Tcl/Tk is ;-) So, instead of switching to of full Java application, I wonder if Swank would be usable with Jruby. So the question is : can Swank be used as as Java independant GUI library for Java? Thanks you very much. -- Maurice http://www.ensta.fr/~diam/tcl/ P.S. I'm sorry if this question is relative to swank and not jacl interpreter, but as swank repository switches to the same Sun repository that some JRuby project, it would make sens... > I'll be adding more stuff to the site over the next week. > > cheers, > > Bruce > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > Build the coolest Linux based applications with Moblin SDK & win > great prizes > Grand prize is a trip for two to an Open Source event anywhere in > the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/_______________________________________________ > tcljava-user mailing list > tcl...@li... > https://lists.sourceforge.net/lists/listinfo/tcljava-user |
From: Bruce J. <nm...@ma...> - 2008-09-24 19:45:28
|
Swank , the Tk-like GUI toolkit companion to Jacl, has a new home at: http://kenai.com/projects/swank Kenai is yet another open source repository (recently started by Sun). I was particularly interested in it because they support Mercurial (which I use) as the source code management system. I started a project there yesterday and uploaded the latest version of source into the mercurial repository. The Kenai site provides a Wiki, mailing lists and Bugzilla for bug tracking. They haven't yet added the ability to provide downloadable files (for latest or stable builds, for example) but that is supposed to be coming "real soon now". I'll be adding more stuff to the site over the next week. cheers, Bruce |
From: Mo D. <mo...@mo...> - 2008-09-24 19:30:37
|
Dan Diolosa wrote: > > Hi, > > > I am wondering why I need to "preserve" a TclList that I don't return > to TCL, nor need/use after the function returns. > > I am trying to return just one sub-list from a list of sub-lists. If > I have just a list of normal TclObjects I can return one item without > a problem. What is wrong with this: > Hi Dan It is kind of odd, and the way you are using the list object is kind of odd too. I am sure there is some reason for it in your code, but in this example you should be able to just set the interp result to list1 without having to create another container list. I don't see why your code would need to preserve() the "list" variable, but it would need to release it after the interp.setResult() call in order to avoid leaking memory. When a TclObject is created it should have a ref count of 0, if you then release() it is should then be deallocated. The safest thing to do is to preserve() the container list, and then release() it (which will release any contained objects) after the interp.setResult() call. The release should be in a finally block, in case an exception is thrown. I hope that helps Mo DeJong |