Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Chris Gray
On Monday 18 September 2006 18:14, Geir Magnusson Jr. wrote:
> Pavel Pervov wrote:
> > Tried it on Windows and found the problem which, as it looks like, have
> > never been caught before.
> > As I discovered, launcher uses platform specific line separators to parse
> > harmonyvm.properties on a specific platform. But haromynvm.properties,
> > which
> > is copied into deploy, has unix line endings and is skipped. As the
> > result, EM can't initialize.'
>
> A ha!
>
> > I workarounded this by running unix2dos on harmonyvm.properties.
>
> Ok - we should get that in as eol-native

Wouldn't it be better (and safer) to fix the parser? Normally a properties 
file can contain any kind of line separators and still be parsed correctly, 
which is a Good Thing IMHO. E.g. according to the spec for 
java.util.Properties.load(),
A natural line of input is terminated either by a set of line 
terminator 
characters (\n or \r or \r\n) or by the end of the file. 

Chris

-- 
Chris Gray/k/ Embedded Java Solutions  BE0503765045
Embedded & Mobile Java, OSGihttp://www.k-embedded-java.com/
[EMAIL PROTECTED] +32 3 216 0369


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][io][nio] Sync issue of java.io.FileOutputStream and java.nio.channels.FileChannel

2006-09-18 Thread Andrew Zhang

I just found another bug of sync. Harmony throws SyncFailedException when fd
is read-only while RI returns silently. Spec doesn't explictly describe the
behaviour in such case[1]. But, it seems intended behaviour of RI, because
it requires additional check before invoke os sync. Following test
reproduces the bug:

   public void testSyncReadOnly() throws Exception {
   String TESTFILE = "tempFile";
   try {
   FileOutputStream fos = new FileOutputStream(TESTFILE);
   fos.write("something".getBytes());
   fos.close();

   RandomAccessFile raf = new RandomAccessFile(TESTFILE, "rw");
   raf.getFD().sync();
   raf.close();

   FileInputStream fis = new FileInputStream(TESTFILE);
   fis.getFD().sync();
   fis.close();
   } finally {
   new File(TESTFILE).delete();
   }
   }

I'll file a JIRA to record this bug soon!
[1] "SyncFailedException - Thrown when the buffers cannot be flushed, or
because the system cannot guarantee that all the buffers have been
synchronized with physical media."


On 9/19/06, Richard Liang <[EMAIL PROTECTED]> wrote:


On 9/18/06, Andrew Zhang <[EMAIL PROTECTED]> wrote:
> On 9/18/06, Richard Liang <[EMAIL PROTECTED]> wrote:
> >
> > Hello,
> >
> > One Apache Derby test[1] fails on Harmony. It seems that RI always
> > sync the FileOutputStream and FileChannel after each "write", which is
> > different from Harmony. But there is no explicit description in Java
> > Spec. Shall we follow RI? Thanks a lot.
> >
> > The following test cases could demonstrate this issue.
> >
> >public void testFile() {
> >File derbyLog = new File("d:\\", "derby1.log");
> >
> >try {
> >FileOutputStream fos = new FileOutputStream(derbyLog);
> >fos.write(0x41);
> >assertEquals(1, derbyLog.length());
> >} catch (Exception e) {
> >e.printStackTrace();
> >}
> >}
> >
> >public void testFileChannel() {
> >File derbyLog = new File("d:\\", "derby2.log");
> >
> >try {
> >FileOutputStream fos = new FileOutputStream(derbyLog);
> >FileChannel fc = fos.getChannel();
> >fc.write(ByteBuffer.wrap(new byte[]{0x41, 0x42}));
> >assertEquals(2, derbyLog.length());
> >} catch (Exception e) {
> >e.printStackTrace();
> >}
> >}
>
>
> Interesting. I think we'd better follow RI although it's implementation
> dependent. Otherwise, it breaks existing application.
>
> To make test more interesting, I wrote a similar test:
>
>
>  public void testFile() throws Exception {
> File derbyLog = File.createTempFile("test", "log");
> derbyLog.deleteOnExit();
> RandomAccessFile fos = new RandomAccessFile(derbyLog, "rws");
> for (int i = 0; i < 1000; i++) {
> fos.write(0x41);
> assertEquals(1 + i, derbyLog.length());
> }
>
>  }
>
> Run it and you'll be surprised. :-)

Wow! It tooks RI 0.381 seconds, while 21.761 seconds for Harmony. We
shall improve our performance!

Let's have a more further study about this issue.

>
> [1]
> >
http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/logStream.java?view=co
> > --
> > Richard Liang
> > China Development Lab, IBM
> >
> > -
> > Terms of use : http://incubator.apache.org/harmony/mailing.html
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
> --
> Andrew Zhang
> China Software Development Lab, IBM
>
>


--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Andrew Zhang
China Software Development Lab, IBM


Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Alexey Varlamov

2006/9/18, Geir Magnusson Jr. <[EMAIL PROTECTED]>:



Pavel Pervov wrote:
> Tried it on Windows and found the problem which, as it looks like, have
> never been caught before.
> As I discovered, launcher uses platform specific line separators to parse
> harmonyvm.properties on a specific platform. But haromynvm.properties,
> which
> is copied into deploy, has unix line endings and is skipped. As the result,
> EM can't initialize.'

A ha!

>
> I workarounded this by running unix2dos on harmonyvm.properties.

Ok - we should get that in as eol-native


Actually, the same problem was already fixed for
bootclasspath.properties, and now there is shared properties parser in
luni/common. Also look at HARMONY-1376 - I believe these issues will
be fixed together - just go for a patch if you don't want to wait for
mine ;)



>
> Anyone else using launcher out there? :)

Yes.  We all will be. :)

geir

>
> Pavel.
>
> On 9/14/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote:
>>
>> I now have things building and running with the 1363 patch - more work
>> for the launcher was needed.
>>
>> I'm now using the harmonyvm.properties file in the , and this is
>> working well.
>>
>> I am now able to run tests, although I have one failure in StackTest,
>> and interestingly, the new testsuite that came with the thread manager
>> isn't running.
>>
>> So progress.
>>
>> geir
>>
>> -
>> Terms of use : http://incubator.apache.org/harmony/mailing.html
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[drlvm] gc.LOS hangs on win32

2006-09-18 Thread Weldon Washburn

All,
I have noticed endless loop behavior when running gc.LOS.  It appears to go
into some sort of endless loop when I try, " build test".  Does anyone else
see this problem?

I used MSVC to break into drlvm when it gets stuck.  It shows basically
what's been reported before – a bunch of threads in JITed code.  They keep
making some system call.

Semis/vm/_smoke.tests/reports/gc.LOS_jit.out shows that somehow LOS.java is
in an infinite loop after it prints all 200 dots.  This is rather curious.

Looking at gc/LOS.java, there is a "threads[i].join()" where "i" goes from 0
to 199.  This thread join happens immediately after a "notifyAll()" that is
intended to tell each of the threads to start running.

I moved the trace(".") to immediately after the synchronized statement in
run().  The test now completes successfully.  It might be a bug in the
implementation of Object.wait() and Object.notifyAll() that different HW/SW
combinations are aggrevating???   Below are the mods that I made:

   public void run () {

   //trace(".");

   synchronized (this.getClass()) {

   if (!started)

   try {

   this.getClass().wait();

   } catch (InterruptedException e) {}

   }

   trace(".");  //wjw










--
Weldon Washburn
Intel Middleware Products Division


Re: [test] Jetty integration progress ? (was Re: [classlib] jetty based tests)

2006-09-18 Thread Richard Liang

On 9/18/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote:



Andrew Zhang wrote:
> On 9/18/06, Richard Liang <[EMAIL PROTECTED]> wrote:
>>
>> On 9/18/06, Andrew Zhang <[EMAIL PROTECTED]> wrote:
>> > Hi,
>> >
>> > It's me again. Seems no big progress on jetty. I'd like to take the job
>> if
>> > no one objects. Here are my suggestions:
>>
>> Great :-)
>>
>> >
>> > 1. jetty version:  I suggest that Harmony adopt jetty 6. Because many
>> > 5.xAPIs are deprecated in jetty 6, we'd better follow latest jetty
>> > version.
>>
>> +1
>>
>> >
>> > 2. location to put jetty jars: support module.
>> >
>>
>> Do you mean we will check the jetty jars into Harmony svn?
>
>
> Yes. Is it OK? Or put the jar in depends folder?

Just make it a depends.  We should avoid checking in jars.



Yes. It's good make jetty as a depends, and we could add jetty.jar
into their build scripts if some modules (e.g., luni) require jetty.
Just thinking about another question, how shall we handle the
.classpath of luni in Eclipse? Use external jar"?



>
>> 3. how to write jetty test? I suggest that we could start jetty in any
>> test
>> > if necessary. If we found there are heavy code duplicates, we could
>> extract
>> > them as utility methods in support module. So far, I'd like to write
>> jetty
>> > test directly in each module, because the code is rather simple, only a
>> few
>> > lines.[1] It's also easy to write user-customized handler for
>> > negative tests. Let's make it work, and then make it better. :-)
>> >
>> > Any suggestions/comments/objections?  I volunteer to upload patches
>> when
>> we
>> > reach an agreement.
>> >
>> > Best regards,
>> > Andrew
>> >
>> > [1]
>> > jetty-based test example:
>> > setUp code:
>> > port = Support_PortManager.getNextPort();
>> > Server server = new Server(port);
>> > ResourceHandler resource_handler=new ResourceHandler();
>> > resource_handler.setResourceBase("somewhere");
>> > server.setHandler(resource_handler);
>> > server.start();
>> > tearDown code:
>> > server.stop();
>> >
>> >
>>
>>
>> --
>> Richard Liang
>> China Development Lab, IBM
>>
>> -
>> Terms of use : http://incubator.apache.org/harmony/mailing.html
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>
>

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[drlvm] regression test problems on windows

2006-09-18 Thread Weldon Washburn

All,

I threw away my existing source trees and did an "svn checkout" for both
classlib and dlrvm.   Both classlib and drlvm  were successfully built.
I get different regression test problems on both Linux and Windows::

Windows problems
DRLVM hangs when it tries to execute LOS.java.   More on the
LOS.javaproblem in a new email thread. When LOS is commented out, it
hits the second
problem below.  Anyone else seeing these problems?

  Thanks
 Weldon

PS -- I am getting a premature EOF in ClassloaderTest on Linux.  I suspect
running dos2unix will clear this up -- I think this was mentioned in
harmony-dev emails.


[echo]  PASSED : util.StringIntern
[echo] Please find test classes and results at
C:\t_harmony\drlvm\trunk\bui
ld\win_ia32_msvc_debug\semis/vm/_smoke.tests/

BUILD FAILED
C:\t_harmony\drlvm\trunk\build\make\build.xml:373: The following error
occurred
while executing this line:
C:\t_harmony\drlvm\trunk\build\make\build_component.xml:72: The following
error
occurred while executing this line:
C:\t_harmony\drlvm\trunk\build\win_ia32_msvc_debug\semis\build\targets\smoke.tes
t.xml:33: The following error occurred while executing this line:
C:\t_harmony\drlvm\trunk\build\win_ia32_msvc_debug\semis\build\targets\smoke.tes
t.xml:173: Smoke tests are not passed.




--
Weldon Washburn
Intel Middleware Products Division


Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Alexey Varlamov

2006/9/18, Geir Magnusson Jr. <[EMAIL PROTECTED]>:



Artem Aliev wrote:
> Geir,
>
> The current DRLVM build is still failed.

Because I was waiting for Alexey :)

I'll take your patch though.


Geir,

Sorry for late response, I was busy offline. As now compilation
problem is fixed, I will look into the "canonical" issue in some time.

--
Alexey

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [DRLVM][JIT] can Jitrino.JET call MMTk alloc() instead of C helper?

2006-09-18 Thread Egor Pasko
On the 0x1E9 day of Apache Harmony [EMAIL PROTECTED] wrote:
> Can someone clarify what Jetrnio.JET is please ?

DRLVM has two JIT compilers:
* Jitrino.OPT -- aggressively optimizing compiler (having two IRs,
  high-level and platform-specific optimizations)
* Jitrino.JET -- fast JIT (no IR, simple design, fast compilation,
  improves startup time)

does it anser your question?

> On 9/8/06, Weldon Washburn <[EMAIL PROTECTED]> wrote:
> >
> > On 9/8/06, Mikhail Fursov <[EMAIL PROTECTED]> wrote:
> > >
> > > Weldon,
> > > I added 'alloc' support to JIRA 816 (magic2.zip file)
> > > Now it supports objects allocation only, not arrays. MMTk allocation
> > works
> > > only for class named 'test'  and methods with prefix  'testAlloc'. To
> > turn
> > > it on use "-Xjit jet::alloc4j" option.
> >
> >
> > Thanks!  I will take a look this weekend.
> >
> > I had a problem with implementation: usual 'new' vm helper does vtable
> > field
> > > initialization in allocated object space by itself. Your alloc() method
> > > doesn't.
> > > In the patch in JIRA I added vtable initialization code right after the
> > > alloc() call to JIT, that is actually bad design decision (IMO).
> >
> >
> > You are correct.  Its bad design.  Writing the vtable pointer is not the
> > responsibility of the JIT.  MMTk is somewhat vague on who owns vtable ptr
> > init.  In any case, it looks like the jit should follow the call to
> > alloc()
> > with a call to postAlloc().  I will make sure the postAlloc() code fixes
> > up
> > the vtable ptr.  Its OK to "bend" the typeRef.  All I want is the hard ptr
> > that gets written into the object header.  We will go back later and fix
> > this interface hack.  See below:
> >
> >
> > /**
> >
> > * Perform post-allocation actions. For many allocators none are
> >
> > * required.
> >
> > *
> >
> > * @param ref The newly allocated object
> >
> > * @param typeRef the type reference for the instance being created
> >
> > * @param bytes The size of the space to be allocated (in bytes)
> >
> > * @param allocator The allocator number to be used for this allocation
> >
> > */
> >
> > public void postAlloc(ObjectReference ref, ObjectReference typeRef,
> >
> > int bytes, int allocator) throws InlinePragma {
> >
> >
> >
> >
> >
> > Can we replace the 'alloc()' call with another Java method  that uses
> > > unboxed API and behaves exactly like 'new' helper?
> > >
> > > +The test in the patch throws NullPointerException because no memory is
> > > allocated in alloc() now and JET tries to write vtable data by NULL
> > > address.
> > >
> > >
> > >
> > > On 9/7/06, Weldon Washburn <[EMAIL PROTECTED]> wrote:
> > > >
> > > > At some point soon we need to go multithread.  When can you fix the
> > > > vmmagic
> > > > atomic operations?
> > > >
> > >
> > > I need one more day to estimate the complexity of this move.
> > >
> > >
> > > --
> > > Mikhail Fursov
> > >
> > >
> >
> >
> > --
> > Weldon Washburn
> > Intel Middleware Products Division
> >
> >
> 
> 
> -- 
> www.FaeLLe.com
> www.VikramMohan.com

-- 
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][io][nio] Sync issue of java.io.FileOutputStream and java.nio.channels.FileChannel

2006-09-18 Thread Richard Liang

On 9/18/06, Andrew Zhang <[EMAIL PROTECTED]> wrote:

On 9/18/06, Richard Liang <[EMAIL PROTECTED]> wrote:
>
> Hello,
>
> One Apache Derby test[1] fails on Harmony. It seems that RI always
> sync the FileOutputStream and FileChannel after each "write", which is
> different from Harmony. But there is no explicit description in Java
> Spec. Shall we follow RI? Thanks a lot.
>
> The following test cases could demonstrate this issue.
>
>public void testFile() {
>File derbyLog = new File("d:\\", "derby1.log");
>
>try {
>FileOutputStream fos = new FileOutputStream(derbyLog);
>fos.write(0x41);
>assertEquals(1, derbyLog.length());
>} catch (Exception e) {
>e.printStackTrace();
>}
>}
>
>public void testFileChannel() {
>File derbyLog = new File("d:\\", "derby2.log");
>
>try {
>FileOutputStream fos = new FileOutputStream(derbyLog);
>FileChannel fc = fos.getChannel();
>fc.write(ByteBuffer.wrap(new byte[]{0x41, 0x42}));
>assertEquals(2, derbyLog.length());
>} catch (Exception e) {
>e.printStackTrace();
>}
>}


Interesting. I think we'd better follow RI although it's implementation
dependent. Otherwise, it breaks existing application.

To make test more interesting, I wrote a similar test:


 public void testFile() throws Exception {
File derbyLog = File.createTempFile("test", "log");
derbyLog.deleteOnExit();
RandomAccessFile fos = new RandomAccessFile(derbyLog, "rws");
for (int i = 0; i < 1000; i++) {
fos.write(0x41);
assertEquals(1 + i, derbyLog.length());
}

 }

Run it and you'll be surprised. :-)


Wow! It tooks RI 0.381 seconds, while 21.761 seconds for Harmony. We
shall improve our performance!

Let's have a more further study about this issue.



[1]
> 
http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/logStream.java?view=co
> --
> Richard Liang
> China Development Lab, IBM
>
> -
> Terms of use : http://incubator.apache.org/harmony/mailing.html
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


--
Andrew Zhang
China Software Development Lab, IBM





--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][build] failure?

2006-09-18 Thread Spark Shen

Nathan Beyer 写道:

I just checked in a fix for this. The jarRunner variable needed to be
commented out, as the code that used it was commented out.

Try it now and see if it compiles.
  

Seems caused by restored the capability to do
java -jar foo.jar :-)

And now, it builds. Thanks a lot.

Best regards

-Nathan

  

-Original Message-
From: Spark Shen [mailto:[EMAIL PROTECTED]
Sent: Monday, September 18, 2006 8:49 PM
To: harmony-dev@incubator.apache.org
Subject: [classlib][build] failure?

Hi All:
When building today's(Sep 19, r447671) classlib on window xp, I got the
following error message:
 [exec] main.c
 [exec] ..\shared\main.c(628) : error C2220: warning treated as
error - no o
bject file generated
 [exec] ..\shared\main.c(628) : warning C4101: 'jarRunner' :
unreferenced lo
cal variable
 [exec] NMAKE : fatal error U1077: 'cl' : return code '0x2'
 [exec] Stop.
 [exec] NMAKE : fatal error U1077: '"c:\Program Files\Microsoft
Visual Studi
o .NET 2003\VC7\BIN\nmake.exe"' : return code '0x2'
 [exec] Stop.

BUILD FAILED
C:\spark\harmony\build.xml:95: The following error occurred while
executing this
 line:
C:\spark\harmony\make\build-native.xml:75: The following error occurred
while ex
ecuting this line:
C:\spark\harmony\modules\luni\build.xml:167: The following error
occurred while
executing this line:
C:\spark\harmony\make\properties.xml:258: exec returned: 2

Could any one check it?

Best regards

--
Spark Shen
China Software Development Lab, IBM


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



--
Spark Shen
China Software Development Lab, IBM


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][build] failure?

2006-09-18 Thread Leo Li

Just comment it out since it is just a warning treated as error.
It compiles successfully and runs well.
Maybe it will not lead to such an error on Linux due to the configuration of
make rules.:)

Good luck!


On 9/19/06, Spark Shen <[EMAIL PROTECTED]> wrote:


Hi All:
When building today's(Sep 19, r447671) classlib on window xp, I got the
following error message:
[exec] main.c
[exec] ..\shared\main.c(628) : error C2220: warning treated as
error - no o
bject file generated
[exec] ..\shared\main.c(628) : warning C4101: 'jarRunner' :
unreferenced lo
cal variable
[exec] NMAKE : fatal error U1077: 'cl' : return code '0x2'
[exec] Stop.
[exec] NMAKE : fatal error U1077: '"c:\Program Files\Microsoft
Visual Studi
o .NET 2003\VC7\BIN\nmake.exe"' : return code '0x2'
[exec] Stop.

BUILD FAILED
C:\spark\harmony\build.xml:95: The following error occurred while
executing this
line:
C:\spark\harmony\make\build-native.xml:75: The following error occurred
while ex
ecuting this line:
C:\spark\harmony\modules\luni\build.xml:167: The following error
occurred while
executing this line:
C:\spark\harmony\make\properties.xml:258: exec returned: 2

Could any one check it?

Best regards

--
Spark Shen
China Software Development Lab, IBM


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Leo Li
China Software Development Lab, IBM


RE: [classlib][build] failure?

2006-09-18 Thread Nathan Beyer
I just checked in a fix for this. The jarRunner variable needed to be
commented out, as the code that used it was commented out.

Try it now and see if it compiles.

-Nathan

> -Original Message-
> From: Spark Shen [mailto:[EMAIL PROTECTED]
> Sent: Monday, September 18, 2006 8:49 PM
> To: harmony-dev@incubator.apache.org
> Subject: [classlib][build] failure?
> 
> Hi All:
> When building today's(Sep 19, r447671) classlib on window xp, I got the
> following error message:
>  [exec] main.c
>  [exec] ..\shared\main.c(628) : error C2220: warning treated as
> error - no o
> bject file generated
>  [exec] ..\shared\main.c(628) : warning C4101: 'jarRunner' :
> unreferenced lo
> cal variable
>  [exec] NMAKE : fatal error U1077: 'cl' : return code '0x2'
>  [exec] Stop.
>  [exec] NMAKE : fatal error U1077: '"c:\Program Files\Microsoft
> Visual Studi
> o .NET 2003\VC7\BIN\nmake.exe"' : return code '0x2'
>  [exec] Stop.
> 
> BUILD FAILED
> C:\spark\harmony\build.xml:95: The following error occurred while
> executing this
>  line:
> C:\spark\harmony\make\build-native.xml:75: The following error occurred
> while ex
> ecuting this line:
> C:\spark\harmony\modules\luni\build.xml:167: The following error
> occurred while
> executing this line:
> C:\spark\harmony\make\properties.xml:258: exec returned: 2
> 
> Could any one check it?
> 
> Best regards
> 
> --
> Spark Shen
> China Software Development Lab, IBM
> 
> 
> -
> Terms of use : http://incubator.apache.org/harmony/mailing.html
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] Trouble Building DRLVM

2006-09-18 Thread anavabi
Geir,

Thanks. I got it the DRLVM to build now, but I'm coming across problems running
it.  First, let me mention a couple things about the README that I found, while
trying to build the VM.

1.  I had to remove the revision tag (-r revision_number) for the downloading of
software and tools.  There were two places in the file lnx.properties where I
removed svn's -r tag.  Perhaps this is why I am currently having trouble running
it.  But without removing the -r tag, I kept getting a 'Secure connection
truncated' error message, causing the build to fail.

2.  Geir's comment fixed the other problem I had (i.e. change drlvm.properties
to point to classlib).  I should have seen this one on my own but, just for the
record, I don't think there is anything in the README about this.

After those two things, the build is just fine.  After that, the README starts
talking about ij.sh, which I don't even see in the deploy/jre/bin directory. 
What I do see is a file called java.  I have set my LD_LIBRARY_PATH to
/Harmony/enhanced/drlvm/trunk/build/deploy/jre/bin.
So, here is what happens when I tried to run it:

/Harmony/enhanced/drlvm/trunk/build/deploy/jre/bin>./java 
Harmony Java launcher
Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software
Foundation or its licensors, as applicable.
java [-vm:vmdll -vmdir:dir -D... [-X...]] [args]
java:
/Harmony/enhanced/drlvm/trunk/vm/thread/src/thread_native_fat_monitor.c:183:
monitor_wait_impl: Assertion `saved_recursion<1' failed.
Aborted

Also, if I try to run a java program it just hangs.

After this, I searched the mailing list archives for this problem, and found
this:
http://mail-archives.apache.org/mod_mbox/incubator-harmony-commits/200608.mbox/[EMAIL
 PROTECTED]
So, since my problem looked similar I changed the assertion, but now I get this:

/Harmony/enhanced/drlvm/trunk/build/deploy/jre/bin>./java 
Harmony Java launcher
Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software
Foundation or its licensors, as applicable.
java [-vm:vmdll -vmdir:dir -D... [-X...]] [args]
./java: relocation error:
/Harmony/enhanced/drlvm/trunk/build/deploy/jre/bin/libhyprt.so: symbol
hythread_exit, version HYTHR_0.1 not defined in file libhythr.so with link time
reference

This looks like I may have the wrong version of one of these lib files.  Any
ideas on what I am doing wrong?


Thanks in advance for your help,
Armand

Quoting "Geir Magnusson Jr." <[EMAIL PROTECTED]>:

> 
> 
> Morozova, Nadezhda wrote:
> > Geir, 
> > 
> >> Ok - it's clear I need to doc this.
> > 
> > This is a trigger phrase for me. We have README and Getting Started for
> > DRLVM that are terribly out-of-date. Now, if we update them, and keep
> > them up-to-date, Armand would not need to write to the mailing list but
> > would just follow the guide to successfully build DRLVM :) 
> 
> Indeed!
> 
> > 
> > Can you help me update those docs? README is probably of the greatest
> > urgency. I can use your explanation below, but there are other things in
> > the file that need your attention ;) 
> 
> Sure. :)
> 
> geir
> 
> > 
> > Best regards, 
> > Nadya Morozova
> >  
> > -Original Message-
> > From: Geir Magnusson Jr. [mailto:[EMAIL PROTECTED] 
> > Sent: Monday, September 18, 2006 8:20 PM
> > To: harmony-dev@incubator.apache.org
> > Subject: Re: [drlvm] Trouble Building DRLVM
> > 
> > 
> > 
> > Armand Navabi wrote:
> >> I am new to using Harmony.  I am currently having trouble getting the
> >> DRLVM to build.  I have a successful build of the class library.  I
> > have
> >> the following error when I try to ./build.sh update:
> >>
> >> [mkdir] Created dir:
> >> /u/u12/anavabi/Harmony_VM/build/pre-copied/archives/common/XALAN
> >>  [echo] downloading XALAN from
> > no_settings_in_config_or_environment
> > 
> > Ok - it's clear I need to doc this.
> > 
> > DRLVM depends on knowing where the claslibrary is because it uses 
> > headers and libraries from it when building, and copies stuff when 
> > assembling the jre.
> > 
> > So, by default, the DRLVM assumes that it and the classlibrary are 
> > located as follows, relative to each other :
> > 
> > enhanced/classlib/trunk
> > 
> > enhanced/drlvm/trunk
> > 
> > So if that relationship isn't the way it is on your machine, then you 
> > will have problems like you see, as DRLVM "looks over" into classlib to 
> > see if XALAN is there as a check.
> > 
> > The solution is to go :
> > 
> >   $ cd  drlvm/trunk/build
> >   $ cp drlvm.properties.example drlvm.properties
> > 
> > and them modify drlvm.properties so that it finds the right classlib 
> > root.  I believe it's relative to trunk/build.
> > 
> > When you then type sh build.sh, it will print out the classslib 
> > location.  if it's not right, repeat :)
> > 
> > geir
> > 
> >> BUILD FAILED
> >> /u/u12/anavabi/Harmony_VM/build/make/build.xml:238: The following
> > error
> >> occurred while executing this line:
> >> /u/u12/anavabi/Harmony_VM/build/make/setup.xml:289: The f

[classlib][build] failure?

2006-09-18 Thread Spark Shen

Hi All:
When building today's(Sep 19, r447671) classlib on window xp, I got the 
following error message:

[exec] main.c
[exec] ..\shared\main.c(628) : error C2220: warning treated as 
error - no o

bject file generated
[exec] ..\shared\main.c(628) : warning C4101: 'jarRunner' : 
unreferenced lo

cal variable
[exec] NMAKE : fatal error U1077: 'cl' : return code '0x2'
[exec] Stop.
[exec] NMAKE : fatal error U1077: '"c:\Program Files\Microsoft 
Visual Studi

o .NET 2003\VC7\BIN\nmake.exe"' : return code '0x2'
[exec] Stop.

BUILD FAILED
C:\spark\harmony\build.xml:95: The following error occurred while 
executing this

line:
C:\spark\harmony\make\build-native.xml:75: The following error occurred 
while ex

ecuting this line:
C:\spark\harmony\modules\luni\build.xml:167: The following error 
occurred while

executing this line:
C:\spark\harmony\make\properties.xml:258: exec returned: 2

Could any one check it?

Best regards

--
Spark Shen
China Software Development Lab, IBM


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[drlvm] When running caffinemark, DRLVM now crashes..

2006-09-18 Thread Geir Magnusson Jr
On Ubuntu 6, I was trying to run CaffineMark to see where we are w/ the
lastest set of patches and the big java 5 and other fix patch.  release
build, r447024

top of the stack trace is
Java_org_harmony_awt_nativebridge_linux_X11_XmuLookupStandardColormap

Can anyone repeat this error?

geir

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [General VM] GC strategy:how to garbage collect short-lived objects quickly.

2006-09-18 Thread Leo Li

Hi, Weldon:
Thank you. I can read the code:)

Good luck!

On 9/16/06, Weldon Washburn <[EMAIL PROTECTED]> wrote:


On 9/14/06, Leo Li <[EMAIL PROTECTED]> wrote:
>
> Hi, Xiao-Feng:
> It will be great if VM can adjust its strategy adaptively. However,
as
> a programmer, I would like to have some method to instruct the GC
> strategy.
> If I can, I tend to control things and get definite result, whenever I
am
> programming or tuning . :)
> Besides, where are your GCv5, is it open-sourced? I am quite
> interesting in the topic.


In case it fell between the cracks, Xiao Feng posted initial rough GCV5
files at:

http://issues.apache.org/jira/browse/HARMONY-1428

Also, you may be interested in MMTk.  Its an infrastructure for
experimenting with GC algorithms.  An initial incomplete port is in
drlvm/trunk/vm/MMTk.



Good luck!
>
> --
> Weldon Washburn
> Intel Middleware Products Division





--
Leo Li
China Software Development Lab, IBM


Re: [General VM] GC strategy:how to garbage collect short-lived objects quickly.

2006-09-18 Thread Xiao-Feng Li

On 9/18/06, Oliver Deakin <[EMAIL PROTECTED]> wrote:

Xiao-Feng Li wrote:
> On 9/14/06, Jimmy, Jing Lv <[EMAIL PROTECTED]> wrote:
>> Interesting topic, I'm still dreaming of "free()" in Java (This dream
>> begins at the very beginning when I see Java, as C/C++ is my first
>> program language )However, it seems RI will never give us "free()". :)
>>
>> Only a thought, Java may offer a key word "temp", indicating that this
>> variety can be freed at once.
>
>
> Well, it is not so easy to support "free()" in JVM as it looks like,
> and may not really bring benefit. Even worse, it may introduce unsafe
> code, which was one of the major design goals of Java/JVM. That said,
> I agree that some hints by programmer to assist GC might be an
> interesting topic.

There are always weak references to help out with short lived objects -
you know they will be collected fairly soon (should be within a few
gc cycles) - and soft references for longer lived ones. That's
about as close to free() as youll get for now!

Regards,
Oliver



I don't understand. How can weak references help short-lived objects reclaim?

Thanks,
xiaofeng

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [DRLVM][JIT] can Jitrino.JET call MMTk alloc() instead of C helper?

2006-09-18 Thread FaeLLe

Can someone clarify what Jetrnio.JET is please ?

On 9/8/06, Weldon Washburn <[EMAIL PROTECTED]> wrote:


On 9/8/06, Mikhail Fursov <[EMAIL PROTECTED]> wrote:
>
> Weldon,
> I added 'alloc' support to JIRA 816 (magic2.zip file)
> Now it supports objects allocation only, not arrays. MMTk allocation
works
> only for class named 'test'  and methods with prefix  'testAlloc'. To
turn
> it on use "-Xjit jet::alloc4j" option.


Thanks!  I will take a look this weekend.

I had a problem with implementation: usual 'new' vm helper does vtable
field
> initialization in allocated object space by itself. Your alloc() method
> doesn't.
> In the patch in JIRA I added vtable initialization code right after the
> alloc() call to JIT, that is actually bad design decision (IMO).


You are correct.  Its bad design.  Writing the vtable pointer is not the
responsibility of the JIT.  MMTk is somewhat vague on who owns vtable ptr
init.  In any case, it looks like the jit should follow the call to
alloc()
with a call to postAlloc().  I will make sure the postAlloc() code fixes
up
the vtable ptr.  Its OK to "bend" the typeRef.  All I want is the hard ptr
that gets written into the object header.  We will go back later and fix
this interface hack.  See below:


/**

* Perform post-allocation actions. For many allocators none are

* required.

*

* @param ref The newly allocated object

* @param typeRef the type reference for the instance being created

* @param bytes The size of the space to be allocated (in bytes)

* @param allocator The allocator number to be used for this allocation

*/

public void postAlloc(ObjectReference ref, ObjectReference typeRef,

int bytes, int allocator) throws InlinePragma {





Can we replace the 'alloc()' call with another Java method  that uses
> unboxed API and behaves exactly like 'new' helper?
>
> +The test in the patch throws NullPointerException because no memory is
> allocated in alloc() now and JET tries to write vtable data by NULL
> address.
>
>
>
> On 9/7/06, Weldon Washburn <[EMAIL PROTECTED]> wrote:
> >
> > At some point soon we need to go multithread.  When can you fix the
> > vmmagic
> > atomic operations?
> >
>
> I need one more day to estimate the complexity of this move.
>
>
> --
> Mikhail Fursov
>
>


--
Weldon Washburn
Intel Middleware Products Division





--
www.FaeLLe.com
www.VikramMohan.com


Re: [drlvm] Jars work again, and other notes

2006-09-18 Thread Gregory Shimansky
On Monday 18 September 2006 20:29 Geir Magnusson Jr. wrote:
> I'm at a conference today, but in my idle bits of time, I restored the
> capability to do
>
> java -jar foo.jar
>
> I added a little JarRunner class to our kernel classes, but we should
> move this to classlib, as there's nothing DRLVM specific about it.  I
> also had to modify the launcher to get this to work, as there's a
> codepath in the launcher that makes DRLVM crash hard.  I've commented it
> out because it was just a safety check, but it would be good for us to
> figure out what it is.  Broken windows, and all that.
>
> One thing I noticed is that we now have to set JAVA_HOME correctly.  We
> never had to do this before, and from the stacktraces generated, I
> haven't a clue why.  Something for someone to figure out.
>
> Anyway, I'm going to test a bit more and then do a new set of snapshots.

There is a compilation warning (treated as error) for the launcher on windows. 
I think it doesn't deserve as JIRA since it is trivial to fix:

 [exec] ..\shared\main.c(628) : error C2220: warning treated as error - no 
object file generated
 [exec] ..\shared\main.c(628) : warning C4101: 'jarRunner' : unreferenced 
local variable

With the following patch it works ok:

Index: modules/luni/src/main/native/launcher/shared/main.c
===
--- modules/luni/src/main/native/launcher/shared/main.c (revision 447550)
+++ modules/luni/src/main/native/launcher/shared/main.c (working copy)
@@ -625,7 +625,6 @@
 {
   if (isStandaloneJar)
 {
-  jclass jarRunner;
   jclass clazz;
   jmethodID mID;
   jstring jStrObject;

-- 
Gregory Shimansky, Intel Middleware Products Division

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][luni][HashMap]Avoid to expand data array in HashMap.putAll more than once.

2006-09-18 Thread Tim Ellison
Go for it.

Tim

Leo Li wrote:
> Hi, all:
> Current implementation of HashMap.putAll() in Harmony just calls
> super.putAll() which ultimately will call HashMap.put(), while this way
> might lead to expand the backing data array more than once if the elements
> in the added Map is sufficiently large. However, the situation is able to
> be avoided, since we actually know the size of the added Map, thus the
> expected HashMap capacity.
> If no one objects, I will add an expected capacity argument in internal
> rehash() method as rehash(int expectedCapacity) and rewrite  the
> HashMap.putAll().
> 
>Good luck!
> 

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][vmi] VMI classes for Thread/Object manipulation for java.util.concurrent

2006-09-18 Thread Tim Ellison
Thanks Nathan -- I'll take a look and post comments back here.

Regards,
Tim

Nathan Beyer wrote:
> I've added some classes[1][2] to luni-kernel in the
> org.apache.harmony.kernel.vm package that are intended the VMI replacement
> for the sun.misc.Unsafe class. The intent is to provide a VMI class to
> support java.util.concurrent. Initially this will be done by implementing
> the sun.misc.Unsafe in 'suncompat' module in terms of these new classes.
> 
>  
> 
> For the most part, the methods are essentially the subset of Unsafe that's
> needed for java.util.concurrent. I've separated the methods into two
> classes; Threads [1] for the threading features and Objects [2] for the
> object manipulation features. My initial thought is that Threads may be
> extended to provide additional support needed for lang-management features.
> 
>  
> 
> Please take a look at the classes and provide some feedback.
> 
>  
> 
> [1]
> http://svn.apache.org/repos/asf/incubator/harmony/enhanced/classlib/trunk/mo
> dules/luni-kernel/src/main/java/org/apache/harmony/kernel/vm/Threads.java
> 
> [2]
> http://svn.apache.org/repos/asf/incubator/harmony/enhanced/classlib/trunk/mo
> dules/luni-kernel/src/main/java/org/apache/harmony/kernel/vm/Objects.java
> 
>  
> 
> 

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] Trouble Building DRLVM

2006-09-18 Thread Geir Magnusson Jr.



Morozova, Nadezhda wrote:
Geir, 


Ok - it's clear I need to doc this.


This is a trigger phrase for me. We have README and Getting Started for
DRLVM that are terribly out-of-date. Now, if we update them, and keep
them up-to-date, Armand would not need to write to the mailing list but
would just follow the guide to successfully build DRLVM :) 


Indeed!



Can you help me update those docs? README is probably of the greatest
urgency. I can use your explanation below, but there are other things in
the file that need your attention ;) 


Sure. :)

geir



Best regards, 
Nadya Morozova
 
-Original Message-
From: Geir Magnusson Jr. [mailto:[EMAIL PROTECTED] 
Sent: Monday, September 18, 2006 8:20 PM

To: harmony-dev@incubator.apache.org
Subject: Re: [drlvm] Trouble Building DRLVM



Armand Navabi wrote:

I am new to using Harmony.  I am currently having trouble getting the
DRLVM to build.  I have a successful build of the class library.  I

have

the following error when I try to ./build.sh update:

[mkdir] Created dir:
/u/u12/anavabi/Harmony_VM/build/pre-copied/archives/common/XALAN
 [echo] downloading XALAN from

no_settings_in_config_or_environment

Ok - it's clear I need to doc this.

DRLVM depends on knowing where the claslibrary is because it uses 
headers and libraries from it when building, and copies stuff when 
assembling the jre.


So, by default, the DRLVM assumes that it and the classlibrary are 
located as follows, relative to each other :


enhanced/classlib/trunk

enhanced/drlvm/trunk

So if that relationship isn't the way it is on your machine, then you 
will have problems like you see, as DRLVM "looks over" into classlib to 
see if XALAN is there as a check.


The solution is to go :

  $ cd  drlvm/trunk/build
  $ cp drlvm.properties.example drlvm.properties

and them modify drlvm.properties so that it finds the right classlib 
root.  I believe it's relative to trunk/build.


When you then type sh build.sh, it will print out the classslib 
location.  if it's not right, repeat :)


geir


BUILD FAILED
/u/u12/anavabi/Harmony_VM/build/make/build.xml:238: The following

error

occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:289: The following

error

occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:291: The following

error

occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:462: Warning: Could not
find file


/u/u12/anavabi/Harmony_VM/build/make/no_settings_in_config_or_environmen
t

to copy.

Not sure why the ${remote.resource.archive} variable in setup.xml is
no_settings_in_config_or_environment.   Any help is appreciated.

Thanks,
Armand

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [jira] Updated: (HARMONY-1409) [classlib][beans] add missing get/setSource methods to PropertyEditorSupport

2006-09-18 Thread Alexei Zakharov

Stepan,

I 've filed it as HARMONY-1491. As far as I understand someone should
close it according to the latest "Non-bug differences from RI" policy.

Thanks,

2006/9/13, Stepan Mishura <[EMAIL PROTECTED]>:

On 9/13/06, Alexei Zakharov wrote:
>
> Ok, Stepan, in this case I suggest to leave the check and rise the
> additional "Non-bug differences from RI" JIRA (I can do if no one
> objects). I don't really think there are many applications that rely
> on this silent RI behavior, and IMHO we should not care until we
> encounter one.



Agree. Go forward with JIRA.

-Stepan.

Regards,
>
> 2006/9/12, Stepan Mishura <[EMAIL PROTECTED]>:
> > Just have found in java.beans package description:
> > "Unless explicitly stated, null values or empty Strings are not valid
> > parameters for the methods in this package. You may expect to see
> exceptions
> > if these parameters are used."
> >
> > So it is a bug in RI.
> >
> > -Stepan.
> >
> > On 9/12/06, Stepan Mishura wrote:
> > >
> > >  Alexei,
> > >
> > > We have the following RI behaviour here:
> > > 1) Constructor doesn't allow 'null' value and throws NPE
> > > 2) setSource allow 'null' value
> > >
> > > This looks inconsistent - to assign soure null value we can not use
> > > constuctor directly!
> > >
> > > Thanks,
> > > Stepan.
> > >
> > >
> > >  On 9/12/06, Alexei Zakharov wrote:
> > > >
> > > > Hi Stepan,
> > > >
> > > > Thank you for your attention to my patch first of all. IMHO
> everything
> > > > is ok except for the null-check you add to the setSource() method.
> It
> > > > seems RI does not check for null in this case. At least your
> > > > regression test fails on Sun JDK 1.5.0_06:
> > > >
> > > > No expected NullPointerException
> > > > junit.framework.AssertionFailedError: No expected
> NullPointerException
> > > >at
> > > >
> 
org.apache.harmony.beans.tests.java.beans.PropertyEditorSupportTest.test_setSourceLjava_lang_Object
> > > > (PropertyEditorSupportTest.java:291)
> > > >
> > > > Thanks,
> > > >
> > > > 2006/9/12, Stepan Mishura (JIRA) < [EMAIL PROTECTED]>:
> > > > > [ http://issues.apache.org/jira/browse/HARMONY-1409?page=all ]
> > > > >
> > > > > Stepan Mishura updated HARMONY-1409:
> > > > > 
> > > > >
> > > > >Summary: [classlib][beans] add missing get/setSource methods to
> > > > PropertyEditorSupport  (was: [classlib][beans] PropertyEditorSupport
> > > > cleanup)
> > > > >
> > > > > > [classlib][beans] add missing get/setSource methods to
> > > > PropertyEditorSupport
> > > > > >
> > > >
> 
> > > > > >
> > > > > > Key: HARMONY-1409
> > > > > > URL:
> > > > http://issues.apache.org/jira/browse/HARMONY-1409
> > > > > > Project: Harmony
> > > > > >  Issue Type: Improvement
> > > > > >  Components: Classlib
> > > > > > Environment: ws2003
> > > > > >Reporter: Alexei Zakharov
> > > > > > Assigned To: Stepan Mishura
> > > > > > Attachments: PropertyEditorSupport.patch
> > > > > >
> > > > > >
> > > > > > Attached patch adds two missing API methods that were introduced
> in
> > > > Java 1.5 API. In addition to that all unnecessary javadoc comments
> are
> > > > removed (@author and etc.), the coding style is corrected.
> > > > >
> > > > > --
> > > > > This message is automatically generated by JIRA.
> > > > > -
> > > > > If you think it was sent incorrectly contact one of the
> > > > administrators:
> http://issues.apache.org/jira/secure/Administrators.jspa
> > > > > -
> > > > > For more information on JIRA, see:
> > > > http://www.atlassian.com/software/jira
>
>
--
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Alexei Zakharov,
Intel Middleware Product Division

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [drlvm] Trouble Building DRLVM

2006-09-18 Thread Morozova, Nadezhda
Geir, 

> Ok - it's clear I need to doc this.

This is a trigger phrase for me. We have README and Getting Started for
DRLVM that are terribly out-of-date. Now, if we update them, and keep
them up-to-date, Armand would not need to write to the mailing list but
would just follow the guide to successfully build DRLVM :) 

Can you help me update those docs? README is probably of the greatest
urgency. I can use your explanation below, but there are other things in
the file that need your attention ;) 

Best regards, 
Nadya Morozova
 
-Original Message-
From: Geir Magnusson Jr. [mailto:[EMAIL PROTECTED] 
Sent: Monday, September 18, 2006 8:20 PM
To: harmony-dev@incubator.apache.org
Subject: Re: [drlvm] Trouble Building DRLVM



Armand Navabi wrote:
> I am new to using Harmony.  I am currently having trouble getting the
> DRLVM to build.  I have a successful build of the class library.  I
have
> the following error when I try to ./build.sh update:
> 
> [mkdir] Created dir:
> /u/u12/anavabi/Harmony_VM/build/pre-copied/archives/common/XALAN
>  [echo] downloading XALAN from
no_settings_in_config_or_environment

Ok - it's clear I need to doc this.

DRLVM depends on knowing where the claslibrary is because it uses 
headers and libraries from it when building, and copies stuff when 
assembling the jre.

So, by default, the DRLVM assumes that it and the classlibrary are 
located as follows, relative to each other :

enhanced/classlib/trunk

enhanced/drlvm/trunk

So if that relationship isn't the way it is on your machine, then you 
will have problems like you see, as DRLVM "looks over" into classlib to 
see if XALAN is there as a check.

The solution is to go :

  $ cd  drlvm/trunk/build
  $ cp drlvm.properties.example drlvm.properties

and them modify drlvm.properties so that it finds the right classlib 
root.  I believe it's relative to trunk/build.

When you then type sh build.sh, it will print out the classslib 
location.  if it's not right, repeat :)

geir

> 
> BUILD FAILED
> /u/u12/anavabi/Harmony_VM/build/make/build.xml:238: The following
error
> occurred while executing this line:
> /u/u12/anavabi/Harmony_VM/build/make/setup.xml:289: The following
error
> occurred while executing this line:
> /u/u12/anavabi/Harmony_VM/build/make/setup.xml:291: The following
error
> occurred while executing this line:
> /u/u12/anavabi/Harmony_VM/build/make/setup.xml:462: Warning: Could not
> find file
>
/u/u12/anavabi/Harmony_VM/build/make/no_settings_in_config_or_environmen
t
> to copy.
> 
> Not sure why the ${remote.resource.archive} variable in setup.xml is
> no_settings_in_config_or_environment.   Any help is appreciated.
> 
> Thanks,
> Armand
> 
> -
> Terms of use : http://incubator.apache.org/harmony/mailing.html
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[drlvm] Jars work again, and other notes

2006-09-18 Thread Geir Magnusson Jr.
I'm at a conference today, but in my idle bits of time, I restored the 
capability to do


   java -jar foo.jar

I added a little JarRunner class to our kernel classes, but we should 
move this to classlib, as there's nothing DRLVM specific about it.  I 
also had to modify the launcher to get this to work, as there's a 
codepath in the launcher that makes DRLVM crash hard.  I've commented it 
out because it was just a safety check, but it would be good for us to 
figure out what it is.  Broken windows, and all that.


One thing I noticed is that we now have to set JAVA_HOME correctly.  We 
never had to do this before, and from the stacktraces generated, I 
haven't a clue why.  Something for someone to figure out.


Anyway, I'm going to test a bit more and then do a new set of snapshots.

geir

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Geir Magnusson Jr.



Artem Aliev wrote:

Geir,

The current DRLVM build is still failed.


Because I was waiting for Alexey :)

I'll take your patch though.

geir


I attach patch  for the current state of VM.
Could you please apply it or commit  new version of natives_support.cpp

Thanks
Artem


On 9/18/06, Alexey Varlamov <[EMAIL PROTECTED]> wrote:

Geir,

The DRLVM build is broken now on gcc3.3.3 (SUSE9):

build.native.cpp:
   [cc] 135 total files to be compiled.
   [cc] drlvm/vm/vmcore/src/util/natives_support.cpp: In
   [cc]function `apr_dso_handle_t* natives_load_library(const




Index: vm/vmcore/src/util/natives_support.cpp
===
--- vm/vmcore/src/util/natives_support.cpp  (revision 447423)
+++ vm/vmcore/src/util/natives_support.cpp  (working copy)
@@ -203,7 +203,12 @@
 
 char *localLibName = (char *) library_name;

 NativeLibraryHandle returnCode = NULL;
-
+NativeLibInfo* pfound;

+NativeLibInfo* pinfo;
+NativeLibraryHandle handle;
+apr_status_t apr_status; 
+Global_Env *ge;

+jint UNREF res;
 #ifdef PLATFORM_NT
 TRACE2("init", "### lib name = " << library_name);
 
@@ -221,7 +226,7 @@
 
 jni_libs.lock._lock();
 
-NativeLibInfo* pfound = search_library_list(localLibName);

+pfound = search_library_list(localLibName);
 
 if (pfound)

 {
@@ -237,8 +242,7 @@
 *just_loaded = true;
 
 // library was not loaded previously, try to load it

-NativeLibraryHandle handle;
-apr_status_t apr_status = port_dso_load_ex(&handle, localLibName,
+apr_status = port_dso_load_ex(&handle, localLibName,
PORT_DSO_BIND_DEFER, 
jni_libs.ppool);
 if (APR_SUCCESS != apr_status)
 {
@@ -255,7 +259,7 @@
 goto NATIVES_LOAD_LIBRARY_EXIT;
 }
 
-NativeLibInfo* pinfo = (NativeLibInfo*)apr_palloc(jni_libs.ppool, sizeof(NativeLibInfo));

+pinfo = (NativeLibInfo*)apr_palloc(jni_libs.ppool, sizeof(NativeLibInfo));
 if (NULL == pinfo)
 {
 apr_dso_unload(handle);
@@ -270,7 +274,7 @@
 
 pinfo->handle = handle;
 
-Global_Env *ge = VM_Global_State::loader_env;

+ge = VM_Global_State::loader_env;
 pinfo->name = ge->string_pool.lookup(localLibName);
 
 pinfo->next = jni_libs.lib_info_list;

@@ -278,7 +282,7 @@
 
 jni_libs.lock._unlock();
 
-jint UNREF res = find_call_JNI_OnLoad(pinfo->handle); // What to do with result???

+res = find_call_JNI_OnLoad(pinfo->handle); // What to do with result???
 
 *pstatus = APR_SUCCESS;
 





-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] Trouble Building DRLVM

2006-09-18 Thread Geir Magnusson Jr.



Armand Navabi wrote:

I am new to using Harmony.  I am currently having trouble getting the
DRLVM to build.  I have a successful build of the class library.  I have
the following error when I try to ./build.sh update:

[mkdir] Created dir:
/u/u12/anavabi/Harmony_VM/build/pre-copied/archives/common/XALAN
 [echo] downloading XALAN from no_settings_in_config_or_environment


Ok - it's clear I need to doc this.

DRLVM depends on knowing where the claslibrary is because it uses 
headers and libraries from it when building, and copies stuff when 
assembling the jre.


So, by default, the DRLVM assumes that it and the classlibrary are 
located as follows, relative to each other :


   enhanced/classlib/trunk

   enhanced/drlvm/trunk

So if that relationship isn't the way it is on your machine, then you 
will have problems like you see, as DRLVM "looks over" into classlib to 
see if XALAN is there as a check.


The solution is to go :

 $ cd  drlvm/trunk/build
 $ cp drlvm.properties.example drlvm.properties

and them modify drlvm.properties so that it finds the right classlib 
root.  I believe it's relative to trunk/build.


When you then type sh build.sh, it will print out the classslib 
location.  if it's not right, repeat :)


geir



BUILD FAILED
/u/u12/anavabi/Harmony_VM/build/make/build.xml:238: The following error
occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:289: The following error
occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:291: The following error
occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:462: Warning: Could not
find file
/u/u12/anavabi/Harmony_VM/build/make/no_settings_in_config_or_environment
to copy.

Not sure why the ${remote.resource.archive} variable in setup.xml is
no_settings_in_config_or_environment.   Any help is appreciated.

Thanks,
Armand

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Geir Magnusson Jr.



Pavel Pervov wrote:

Tried it on Windows and found the problem which, as it looks like, have
never been caught before.
As I discovered, launcher uses platform specific line separators to parse
harmonyvm.properties on a specific platform. But haromynvm.properties, 
which

is copied into deploy, has unix line endings and is skipped. As the result,
EM can't initialize.'


A ha!



I workarounded this by running unix2dos on harmonyvm.properties.


Ok - we should get that in as eol-native



Anyone else using launcher out there? :)


Yes.  We all will be. :)

geir



Pavel.

On 9/14/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote:


I now have things building and running with the 1363 patch - more work
for the launcher was needed.

I'm now using the harmonyvm.properties file in the , and this is
working well.

I am now able to run tests, although I have one failure in StackTest,
and interestingly, the new testsuite that came with the thread manager
isn't running.

So progress.

geir

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Artem Aliev

Geir,

The current DRLVM build is still failed.
I attach patch  for the current state of VM.
Could you please apply it or commit  new version of natives_support.cpp

Thanks
Artem


On 9/18/06, Alexey Varlamov <[EMAIL PROTECTED]> wrote:

Geir,

The DRLVM build is broken now on gcc3.3.3 (SUSE9):

build.native.cpp:
   [cc] 135 total files to be compiled.
   [cc] drlvm/vm/vmcore/src/util/natives_support.cpp: In
   [cc]function `apr_dso_handle_t* natives_load_library(const
Index: vm/vmcore/src/util/natives_support.cpp
===
--- vm/vmcore/src/util/natives_support.cpp	(revision 447423)
+++ vm/vmcore/src/util/natives_support.cpp	(working copy)
@@ -203,7 +203,12 @@
 
 char *localLibName = (char *) library_name;
 NativeLibraryHandle returnCode = NULL;
-
+NativeLibInfo* pfound;
+NativeLibInfo* pinfo;
+NativeLibraryHandle handle;
+apr_status_t apr_status; 
+Global_Env *ge;
+jint UNREF res;
 #ifdef PLATFORM_NT
 TRACE2("init", "### lib name = " << library_name);
 
@@ -221,7 +226,7 @@
 
 jni_libs.lock._lock();
 
-NativeLibInfo* pfound = search_library_list(localLibName);
+pfound = search_library_list(localLibName);
 
 if (pfound)
 {
@@ -237,8 +242,7 @@
 *just_loaded = true;
 
 // library was not loaded previously, try to load it
-NativeLibraryHandle handle;
-apr_status_t apr_status = port_dso_load_ex(&handle, localLibName,
+apr_status = port_dso_load_ex(&handle, localLibName,
PORT_DSO_BIND_DEFER, jni_libs.ppool);
 if (APR_SUCCESS != apr_status)
 {
@@ -255,7 +259,7 @@
 goto NATIVES_LOAD_LIBRARY_EXIT;
 }
 
-NativeLibInfo* pinfo = (NativeLibInfo*)apr_palloc(jni_libs.ppool, sizeof(NativeLibInfo));
+pinfo = (NativeLibInfo*)apr_palloc(jni_libs.ppool, sizeof(NativeLibInfo));
 if (NULL == pinfo)
 {
 apr_dso_unload(handle);
@@ -270,7 +274,7 @@
 
 pinfo->handle = handle;
 
-Global_Env *ge = VM_Global_State::loader_env;
+ge = VM_Global_State::loader_env;
 pinfo->name = ge->string_pool.lookup(localLibName);
 
 pinfo->next = jni_libs.lib_info_list;
@@ -278,7 +282,7 @@
 
 jni_libs.lock._unlock();
 
-jint UNREF res = find_call_JNI_OnLoad(pinfo->handle); // What to do with result???
+res = find_call_JNI_OnLoad(pinfo->handle); // What to do with result???
 
 *pstatus = APR_SUCCESS;
 
-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: [drlvm][jit] MMTk-style magics implementation in Jitrino.OPT compiler

2006-09-18 Thread Weldon Washburn

On 9/18/06, Mikhail Fursov <[EMAIL PROTECTED]> wrote:


All,
I'm working on the implementation of MMTk's
"org.vmmagic.unboxed"
package functionality in Jitrino.OPT compiler.
If you are interested to participate in the development, I propose to
discuss all details in this mail thread.

The current state:
Part of the functionality of vmmagic package is done in the magic1.patch.
See JIRA 1489 (http://issues.apache.org/jira/browse/HARMONY-1489)

Tasks that are not finished:
1) Support of unsigned types.
2) Support of atomic prepare/attempt operations
3) Testing suit for vmmagic package.
4) EM64T support


I hope items 1) and 2) will be finished in a week or even sooner if
someone
helps. After it's done the item 4) won't be a problem.
I think that the problem (at least for me) is item 3): we need a test
suite
for vmmagic package. I saw several tests in Weldon's drlvm/trunk/vm/MMTk
folder, but this is not sufficient to cover the whole vmmagic package.
Does
anyone know/can_write a reliability test suite for vmmagic we can use in
Harmony?




A regression test for vmmagic exists.  I have been trying to get it donated
and posted to MMTk repository.  Its been a couple of months and no
response.  I will find out if it can be donated to Apache.

--

Mikhail Fursov





--
Weldon Washburn
Intel Middleware Products Division


[drlvm] Trouble Building DRLVM

2006-09-18 Thread Armand Navabi
I am new to using Harmony.  I am currently having trouble getting the
DRLVM to build.  I have a successful build of the class library.  I have
the following error when I try to ./build.sh update:

[mkdir] Created dir:
/u/u12/anavabi/Harmony_VM/build/pre-copied/archives/common/XALAN
 [echo] downloading XALAN from no_settings_in_config_or_environment

BUILD FAILED
/u/u12/anavabi/Harmony_VM/build/make/build.xml:238: The following error
occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:289: The following error
occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:291: The following error
occurred while executing this line:
/u/u12/anavabi/Harmony_VM/build/make/setup.xml:462: Warning: Could not
find file
/u/u12/anavabi/Harmony_VM/build/make/no_settings_in_config_or_environment
to copy.

Not sure why the ${remote.resource.archive} variable in setup.xml is
no_settings_in_config_or_environment.   Any help is appreciated.

Thanks,
Armand

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [jira] Commented: (HARMONY-286) Add build-java and build-native targets to main build.xml

2006-09-18 Thread Oliver Deakin

I wouldnt say wrong - just a different opinion :)

Ill get a patch together for it and attach it to the old JIRA.

Regards,
Oliver

Alexey Petrenko wrote:

OK, guys.
Seems I was wrong :)

Let's create a patch and apply it!

SY, Alexey

2006/9/18, Oliver Deakin <[EMAIL PROTECTED]>:

Hi Alexey,

At the time I was working on native code all over the place, and
since rebuilding our java classes takes a very long time on my
Windows box I found it useful to be able to just build all the natives.

I dont mind if this issue is closed as it's not really a major problem
(also the patch is probably very out of date, although it should be 
fairly

easy to create a new one) - however, I think it is something that
is still useful, and if we can add it without much effort, then
why not?

As for using "ant -f make/build-java.xml -Dbuild.module=awt build",
I believe that we discussed a little while ago that we would try to put
all main build targets into the top level build.xml, so that no 
developer

needs to directly execute the build scripts under make. IMHO it is
preferable to call "ant -Dbuild.module=awt build-java" in this case.

If there is still interest in this feature, I can create an up-to-date
patch and attach it to the JIRA.

Regards,
Oliver

Alexey Petrenko wrote:
> Guys,
>
> I suggest to close this issue as "won't fix" because current build
> allows to build only specified module. And it is enough.
>
> Thoughts? Objections?
>
> SY, Alexey
>
> 2006/9/15, Alexey Petrenko (JIRA) <[EMAIL PROTECTED]>:
>>[
>> 
http://issues.apache.org/jira/browse/HARMONY-286?page=comments#action_12434930 


>> ]
>>
>> Alexey Petrenko commented on HARMONY-286:
>> -
>>
>> Current build allows to build only specified module. So I think that
>> this bug should be closed as "won't fix"
>>
>> > Add build-java and build-native targets to main build.xml
>> > -
>> >
>> > Key: HARMONY-286
>> > URL: 
http://issues.apache.org/jira/browse/HARMONY-286

>> > Project: Harmony
>> >  Issue Type: Improvement
>> >  Components: Classlib
>> >Reporter: Oliver Deakin
>> >Priority: Minor
>> > Attachments: build.targets.diff
>> >
>> >
>> > At the moment there are no targets in make/build.xml to clean and
>> build only the native code or only the java code in classlib.
>> > I think it would be useful to have these as separate targets for
>> convenience, so that when you are only working on Java code you need
>> not recompile the native code entirely everytime, and vice versa.
>> > I will attach a patch with the necessary changes
>>
>> --
>> This message is automatically generated by JIRA.
>> -
>> If you think it was sent incorrectly contact one of the
>> administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa

>> -
>> For more information on JIRA, see:
>> http://www.atlassian.com/software/jira
>>
>>
>>
>
>

--
Oliver Deakin
IBM United Kingdom Limited


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]







--
Oliver Deakin
IBM United Kingdom Limited


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Pavel Pervov

Tried it on Windows and found the problem which, as it looks like, have
never been caught before.
As I discovered, launcher uses platform specific line separators to parse
harmonyvm.properties on a specific platform. But haromynvm.properties, which
is copied into deploy, has unix line endings and is skipped. As the result,
EM can't initialize.

I workarounded this by running unix2dos on harmonyvm.properties.

Anyone else using launcher out there? :)

Pavel.

On 9/14/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote:


I now have things building and running with the 1363 patch - more work
for the launcher was needed.

I'm now using the harmonyvm.properties file in the , and this is
working well.

I am now able to run tests, although I have one failure in StackTest,
and interestingly, the new testsuite that came with the thread manager
isn't running.

So progress.

geir

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




[drlvm][jit] MMTk-style magics implementation in Jitrino.OPT compiler

2006-09-18 Thread Mikhail Fursov

All,
I'm working on the implementation of MMTk's
"org.vmmagic.unboxed"
package functionality in Jitrino.OPT compiler.
If you are interested to participate in the development, I propose to
discuss all details in this mail thread.

The current state:
Part of the functionality of vmmagic package is done in the magic1.patch.
See JIRA 1489 (http://issues.apache.org/jira/browse/HARMONY-1489)

Tasks that are not finished:
1) Support of unsigned types.
2) Support of atomic prepare/attempt operations
3) Testing suit for vmmagic package.
4) EM64T support


I hope items 1) and 2) will be finished in a week or even sooner if someone
helps. After it's done the item 4) won't be a problem.
I think that the problem (at least for me) is item 3): we need a test suite
for vmmagic package. I saw several tests in Weldon's drlvm/trunk/vm/MMTk
folder, but this is not sufficient to cover the whole vmmagic package. Does
anyone know/can_write a reliability test suite for vmmagic we can use in
Harmony?



--
Mikhail Fursov


Re: [jira] Commented: (HARMONY-286) Add build-java and build-native targets to main build.xml

2006-09-18 Thread Alexey Petrenko

OK, guys.
Seems I was wrong :)

Let's create a patch and apply it!

SY, Alexey

2006/9/18, Oliver Deakin <[EMAIL PROTECTED]>:

Hi Alexey,

At the time I was working on native code all over the place, and
since rebuilding our java classes takes a very long time on my
Windows box I found it useful to be able to just build all the natives.

I dont mind if this issue is closed as it's not really a major problem
(also the patch is probably very out of date, although it should be fairly
easy to create a new one) - however, I think it is something that
is still useful, and if we can add it without much effort, then
why not?

As for using "ant -f make/build-java.xml -Dbuild.module=awt build",
I believe that we discussed a little while ago that we would try to put
all main build targets into the top level build.xml, so that no developer
needs to directly execute the build scripts under make. IMHO it is
preferable to call "ant -Dbuild.module=awt build-java" in this case.

If there is still interest in this feature, I can create an up-to-date
patch and attach it to the JIRA.

Regards,
Oliver

Alexey Petrenko wrote:
> Guys,
>
> I suggest to close this issue as "won't fix" because current build
> allows to build only specified module. And it is enough.
>
> Thoughts? Objections?
>
> SY, Alexey
>
> 2006/9/15, Alexey Petrenko (JIRA) <[EMAIL PROTECTED]>:
>>[
>> 
http://issues.apache.org/jira/browse/HARMONY-286?page=comments#action_12434930
>> ]
>>
>> Alexey Petrenko commented on HARMONY-286:
>> -
>>
>> Current build allows to build only specified module. So I think that
>> this bug should be closed as "won't fix"
>>
>> > Add build-java and build-native targets to main build.xml
>> > -
>> >
>> > Key: HARMONY-286
>> > URL: http://issues.apache.org/jira/browse/HARMONY-286
>> > Project: Harmony
>> >  Issue Type: Improvement
>> >  Components: Classlib
>> >Reporter: Oliver Deakin
>> >Priority: Minor
>> > Attachments: build.targets.diff
>> >
>> >
>> > At the moment there are no targets in make/build.xml to clean and
>> build only the native code or only the java code in classlib.
>> > I think it would be useful to have these as separate targets for
>> convenience, so that when you are only working on Java code you need
>> not recompile the native code entirely everytime, and vice versa.
>> > I will attach a patch with the necessary changes
>>
>> --
>> This message is automatically generated by JIRA.
>> -
>> If you think it was sent incorrectly contact one of the
>> administrators: http://issues.apache.org/jira/secure/Administrators.jspa
>> -
>> For more information on JIRA, see:
>> http://www.atlassian.com/software/jira
>>
>>
>>
>
>

--
Oliver Deakin
IBM United Kingdom Limited


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Alexey A. Petrenko
Intel Middleware Products Division

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [General VM] GC strategy:how to garbage collect short-lived objects quickly.

2006-09-18 Thread Oliver Deakin

Xiao-Feng Li wrote:

On 9/14/06, Jimmy, Jing Lv <[EMAIL PROTECTED]> wrote:

Interesting topic, I'm still dreaming of "free()" in Java (This dream
begins at the very beginning when I see Java, as C/C++ is my first
program language )However, it seems RI will never give us "free()". :)

Only a thought, Java may offer a key word "temp", indicating that this
variety can be freed at once.



Well, it is not so easy to support "free()" in JVM as it looks like,
and may not really bring benefit. Even worse, it may introduce unsafe
code, which was one of the major design goals of Java/JVM. That said,
I agree that some hints by programmer to assist GC might be an
interesting topic.


There are always weak references to help out with short lived objects -
you know they will be collected fairly soon (should be within a few
gc cycles) - and soft references for longer lived ones. That's
about as close to free() as youll get for now!

Regards,
Oliver


Thanks,
xiaofeng


--

Best Regards!

Jimmy, Jing Lv
China Software Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
Oliver Deakin
IBM United Kingdom Limited


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [DRLVM] Integration checks (was building from svn on FC5)

2006-09-18 Thread Anton Luht

Hello,

I've created a patch that  adds task 'eclipsehwa' (Eclipse 'Hello,
world!' application) to Harmony classlib build.xml . It's attached to
the issue.

You can run

ant -Dharmony.vm.exe=...  -Declipse-home= eclipsehwa

and Eclipse will start, create a project, create a test and compile it

Now it doesn't work with Harmony DRLVM because '-jar' launching is used.

On 7/4/06, Anton Luht <[EMAIL PROTECTED]> wrote:

Hello,

I've created an Eclipse automated test based on Salikh's code - please see

http://issues.apache.org/jira/browse/HARMONY-752

I've tested it on Windows XP on Eclipse that goes with harmony VM -
eclipse-SDK-3.1.1-win32.zip

Sometimes (irregularry) after execution it prints some stack traces to
the console. Scenario is executed successfully anyway - a project is
created, editor opens, some code is pasted in it, project is built,
closed and deleted.

Please feel free to add comments to that issue if you find errors in
it or fail to run it on some configurations.
--
Regards,
Anton Luht,
Intel Middleware Products Division




--
Regards,
Anton Luht,
Intel Middleware Products Division

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Egor Pasko
On the 0x1E8 day of Apache Harmony Oliver Deakin wrote:
> I have taken a look at the Linux makefile for launcher, and I notice
> that libhysig.so is not listed in MDLLIBFILES, but libhyport.so and
> libhythr.so are. Adding "$(DLLPATH)libhysig.so" to this line
> of the makefile solves the LD_LIBRARY_PATH problem for me.
> Do you see the same thing Egor?

I do. Thanks, Oliver!

Here is the patch:
--- working_classlib/modules/luni/src/main/native/launcher/linux/makefile   
(revision 447251)
+++ working_classlib/modules/luni/src/main/native/launcher/linux/makefile   
(working copy)
@@ -21,7 +21,7 @@
 BUILDFILES = $(SHAREDSUB)main.o $(SHAREDSUB)cmain.o \
$(SHAREDSUB)launcher_copyright.o $(SHAREDSUB)strbuf.o \
$(SHAREDSUB)libhlp.o
-MDLLIBFILES = $(DLLPATH)libhyprt.so $(DLLPATH)libhythr.so
+MDLLIBFILES = $(DLLPATH)libhyprt.so $(DLLPATH)libhythr.so $(DLLPATH)libhysig.so
 EXENAME = $(EXEPATH)java

 include $(HY_HDK)/build/make/rules.mk

'./java -showversion Hello' fails as previously.
...under investigation...

-- 
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Mark Hindess

On 18 September 2006 at 7:06, "Geir Magnusson Jr." <[EMAIL PROTECTED]> wrote:
> Sorry - that came across too harsh w/o the smileys...

Actually, I thought it was pretty fair.

> Seriously, we had mixed up two things... does it make sense?

I'd read the body of the message without really reading the subject line
and consequently jumped to an invalid conclusion about the context.  Now
I've read the body again (after looking at the subject line and reading
the related thread) it makes sense.

Regards,
 Mark.

> Geir Magnusson Jr. wrote:
> > Do you really understand what we are talking about?
> > 
> > The change discussed doesn't happen on linux unless you choose to define 
> > PLATFORM_NT while compiling, but then I suspect lower-casing a file path 
> > for a string pool will be the least of your problems.
> > 
> > geir
> > 
> > 
> > Mark Hindess wrote:
> >> On 15 September 2006 at 10:56, "Geir Magnusson Jr." <[EMAIL PROTECTED]> 
> >> wrote:
> >>> Looking at things, yes, it's the ICU dll, which has uppercase letters 
> >>> in the filename.
> >>>
> >>> My plan is to just convert all paths to lowercase.
> >>>
> >>> Any problems people can see?
> >>
> >> Yes.  It will break the IBM VME on linux.  Renaming locally and 
> >> running HelloWorld results in:
> >>
> >>   >> com.ibm.oti.vm.bootstrap.library.path)>
> >> JVMJ9VM015W Initialization error for library jclclear_23(14): 
> >> JVMJ9VM009E J9VMDllMain failed
> >> HMYEXEL062E Internal VM error: Failed to create Java VM
> >> FAILED.
> >>
> >> -Mark.
> >>
> >>
> >>
> >> -
> >> Terms of use : http://incubator.apache.org/harmony/mailing.html
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> > 
> > -
> > Terms of use : http://incubator.apache.org/harmony/mailing.html
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> 
> -
> Terms of use : http://incubator.apache.org/harmony/mailing.html
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [General VM] GC strategy:how to garbage collect short-lived objects quickly.

2006-09-18 Thread Tim Ellison
Geir Magnusson Jr. wrote:
> Robin Garner wrote:
>> Designing a garbage collector with low pause times and high throughput
>> (ie
>> low overhead) is to an extent the 'holy grail' of memory management
>> research.
> 
> Do you know much about this on in JRockit?
> 
> http://www.networkcomputing.com/showArticle.jhtml?articleId=193000182

and, of course, in the interests of unbiased reporting

   http://www.ibm.com/software/webservers/realtime/

;-)

Regards,
Tim

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][luni]A difference between Unicode4.0 and Unicode4.1 affects our implementation of j.l.Character.

2006-09-18 Thread Tony Wu

I have raised a non-bug difference JIRA issue at
https://issues.apache.org/jira/browse/HARMONY-1488

On 9/18/06, Tim Ellison <[EMAIL PROTECTED]> wrote:


Looks like 200B was modified/corrected from 'space separator 'to
'format'.  Therefore I'd be inclined to follow the allowances in the
spec, i.e. modify the test to allow it since it is an ignorable format
character.

Regards,
Tim

Tony Wu wrote:
> Hi all,
> I encounter a problem when implement the method
> isJavaIdentifierPart(int) in
> j.l.Character. The Character U+200B was redefined[1] in Unicode4.1 and
> caused a testcase[2] failed.
> Our implementation is compatible with Unicode 4.1 whereas RI is
compatible
> with 4.0. I wonder which one should we follow.
> [1]
> Unicode 4.0 200B;ZERO WIDTH SPACE;Zs;0;BN;N;
> Unicode 4.1 200B;ZERO WIDTH SPACE;Cf;0;BN;N;
>
> [2]
> assertFalse(isJavaIdentifierPart("\u200B"));
>

--

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Tony Wu
China Software Development Lab, IBM


Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Geir Magnusson Jr.

Sorry - that came across too harsh w/o the smileys...

Seriously, we had mixed up two things... does it make sense?

geir


Geir Magnusson Jr. wrote:

Do you really understand what we are talking about?

The change discussed doesn't happen on linux unless you choose to define 
PLATFORM_NT while compiling, but then I suspect lower-casing a file path 
for a string pool will be the least of your problems.


geir


Mark Hindess wrote:
On 15 September 2006 at 10:56, "Geir Magnusson Jr." <[EMAIL PROTECTED]> 
wrote:
Looking at things, yes, it's the ICU dll, which has uppercase letters 
in the filename.


My plan is to just convert all paths to lowercase.

Any problems people can see?


Yes.  It will break the IBM VME on linux.  Renaming locally and 
running HelloWorld results in:


 com.ibm.oti.vm.bootstrap.library.path)>
JVMJ9VM015W Initialization error for library jclclear_23(14): 
JVMJ9VM009E J9VMDllMain failed

HMYEXEL062E Internal VM error: Failed to create Java VM
FAILED.

-Mark.



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [test] Jetty integration progress ? (was Re: [classlib] jetty based tests)

2006-09-18 Thread Geir Magnusson Jr.



Andrew Zhang wrote:

On 9/18/06, Richard Liang <[EMAIL PROTECTED]> wrote:


On 9/18/06, Andrew Zhang <[EMAIL PROTECTED]> wrote:
> Hi,
>
> It's me again. Seems no big progress on jetty. I'd like to take the job
if
> no one objects. Here are my suggestions:

Great :-)

>
> 1. jetty version:  I suggest that Harmony adopt jetty 6. Because many
> 5.xAPIs are deprecated in jetty 6, we'd better follow latest jetty
> version.

+1

>
> 2. location to put jetty jars: support module.
>

Do you mean we will check the jetty jars into Harmony svn?



Yes. Is it OK? Or put the jar in depends folder?


Just make it a depends.  We should avoid checking in jars.




3. how to write jetty test? I suggest that we could start jetty in any
test
> if necessary. If we found there are heavy code duplicates, we could
extract
> them as utility methods in support module. So far, I'd like to write
jetty
> test directly in each module, because the code is rather simple, only a
few
> lines.[1] It's also easy to write user-customized handler for
> negative tests. Let's make it work, and then make it better. :-)
>
> Any suggestions/comments/objections?  I volunteer to upload patches 
when

we
> reach an agreement.
>
> Best regards,
> Andrew
>
> [1]
> jetty-based test example:
> setUp code:
> port = Support_PortManager.getNextPort();
> Server server = new Server(port);
> ResourceHandler resource_handler=new ResourceHandler();
> resource_handler.setResourceBase("somewhere");
> server.setHandler(resource_handler);
> server.start();
> tearDown code:
> server.stop();
>
>


--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]







-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [classlib][luni]A difference between Unicode4.0 and Unicode4.1 affects our implementation of j.l.Character.

2006-09-18 Thread Tim Ellison
Looks like 200B was modified/corrected from 'space separator 'to
'format'.  Therefore I'd be inclined to follow the allowances in the
spec, i.e. modify the test to allow it since it is an ignorable format
character.

Regards,
Tim

Tony Wu wrote:
> Hi all,
> I encounter a problem when implement the method
> isJavaIdentifierPart(int) in
> j.l.Character. The Character U+200B was redefined[1] in Unicode4.1 and
> caused a testcase[2] failed.
> Our implementation is compatible with Unicode 4.1 whereas RI is compatible
> with 4.0. I wonder which one should we follow.
> [1]
> Unicode 4.0 200B;ZERO WIDTH SPACE;Zs;0;BN;N;
> Unicode 4.1 200B;ZERO WIDTH SPACE;Cf;0;BN;N;
> 
> [2]
> assertFalse(isJavaIdentifierPart("\u200B"));
> 

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [test] Jetty integration progress ? (was Re: [classlib] jetty based tests)

2006-09-18 Thread Andrew Zhang

On 9/18/06, Richard Liang <[EMAIL PROTECTED]> wrote:


On 9/18/06, Andrew Zhang <[EMAIL PROTECTED]> wrote:
> Hi,
>
> It's me again. Seems no big progress on jetty. I'd like to take the job
if
> no one objects. Here are my suggestions:

Great :-)

>
> 1. jetty version:  I suggest that Harmony adopt jetty 6. Because many
> 5.xAPIs are deprecated in jetty 6, we'd better follow latest jetty
> version.

+1

>
> 2. location to put jetty jars: support module.
>

Do you mean we will check the jetty jars into Harmony svn?



Yes. Is it OK? Or put the jar in depends folder?


3. how to write jetty test? I suggest that we could start jetty in any
test
> if necessary. If we found there are heavy code duplicates, we could
extract
> them as utility methods in support module. So far, I'd like to write
jetty
> test directly in each module, because the code is rather simple, only a
few
> lines.[1] It's also easy to write user-customized handler for
> negative tests. Let's make it work, and then make it better. :-)
>
> Any suggestions/comments/objections?  I volunteer to upload patches when
we
> reach an agreement.
>
> Best regards,
> Andrew
>
> [1]
> jetty-based test example:
> setUp code:
> port = Support_PortManager.getNextPort();
> Server server = new Server(port);
> ResourceHandler resource_handler=new ResourceHandler();
> resource_handler.setResourceBase("somewhere");
> server.setHandler(resource_handler);
> server.start();
> tearDown code:
> server.stop();
>
>


--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Andrew Zhang
China Software Development Lab, IBM


Re: [classlib][io][nio] Sync issue of java.io.FileOutputStream and java.nio.channels.FileChannel

2006-09-18 Thread Andrew Zhang

On 9/18/06, Richard Liang <[EMAIL PROTECTED]> wrote:


Hello,

One Apache Derby test[1] fails on Harmony. It seems that RI always
sync the FileOutputStream and FileChannel after each "write", which is
different from Harmony. But there is no explicit description in Java
Spec. Shall we follow RI? Thanks a lot.

The following test cases could demonstrate this issue.

   public void testFile() {
   File derbyLog = new File("d:\\", "derby1.log");

   try {
   FileOutputStream fos = new FileOutputStream(derbyLog);
   fos.write(0x41);
   assertEquals(1, derbyLog.length());
   } catch (Exception e) {
   e.printStackTrace();
   }
   }

   public void testFileChannel() {
   File derbyLog = new File("d:\\", "derby2.log");

   try {
   FileOutputStream fos = new FileOutputStream(derbyLog);
   FileChannel fc = fos.getChannel();
   fc.write(ByteBuffer.wrap(new byte[]{0x41, 0x42}));
   assertEquals(2, derbyLog.length());
   } catch (Exception e) {
   e.printStackTrace();
   }
   }



Interesting. I think we'd better follow RI although it's implementation
dependent. Otherwise, it breaks existing application.

To make test more interesting, I wrote a similar test:


public void testFile() throws Exception {
   File derbyLog = File.createTempFile("test", "log");
   derbyLog.deleteOnExit();
   RandomAccessFile fos = new RandomAccessFile(derbyLog, "rws");
   for (int i = 0; i < 1000; i++) {
   fos.write(0x41);
   assertEquals(1 + i, derbyLog.length());
   }

}

Run it and you'll be surprised. :-)

[1]

http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/logStream.java?view=co
--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Andrew Zhang
China Software Development Lab, IBM


Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Geir Magnusson Jr.
I'm trying on Ubuntu 5 and I'm getting problems as well.  Problem is 
that it's in a Parallels VM on OS X and I can't figure out how to cut 
and paste between them...


It's a really useless stacktrace w/ addr2line...


Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Egor Pasko wrote:

If you let that run, it will build classlib and drlvm, and then
package in to hdk and jre, but I don't use this in my day to day life.

I tend to go into either working_vm and build there via build/build.sh
(note you need to either set -Dextern.dep.CLASSLIB.loc correctly, or
just have a drlvm.properties file in working_vm/build or when I need a
classlib update, go up into working_classlib, do an svn update, and
then ant.

this one does not allow me to build.sh update on downloading
XALAN. This is a kind of problem that appeared when classlib was not
built, but now it looks like built successfully.

trying more...

Simple.  You need to tell the DRLVM build where to find the built
classlib.  Right now it assumes a structure like :

  enhanced/classlib/trunk
  enhanced/drlvm/trunk

but with the "federated build" structure of

  enhanced/trunk/
working_vm/
working_classlib/

I just put a file called "drlvm.properties" into

  enhanced/trunk/working_vm/build

that contains

external.dep.CLASSLIB.loc=../../../working_vm

gotcha! :)
external.dep.CLASSLIB.loc=../../../working_classlib

maybe, put it in SVN directly? are there any caveats?


and then I can go into working_classlib and refresh and build, and
working_vm just picks that up on build and local assembly of jre.

building further, drinking coffee..


interesting... if I build working_classlib and working_drlvm
separately, there is no issue with lcms.h, and the build is successful
(i.e. let's get rid of this lcms.h dependency later on)

And yet, I just cannot run it...

bash-boom-bang$ LD_LIBRARY_PATH=`pwd`:`pwd`/default ./java -showversion -cp 
<...> Hello
Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software 
Foundation or its licensors, as applicable.
java version "1.5.0"
pre-alpha : not complete or compatible
svn = r446534, (Sep 18 2006), Linux/ia32/gcc 3.3.3, debug build
http://incubator.apache.org/harmony
free(): invalid pointer 0xbfffd0b8!
SIGSEGV in VM code.
Stack trace:
1: free (??:-1)
2: ?? (??:-1)
3: hymem_free_memory (??:-1)
4: find_call_JNI_OnLoad 
(/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
5: properties_free (??:-1)
6: find_call_JNI_OnLoad 
(/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
7: ?? (??:-1)
8: readClassPathFromPropertiesFile (??:-1)
9: ?? (??:-1)
10: ?? (??:-1)
11: ?? (??:-1)
12: ?? (??:-1)
13: ?? (??:-1)
14: _dl_runtime_resolve (??:-1)
15: ?? (??:-1)
16: JNI_OnLoad (??:-1)
17: ?? (??:-1)
18: ?? (??:-1)

Segmentation fault

Am I running the Harmony Launcher? Should I run it somewhat
differently?



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Geir Magnusson Jr.

Do you really understand what we are talking about?

The change discussed doesn't happen on linux unless you choose to define 
PLATFORM_NT while compiling, but then I suspect lower-casing a file path 
for a string pool will be the least of your problems.


geir


Mark Hindess wrote:

On 15 September 2006 at 10:56, "Geir Magnusson Jr." <[EMAIL PROTECTED]> wrote:
Looking at things, yes, it's the ICU dll, which has uppercase letters in 
the filename.


My plan is to just convert all paths to lowercase.

Any problems people can see?


Yes.  It will break the IBM VME on linux.  Renaming locally and running 
HelloWorld results in:


 
JVMJ9VM015W Initialization error for library jclclear_23(14): JVMJ9VM009E 
J9VMDllMain failed
HMYEXEL062E Internal VM error: Failed to create Java VM
FAILED.

-Mark.



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [vmi] Extending the VMI to allow setting a default portlib

2006-09-18 Thread Oliver Deakin

Tim Ellison wrote:

Geir Magnusson Jr. wrote:
  

Tim Ellison wrote:


At present, the Harmony launcher creates and passes an instance of the
portlib to the VM as it is being created (via an
_org.apache.harmony.vmi.portlib init arg).  This is good because allows
the launcher to define functions used for memory alloc, file IO, etc.
early.

However, we also need to work with regular applications that are
embedding the JVM, and don't know/want to set up this argument for us.
In such a case the classlib should use a default portlib (and possibly
JVM subsequently if it wants).
  

This seems backwards to me.  Wouldn't we want the VM use the default
portlib and give that to the classlib?



VMs that want to use the portlib can do that today anyway (e.g. drlvm
was creating the portlib itself), so this would allow setting the
portlib by the classlib where the VM doesn't care.

So today, the launcher creates a portlib and passes it in as a VM
property, and the VM stores the struct ptr in the VMI.

I'm suggesting that we allow any one of:
 - VM takes the version passed in via the launcher property
 - VM creates a default version and puts it in VMI
 - classlib creates a default version and puts it in VMI
  


This makes sense to me - it gives the most flexibility for when the port 
library

is created. If the launcher doesnt do it, fall back to the VM. If the VM
doesnt do it, fall back to the classlib default. It seems sensible to have
a failsafe in place, even if we never have to use it.

Regards,
Oliver


Regards,
Tim

  

I propose that we retain support for the init arg, but make it optional,
and that we extend the VMI [1] to allow setting the portlib struct where
it has not been previously defined.  The portlib struct can only be
defined once, subsequent attempts to set the portlib would return an
error.  Of course, you can still modify the struct to redefine the
functions it contains.

The new VMI function would be:
  vmiError(JNICALL * SetPortLibrary)
(VMInterface * vmi, HyPortLibrary * portlib);

then the early logic in JNI_OnLoad for luniglob.c [2] would become:
 (a) if vmInterface->GetPortLibrary(vmi) is not NULL then continue
 (b) otherwise create new portlib, and vmi->SetPortlib(vmi, portlib).

and the corresponding JNI_OnUnload would destroy the portlib iff it had
been created in step (b).


[1]
http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/native/include/shared/vmi.h?revision=442941&view=markup

[2]
http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/native/luni/shared/luniglob.c?revision=442941&view=markup


Comments?

Regards,
Tim

  

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





  


--
Oliver Deakin
IBM United Kingdom Limited


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Mark Hindess

On 15 September 2006 at 10:56, "Geir Magnusson Jr." <[EMAIL PROTECTED]> wrote:
> Looking at things, yes, it's the ICU dll, which has uppercase letters in 
> the filename.
> 
> My plan is to just convert all paths to lowercase.
> 
> Any problems people can see?

Yes.  It will break the IBM VME on linux.  Renaming locally and running 
HelloWorld results in:

 
JVMJ9VM015W Initialization error for library jclclear_23(14): JVMJ9VM009E 
J9VMDllMain failed
HMYEXEL062E Internal VM error: Failed to create Java VM
FAILED.

-Mark.



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm]A subject to profiling instrumenting

2006-09-18 Thread zouqiong

2006/9/18, zouqiong <[EMAIL PROTECTED]>:

This is the JIRA number for my profile.

https://issues.apache.org/jira/secure/ManageAttachments.jspa?id=12350137

If still have problem, please tell me.

If you are free, we can discuss about what to do next.





I have fix the aaload problem, and it can work with specjbb2000, and
most of the jvm98, except compress and javac.




2006/9/13, Mikhail Fursov <[EMAIL PROTECTED]>:
> Qiong,
> I tried to build your vm.tar.bz2 file and have the following problems:
> 1) RUNTIME_OBJ_PATTERN_FILE_NAME is not defined but used
> 2) open/write_thread.h file is absent
> 3) mutex_write_thread is used in jit_runtime_support.cpp but is not
> declared.
>
> Can you post only diffs file to JIRA with write_thread.h file included?
>
>
>
> On 9/7/06, zouqiong <[EMAIL PROTECTED]> wrote:
> >
> > This is the JIRA number.
> > https://issues.apache.org/jira/browse/HARMONY-1406
> >
> > I upload the vm code, it`s not so large, 3.8 Megabytes.
> >
> > And the code still have bugs when profile the AALOAD.
> > But I am not sure the GETFIELD and GETSTATIC are totally right. :(
> >
> > If you want to profile the AALOAD, please look at the _TEST_ macro in
> > gen_aload() method.
> > And the GETFIELD and GETSTATIC is opened automatically.
> >
> > Now I have the following schedule:
> > 1.First implement the instrument which helps to profile the access
> > patterns
> > 2.Second using sampling to implement the instrument.
> >
> >
> > 2006/9/7, Mikhail Fursov <[EMAIL PROTECTED]>:
> > >
> > > On 9/6/06, zouqiong <[EMAIL PROTECTED]> wrote:
> > > >
> > > > Ok, I will put my diffs to the JIRA later. And I have solved the issue
> > I
> > > > asked two days ago.
> > >
> > >
> > > Ok, I will wait the JIRA number from you.
> > >
> > >
> > > It needs liblwdis.so supporting.
> > > >
> > >
> > > Check JIRA 1402 for it.
> > http://issues.apache.org/jira/browse/HARMONY-1402
> > >
> > > --
> > > Mikhail Fursov
> > >
> > >
> >
> >
> > --
> > Best Regards,
> > Qiong,Zou
> >
> >
>
>
> --
> Mikhail Fursov
>
>


--
Best Regards,
Qiong,Zou




--
Best Regards,
Qiong,Zou

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Geir Magnusson Jr.



Alexey Varlamov wrote:

Geir,

The DRLVM build is broken now on gcc3.3.3 (SUSE9):

build.native.cpp:
  [cc] 135 total files to be compiled.
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp: In
  [cc]function `apr_dso_handle_t* natives_load_library(const
char*, bool*,
  [cc]NativeLoadStatus*)':
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:287: error: jump
  [cc]to label `NATIVES_LOAD_LIBRARY_EXIT'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:268: error:
  [cc] from here
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:281: error:
  [cc] crosses initialization of `jint res'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:273: error:
  [cc] crosses initialization of `Global_Env*ge'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:287: error: jump
  [cc]to label `NATIVES_LOAD_LIBRARY_EXIT'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:255: error:
  [cc] from here
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:281: error:
  [cc] crosses initialization of `jint res'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:273: error:
  [cc] crosses initialization of `Global_Env*ge'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:258: error:
  [cc] crosses initialization of `NativeLibInfo*pinfo'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:287: error: jump
  [cc]to label `NATIVES_LOAD_LIBRARY_EXIT'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:234: error:
  [cc] from here
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:281: error:
  [cc] crosses initialization of `jint res'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:273: error:
  [cc] crosses initialization of `Global_Env*ge'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:258: error:
  [cc] crosses initialization of `NativeLibInfo*pinfo'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:241: error:
  [cc] crosses initialization of `apr_status_t apr_status'

BUILD FAILED


How bizarre.  Propose a fix then. All I was trying to do was localize 
the free() under windows.




Besides, you introduced inconsistency in names, ones registered inside
of ClassLoader::LoadNativeLibrary and those actually loaded in
natives_load_library().
So, if one will try loading the same lib with different names on
Windows via j.l.System.loadLibrary(), there will be unexpected
UnsatisfiedLinkError.
I guess that awkward usage of port_filepath_canonical() was intended
to solve exactly this problem.


I can't see how. Seems like port_filepath_canonical() was being used in 
LoadNativeLibrary() was to create a full path, and would PREPEND THE 
CURRENT DIRECTORY to it.  So in our case, where we are wanting to let 
apr_dso_load() get a dll/so, it *can't* presume current directory.


That said, I do agree that we should move the lower-casing done in 
natives_load_library() and just demand that callers get their path right 
as part of the API for natives_load_library()


If you want to add that to your fix above, that would be great.

Sorry for the trouble.  I'll do it if you want.

geir



So we still need better solution.

--
Alexey

2006/9/15, Geir Magnusson Jr. <[EMAIL PROTECTED]>:

Looking at things, yes, it's the ICU dll, which has uppercase letters in
the filename.

My plan is to just convert all paths to lowercase.

Any problems people can see?

geir

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm]A subject to profiling instrumenting

2006-09-18 Thread zouqiong

This is the JIRA number for my profile.

https://issues.apache.org/jira/secure/ManageAttachments.jspa?id=12350137

If still have problem, please tell me.

If you are free, we can discuss about what to do next.



2006/9/13, Mikhail Fursov <[EMAIL PROTECTED]>:

Qiong,
I tried to build your vm.tar.bz2 file and have the following problems:
1) RUNTIME_OBJ_PATTERN_FILE_NAME is not defined but used
2) open/write_thread.h file is absent
3) mutex_write_thread is used in jit_runtime_support.cpp but is not
declared.

Can you post only diffs file to JIRA with write_thread.h file included?



On 9/7/06, zouqiong <[EMAIL PROTECTED]> wrote:
>
> This is the JIRA number.
> https://issues.apache.org/jira/browse/HARMONY-1406
>
> I upload the vm code, it`s not so large, 3.8 Megabytes.
>
> And the code still have bugs when profile the AALOAD.
> But I am not sure the GETFIELD and GETSTATIC are totally right. :(
>
> If you want to profile the AALOAD, please look at the _TEST_ macro in
> gen_aload() method.
> And the GETFIELD and GETSTATIC is opened automatically.
>
> Now I have the following schedule:
> 1.First implement the instrument which helps to profile the access
> patterns
> 2.Second using sampling to implement the instrument.
>
>
> 2006/9/7, Mikhail Fursov <[EMAIL PROTECTED]>:
> >
> > On 9/6/06, zouqiong <[EMAIL PROTECTED]> wrote:
> > >
> > > Ok, I will put my diffs to the JIRA later. And I have solved the issue
> I
> > > asked two days ago.
> >
> >
> > Ok, I will wait the JIRA number from you.
> >
> >
> > It needs liblwdis.so supporting.
> > >
> >
> > Check JIRA 1402 for it.
> http://issues.apache.org/jira/browse/HARMONY-1402
> >
> > --
> > Mikhail Fursov
> >
> >
>
>
> --
> Best Regards,
> Qiong,Zou
>
>


--
Mikhail Fursov





--
Best Regards,
Qiong,Zou

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [General]Is there an agreement on different order of throwing Exceptions between RI and Harmony?

2006-09-18 Thread Rui Hu

And, based on the agreement of exception-throwing compability issue,  I
think most those JIRAs can fall into guideline2:"*Follow the Reference
Implementation* "

Because in most situation, the order of throwing Exceptions is not
restricted in spec, and almost any order is reasonable. So we can just
follow RI in most JIRAs. And maybe few special cases need to be discussed.

On 9/18/06, Andrew Zhang <[EMAIL PROTECTED]> wrote:


Tony, we have got an agreement on exception-throwing compability issue[1].

But of course it's always OK to discuss any specific case.

[1]
http://incubator.apache.org/harmony/subcomponents/classlibrary/compat.html


On 9/18/06, Tony Wu <[EMAIL PROTECTED]> wrote:
>
> I noticed there are many JIRA issues [1] about Exception order. Some of
> them
> were fixed whereas others were marked as non-bug difference.
> I wonder which kind of Exception order problem should be fixed, and
which
> type should be left as non-bug difference.
> Is there any agreement? I suggest setting one if not.
>
> [1]
> HARMONY-1214
> HARMONY-1215
> HARMONY-1240
> HARMONY-1082
> …
>
>
> --
> Tony Wu
> China Software Development Lab, IBM
>
>


--
Andrew Zhang
China Software Development Lab, IBM





--
Robert Hu
China Software Development Lab, IBM


Re: [drlvm] build fails at revision 447316

2006-09-18 Thread Vladimir Gorr

On 9/18/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote:


Ah!

Probably build/drlvm.properties that I added, which will point your
build off into nowhere for classlib if not setup right (which is where
those headers come from...)

Just do a svn update - I renamed to drlvm.properties.example to make it
less harmful.

Sorry about that.



No problems with this. Just I'd like to mention I have the recent sources.
I was able to successfully build after cleaning (build.bat clean; build.bat
).

In any case thanks for your help,
Vladimir.


geir


Vladimir Gorr wrote:
> Does anybody observe this DRLVM build issue at the revision 447316?
>
> ...
> build.native.cpp:
>   [cc] 2 total files to be compiled.
>   [cc] cl : Command line warning D4025 : overriding '/Ox' with '/Od'
>   [cc] j9vmls.cpp
>   [cc] C:\DrlSrc\drlvm\trunk\vm\vmi\src\j9vmls.cpp(20) : fatal error
> C1083: Cannot open include file: 'hyvmls.h': No such file or directory
>   [cc] vmi.cpp
>   [cc] C:\DrlSrc\drlvm\trunk\vm\vmi\src\vmi.cpp(25) : fatal error
> C1083: Cannot open include file: 'zipsup.h': No such file or directory
>   [cc] Generating Code...
>
> Thanks,
> Vladimir.
>

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: [General]Is there an agreement on different order of throwing Exceptions between RI and Harmony?

2006-09-18 Thread Spark Shen

Tony Wu 写道:
I noticed there are many JIRA issues [1] about Exception order. Some 
of them

were fixed whereas others were marked as non-bug difference.
I wonder which kind of Exception order problem should be fixed, and which
type should be left as non-bug difference.
Is there any agreement? I suggest setting one if not.

[1]
HARMONY-1214
HARMONY-1215
HARMONY-1240
HARMONY-1082
…


But there are cases you can never follow RI on the order of the 
exceptions they thrown. I encounter this situation when developing 
java.util.Formatter.
So I suggest (*try* :-) ) to follow guide line cited by Andrew. Where 
it's impossible, just let it go.


Best regards

--
Spark Shen
China Software Development Lab, IBM


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Oliver Deakin


Geir Magnusson Jr. wrote:



Egor Pasko wrote:



this binary cannot find libhysig.so:
$ ldd deploy/jre/bin/java | grep hysig
libhysig.so => not found


In build/default/jre/bin, is there a libhysig.so anywhere?


yes, in deploy/jre/bin/


That's really weird.  I can do the same, and it resolves on Ubuntu 6 
w/ no LD_LIBRARY_PATH set.


I get the same thing on my SLES9 machine. If I dont manually set
LD_LIBRARY_PATH, I get an error message:

./java: error while loading shared libraries: libhysig.so: cannot open 
shared object file: No such file or directory


"ldd ./java" gives me the following:

   linux-gate.so.1 =>  (0xe000)
   libhyprt.so => 
/harmony/svn-checkouts/test/deploy/jdk/jre/bin/libhyprt.so (0x40018000)
   libhythr.so => 
/harmony/svn-checkouts/test/deploy/jdk/jre/bin/libhythr.so (0x40035000)

   libm.so.6 => /lib/tls/libm.so.6 (0x4004c000)
   libpthread.so.0 => /lib/tls/libpthread.so.0 (0x4006f000)
   libc.so.6 => /lib/tls/libc.so.6 (0x4007f000)
   libdl.so.2 => /lib/libdl.so.2 (0x40199000)
   /lib/ld-linux.so.2 (0x4000)
   libhysig.so => not found

so oddly it appears that libhyprt.so and libhythr.so are found,
but libhysig.so is not, even though they are in the same directory!

I have taken a look at the Linux makefile for launcher, and I notice
that libhysig.so is not listed in MDLLIBFILES, but libhyport.so and
libhythr.so are. Adding "$(DLLPATH)libhysig.so" to this line
of the makefile solves the LD_LIBRARY_PATH problem for me.
Do you see the same thing Egor?

Regards,
Oliver



geir





-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
Oliver Deakin
IBM United Kingdom Limited


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [test] Jetty integration progress ? (was Re: [classlib] jetty based tests)

2006-09-18 Thread Richard Liang

On 9/18/06, Andrew Zhang <[EMAIL PROTECTED]> wrote:

Hi,

It's me again. Seems no big progress on jetty. I'd like to take the job if
no one objects. Here are my suggestions:


Great :-)



1. jetty version:  I suggest that Harmony adopt jetty 6. Because many
5.xAPIs are deprecated in jetty 6, we'd better follow latest jetty
version.


+1



2. location to put jetty jars: support module.



Do you mean we will check the jetty jars into Harmony svn?


3. how to write jetty test? I suggest that we could start jetty in any test
if necessary. If we found there are heavy code duplicates, we could extract
them as utility methods in support module. So far, I'd like to write jetty
test directly in each module, because the code is rather simple, only a few
lines.[1] It's also easy to write user-customized handler for
negative tests. Let's make it work, and then make it better. :-)

Any suggestions/comments/objections?  I volunteer to upload patches when we
reach an agreement.

Best regards,
Andrew

[1]
jetty-based test example:
setUp code:
port = Support_PortManager.getNextPort();
Server server = new Server(port);
ResourceHandler resource_handler=new ResourceHandler();
resource_handler.setResourceBase("somewhere");
server.setHandler(resource_handler);
server.start();
tearDown code:
server.stop();





--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Geir Magnusson Jr.



Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:

Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:

Hm.

What platform are you running on?

SUSE 9


I can build and run on Ubuntu 6, 5 and WinXP in debug and release.

Do your tests pass?

many tests pass, hm..
but it runs on the RI from my path with
org.apache.tools.ant.launch.Launcher

waiting a little bit gives what's expected: test failures:
./lnx_ia32_gcc_debug/deploy/jre/bin/java: error while loading shared 
libraries: libhysig.so: cannot open shared object file: No such file or 
directory


Hm. You shouldn't have to set any LD_LIBRARY_PATH - the harmony
launcher is doing that.


What is the launcher?
deploy/jre/bin/java? 


yes


this binary cannot find libhysig.so:
$ ldd deploy/jre/bin/java | grep hysig
libhysig.so => not found


In build/default/jre/bin, is there a libhysig.so anywhere?


yes, in deploy/jre/bin/


That's really weird.  I can do the same, and it resolves on Ubuntu 6 w/ 
no LD_LIBRARY_PATH set.


geir





-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[classlib][io][nio] Sync issue of java.io.FileOutputStream and java.nio.channels.FileChannel

2006-09-18 Thread Richard Liang

Hello,

One Apache Derby test[1] fails on Harmony. It seems that RI always
sync the FileOutputStream and FileChannel after each "write", which is
different from Harmony. But there is no explicit description in Java
Spec. Shall we follow RI? Thanks a lot.

The following test cases could demonstrate this issue.

   public void testFile() {
   File derbyLog = new File("d:\\", "derby1.log");

   try {
   FileOutputStream fos = new FileOutputStream(derbyLog);
   fos.write(0x41);
   assertEquals(1, derbyLog.length());
   } catch (Exception e) {
   e.printStackTrace();
   }
   }

   public void testFileChannel() {
   File derbyLog = new File("d:\\", "derby2.log");

   try {
   FileOutputStream fos = new FileOutputStream(derbyLog);
   FileChannel fc = fos.getChannel();
   fc.write(ByteBuffer.wrap(new byte[]{0x41, 0x42}));
   assertEquals(2, derbyLog.length());
   } catch (Exception e) {
   e.printStackTrace();
   }
   }

[1] 
http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/logStream.java?view=co
--
Richard Liang
China Development Lab, IBM

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [jira] Commented: (HARMONY-286) Add build-java and build-native targets to main build.xml

2006-09-18 Thread Oliver Deakin

Hi Alexey,

At the time I was working on native code all over the place, and
since rebuilding our java classes takes a very long time on my
Windows box I found it useful to be able to just build all the natives.

I dont mind if this issue is closed as it's not really a major problem
(also the patch is probably very out of date, although it should be fairly
easy to create a new one) - however, I think it is something that
is still useful, and if we can add it without much effort, then
why not?

As for using "ant -f make/build-java.xml -Dbuild.module=awt build",
I believe that we discussed a little while ago that we would try to put
all main build targets into the top level build.xml, so that no developer
needs to directly execute the build scripts under make. IMHO it is
preferable to call "ant -Dbuild.module=awt build-java" in this case.

If there is still interest in this feature, I can create an up-to-date
patch and attach it to the JIRA.

Regards,
Oliver

Alexey Petrenko wrote:

Guys,

I suggest to close this issue as "won't fix" because current build
allows to build only specified module. And it is enough.

Thoughts? Objections?

SY, Alexey

2006/9/15, Alexey Petrenko (JIRA) <[EMAIL PROTECTED]>:
   [ 
http://issues.apache.org/jira/browse/HARMONY-286?page=comments#action_12434930 
]


Alexey Petrenko commented on HARMONY-286:
-

Current build allows to build only specified module. So I think that 
this bug should be closed as "won't fix"


> Add build-java and build-native targets to main build.xml
> -
>
> Key: HARMONY-286
> URL: http://issues.apache.org/jira/browse/HARMONY-286
> Project: Harmony
>  Issue Type: Improvement
>  Components: Classlib
>Reporter: Oliver Deakin
>Priority: Minor
> Attachments: build.targets.diff
>
>
> At the moment there are no targets in make/build.xml to clean and 
build only the native code or only the java code in classlib.
> I think it would be useful to have these as separate targets for 
convenience, so that when you are only working on Java code you need 
not recompile the native code entirely everytime, and vice versa.

> I will attach a patch with the necessary changes

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the 
administrators: http://issues.apache.org/jira/secure/Administrators.jspa

-
For more information on JIRA, see: 
http://www.atlassian.com/software/jira









--
Oliver Deakin
IBM United Kingdom Limited


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] is_name_lowercase() in natives_support.cpp

2006-09-18 Thread Alexey Varlamov

Geir,

The DRLVM build is broken now on gcc3.3.3 (SUSE9):

build.native.cpp:
  [cc] 135 total files to be compiled.
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp: In
  [cc]function `apr_dso_handle_t* natives_load_library(const
char*, bool*,
  [cc]NativeLoadStatus*)':
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:287: error: jump
  [cc]to label `NATIVES_LOAD_LIBRARY_EXIT'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:268: error:
  [cc] from here
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:281: error:
  [cc] crosses initialization of `jint res'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:273: error:
  [cc] crosses initialization of `Global_Env*ge'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:287: error: jump
  [cc]to label `NATIVES_LOAD_LIBRARY_EXIT'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:255: error:
  [cc] from here
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:281: error:
  [cc] crosses initialization of `jint res'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:273: error:
  [cc] crosses initialization of `Global_Env*ge'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:258: error:
  [cc] crosses initialization of `NativeLibInfo*pinfo'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:287: error: jump
  [cc]to label `NATIVES_LOAD_LIBRARY_EXIT'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:234: error:
  [cc] from here
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:281: error:
  [cc] crosses initialization of `jint res'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:273: error:
  [cc] crosses initialization of `Global_Env*ge'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:258: error:
  [cc] crosses initialization of `NativeLibInfo*pinfo'
  [cc] drlvm/vm/vmcore/src/util/natives_support.cpp:241: error:
  [cc] crosses initialization of `apr_status_t apr_status'

BUILD FAILED

Besides, you introduced inconsistency in names, ones registered inside
of ClassLoader::LoadNativeLibrary and those actually loaded in
natives_load_library().
So, if one will try loading the same lib with different names on
Windows via j.l.System.loadLibrary(), there will be unexpected
UnsatisfiedLinkError.
I guess that awkward usage of port_filepath_canonical() was intended
to solve exactly this problem.

So we still need better solution.

--
Alexey

2006/9/15, Geir Magnusson Jr. <[EMAIL PROTECTED]>:

Looking at things, yes, it's the ICU dll, which has uppercase letters in
the filename.

My plan is to just convert all paths to lowercase.

Any problems people can see?

geir

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] build fails at revision 447316

2006-09-18 Thread Geir Magnusson Jr.

Ah!

Probably build/drlvm.properties that I added, which will point your 
build off into nowhere for classlib if not setup right (which is where 
those headers come from...)


Just do a svn update - I renamed to drlvm.properties.example to make it 
less harmful.


Sorry about that.

geir

Vladimir Gorr wrote:

Does anybody observe this DRLVM build issue at the revision 447316?

...
build.native.cpp:
  [cc] 2 total files to be compiled.
  [cc] cl : Command line warning D4025 : overriding '/Ox' with '/Od'
  [cc] j9vmls.cpp
  [cc] C:\DrlSrc\drlvm\trunk\vm\vmi\src\j9vmls.cpp(20) : fatal error
C1083: Cannot open include file: 'hyvmls.h': No such file or directory
  [cc] vmi.cpp
  [cc] C:\DrlSrc\drlvm\trunk\vm\vmi\src\vmi.cpp(25) : fatal error
C1083: Cannot open include file: 'zipsup.h': No such file or directory
  [cc] Generating Code...

Thanks,
Vladimir.



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [test] Jetty integration progress ? (was Re: [classlib] jetty based tests)

2006-09-18 Thread Andrew Zhang

Hi,

It's me again. Seems no big progress on jetty. I'd like to take the job if
no one objects. Here are my suggestions:

1. jetty version:  I suggest that Harmony adopt jetty 6. Because many
5.xAPIs are deprecated in jetty 6, we'd better follow latest jetty
version.

2. location to put jetty jars: support module.

3. how to write jetty test? I suggest that we could start jetty in any test
if necessary. If we found there are heavy code duplicates, we could extract
them as utility methods in support module. So far, I'd like to write jetty
test directly in each module, because the code is rather simple, only a few
lines.[1] It's also easy to write user-customized handler for
negative tests. Let's make it work, and then make it better. :-)

Any suggestions/comments/objections?  I volunteer to upload patches when we
reach an agreement.

Best regards,
Andrew

[1]
jetty-based test example:
setUp code:
   port = Support_PortManager.getNextPort();
   Server server = new Server(port);
   ResourceHandler resource_handler=new ResourceHandler();
   resource_handler.setResourceBase("somewhere");
   server.setHandler(resource_handler);
   server.start();
tearDown code:
   server.stop();


[drlvm] build fails at revision 447316

2006-09-18 Thread Vladimir Gorr

Does anybody observe this DRLVM build issue at the revision 447316?

...
build.native.cpp:
  [cc] 2 total files to be compiled.
  [cc] cl : Command line warning D4025 : overriding '/Ox' with '/Od'
  [cc] j9vmls.cpp
  [cc] C:\DrlSrc\drlvm\trunk\vm\vmi\src\j9vmls.cpp(20) : fatal error
C1083: Cannot open include file: 'hyvmls.h': No such file or directory
  [cc] vmi.cpp
  [cc] C:\DrlSrc\drlvm\trunk\vm\vmi\src\vmi.cpp(25) : fatal error
C1083: Cannot open include file: 'zipsup.h': No such file or directory
  [cc] Generating Code...

Thanks,
Vladimir.


Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Egor Pasko
On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:
> Egor Pasko wrote:
> > On the 0x1E8 day of Apache Harmony Egor Pasko wrote:
> >> On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:
> >>> Hm.
> >>>
> >>> What platform are you running on?
> >> SUSE 9
> >>
> >>> I can build and run on Ubuntu 6, 5 and WinXP in debug and release.
> >>>
> >>> Do your tests pass?
> >> many tests pass, hm..
> >> but it runs on the RI from my path with
> >> org.apache.tools.ant.launch.Launcher
> > waiting a little bit gives what's expected: test failures:
> > ./lnx_ia32_gcc_debug/deploy/jre/bin/java: error while loading shared 
> > libraries: libhysig.so: cannot open shared object file: No such file or 
> > directory
> >
> 
> Hm. You shouldn't have to set any LD_LIBRARY_PATH - the harmony
> launcher is doing that.

What is the launcher?
deploy/jre/bin/java? 
this binary cannot find libhysig.so:
$ ldd deploy/jre/bin/java | grep hysig
libhysig.so => not found

> In build/default/jre/bin, is there a libhysig.so anywhere?

yes, in deploy/jre/bin/

-- 
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [build]Anyone else got these test errors of Pack200 like this?

2006-09-18 Thread Paulex Yang

Alex Blewitt wrote:

Phew :-) You had me worried there for a moment ...

:-)


Alex.

On 18/09/06, Paulex Yang <[EMAIL PROTECTED]> wrote:

Pls. ignore it, cannot reproduce at r447234, probably I forgot "ant
build" before running "ant -Dbuild.module=archive test". Sorry for the
confusion caused.

Paulex Yang wrote:
> My build machine is WinXP SP2, Harmony classlib+IBM VME, at revision r
> 447234, and I got 5 similar errors of
> org.apache.harmony.archive.tests.internal.pack200.CodecTest like this:
>
> java.lang.NoSuchFieldError:
> org/apache/harmony/archive/internal/pack200/Codec.BYTE1 at
> 
org.apache.harmony.archive.tests.internal.pack200.CodecTest.testCodecToString(CodecTest.java:59) 


> at
> java.lang.reflect.AccessibleObject.invokeV(AccessibleObject.java:25)
>
> Any ideas or comments?
>


--
Paulex Yang
China Software Development Lab
IBM



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Paulex Yang
China Software Development Lab
IBM



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Re: [build]Anyone else got these test errors of Pack200 like this?

2006-09-18 Thread Alex Blewitt

Phew :-) You had me worried there for a moment ...

Alex.

On 18/09/06, Paulex Yang <[EMAIL PROTECTED]> wrote:

Pls. ignore it, cannot reproduce at r447234, probably I forgot "ant
build" before running "ant -Dbuild.module=archive test". Sorry for the
confusion caused.

Paulex Yang wrote:
> My build machine is WinXP SP2, Harmony classlib+IBM VME, at revision r
> 447234, and I got 5 similar errors of
> org.apache.harmony.archive.tests.internal.pack200.CodecTest like this:
>
> java.lang.NoSuchFieldError:
> org/apache/harmony/archive/internal/pack200/Codec.BYTE1 at
> 
org.apache.harmony.archive.tests.internal.pack200.CodecTest.testCodecToString(CodecTest.java:59)
> at
> java.lang.reflect.AccessibleObject.invokeV(AccessibleObject.java:25)
>
> Any ideas or comments?
>


--
Paulex Yang
China Software Development Lab
IBM



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Geir Magnusson Jr.



Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:

Hm.

What platform are you running on?

SUSE 9


I can build and run on Ubuntu 6, 5 and WinXP in debug and release.

Do your tests pass?

many tests pass, hm..
but it runs on the RI from my path with org.apache.tools.ant.launch.Launcher 


waiting a little bit gives what's expected: test failures:
./lnx_ia32_gcc_debug/deploy/jre/bin/java: error while loading shared 
libraries: libhysig.so: cannot open shared object file: No such file or 
directory



Hm. You shouldn't have to set any LD_LIBRARY_PATH - the harmony launcher 
is doing that.


In build/default/jre/bin, is there a libhysig.so anywhere?

geir


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Egor Pasko
On the 0x1E8 day of Apache Harmony Egor Pasko wrote:
> On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:
> > Hm.
> > 
> > What platform are you running on?
> 
> SUSE 9
> 
> > I can build and run on Ubuntu 6, 5 and WinXP in debug and release.
> > 
> > Do your tests pass?
> 
> many tests pass, hm..
> but it runs on the RI from my path with org.apache.tools.ant.launch.Launcher 

waiting a little bit gives what's expected: test failures:
./lnx_ia32_gcc_debug/deploy/jre/bin/java: error while loading shared 
libraries: libhysig.so: cannot open shared object file: No such file or 
directory

-- 
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Egor Pasko
On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:
> Hm.
> 
> What platform are you running on?

SUSE 9

> I can build and run on Ubuntu 6, 5 and WinXP in debug and release.
> 
> Do your tests pass?

many tests pass, hm..
but it runs on the RI from my path with org.apache.tools.ant.launch.Launcher 

> using the launcher is the default now :
> 
> $ cd working_vm
> $ cd build
> $ sh build.sh

yep, sometimes, things like this:
sh build.sh update

> $ cd deploy/jre/bin
> $ ./java -version
> $ ./java Foo
> 
> works...

well, the ./java of mine catches no runtime path for libhysig.so,
there is only LD_LIBRARY_PATH for the last try...

Something is definitely wrong. And not many ideas I have how to repair

> geir
> 
> 
> Egor Pasko wrote:
> > On the 0x1E8 day of Apache Harmony Egor Pasko wrote:
> > If you let that run, it will build classlib and drlvm, and then
> > package in to hdk and jre, but I don't use this in my day to day life.
> >
> > I tend to go into either working_vm and build there via build/build.sh
> > (note you need to either set -Dextern.dep.CLASSLIB.loc correctly, or
> > just have a drlvm.properties file in working_vm/build or when I need a
> > classlib update, go up into working_classlib, do an svn update, and
> > then ant.
>  this one does not allow me to build.sh update on downloading
>  XALAN. This is a kind of problem that appeared when classlib was not
>  built, but now it looks like built successfully.
> 
>  trying more...
> >>> Simple.  You need to tell the DRLVM build where to find the built
> >>> classlib.  Right now it assumes a structure like :
> >>>
> >>>   enhanced/classlib/trunk
> >>>   enhanced/drlvm/trunk
> >>>
> >>> but with the "federated build" structure of
> >>>
> >>>   enhanced/trunk/
> >>> working_vm/
> >>> working_classlib/
> >>>
> >>> I just put a file called "drlvm.properties" into
> >>>
> >>>   enhanced/trunk/working_vm/build
> >>>
> >>> that contains
> >>>
> >>> external.dep.CLASSLIB.loc=../../../working_vm
> >> gotcha! :)
> >> external.dep.CLASSLIB.loc=../../../working_classlib
> >>
> >> maybe, put it in SVN directly? are there any caveats?
> >>
> >>> and then I can go into working_classlib and refresh and build, and
> >>> working_vm just picks that up on build and local assembly of jre.
> >> building further, drinking coffee..
> > interesting... if I build working_classlib and working_drlvm
> > separately, there is no issue with lcms.h, and the build is successful
> > (i.e. let's get rid of this lcms.h dependency later on)
> > And yet, I just cannot run it...
> > bash-boom-bang$ LD_LIBRARY_PATH=`pwd`:`pwd`/default ./java
> > -showversion -cp <...> Hello
> > Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software 
> > Foundation or its licensors, as applicable.
> > java version "1.5.0"
> > pre-alpha : not complete or compatible
> > svn = r446534, (Sep 18 2006), Linux/ia32/gcc 3.3.3, debug build
> > http://incubator.apache.org/harmony
> > free(): invalid pointer 0xbfffd0b8!
> > SIGSEGV in VM code.
> > Stack trace:
> > 1: free (??:-1)
> > 2: ?? (??:-1)
> > 3: hymem_free_memory (??:-1)
> > 4: find_call_JNI_OnLoad 
> > (/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
> > 5: properties_free (??:-1)
> > 6: find_call_JNI_OnLoad 
> > (/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
> > 7: ?? (??:-1)
> > 8: readClassPathFromPropertiesFile (??:-1)
> > 9: ?? (??:-1)
> > 10: ?? (??:-1)
> > 11: ?? (??:-1)
> > 12: ?? (??:-1)
> > 13: ?? (??:-1)
> > 14: _dl_runtime_resolve (??:-1)
> > 15: ?? (??:-1)
> > 16: JNI_OnLoad (??:-1)
> > 17: ?? (??:-1)
> > 18: ?? (??:-1)
> > 
> > Segmentation fault
> > Am I running the Harmony Launcher? Should I run it somewhat
> > differently?
> >
> 
> -
> Terms of use : http://incubator.apache.org/harmony/mailing.html
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-- 
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Geir Magnusson Jr.

Hm.

What platform are you running on?

I can build and run on Ubuntu 6, 5 and WinXP in debug and release.

Do your tests pass?

using the launcher is the default now :

$ cd working_vm
$ cd build
$ sh build.sh
$ cd deploy/jre/bin
$ ./java -version
$ ./java Foo

works...

geir


Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Egor Pasko wrote:

If you let that run, it will build classlib and drlvm, and then
package in to hdk and jre, but I don't use this in my day to day life.

I tend to go into either working_vm and build there via build/build.sh
(note you need to either set -Dextern.dep.CLASSLIB.loc correctly, or
just have a drlvm.properties file in working_vm/build or when I need a
classlib update, go up into working_classlib, do an svn update, and
then ant.

this one does not allow me to build.sh update on downloading
XALAN. This is a kind of problem that appeared when classlib was not
built, but now it looks like built successfully.

trying more...

Simple.  You need to tell the DRLVM build where to find the built
classlib.  Right now it assumes a structure like :

  enhanced/classlib/trunk
  enhanced/drlvm/trunk

but with the "federated build" structure of

  enhanced/trunk/
working_vm/
working_classlib/

I just put a file called "drlvm.properties" into

  enhanced/trunk/working_vm/build

that contains

external.dep.CLASSLIB.loc=../../../working_vm

gotcha! :)
external.dep.CLASSLIB.loc=../../../working_classlib

maybe, put it in SVN directly? are there any caveats?


and then I can go into working_classlib and refresh and build, and
working_vm just picks that up on build and local assembly of jre.

building further, drinking coffee..


interesting... if I build working_classlib and working_drlvm
separately, there is no issue with lcms.h, and the build is successful
(i.e. let's get rid of this lcms.h dependency later on)

And yet, I just cannot run it...

bash-boom-bang$ LD_LIBRARY_PATH=`pwd`:`pwd`/default ./java -showversion -cp 
<...> Hello
Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software 
Foundation or its licensors, as applicable.
java version "1.5.0"
pre-alpha : not complete or compatible
svn = r446534, (Sep 18 2006), Linux/ia32/gcc 3.3.3, debug build
http://incubator.apache.org/harmony
free(): invalid pointer 0xbfffd0b8!
SIGSEGV in VM code.
Stack trace:
1: free (??:-1)
2: ?? (??:-1)
3: hymem_free_memory (??:-1)
4: find_call_JNI_OnLoad 
(/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
5: properties_free (??:-1)
6: find_call_JNI_OnLoad 
(/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
7: ?? (??:-1)
8: readClassPathFromPropertiesFile (??:-1)
9: ?? (??:-1)
10: ?? (??:-1)
11: ?? (??:-1)
12: ?? (??:-1)
13: ?? (??:-1)
14: _dl_runtime_resolve (??:-1)
15: ?? (??:-1)
16: JNI_OnLoad (??:-1)
17: ?? (??:-1)
18: ?? (??:-1)

Segmentation fault

Am I running the Harmony Launcher? Should I run it somewhat
differently?



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [General]Is there an agreement on different order of throwing Exceptions between RI and Harmony?

2006-09-18 Thread Andrew Zhang

Tony, we have got an agreement on exception-throwing compability issue[1].

But of course it's always OK to discuss any specific case.

[1]
http://incubator.apache.org/harmony/subcomponents/classlibrary/compat.html


On 9/18/06, Tony Wu <[EMAIL PROTECTED]> wrote:


I noticed there are many JIRA issues [1] about Exception order. Some of
them
were fixed whereas others were marked as non-bug difference.
I wonder which kind of Exception order problem should be fixed, and which
type should be left as non-bug difference.
Is there any agreement? I suggest setting one if not.

[1]
HARMONY-1214
HARMONY-1215
HARMONY-1240
HARMONY-1082
…


--
Tony Wu
China Software Development Lab, IBM





--
Andrew Zhang
China Software Development Lab, IBM


Re: [testing] optimization regressions (was: Re: [result] Re: [vote] HARMONY-1363 - DRLVM fixes and additions)

2006-09-18 Thread Pavel Ozhdikhin

On 18 Sep 2006 12:00:57 +0700, Egor Pasko <[EMAIL PROTECTED]> wrote:

On the 0x1E5 day of Apache Harmony Pavel Ozhdikhin wrote:
> Thanks for explaining. This is another variant of the bytecode-based
> regression tests.

This variant is also adoptable to Java-based and IR-based regression tests.



The IR-based framework proposed by Mikhail Fursov does not implies
running the transformed code so what you have just proposed makes a
new type of IR-based tests. Good idea for extension of the framework,
thank you!


> On 15 Sep 2006 17:53:00 +0700, Egor Pasko <[EMAIL PROTECTED]> wrote:
> >
> > On the 0x1E5 day of Apache Harmony Pavel Ozhdikhin wrote:
> > >  Egor,
> > >
> > > How Nullstone tests differ from what Rana proposed and Mikhail L.
> > prototyped
> > > - could you please elaborate?
> >
> > the idea is simple. You have two versions of a test. First --
> > unoptimized, second -- same algorithm, but optimized by hand with a
> > specific optimization. If the times of execution differ much, then,
> > the optimization is not done properly in the checked compiler.
> >
> > It works best with optimizations that are easy to represent in a
> > high-level language (i.e. Java), such as "load hoisting", "loop
> > unrolling", etc.
> >
> > see http://www.nullstone.com for more info
> >
> > --
> > Egor Pasko, Intel Managed Runtime Division
> >
> >
> > -
> > Terms of use : http://incubator.apache.org/harmony/mailing.html
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >

--
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-Pavel Ozhdikhin

-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Egor Pasko
On the 0x1E8 day of Apache Harmony Egor Pasko wrote:
> > >> If you let that run, it will build classlib and drlvm, and then
> > >> package in to hdk and jre, but I don't use this in my day to day life.
> > >>
> > >> I tend to go into either working_vm and build there via build/build.sh
> > >> (note you need to either set -Dextern.dep.CLASSLIB.loc correctly, or
> > >> just have a drlvm.properties file in working_vm/build or when I need a
> > >> classlib update, go up into working_classlib, do an svn update, and
> > >> then ant.
> > > 
> > > this one does not allow me to build.sh update on downloading
> > > XALAN. This is a kind of problem that appeared when classlib was not
> > > built, but now it looks like built successfully.
> > > 
> > > trying more...
> > 
> > Simple.  You need to tell the DRLVM build where to find the built
> > classlib.  Right now it assumes a structure like :
> > 
> >   enhanced/classlib/trunk
> >   enhanced/drlvm/trunk
> > 
> > but with the "federated build" structure of
> > 
> >   enhanced/trunk/
> > working_vm/
> > working_classlib/
> > 
> > I just put a file called "drlvm.properties" into
> > 
> >   enhanced/trunk/working_vm/build
> > 
> > that contains
> > 
> > external.dep.CLASSLIB.loc=../../../working_vm
> 
> gotcha! :)
> external.dep.CLASSLIB.loc=../../../working_classlib
> 
> maybe, put it in SVN directly? are there any caveats?
> 
> > and then I can go into working_classlib and refresh and build, and
> > working_vm just picks that up on build and local assembly of jre.
> 
> building further, drinking coffee..

interesting... if I build working_classlib and working_drlvm
separately, there is no issue with lcms.h, and the build is successful
(i.e. let's get rid of this lcms.h dependency later on)

And yet, I just cannot run it...

bash-boom-bang$ LD_LIBRARY_PATH=`pwd`:`pwd`/default ./java -showversion -cp 
<...> Hello
Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software 
Foundation or its licensors, as applicable.
java version "1.5.0"
pre-alpha : not complete or compatible
svn = r446534, (Sep 18 2006), Linux/ia32/gcc 3.3.3, debug build
http://incubator.apache.org/harmony
free(): invalid pointer 0xbfffd0b8!
SIGSEGV in VM code.
Stack trace:
1: free (??:-1)
2: ?? (??:-1)
3: hymem_free_memory (??:-1)
4: find_call_JNI_OnLoad 
(/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
5: properties_free (??:-1)
6: find_call_JNI_OnLoad 
(/export/users/evpasko/svn/harmony/enhanced/trunk/working_vm/vm/vmcore/src/util/natives_support.cpp:117)
7: ?? (??:-1)
8: readClassPathFromPropertiesFile (??:-1)
9: ?? (??:-1)
10: ?? (??:-1)
11: ?? (??:-1)
12: ?? (??:-1)
13: ?? (??:-1)
14: _dl_runtime_resolve (??:-1)
15: ?? (??:-1)
16: JNI_OnLoad (??:-1)
17: ?? (??:-1)
18: ?? (??:-1)

Segmentation fault

Am I running the Harmony Launcher? Should I run it somewhat
differently?

-- 
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Geir Magnusson Jr.



Egor Pasko wrote:

On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:

Egor Pasko wrote:

On the 0x1E5 day of Apache Harmony Geir Magnusson, Jr. wrote:

Am I doing something wrong? do we build with 'build.sh' yet?

?

I build only w/ build.sh

Here's how I work these days : I have checked out

 enhanced/trunk

and run "ant" in that directory, which will do a svn switch on
working_classlib and working_vm, checking out the head of
classlib/trunk and drlvm/trunk into those two directories.

trying...
"ant" from "enhanced/trunk" failed on "build.native", could not find 
lcms.h and icc34.h

sounds like a dependency problem...  we need to document those.  I'll do
that in a fresh install of Ubuntu sometime.


yeah, but isn't it a kind of false dependence? I wonder, why we need
liblcms.. need to investigate this.. maybe, unset HAVE_LCMS_H ...


looks exactly as this failure:
http://mail-archives.apache.org/mod_mbox/incubator-harmony-commits/200607.mbox/[EMAIL
 PROTECTED]


If you let that run, it will build classlib and drlvm, and then
package in to hdk and jre, but I don't use this in my day to day life.

I tend to go into either working_vm and build there via build/build.sh
(note you need to either set -Dextern.dep.CLASSLIB.loc correctly, or
just have a drlvm.properties file in working_vm/build or when I need a
classlib update, go up into working_classlib, do an svn update, and
then ant.

this one does not allow me to build.sh update on downloading
XALAN. This is a kind of problem that appeared when classlib was not
built, but now it looks like built successfully.

trying more...

Simple.  You need to tell the DRLVM build where to find the built
classlib.  Right now it assumes a structure like :

  enhanced/classlib/trunk
  enhanced/drlvm/trunk

but with the "federated build" structure of

  enhanced/trunk/
working_vm/
working_classlib/

I just put a file called "drlvm.properties" into

  enhanced/trunk/working_vm/build

that contains

external.dep.CLASSLIB.loc=../../../working_vm


gotcha! :)
external.dep.CLASSLIB.loc=../../../working_classlib


Doh!  of course :)



maybe, put it in SVN directly? are there any caveats?


Well, I don't think so - the only problem I can imagine is what happens 
when you do the federated build from enhanced/trunk, but now that I 
think of it, I've been working this way for months now, and it hasn't 
gotten in the way.


I'll check it in.

geir




and then I can go into working_classlib and refresh and build, and
working_vm just picks that up on build and local assembly of jre.


building further, drinking coffee..



-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [drlvm] HARMONY-1363 - status update

2006-09-18 Thread Egor Pasko
On the 0x1E8 day of Apache Harmony Geir Magnusson, Jr. wrote:
> Egor Pasko wrote:
> > On the 0x1E5 day of Apache Harmony Geir Magnusson, Jr. wrote:
> >>> Am I doing something wrong? do we build with 'build.sh' yet?
> >> ?
> >>
> >> I build only w/ build.sh
> >>
> >> Here's how I work these days : I have checked out
> >>
> >>  enhanced/trunk
> >>
> >> and run "ant" in that directory, which will do a svn switch on
> >> working_classlib and working_vm, checking out the head of
> >> classlib/trunk and drlvm/trunk into those two directories.
> > 
> > trying...
> > "ant" from "enhanced/trunk" failed on "build.native", could not find 
> > lcms.h and icc34.h
> 
> sounds like a dependency problem...  we need to document those.  I'll do
> that in a fresh install of Ubuntu sometime.

yeah, but isn't it a kind of false dependence? I wonder, why we need
liblcms.. need to investigate this.. maybe, unset HAVE_LCMS_H ...

> > looks exactly as this failure:
> > http://mail-archives.apache.org/mod_mbox/incubator-harmony-commits/200607.mbox/[EMAIL
> >  PROTECTED]
> > 
> >> If you let that run, it will build classlib and drlvm, and then
> >> package in to hdk and jre, but I don't use this in my day to day life.
> >>
> >> I tend to go into either working_vm and build there via build/build.sh
> >> (note you need to either set -Dextern.dep.CLASSLIB.loc correctly, or
> >> just have a drlvm.properties file in working_vm/build or when I need a
> >> classlib update, go up into working_classlib, do an svn update, and
> >> then ant.
> > 
> > this one does not allow me to build.sh update on downloading
> > XALAN. This is a kind of problem that appeared when classlib was not
> > built, but now it looks like built successfully.
> > 
> > trying more...
> 
> Simple.  You need to tell the DRLVM build where to find the built
> classlib.  Right now it assumes a structure like :
> 
>   enhanced/classlib/trunk
>   enhanced/drlvm/trunk
> 
> but with the "federated build" structure of
> 
>   enhanced/trunk/
> working_vm/
> working_classlib/
> 
> I just put a file called "drlvm.properties" into
> 
>   enhanced/trunk/working_vm/build
> 
> that contains
> 
> external.dep.CLASSLIB.loc=../../../working_vm

gotcha! :)
external.dep.CLASSLIB.loc=../../../working_classlib

maybe, put it in SVN directly? are there any caveats?

> and then I can go into working_classlib and refresh and build, and
> working_vm just picks that up on build and local assembly of jre.

building further, drinking coffee..

-- 
Egor Pasko, Intel Managed Runtime Division


-
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[General]Is there an agreement on different order of throwing Exceptions between RI and Harmony?

2006-09-18 Thread Tony Wu

I noticed there are many JIRA issues [1] about Exception order. Some of them
were fixed whereas others were marked as non-bug difference.
I wonder which kind of Exception order problem should be fixed, and which
type should be left as non-bug difference.
Is there any agreement? I suggest setting one if not.

[1]
HARMONY-1214
HARMONY-1215
HARMONY-1240
HARMONY-1082
…


--
Tony Wu
China Software Development Lab, IBM