OSDN Git Service

f26689af4ff9e057c2e0358febb70e0a736ede19
[pf3gnuchains/gcc-fork.git] / libjava / ChangeLog
1 2000-05-05  Tom Tromey  <tromey@cygnus.com>
2
3         Fix for PR libgcj/220:
4         * Makefile.in: Rebuilt.
5         * Makefile.am (gij_LDFLAGS): Don't use libstdc++.
6         (jv_convert_LDFLAGS): Likewise.
7         (libgcj_la_LDFLAGS): Likewise.
8         (GCJLINK): New macro.
9         (jv_convert_LINK): Use it.
10         (gij_LINK): Likewise.
11         (libgcj_la_LINK): New macro.
12         (libgcjawt_la_LINK): Likewise.
13
14 2000-05-04  Tom Tromey  <tromey@cygnus.com>
15
16         * gcj/field.h (JvFieldIsRef): Return false for gnu.gcj.RawData
17         field.
18         * boehm.cc (_Jv_MarkObj): Removed dead code.  Use `STATIC', not
19         `0x0008'.
20         Include Modifier.h.
21
22 2000-05-05  Bryce McKinlay  <bryce@albatross.co.nz>
23
24         * java/lang/natClass.cc (isInstance): Use __builtin_expect.
25         (_Jv_IsAssignableFrom): Ditto.
26         (_Jv_IsInstanceOf): Ditto.
27         (_Jv_CheckCast): Ditto.
28         (_Jv_CheckArrayStore): Ditto.
29         * java/lang/Class.h (_Jv_InitClass): Ditto.     
30         * java/lang/natObject.cc (_Jv_MonitorEnter): __builtin_expect `false',
31         not `0'.
32         (notify): Ditto.
33         (notifyAll): Ditto.
34         (wait): Ditto.
35         (_Jv_MonitorExit): Ditto.
36         * boehm.cc (_Jv_MarkObj): Ditto.
37         (_Jv_MarkObj): Ditto.
38         (_Jv_MarkArray): Ditto.
39         * prims.cc (_Jv_AllocObject): Ditto.
40         (_Jv_NewObjectArray): Ditto.
41         (_Jv_NewPrimArray): Ditto.
42         (_Jv_Malloc): Ditto.
43         (_Jv_Realloc): Ditto.
44         (_Jv_MallocUnchecked): Ditto.
45         (_Jv_divI): Ditto.
46         (_Jv_remI): Ditto.
47         (_Jv_divJ): Ditto.
48         (_Jv_remJ): Ditto.
49
50 2000-05-04  Tom Tromey  <tromey@cygnus.com>
51
52         * java/util/Locale.java (Locale): Don't explicitly check for
53         null.
54         * java/util/Hashtable.java (containsKey): Don't explicitly check
55         for null.
56         (get): Likewise.
57         * java/util/BitSet.java (and, or, xor): Don't explicitly check for
58         null.
59         * java/util/zip/ZipEntry.java (ZipEntry): Don't explicitly check
60         for null.
61         * java/text/StringCharacterIterator.java
62         (StringCharacterIterator): Don't check for null.
63         * java/text/ChoiceFormat.java (setChoices): Don't explicitly check
64         for null pointer.
65         * java/net/MulticastSocket.java (joinGroup): Don't explicitly
66         check for null pointer.
67         (leaveGroup): Likewise.
68         * java/net/DatagramPacket.java (DatagramPacket): Removed erroneous
69         comment.
70         (setData): Likewise.
71         * java/lang/ThreadGroup.java (ThreadGroup): Don't explicitly check
72         for `p==null'.
73
74 2000-04-28  Jakub Jelinek  <jakub@redhat.com>
75
76         * Makefile.am (GCJCOMPILE, JCFLAGS, JF1CLAGS, jv_convert_LINK,
77         gij_LINK, libgcj.zip, .java=.class): Move -L option out of FLAGS.
78         (libgcj_la_LDFLAGS): Add -L../libstdc++ for in-gcc builds.
79         (jv_convert_LDFLAGS, gij_LDFLAGS): Add `pwd`/../libstdc++ to
80         -rpath for in-gcc builds.
81         * Makefile.in: Rebuilt.
82
83 2000-04-28  Tom Tromey  <tromey@cygnus.com>
84
85         * libgcj.spec.in (*jc1): Added -fasynchronous-exceptions.
86         Fix for PR gcj/218.
87
88 2000-04-28  Bryce McKinlay  <bryce@albatross.co.nz>
89
90         * libjava/java/lang/String.java (toString): Remove `final' hack.
91
92 2000-04-05  Tom Tromey  <tromey@cygnus.com>
93
94         Runtime support for PR gcj/2:
95         * prims.cc (_Jv_ThrowNullPointerException): New function.
96         * include/jvm.h (_Jv_ThrowNullPointerException): Declare.
97
98 2000-04-27  Bryce McKinlay  <bryce@albatross.co.nz>
99
100         * prims.cc (_Jv_NewObjectArray): Fix typo.
101
102 2000-04-26  Tom Tromey  <tromey@cygnus.com>
103
104         * Makefile.in: Rebuilt.
105         * Makefile.am (AM_CXXFLAGS): Added -fasynchronous-exceptions.
106
107 2000-04-24  Jeff Sturm  <jsturm@sigma6.com>
108
109         * gnu/gcj/runtime/natFirstThread.cc (run): Initialize class before
110         calling main.
111
112 2000-04-22  Anthony Green  <green@cygnus.com>
113
114         * include/jvm.h (__builtin_expect): Define as unused for now.
115         * java/lang/natObject.cc (_Jv_MonitorEnter): Add __builtin_expect.
116         (notify): Ditto.
117         (notifyAll): Ditto.
118         (wait): Ditto.
119         (_Jv_MonitorExit): Ditto.
120         * boehm.cc (_Jv_MarkObj): Ditto.
121         (_Jv_MarkObj): Ditto.
122         (_Jv_MarkArray): Ditto.
123         (_Jv_AllocBytes): Ditto.
124         * prims.cc (_Jv_AllocObject): Ditto.
125         (_Jv_NewObjectArray): Ditto.
126         (_Jv_NewPrimArray): Ditto.
127         (_Jv_Malloc): Ditto.
128         (_Jv_Realloc): Ditto.
129         (_Jv_MallocUnchecked): Ditto.
130         (_Jv_divI): Ditto.
131         (_Jv_remI): Ditto.
132         (_Jv_divJ): Ditto.
133         (_Jv_remJ): Ditto.
134
135         * include/Makefile.in: Rebuilt.
136         * include/Makefile.am (include_HEADERS): Add jvmpi.h.
137
138 2000-04-21  Tom Tromey  <tromey@cygnus.com>
139
140         * java/io/PipedInputStream.java, java/io/PipedOutputStream.java:
141         Yet another new version from Classpath.
142
143         Fix for PR libgcj/15:
144         * java/util/natGregorianCalendar.cc (_REENTRANT,
145         _POSIX_PTHREAD_SEMANTICS): Don't define.
146         * java/net/natInetAddress.cc (_REENTRANT): Don't define.
147         * java/lang/natSystem.cc (_REENTRANT, _POSIX_PTHREAD_SEMANTICS):
148         Don't define.
149         * java/io/natFile.cc (_REENTRANT, _POSIX_PTHREAD_SEMANTICS): Don't
150         define.
151         * configure: Rebuilt.
152         * configure.in: If using POSIX threads, define _REENTRANT if
153         needed.  Define _POSIX_PTHREAD_SEMANTICS.  Don't define
154         GETHOSTBYNAME_R_NEEDS_REENTRANT.
155
156         * java/io/PipedInputStream.java, java/io/PipedReader.java,
157         java/io/PipedOutputStream.java, java/io/PipedWriter.java: New
158         version from Classpath.
159
160         Fix for PR libgcj/213:
161         * Makefile.in: Rebuilt.
162         * Makefile.am (gij_SOURCES): Added gij.cc.
163         (EXTRA_gij_SOURCES): Removed.
164         (gij_LDADD): Removed gij.lo.
165         (gij_DEPENDENCIES): Likewise.
166         ($(gij_OBJECTS)): Depend on nat_headers.
167
168         * gnu/gcj/protocol/file/Handler.java (openConnection): Use
169         `setURL', not `url.set'.
170
171 2000-04-20  Tom Tromey  <tromey@cygnus.com>
172
173         Fix for PR java.io/204:
174         * java/io/PipedInputStream.java, java/io/PipedReader.java,
175         java/io/PipedOutputStream.java, java/io/PipedWriter.java: Imported
176         from Classpath.
177
178         Fix for PR libgcj/212:
179         * gcj/javaprims.h (_Jv_word, _Jv_word2): Removed definitions.
180         * include/jvm.h (_Jv_word, _Jv_word2): Define.
181         * java/lang/Class.h (_Jv_word): Declare.
182
183         * jni.cc (_Jv_JNI_PopSystemFrame): Clear `env->ex'.
184
185 2000-04-19  Tom Tromey  <tromey@cygnus.com>
186
187         * jni.cc (_Jv_JNI_FindClass): Use system class loader if class
188         doesn't have a loader.
189
190 2000-04-19  Bryce McKinlay  <bryce@albatross.co.nz>
191
192         * boehm.cc: (_Jv_MarkObj, _Jv_MarkArray): Cast pointers for
193         MAYBE_MARK to ptr_t, for compatibility with new GC version.
194
195 2000-04-16  Bryce McKinlay  <bryce@albatross.co.nz>
196
197         * java/io/natFileDescriptorPosix.cc (open): Use mode 0666. Fix for PR
198         libgcj/202.
199         (available): Initialize `where' to prevent bogus compiler warning.
200
201 2000-04-12  Tom Tromey  <tromey@cygnus.com>
202
203         * java/lang/natString.cc (intern): Temporarily disable finalizer
204         registration.
205
206         * java/lang/natString.cc (unintern): Added `obj' argument.
207         (intern): Register finalizer for string.
208         * java/lang/String.java (unintern): Now static; added obj
209         argument.
210
211 2000-04-11  Tom Tromey  <tromey@cygnus.com>
212
213         * java/util/Vector.java (VectorEnumeration): Now `final'.
214         * java/util/Hashtable.java (HashtableEntry): Now `final'.
215         (HashtableEnumeration): Likewise.
216         * java/util/zip/ZipFile.java (ZipEnumeration): Now `final'.
217         * java/text/RuleBasedCollator.java (RBCElement): Now `final'.
218
219 2000-04-10  Warren Levy  <warrenl@cygnus.com>
220
221         * java/io/ObjectStreamException.java: New file.
222         * java/io/OptionalDataException.java: New file.
223         * java/io/StreamCorruptedException.java: New file.
224         * java/math/BigDecimal.java: New file.
225         * java/sql/CallableStatement.java: New file.
226         * java/sql/Connection.java: New file.
227         * java/sql/DataTruncation.java: New file.
228         * java/sql/DatabaseMetaData.java: New file.
229         * java/sql/Date.java: New file.
230         * java/sql/Driver.java: New file.
231         * java/sql/DriverManager.java: New file.
232         * java/sql/DriverPropertyInfo.java: New file.
233         * java/sql/PreparedStatement.java: New file.
234         * java/sql/ResultSet.java: New file.
235         * java/sql/ResultSetMetaData.java: New file.
236         * java/sql/SQLException.java: New file.
237         * java/sql/SQLWarning.java: New file.
238         * java/sql/Statement.java: New file.
239         * java/sql/Time.java: New file.
240         * java/sql/Timestamp.java: New file.
241         * java/sql/Types.java: New file.
242         * Makefile.am: Added above new files.
243         * Makefile.in: Rebuilt.
244
245         * mauve-libgcj: Turned on java.math, java.sql and java.security tests.
246         * java/net/MulticastSocket.java (MulticastSocket): Pass values a la
247         DatagramSocket constructor instead of null.
248
249 2000-04-08  Anthony Green  <green@cygnus.com>
250
251         * include/posix-threads.h (_Jv_MutexUnlock): Replace
252         _JV_NOT_OWNER.
253         
254 2000-04-08  Anthony Green  <green@cygnus.com>
255
256         * posix-threads.cc (_Jv_MutexLock): Moved back to posix-threads.h.
257         (_Jv_MutexUnlock): Ditto.
258         * include/posix-threads.h (_Jv_MutexLock): From posix-threads.cc.
259         (_Jv_MutexUnlock): Ditto.
260
261 2000-04-08  Anthony Green  <green@cygnus.com>
262
263         * java/lang/StringBuffer.java (ensureCapacity): Don't call Math::max.
264         (ensureCapacity_unsynchronized): New private method.
265         (append): Use ensureCapacity_unsynchronized.
266
267 2000-04-08  Tom Tromey  <tromey@cygnus.com>
268
269         * Makefile.in: Rebuilt.
270         * Makefile.am (awt_java_source_files): Added new files.
271         * java/awt/IllegalComponentStateException.java: New file.
272         * java/awt/ItemSelectable.java: New file.
273         * java/awt/event/WindowEvent.java: Finished.
274         * java/awt/event/TextEvent.java: Finished.
275         * java/awt/event/ContainerEvent.java: New file.
276         * java/awt/Component.java (getX, getY): New methods.
277         * java/awt/event/PaintEvent.java: New file.
278         * java/awt/event/MouseEvent.java: New file.
279         * java/awt/ActiveEvent.java: New file.
280         * java/awt/event/KeyEvent.java: Finished.
281         * java/awt/event/ItemEvent.java: New file.
282         * java/awt/Adjustable.java: New file.
283         * java/awt/event/InputMethodEvent.java: New file.
284         * java/awt/event/InputEvent.java: Finished.
285         * java/awt/event/FocusEvent.java: New file.
286         * java/awt/event/MouseMotionAdapter.java: New file.
287         * java/awt/event/MouseAdapter.java: New file.
288         * java/awt/event/KeyAdapter.java: New file.
289         * java/awt/event/FocusAdapter.java: New file.
290         * java/awt/event/ContainerAdapter.java: New file.
291         * java/awt/event/ComponentEvent.java: Finished.
292         * java/awt/event/AdjustmentEvent.java: New file.
293         * java/awt/event/ComponentAdapter.java: New file.
294         * java/awt/event/ActionEvent.java: Finished.
295         * java/awt/event/MouseMotionListener.java: New file.
296         * java/awt/event/MouseListener.java: New file.
297         * java/awt/event/ItemListener.java: New file.
298         * java/awt/event/InputMethodListener.java: New file.
299         * java/awt/event/ContainerListener.java: New file.
300         * java/awt/event/FocusListener.java: New file.
301         * java/awt/event/ComponentListener.java: New file.
302         * java/awt/event/AWTEventListener.java: New file.
303         * java/awt/event/AdjustmentListener.java: New file.
304
305 2000-04-08  Anthony Green  <green@cygnus.com>
306
307         * java/lang/natObject.cc (_Jv_MonitorEnter): Only perform null
308         check when we have to.
309
310         * gcj/array.h: Mark elements(JArray<T>& x) and elements(JArray<T>*
311         x) as `inline'.
312
313         * java/util/StringTokenizer.java: Minor optimization.  Eliminates
314         one method call.
315
316         * java/util/Vector.java (VectorEnumeration.nextElement): Manually
317         inline hasMoreElements.
318
319 2000-04-05  Tom Tromey  <tromey@cygnus.com>
320
321         * configure: Rebuilt.
322         * configure.in: Recognize --enable-java-awt.
323         (AWT): New conditional.
324         * Makefile.in: Rebuilt.
325         * Makefile.am (toolexeclib_LTLIBRARIES): Build libgcjawt.la if
326         requested.
327         (libgcjawt_la_SOURCES): New macro.
328         (EXTRA_libgcjawt_la_SOURCES): Likewise.
329         (libgcjawt_la_DEPENDENCIES): Likewise.
330         (libgcjawt_la_LIBADD): Likewise.
331         (libgcjawt_la_LDFLAGS): Likewise.
332         (libgcj.zip): Depend on cond_java_awt_source_files
333         (cond_awt_java_source_files): New macro.
334         (MOSTLYCLEANFILES): Added awto_files.
335         (awto_files): New macro.  Use where javao_files used.
336         (nat_headers): Use cond_awt_java_source_files.
337
338 2000-04-04  Tom Tromey  <tromey@cygnus.com>
339
340         * Makefile.in: Rebuilt.
341         * Makefile.am (awt_java_source_files): Added AWTException.java.
342         * java/awt/AWTException.java: New file.
343
344 2000-04-03  Tom Tromey  <tromey@cygnus.com>
345
346         * include/jvm.h (_Jv_GetArrayElementFromElementType): More
347         commentary from Alex.
348
349         * Makefile.in: Rebuilt.
350         * Makefile.am ($(javao_files)): Depend on libgcj.zip.
351         From H.J. Lu.
352
353 Sun Apr  2 08:27:18 2000  Anthony Green  <green@redhat.com>
354
355         * configure: Rebuilt.
356         * configure.in: Add --disable-jvmpi.
357         * include/config.h.in: Rebuilt.
358         * acconfig.h: Add ENABLE_JVMPI.
359          
360         * include/jvm.h: Declare _Jv_DisableGC and _Jv_EnableGC.
361         (_Jv_JVMPI_Notify_OBJECT_ALLOC): New define.
362         (_Jv_JVMPI_Notify_THREAD_END): New define.
363         (_Jv_JVMPI_Notify_THREAD_END): New define.
364         * prims.cc (_Jv_JVMPI_Notify_OBJECT_ALLOC): Declare.
365         (_Jv_JVMPI_Notify_THREAD_END): Declare.
366         (_Jv_JVMPI_Notify_THREAD_END): Declare.
367
368         * prims.cc (_Jv_AllocObject): Generate JVMPI object allocation
369         events.
370
371         * java/lang/natThread.cc: Include JVMPI headers if necessary.
372         (finish_): Generate JVMPI thread end events.
373         (run_): Generate JVMPI thread start events.
374         * gnu/gcj/runtime/natFirstThread.cc (run): Call JNI_OnLoad for any
375         preloaded JNI library.
376         Include JVMPI headers if necessary.
377         (run): Generate JVMPI thread start events.
378
379         * boehm.cc: Define GC_disable and GC_enable.
380         (_Jv_DisableGC): New function.
381         (_Jv_EnableGC): New function.
382         (disable_gc_mutex): Declare.
383         * nogc.cc (_Jv_DisableGC): New function.
384         (_Jv_EnableGC): New function.
385           
386         * jni.cc (_Jv_JNI_GetEnv): Handle JVMPI interface requests.
387         (_Jv_JVMPI_Interface): Define.
388         (jvmpiEnableEvent): New function.
389         (_Jv_JNI_Init): Initialize _Jv_JVMPI_Interface.
390           
391         * include/jvmpi.h: New file.
392
393 2000-03-27  Bryce McKinlay  <bryce@albatross.co.nz>
394
395         * Makefile.in: New #defines and friends for Thread.h.
396         * Makefile.am: Ditto.
397         * posix-threads.cc: (struct starter): Remove `object'.
398         (_Jv_CondWait): Use interruptable condition variables and new
399         recursive mutexes. New return codes on interrupt or non-ownership
400         of mutex.
401         (_Jv_CondNotify): Ditto.
402         (_Jv_CondNotifyAll): Ditto.
403         (_Jv_ThreadInterrupt): Set thread interrupt flag directly. Interrupt
404         the target thread by signaling its wait condition.
405         (_Jv_ThreadInitData): Set `thread_obj' in the thread data struct,
406         not the starter struct. Initialize wait_mutex and wait_cond.
407         (_Jv_MutexLock): New recursive mutex implementation. Moved from 
408         posix-threads.h.
409         (_Jv_MutexUnlock): Ditto.
410         (really_start): Set info->data->thread from pthread_self() to work 
411         around a race condition. Destroy wait_mutex and wait_cond when run()
412         returns.
413         * java/lang/Thread.java: (isInterrupted_): Renamed to overloaded
414         `isInterrupted(boolean)'. Clear interrupted flag if clear_flag is
415         set.
416         startable_flag: New private field.
417         (Thread): Initialize `startable_flag'.
418         (toString): Check for null thread group.
419         * java/lang/natThread.cc: (struct natThread): New fields 
420         `join_mutex', `join_cond'. Removed fields `joiner', `next'.
421         (class locker): Removed.
422         (initialize_native): Initialize `join_cond' and `join_mutex'.
423         (interrupt): Now just calls _Jv_ThreadInterrupt().
424         (join): Simplified. Just wait on the target thread's join condition.
425         (finish_): Remove join list code. Unset thread group. Signal
426         potential joiners by notifying the dying threads join_cond.
427         (start): Check for illegal restarts.
428         * java/lang/natObject.cc: Check for return value of _Jv_CondWait and
429         act appropriatly.
430         * include/posix-threads.h: Remove all HAVE_RECURSIVE_MUTEX related
431         #defines and #ifdefs.
432         (struct _Jv_Thread_t): New fields `thread_obj', `wait_cond',
433         `wait_mutex', `next'.
434         (struct _Jv_ConditionVariable_t): Define as a struct instead of 
435         directly mapping to pthread_cond_t.
436         (struct _Jv_Mutex_t): New recursive implementation.
437         (_Jv_PthreadCheckMonitor): Reimplemented. Simple `owner' check.
438         _Jv_HaveCondDestroy: Never define this for posix-threads.
439         (_Jv_CondNotify): Remove inline implementation(s), prototype instead.
440         (_Jv_CondNotifyAll): Ditto.
441         (_Jv_MutexLock): Ditto.
442         (_Jv_MutexUnlock): Ditto.
443         (_Jv_MutexInit): Changed to reflect new mutex implementation.
444         (_Jv_MutexDestroy): Ditto.
445         (_Jv_CondDestroy): Removed.
446         (_Jv_PthreadGetMutex): Removed.
447         * include/win32-threads.h: (_Jv_CondNotify): Guess _JV_NOT_OWNER on an 
448         error. Add a FIXME about this.
449         (_Jv_CondNotifyAll): Ditto.
450         * win32-threads.cc: (_Jv_CondWait): Return 0 on a timeout. Guess 
451         _JV_NOT_OWNER on other errors. Add FIXME.
452
453 2000-03-26  Tom Tromey  <tromey@cygnus.com>
454
455         * jni.cc (_Jv_JNI_PopSystemFrame): If environment has exception
456         set, throw it.
457         (call): Don't throw exception here.
458
459 2000-03-26  Tom Tromey  <tromey@cygnus.com>
460
461         * java/lang/mprec.h: Use SIZEOF_VOID_P.
462         * interpret.cc: Use SIZEOF_VOID_P.
463         * include/java-cpool.h (_Jv_storeLong): Use SIZEOF_VOID_P.
464         (_Jv_loadLong): Likewise.
465         (_Jv_storeDouble): Likewise.
466         * configure: Rebuilt.
467         * configure.in: Check size of void*.
468
469         * resolve.cc (ncode): Use FFI_PREP_RAW_CLOSURE and FFI_RAW_SIZE.
470
471 2000-03-26  Hans Boehm  <boehm@acm.org>
472
473         * include/java-cpool.h (_Jv_storeLong, _Jv_loadLong,
474         _Jv_storeDouble, _Jv_loadDouble): Define differently on 64 bit
475         machine.
476         * java/lang/ieeefp.h: Define __IEEE_BIG_ENDIAN or
477         __IEEE_LITTLE_ENDIAN appropriately on IA64.
478         * java/lang/mprec.h: Don't define Pack_32 on 64 bit machine.
479         * javaprims.h (_Jv_word): Added `l' and `d' entries in 64 bit
480         case.
481         * resolve.cc (FFI_PREP_RAW_CLOSURE): New define.
482         (FFI_RAW_SIZE): Likewise.
483         (_Jv_InterpMethod::ncode): Use them.
484         * interpret.cc (PUSHL, PUSHD, POPL, POPD, LOADL, LOADD, STOREL,
485         STORED): Define differently on a 64 bit machine.
486         (continue1): Use ffi_java_raw_call when appropriate.
487  
488 2000-03-24  Warren Levy  <warrenl@cygnus.com>
489
490         * java/math/BigInteger.java(divide): Handle the special case when
491         dividing by 1 and the high bit of the dividend is set.
492         (setShiftRight): Handle case when count == 0.
493
494 2000-03-24  Warren Levy  <warrenl@cygnus.com>
495
496         * java/awt/Font.java(isBold): Fix syntax error.
497         (isItalic): ditto.
498         * java/awt/Frame.java(postEvent): ditto.
499         * java/awt/Menu.java(postEvent): ditto.
500         * java/awt/MenuBar.java(postEvent): ditto.
501         * java/awt/Toolkit.java(init): Included a stub.
502
503 2000-03-21  Bryce McKinlay  <bryce@albatross.co.nz>
504
505         * java/awt/Event.java: Add all the event type constants.
506         (Event): Implemented constructors.
507         (controlDown): Implemented.
508         (metaDown): Implemented.
509         (paramString): Stubbed.
510         (shiftDown): Implemented.
511         (toString): Implemented.
512         (translate): Implemented.
513
514 2000-03-21  Bryce McKinlay  <bryce@albatross.co.nz>
515
516         * java/lang/natClass.cc (isInstance): Initialize `this'.
517         (isAssignableFrom): Initialize `this' and `klass'.
518         (_Jv_IsAssignableFrom): If an interface has no idt, it is not 
519         implemented by any loaded class, so return false.
520         * java/lang/natClass.cc (isInstance): Use _Jv_IsAssignableFrom(), 
521         not Class.isAssignableFrom(). Use JV_CLASS, not getClass().
522
523 2000-03-19  Warren Levy  <warrenl@cygnus.com>
524
525         * java/awt/Color.java: Specified java.io for Serializable.
526         * java/awt/Toolkit.java: Imported java.net.URL.
527
528 2000-03-19  Warren Levy  <warrenl@cygnus.com>
529
530         * java/awt/Color.java: Rewrote to be more memory efficient (& compile).
531
532 2000-03-16  Warren Levy  <warrenl@cygnus.com>
533
534         * java/awt/Color.java: New file.
535         * java/awt/Graphics.java: New file.
536         * java/awt/Image.java: New file.
537         * java/awt/Paint.java: New file.
538         * java/awt/PaintContext.java: New file.
539         * java/awt/Transparency.java: New file.
540         * java/util/Collection.java: New file.
541         * java/util/Comparator.java: New file.
542         * java/util/Iterator.java: New file.
543         * java/util/List.java: New file.
544         * java/util/ListIterator.java: New file.
545         * Makefile.am: Added above new files.
546         * Makefile.in: Rebuilt.
547
548         * java/awt/Font.java (PLAIN): New field.
549         (BOLD): New field.
550         (ITALIC): New field.
551         (ROMAN_BASELINE): New field.
552         (CENTER_BASELINE): New field.
553         (HANGING_BASELINE): New field.
554         (name): New field.
555         (style): New field.
556         (size): New field.
557         (pointSize): New field.
558         (Font): Implemented constructor.
559         (isPlain): Implemented method.
560         (isBold): Implemented method.
561         (isItalic): Implemented method.
562         (getName): Implemented method.
563         (getStyle): Implemented method.
564         (getSize): Implemented method.
565         (getSize2D): Implemented method.
566         (decode): Stubbed.
567         * java/awt/Frame.java (getFont): Stubbed.
568         (postEvent): Stubbed.
569         (remove): Stubbed.
570         * java/awt/Menu.java (postEvent): Stubbed.
571         * java/awt/MenuBar.java (getFont): Stubbed.
572         (postEvent): Stubbed.
573         * java/awt/Toolkit.java (getImage): Added abstract method.
574
575 2000-03-15  Tom Tromey  <tromey@cygnus.com>
576
577         * java/io/natFileDescriptorWin32.cc (winerr): Now static.
578
579         * prims.cc (win32_exception_handler): Reformatted.
580
581         * include/win32-threads.h (_Jv_HaveCondDestroy): New define.
582         (_Jv_HaveMutexDestroy): Likewise.
583
584 2000-03-15 Jon Beniston <jb7216@bristol.ac.uk>
585
586         * java/io/natFileDescriptorWin32.cc: New file.
587         * java/io/natFileWin32.cc: New file.
588         * java/net/natInetAddress.cc: Added conditional inclusion of
589         Windows / Winsock headers.
590         * java/net/natPlainDatagramSocketImpl.cc: Added conditional
591         inclusion of Windows / Winsock headers.
592         * java/net/natPlainSocketImpl.cc: Added conditional inclusion of
593         Windows / Winsock headers.
594         * include/win32-signal.h: New file.
595         * include/win32-threads.h: New file.
596         * win32-threads.cc: New file.
597         * exception.cc (win32_get_restart_frame): New function.
598         * prims.cc (win32_exception_handler): New function.
599         (main_init) Performs Winsock initialisation.
600         (main_init) Installs exeception handler.
601
602 2000-03-14  Tom Tromey  <tromey@cygnus.com>
603
604         * jni.cc (mangled_name): Fixed assertion.
605         (JNI_GetCreatedJavaVMs): Don't comment out `buf_len' argument;
606         turned assert into actual failure.
607
608 2000-03-09  Warren Levy  <warrenl@cygnus.com>
609
610         * java/security/Key.java(serialVersionUID): Set to 0 for now.
611         * java/security/interfaces/DSAPrivateKey.java(serialVersionUID): Ditto.
612         * java/security/interfaces/DSAPublicKey.java(serialVersionUID): Ditto.
613
614 2000-03-09  Warren Levy  <warrenl@cygnus.com>
615
616         * java/security/AlgorithmParameterGeneratorSpi.java: New file.
617         * java/security/DigestException.java: New file.
618         * java/security/GeneralSecurityException.java: New file.
619         * java/security/InvalidAlgorithmParameterException.java: New file.
620         * java/security/InvalidKeyException.java: New file.
621         * java/security/InvalidParameterException.java: New file.
622         * java/security/Key.java: New file.
623         * java/security/KeyException.java: New file.
624         * java/security/KeyPair.java: New file.
625         * java/security/KeyPairGenerator.java: New file.
626         * java/security/KeyPairGeneratorSpi.java: New file.
627         * java/security/NoSuchProviderException.java: New file.
628         * java/security/PrivateKey.java: New file.
629         * java/security/Provider.java: New file.
630         * java/security/PublicKey.java: New file.
631         * java/security/SecureRandom.java: New file.
632         * java/security/Security.java: New file.
633         * java/security/Signature.java: New file.
634         * java/security/SignatureException.java: New file.
635         * java/security/interfaces/DSAKey.java: New file.
636         * java/security/interfaces/DSAParams.java: New file.
637         * java/security/interfaces/DSAPrivateKey.java: New file.
638         * java/security/interfaces/DSAPublicKey.java: New file.
639         * java/security/interfaces/RSAPrivateCrtKey.java: New file.
640         * java/security/interfaces/RSAPrivateKey.java: New file.
641         * java/security/interfaces/RSAPublicKey.java: New file.
642         * java/security/spec/AlgorithmParameterSpec.java: New file.
643         * java/security/spec/InvalidKeySpecException.java: New file.
644         * java/security/spec/InvalidParameterSpecException.java: New file.
645         * java/security/spec/KeySpec.java: New file.
646         * java/security/spec/RSAPrivateCrtKeySpec.java: New file.
647         * java/security/spec/RSAPrivateKeySpec.java: New file.
648         * java/security/spec/RSAPublicKeySpec.java: New file.
649         * Makefile.am: Added above java.security files.
650         * Makefile.in: Rebuilt.
651
652         * java/security/MessageDigest.java: Rewritten.
653         * java/security/SecureClassLoader.java: Added JDK1.2 comment.
654
655 2000-03-09  Bryce McKinlay  <bryce@albatross.co.nz>
656
657         * README: Updated.
658
659 2000-03-09  Bryce McKinlay  <bryce@albatross.co.nz>
660
661         * java/lang/natClassLoader.cc (_Jv_FindArrayClass): Call
662         _Jv_PrepareConstantTimeTables.
663         * java/lang/natClass.cc (_Jv_PrepareConstantTimeTables): Array
664         classes should have an IDT, so don't return if klass is an array
665         class.
666
667 2000-03-08  Tom Tromey  <tromey@cygnus.com>
668
669         * java/lang/reflect/natArray.cc (newInstance): Don't allow array
670         of `void' to be created.
671
672 2000-03-08  Warren Levy  <warrenl@cygnus.com>
673
674         * java/math/BigInteger.java(signum): Handle zero properly.
675
676 2000-03-07  Tom Tromey  <tromey@cygnus.com>
677
678         * All files: Updated copyright information.
679         * COPYING: New file.
680         * COPYING.LIB: Removed.
681         * LIBGCJ_LICENSE: We now use GPL + special exception.
682
683 2000-03-07  Bryce McKinlay  <bryce@albatross.co.nz>
684
685         * resolve.cc (_Jv_SearchMethodInClass): New function.
686         (_Jv_ResolvePoolEntry): Search superinterfaces for interface methods.
687         * java/lang/Class.h (_Jv_SearchMethodInClass): New prototype.
688
689 2000-03-07  Bryce McKinlay  <bryce@albatross.co.nz>
690
691         * java/lang/Class.h (union _Jv_IDispatchTable): New declaration.
692         (struct _Jv_ifaces): New declaration.
693         JV_CLASS: New macro definition.
694         (getComponentType): Relocate below isArray() for inlining.
695         (getModifiers): Declare `inline'.
696         (getSuperclass): Ditto.
697         (isArray): Ditto.
698         (isPrimitive): Ditto.
699         (_Jv_IsAssignableFrom): New prototype.
700         (_Jv_LookupInterfaceMethodIdx): New prototype. Predeclare with "C"
701         linkage.
702         (_Jv_InitClass): Move from natClass.cc. Declare `inline'.
703         Check for JV_STATE_DONE before invoking initializeClass().
704         (_Jv_PrepareConstantTimeTables): New prototype.
705         (_Jv_GetInterfaces): Ditto.
706         (_Jv_GenerateITable): Ditto.
707         (_Jv_GetMethodString): Ditto.
708         (_Jv_AppendPartialITable): Ditto.
709         (_Jv_FindIIndex): Ditto.
710         depth, ancestors, idt: New class fields.
711
712         * java/lang/natClass.cc (isAssignableFrom): Move functionality to
713         inline function `_Jv_IsAssignableFrom'. Use that function.
714         (isInstance): Declare `inline'.
715         (initializeClass): Get lock on class before checking `state'. Unlock 
716         before calling resolveClass0. Call _Jv_PrepareConstantTimeTables with 
717         the lock held.
718         (_Jv_LookupInterfaceMethod): Use _Jv_GetMessageString.
719         (_Jv_IsAssignableFrom): New inline function. Test assignability using 
720         class->depth and ancestor table.
721         (_Jv_IsInstanceOf): Use _Jv_IsAssignableFrom.
722         (_Jv_CheckCast): Move from prims.cc. Use JV_CLASS and
723         _Jv_IsAssignableFrom.
724         (_Jv_CheckArrayStore): Ditto.
725         (_Jv_LookupInterfaceMethodIdx): New function. 
726         INITIAL_IOFFSETS_LEN, INITIAL_IFACES_LEN: New #defines.
727         (_Jv_PrepareConstantTimeTables): New function.
728         (_Jv_IndexOf): Ditto.
729         (_Jv_GetInterfaces): Ditto.
730         (_Jv_GenerateITable): Ditto.
731         (_Jv_GetMethodString): Ditto.
732         (_Jv_AppendPartialITable): Ditto.
733         iindex_mutex, iindex_mutex_initialized: New static fields.
734         (_Jv_FindIIndex): New function.
735
736         * java/lang/natClassLoader.cc (_Jv_NewClass): Set new jclass fields.
737
738         * prims.cc (_Jv_CheckCast): Moved to natClass.cc.
739         (_Jv_CheckArrayStore): Ditto.
740         (JvNewCharArray, JvNewBooleanArray, JvNewByteArray, JvNewShortArray,
741         JvNewIntArray, JvNewLongArray, JvNewFloatArray, JvNewDoubleArray):
742         Moved to gcj/array.h.
743         (_Jv_Realloc): New function.
744
745         * gcj/cni.h: Move _Jv_PrimClass definitions to gcj/array.h.
746
747         * gcj/array.h: _Jv_PrimClass definitions moved from gcj/cni.h.
748         (JvNewCharArray, JvNewBooleanArray, JvNewByteArray,
749         JvNewShortArray, JvNewIntArray, JvNewLongArray, JvNewFloatArray,
750         JvNewDoubleArray): Implementations moved from prims.cc and
751         declared `inline'.
752
753         * gcj/javaprims.h (_Jv_Realloc): Prototype.
754
755         * include/jvm.h (_Jv_LookupInterfaceMethodIdx): Prototype.
756
757 2000-03-06  Tom Tromey  <tromey@cygnus.com>
758
759         * jni.cc (MARK_NONE): New define.
760         (MARK_USER): Likewise.
761         (MARK_SYSTEM): Likewise.
762         (struct _Jv_JNI_LocalFrame): Made `marker' bigger and `size'
763         smaller.
764         (_Jv_JNI_DeleteLocalRef): Use MARK_NONE in assert.
765         (_Jv_JNI_EnsureLocalCapacity): Use MARK_NONE.
766         (_Jv_JNI_PushLocalFrame): Use MARK_USER.
767         (_Jv_JNI_PopLocalFrame): New version with additional `stop'
768         argument.
769         (call): Use MARK_SYSTEM.
770         (_Jv_GetJNIEnvNewFrame): New function.
771         (_Jv_LookupJNIMethod): New function.
772         (_Jv_JNI_PopSystemFrame): New function.
773         (call): Use _Jv_JNI_PopSystemFrame and _Jv_LookupJNIMethod.
774
775 2000-03-05  Tom Tromey  <tromey@cygnus.com>
776
777         Fix for PR libgcj/43:
778         * include/Makefile.in: Rebuilt.
779         * include/Makefile.am (include_HEADERS): New define.
780
781 2000-03-05  Anthony Green  <green@redhat.com>
782
783         * gcj/javaprims.h ("Java"): Remove FirstThread.
784
785         * configure.host: Fix __NO_MATH_INLNES botch.
786
787         * Makefile.in: Rebuilt.
788         * Makefile.am (nat_source_files): Move natFirstThread.cc.
789         (gnu/gcj/runtime/FirstThread.h): Moved.
790         (ordinary_java_source_files): Move FirstThread.java.
791         * prims.cc: Deal with FirstThread movement.
792         (JvRunMain): Ditto.
793         (_Jv_RunMain): Ditto.
794
795         * gnu/gcj/runtime/FirstThread.java: Moved from java/lang.
796         * gnu/gcj/runtime/natFirstThread.cc: Ditto.
797
798 2000-03-05  Warren Levy  <warrenl@cygnus.com>
799
800         * java/net/DatagramSocket.java(DatagramSocket(int,InetAddress)):
801           Handle null addresses.
802
803 2000-03-04  Anthony Green  <green@redhat.com>
804
805         * configure.host (libgcj_flags): Define __NO_MATH_INLINES.
806         See PR gcj/151.
807
808 2000-03-04  Anthony Green  <green@redhat.com>
809
810         * configure: Rebuilt.
811         * configure.in (ZLIBTESTSPEC): New macro.
812         (GCTESTSPEC): New macro.
813         (LIBGCJTESTSPEC): New macro.
814         * libgcj-test.spec.in: New file.
815
816 2000-03-02  Tom Tromey  <tromey@cygnus.com>
817
818         * include/java-interp.h: Don't include MethodInvocation.h.
819         (class _Jv_InterpMethod): Don't make MethodInvocation a friend.
820         * Makefile.in: Rebuilt.
821         * Makefile.am (gnu/gcj/runtime/MethodInvocation.h): Removed.
822         (ordinary_java_source_files): Don't mention
823         MethodInvocation.java.
824         * gnu/gcj/runtime/MethodInvocation.java: Removed.
825         * interpret.cc (MethodInvocation::continue1): Removed.
826         (run): Handle exceptions here.
827         * java/lang/ClassLoader.java (defineClass1, defineClass2):
828         Removed.
829         * java/lang/natClassLoader.cc (defineClass0): Catch exceptions
830         here.
831         (defineClass2): Removed.
832
833         * java/lang/reflect/Method.java (hack_trampoline, hack_call):
834         Removed.
835         * java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Catch
836         exceptions here.
837         (hack_call): Removed.
838
839         * java/lang/Class.h (Class): Removed hackRunInitializers,
840         hackTrampoline.
841         * java/lang/natClass.cc (hackRunInitializers): Removed.
842         (initializeClass): Catch exceptions here.
843         Include ExceptionInInitializerError.h.
844         * java/lang/Class.java (hackTrampoline, hackRunInitializers):
845         Removed.
846
847         * java/lang/Object.h (Object): Don't mention hack12_6.
848         * java/lang/natObject.cc (_Jv_FinalizeObject): Catch exceptions
849         here.
850         * java/lang/Object.java (hack12_6): Removed.
851
852         * java/lang/natThread.cc (run_): Renamed.  Catch exceptions here.
853         (start): Use run_, not run__.
854         * java/lang/Thread.java (run_): Renamed from run__; old run_
855         removed.
856
857         * jni.cc (_Jv_JNI_FindClass): Handle exceptions.
858         (_Jv_JNI_EnsureLocalCapacity): Likewise.
859         (_Jv_JNI_DefineClass): Likewise.
860         (_Jv_JNI_ThrowNew): Likewise.
861         (_Jv_JNI_AllocObject): Likewise.
862         (_Jv_JNI_GetAnyMethodID): Likewise.
863         (_Jv_JNI_CallAnyMethodV): Likewise.
864         (_Jv_JNI_CallAnyMethodA): Likewise.
865         (_Jv_JNI_CallAnyVoidMethodV): Likewise.
866         (_Jv_JNI_CallAnyVoidMethodA): Likewise.
867         (_Jv_JNI_GetAnyFieldID): Likewise.
868         (_Jv_JNI_NewString): Likewise.
869         (_Jv_JNI_NewStringUTF): Likewise.
870         (_Jv_JNI_GetStringUTFChars): Likewise.
871         (_Jv_JNI_NewObjectArray): Likewise.
872         (_Jv_JNI_NewPrimitiveArray): Likewise.
873         (_Jv_JNI_GetPrimitiveArrayRegion): Likewise.
874         (_Jv_JNI_GetStringRegion): Likewise.
875         (_Jv_JNI_GetStringUTFRegion): Likewise.
876         (_Jv_JNI_SetPrimitiveArrayRegion): Likewise.
877         (_Jv_JNI_MonitorEnter): Likewise.
878         (_Jv_JNI_MonitorExit): Likewise.
879         (_Jv_JNI_ToReflectedField): Likewise.
880         (_Jv_JNI_ToReflectedMethod): Likewise.
881         (_Jv_JNI_RegisterNatives): Likewise.
882         (_Jv_JNI_AttachCurrentThread): Likewise.
883         (_Jv_JNI_DestroyJavaVM): Likewise.
884
885 2000-02-28  Mo DeJong  <mdejong@cygnus.com>
886
887         * java/util/zip/ZipOutputStream.java(closeEntry) : Fixed
888         error caused by the incorrect casting of a long to an int.
889
890 2000-02-28  Mo DeJong  <mdejong@cygnus.com>
891
892         * java/util/zip/ZipOutputStream.java(write_entry) : Fixed
893         SIGSEV caused by use of the wrong instance variable.
894
895 2000-02-27  Bryce McKinlay  <bryce@albatross.co.nz>
896
897         * java/io/File.java (File(String, String)): For dirPath, treat an
898         empty String the same as `null'.
899
900 2000-02-26  Anthony Green  <green@cygnus.com>
901
902         * gnu/gcj/io/MimeTypes.java: Test for null.
903
904         * jni.cc (_Jv_JNI_AttachCurrentThread): Minor cleanup.
905         (JNI_GetCreatedJavaVMs): Remove compiler warning.
906
907         * java/net/URLConnection.java: Update copyright notice.
908
909 2000-02-25  Tom Tromey  <tromey@cygnus.com>
910
911         * jni.cc (_Jv_JNI_RegisterNatives): Conditionalize body on
912         `INTERPRETER'.
913
914 2000-02-25  Bryce McKinlay  <bryce@albatross.co.nz>
915
916         * java/net/URLConnection.java (initializeDateFormats): New
917         private method.
918         (getHeaderFieldDate): Call initializeDateFormats if required.
919         locale, dateFormat1, dateFormat2, dateFormat3: Don't initialize
920         these.
921         Fix for PR libgcj/38.
922
923 2000-02-24  Warren Levy  <warrenl@cygnus.com>
924
925         * java/math/BigInteger.java(ival): Made private.
926         (words): Ditto.
927         (neg): Ditto.
928
929 2000-02-20  Anthony Green  <green@cygnus.com>
930
931         * Makefile.in: Rebuilt.
932         * Makefile.am (ordinary_java_source_files): Add
933         gnu/gcj/io/DefaultMimeTypes.java and gnu/gcj/io/MimeTypes.java
934
935         * scripts/MakeDefaultMimeTypes.java: New file.
936         * scripts/mime.types: New file.
937         * scripts/classes.pl: Moved from top level.
938         * classes.pl: Moved to scripts directory.
939
940         * java/net/URLConnection.java: Implement guessContentTypeFromName.
941
942         * gnu/gcj/io/MimeTypes.java: New file.
943         * gnu/gcj/io/DefaultMimeTypes.java: New file.
944
945 2000-02-20  Tom Tromey  <tromey@cygnus.com>
946
947         * boehm.cc (_Jv_AllocBytes): Clear returned memory.
948
949 2000-02-19  Bryce McKinlay  <bryce@albatross.co.nz>
950
951         * java/util/zip/ZipEntry.java (setCrc): Fix overflow.
952         (setSize): ditto.
953
954 2000-02-18  Tom Tromey  <tromey@cygnus.com>
955
956         * include/jvm.h (_Jv_GetJavaVM): Declare.
957         * include/java-interp.h (_Jv_GetFirstMethod): New function.
958         (_Jv_MethodBase::get_method): New method.
959         (_Jv_JNIMethod::set_function): New method.
960         * jni.cc (_Jv_JNI_UnregisterNatives): New function.
961         (_Jv_JNI_RegisterNatives): New function.
962         (_Jv_JNIFunctions): Updated for new functions.
963         (_Jv_GetJavaVM): New function.
964         (_Jv_JNI_GetJavaVM): Use it.  Now static.
965         (_Jv_JNI_AttachCurrentThread): Create a new JNIEnv if this thread
966         is already a Java thread but does not have a JNIEnv yet.
967
968         * java/lang/natRuntime.cc (_load): Pass the JavaVM to the onload
969         function.
970
971 2000-02-17  Tom Tromey  <tromey@cygnus.com>
972
973         * gcj/field.h (_Jv_Field::getClass): Don't use JvAssert.
974         Fixes PR gcj/152.
975
976 2000-02-16  Tom Tromey  <tromey@cygnus.com>
977
978         * jni.cc (_Jv_JNI_CallStaticMethodV): Added some assertions.
979
980         * jni.cc (_Jv_JNI_NewObjectV): Corrected assertion.
981         (_Jv_JNI_NewObject): Likewise.
982         (_Jv_JNI_NewObjectA): Likewise.
983         (_Jv_JNI_CallAnyMethodV): In constructor case, pass correct value
984         as "return" type to _Jv_CallAnyMethodA.
985         (_Jv_JNI_CallAnyMethodA): Likewise.
986         (_Jv_JNI_CallAnyVoidMethodV): Likewise.
987
988         * jni.cc (_Jv_JNI_FindClass): Use ClassLoader.loadClass, not
989         findClass.
990
991 2000-02-15  Tom Tromey  <tromey@cygnus.com>
992
993         * resolve.cc (ncode): Set args_raw_size.  Compute jni_cif and
994         jni_arg_types.
995         (init_cif): Added `rtype_p' argument.
996         * include/java-interp.h (class _Jv_MethodBase): Added
997         args_raw_size.
998         (class _Jv_InterpMethod): Removed args_raw_size.
999         (class _Jv_JNIMethod): Added jni_cif and jni_arg_types fields.
1000         * jni.cc (call): Pass JNIEnv and (for static methods only) the
1001         class pointer as well as the ordinary arguments.
1002
1003         * jni.cc (mangled_name): Skip leading `(' in signature.
1004
1005         * jni.cc (add_char): Added missing `else'.
1006
1007         * jni.cc (_Jv_JNI_AttachCurrentThread): Return error if malloc
1008         fails.
1009
1010 2000-02-15  Bryce McKinlay  <bryce@albatross.co.nz>
1011
1012         * NEWS: Updated.
1013
1014         * java/lang/natRuntime.cc (_load): Include library path with
1015         exception message.
1016
1017         * java/lang/natSystem.cc (init_properties): set java.lang.classpath 
1018         property.
1019
1020         * java/lang/natThread.cc (dumpStack): Removed.
1021         * java/lang/Thread.java (dumpStack): Implemented.
1022
1023 2000-02-15  Tom Tromey  <tromey@cygnus.com>
1024
1025         * java/lang/natRuntime.cc (_load): On Unix, prefix library name
1026         with `lib' for loadLibrary.  Fixes PR gcj/150.
1027
1028 2000-02-14  Warren Levy  <warrenl@cygnus.com>
1029
1030         * gnu/gcj/math/MPN.java(findLowestBit): Made methods public.
1031
1032         * java/math/BigInteger.java(BigInteger(int,int,java.util.Random):
1033           New constructor.
1034         (min): Implemented.
1035         (max): Implemented.
1036         (modPow): Rewritten to not use the naive, slow, brute force approach.
1037         (isProbablePrime): Implemented.
1038         (testBit): Implemented.
1039         (flipBit): Implemented.
1040         (getLowestSetBit): Implemented.
1041
1042 2000-02-16  Anthony Green  <green@redhat.com>
1043
1044         * configure.host: Use the same options for i386 and i486 as we do
1045         for i586 and i686.
1046
1047 2000-02-12  Tom Tromey  <tromey@cygnus.com>
1048
1049         * java/io/File.java (createTempFile): Use low bits from counter,
1050         not high bits.
1051
1052 Fri Feb 11 19:48:08 2000  Anthony Green  <green@cygnus.com>
1053
1054         * THANKS: More thanks.
1055
1056 2000-02-11  Tom Tromey  <tromey@cygnus.com>
1057
1058         * interpret.cc (continue1): Use STOREA, not STOREI, to implement
1059         astore instruction.  From Hans Boehm.
1060
1061 2000-02-11  Warren Levy  <warrenl@cygnus.com>
1062
1063         * java/math/BigInteger.java(BigInteger(String, int)): New constructor.
1064         (BigInteger(String)): New constructor.
1065         (not): Rewritten using version from Kawa's BitOps class.
1066         (valueOf): New private methods from Kawa's BitOps class.
1067         (swappedOp): ditto.
1068         (bitOp): ditto.
1069         (setBitOp): ditto.
1070         (and): Implemented.
1071         (or): Implemented.
1072         (xor): Implemented.
1073         (andNot): Implemented.
1074         (clearBit): Implemented.
1075         (setBit): Implemented.
1076         (bitCount): Implemented.
1077         (toByteArray): Implemented.
1078
1079 2000-02-11  Tom Tromey  <tromey@cygnus.com>
1080
1081         * java/io/File.java (nextValue): Now synchronized.
1082
1083 2000-02-10  Tom Tromey  <tromey@cygnus.com>
1084
1085         * java/io/natFileDescriptorPosix.cc (open): Recognize EXCL flag.
1086         * java/io/FileDescriptor.java (EXCL): New static field.
1087         * java/io/File.java (tmpdir): New static field.
1088         (createTempFile): New method.
1089         (nextValue): New method.
1090         * java/lang/natSystem.cc (init_properties): Set java.io.tmpdir
1091         property.
1092
1093         * include/jni.h (JNI_FALSE): Renamed from JNI_TRUE; oops.
1094         (jboolean): Declare as an attributed int, not a bool.
1095         (_Jv_func): Declare differently for C.
1096
1097         * gnu/gcj/jni/natNativeThread.cc: New file.
1098         * gnu/gcj/jni/NativeThread.java: New file.
1099         * java/lang/Thread.java (data): Now a RawData.
1100         * include/jvm.h (_Jv_GetCurrentJNIEnv, _Jv_SetCurrentJNIEnv):
1101         Declare.
1102         * Makefile.in: Rebuilt.
1103         * Makefile.am (java/lang/Thread.h): New target.
1104         (ordinary_java_source_files): Added NativeThread.java.
1105         (nat_source_files): Added natNativeThread.cc.
1106         * java/lang/natThread.cc: Include <jni.h>
1107         (struct natThread): Added `jni_env' field.
1108         (_Jv_GetCurrentJNIEnv): New function.
1109         (_Jv_SetCurrentJNIEnv): Likewise.
1110         (initialize_native): Initialize jni_env.
1111         Include RawData.h.
1112         * jni.cc (ThreadGroupClass): New define.
1113         (_Jv_JNI_InvokeFunctions): New structure.
1114         (JNI_GetCreatedJavaVMs): New function.
1115         (the_vm): New global.
1116         (JNI_GetDefaultJavaVMInitArgs): New function.
1117         Include NativeThread.h.
1118         (NativeThreadClass): New define.
1119         (_Jv_JNI_EnsureLocalCapacity): Return JNI_ERR, not -1.
1120         (_Jv_JNI_DestroyJavaVM): New function.
1121         (_Jv_JNI_AttachCurrentThread): New function.
1122         (_Jv_JNI_DetachCurrentThread): New function.
1123         (_Jv_JNI_GetEnv): New function.
1124         (JNI_CreateJavaVM): New function.
1125         (_Jv_JNI_GetJavaVM): New function.
1126         (_Jv_JNIFunctions): Added entry for GetJavaVM.
1127         * include/jni.h (JavaVMAttachArgs): New structure.
1128         (JNI_EDETACHED): New define.
1129         (JNI_EVERSION): Likewise.
1130         (JavaVM): Define properly.
1131         (struct JNIInvokeInterface): New structure.
1132         (class _Jv_JavaVM): New class.
1133         (JNI_OnLoad, JNI_OnUnload): Declare.
1134         (JNI_GetDefaultJavaVMInitArgs, JNI_CreateJavaVM,
1135         JNI_GetCreatedJavaVMs): Declare.
1136         (JavaVMInitArgs): New typedef.
1137         (JavaVMOption): Likewise.
1138         (JNI_ERR): New define.
1139         (JNI_OK): Likewise.
1140
1141 2000-02-10  Andrew Haley  <aph@cygnus.com>
1142
1143         * interpret.cc: Don't include fdlibm.h.
1144         Replace #if with #ifdef throughout.
1145         Declare extern __ieee754_fmod.
1146         (continue1): Remove op_getfield, op_getstatic, op_putfield,
1147         op_putstatic insns.
1148         * resolve.cc (_Jv_PrepareClass): Use imeth as method pointer.
1149         Search class hierarchy for superclass vtable.
1150
1151         * java/lang/natClassLoader.cc (_Jv_UnregisterClass): Don't fall
1152         off the end of a pointer list.
1153
1154         * java/lang/natThread.cc (stop): Don't abort, throw an exception
1155         instead.
1156         (suspend): Ditto.
1157         
1158 2000-02-09  Tom Tromey  <tromey@cygnus.com>
1159
1160         * java/lang/natRuntime.cc (_load): Call add_library.
1161         (loadLibraryInternal): Likewise.
1162
1163         * gnu/gcj/convert/natIconv.cc (Input_iconv::finalize): Call
1164         iconv_close when handle is not NULL.  Thanks to Andrew Haley.
1165         (Output_iconv::finalize): Likewise.
1166
1167 2000-02-08  Tom Tromey  <tromey@cygnus.com>
1168
1169         * java/util/Properties.java (setProperty): New method.
1170         (store): New method.
1171
1172 2000-02-07  Tom Tromey  <tromey@cygnus.com>
1173
1174         * java/lang/Runtime.java (_load): Declare.
1175         (load, loadLibrary): Wrote in terms of _load.
1176         * java/lang/natRuntime.cc (load): Call JNI_OnLoad if it appears in
1177         library.
1178         (loadLibrary): Likewise.
1179         Include <jni.h>.
1180         (_load): New method.
1181         (loadLibrary, load): Removed.
1182
1183         * jni.cc (ThrowableClass): New define.
1184         (_Jv_JNI_Throw): Check argument.
1185         (_Jv_JNI_ThrowNew): Likewise.
1186         (wrap_value): Don't wrap object if it is NULL.
1187         (_Jv_JNI_DefineClass): Use wrap_value.
1188         (_Jv_JNI_FindClass): Likewise.
1189         (_Jv_JNI_GetSuperclass): Likewise.
1190         (_Jv_JNI_ExceptionOccurred): Likewise.
1191         (_Jv_JNI_AllocObject): Likewise.
1192         (_Jv_JNI_GetObjectClass): Likewise.
1193         (_Jv_JNI_NewString): Likewise.
1194         (_Jv_JNI_NewStringUTF): Likewise.
1195         (_Jv_JNI_NewObjectArray): Likewise.
1196         (_Jv_JNI_GetObjectArrayElement): Likewise.
1197         (_Jv_JNI_NewPrimitiveArray): Likewise.
1198         (_Jv_JNI_ToReflectedField): Likewise.
1199         (_Jv_JNI_ToReflectedMethod): Likewise.
1200         (_Jv_JNI_AllocObject): Check argument.
1201         (_Jv_JNI_NewObjectV): Likewise.
1202         (_Jv_JNI_NewObject): Likewise.
1203         (_Jv_JNI_NewObjectA): Likewise.
1204         (_Jv_JNI_GetObjectClass): Likewise.
1205         (_Jv_JNI_GetField): Likewise.
1206         (_Jv_JNI_SetField): Likewise.
1207
1208         * interpret.cc (PUSHL): Don't use expression statement.
1209         (PUSHD): Likewise.
1210         (LOADL): Likewise.
1211         (STOREL): Likewise.
1212
1213         * jni.cc (add_char): Conditional on INTERPRETER.
1214         (mangled_name): Likewise.
1215         (call): Likewise.
1216         * include/java-interp.h (class _Jv_MethodBase): Conditional on
1217         INTERPRETER.
1218         (class _Jv_JNIMethod): Likewise.
1219
1220 2000-02-04  Warren Levy  <warrenl@cygnus.com>
1221
1222         * Makefile.am: Added MPN.java and BigInteger.java.
1223         * Makefile.in: Rebuilt.
1224         * gnu/gcj/math/MPN.java: New file.  From Kawa by Per Bothner
1225         <per@bothner.com>.
1226         * java/math/BigInteger.java: New file.  Based primarily on
1227         Kawa's IntNum.java by Per Bothner <per@bothner.com>.
1228
1229 2000-02-04  Tom Tromey  <tromey@cygnus.com>
1230
1231         * defineclass.cc (handleMethodsBegin): Allocate _Jv_MethodBase
1232         pointers.
1233         (handleMethodsEnd): Fixed error messages.  Create a _Jv_JNIMethod
1234         if the method is native.
1235         * resolve.cc (ncode): Don't handle native methods.
1236         (_Jv_JNIMethod::ncode): New method.
1237         (_Jv_PrepareClass): Handle native methods.
1238         * jni.cc (call): Renamed from _Jv_JNI_conversion_call.
1239         Include AbstractMethodError.h.
1240         (add_char): New function.
1241         (mangled_name): Likewise.
1242         * include/java-interp.h (class _Jv_JNIMethod): New class.
1243         (class _Jv_MethodBase): New class.
1244         (class _Jv_InterpMethod): Derive from _Jv_MethodBase.
1245         (_Jv_InterpClass): Changed `interpreted_methods' field to type
1246         `_Jv_MethodBase'.
1247
1248         * include/jvm.h (_Jv_FindSymbolInExecutable): Declare.
1249         * java/lang/natRuntime.cc (libraries_size, libraries_count,
1250         libraries): New globals.
1251         (add_library): New function.
1252         (_Jv_FindSymbolInExecutable): New function.
1253
1254         * java/lang/natClassLoader.cc (initiated_classes, loaded_classes):
1255         Now static.
1256
1257 2000-02-04  Andrew Haley  <aph@cygnus.com>
1258
1259         * java/lang/Throwable.java (CPlusPlusDemangler): New class.
1260         (printStackTrace): Use a CPlusPlusDemangler to demangle names.
1261         * java/lang/natThrowable.cc (printRawStackTrace): Rename
1262         printStackTrace to printRawStackTrace.
1263
1264 2000-02-03  Tom Tromey  <tromey@cygnus.com>
1265
1266         * java/util/Calendar.java (toString): New method.
1267         * java/util/SimpleTimeZone.java (clone): New method.
1268         (toString): New method.
1269         * java/util/TimeZone.java (clone): New method.
1270         * java/text/SimpleDateFormat.java (clone): New method.
1271         * java/text/NumberFormat.java (clone): New method.
1272         (equals): New method.
1273         * java/text/Format.java (clone): New method.
1274         * java/text/DateFormatSymbols.java (DateFormatSymbols): New
1275         constructor.
1276         (clone): New method.
1277         * java/text/DateFormat.java (clone): New method.
1278         * java/text/Collator.java (clone): New method.
1279
1280 2000-02-03  Tom Tromey  <tromey@cygnus.com>
1281
1282         * java/io/PipedOutputStream.java (write(byte[], int, int)): New
1283         method.
1284
1285 2000-02-01  Tom Tromey  <tromey@cygnus.com>
1286
1287         * include/java-interp.h (_Jv_JNI_conversion_call): Declare.
1288         * resolve.cc (ncode): Use _Jv_JNI_conversion_call when
1289         constructing the closure if the function is native.
1290         * jni.cc (_Jv_JNI_conversion_call): Now returns `void'.  No longer
1291         a template function, #if'd out, or static.
1292         Include <java-interp.h>.
1293
1294         * include/jni.h (class _Jv_JNIEnv): Corrected calls using `...'.
1295
1296         * include/jni.h (class _Jv_JNIEnv): Added all C++ inline methods.
1297
1298         * jni.cc (_Jv_JNI_PopLocalFrame): Leave loop when `n == NULL'.
1299         (_Jv_JNI_conversion_call): _Jv_JNI_PopLocalFrame will never leave
1300         `locals == NULL'.
1301         (wrap_value): New function.
1302         (_Jv_JNI_CallAnyMethodV): Use it.
1303         (_Jv_JNI_CallAnyMethodA): Likewise.
1304         (_Jv_JNI_GetField): Use wrap_value; removed specialized version.
1305         (_Jv_JNI_GetStaticField): Likewise.
1306
1307         * jni.cc (_Jv_JNI_GetField): Specialize for jobject.
1308         (_Jv_JNI_GetStaticField): Likewise.
1309
1310 2000-01-31  Tom Tromey  <tromey@cygnus.com>
1311
1312         * prims.cc (_Jv_MallocUnchecked): New function.
1313         (main_init): Call _Jv_JNI_Init.
1314         * include/jvm.h (_Jv_MallocUnchecked): Declare.
1315         (_Jv_JNI_Init): Declare.
1316         * jni.cc: Include Hashtable.h, OutOfMemoryError.h, Integer.h,
1317         <string.h>.
1318         (_Jv_JNI_NewGlobalRef): New function.
1319         (_Jv_JNI_DeleteGlobalRef): New function.
1320         (_Jv_JNI_DeleteLocalRef): New function.
1321         (_Jv_JNI_conversion_call): Initialize and clear local reference
1322         frame.
1323         (_Jv_JNI_NewLocalRef): New function.
1324         (struct _Jv_JNI_LocalFrame): New structure.
1325         (_Jv_JNI_PushLocalFrame): New function.
1326         (_Jv_JNI_EnsureLocalCapacity): New function.
1327         (FRAME_SIZE): New define.
1328         (_Jv_JNI_GetStringChars): Mark string, not characters.
1329         (_Jv_JNI_ReleaseStringChars): Unmark string, not characters.
1330         (_Jv_JNI_GetPrimitiveArrayElements): Mark array, not elements.
1331         (_Jv_JNI_ReleasePrimitiveArrayElements): Unmark array, not
1332         elements.
1333         (_Jv_JNI_DefineClass): Make return value a local ref.
1334         (_Jv_JNI_FindClass): Likewise.
1335         (_Jv_JNI_GetSuperclass): Likewise.
1336         (_Jv_JNI_ExceptionOccurred): Likewise.
1337         (_Jv_JNI_AllocObject): Likewise.
1338         (_Jv_JNI_GetObjectClass): Likewise.
1339         (_Jv_JNI_CallAnyMethodV): Likewise.
1340         (_Jv_JNI_NewString): Likewise.
1341         (_Jv_JNI_NewStringUTF): Likewise.
1342         (_Jv_JNI_NewObjectArray): Likewise.
1343         (_Jv_JNI_GetObjectArrayElement): Likewise.
1344         (_Jv_JNI_ToReflectedField): Likewise.
1345         (_Jv_JNI_ToReflectedMethod): Likewise.
1346         (_Jv_JNIFunctions): Updated table for new functions.
1347         (_Jv_JNI_Init): New function.
1348         (mark_for_gc): Wrote.
1349         (unmark_for_gc): Wrote.
1350         * include/jni.h (struct JNINativeInterface): Removed name from
1351         PopLocalFrame parameter.
1352         (class _Jv_JNIEnv): Added `locals' field.
1353
1354 Mon Jan 31 00:43:15 2000  Anthony Green  <green@redhat.com>
1355
1356         * gnu/gcj/convert/natIconv.cc (read): Minor fixes.
1357         (write): Ditto.
1358
1359 2000-01-30  Tom Tromey  <tromey@cygnus.com>
1360
1361         * include/config.h.in: Rebuilt.
1362         * acconfig.h (HAVE_ICONV): Define.
1363         * configure: Rebuilt.
1364         * configure.in: Check for `iconv' function.
1365         * gnu/gcj/convert/BytesToUnicode.java (getDecoder): Try iconv if
1366         no specific encoder exists.
1367         * gnu/gcj/convert/UnicodeToBytes.java (getEncoder): Try iconv if
1368         no specific encoder exists.
1369         * Makefile.in: Rebuilt.
1370         * Makefile.am (convert_source_files): Mention Input_iconv.java and
1371         Output_iconv.java.
1372         (nat_source_files): Added natIconv.cc.
1373         * gnu/gcj/convert/natIconv.cc: New file.
1374         * gnu/gcj/convert/Input_iconv.java: New file.
1375         * gnu/gcj/convert/Output_iconv.java: New file.
1376
1377 2000-01-28  Tom Tromey  <tromey@cygnus.com>
1378
1379         * Makefile.in: Rebuilt.
1380         * Makefile.am (LIBFFIINCS): Added MULTIBUILDTOP.
1381
1382 2000-01-26  Tom Tromey  <tromey@cygnus.com>
1383
1384         * gcj/method.h (JvNumMethods): Moved from Class.h.
1385         (JvGetFirstMethod): Likewise.
1386         * java/lang/Class.h (Object): Updated decl of
1387         _Jv_JNI_ToReflectedField.
1388         (Object): Added _Jv_JNI_ToReflectedMethod as a friend.
1389         * Makefile.in: Rebuilt.
1390         * Makefile.am (java/lang/reflect/Field.h): Added `jboolean'
1391         argument of _Jv_JNI_ToReflectedField.
1392         (java/lang/reflect/Constructor.h): Added _Jv_JNI_ToReflectedMethod
1393         as a friend.
1394         (java/lang/reflect/Method.h): Likewise.
1395         * include/jni.h (class _Jv_JNIEnv): Added `klass' member.  Use
1396         __GCJ_JNI_IMPL__.
1397         (jweak): New typedef.
1398         (struct JNINativeInterface): Correctly declare remaining entries.
1399         * jni.cc: Include Class.h, ClassLoader.h.
1400         (_Jv_JNI_FindClass): New function.
1401         (_Jv_JNI_DefineClass): New function.
1402         (_Jv_JNI_conversion_call): New function.
1403         (_Jv_JNI_FindClass): Use current class loader to find class.
1404         (_Jv_JNI_ExceptionCheck): New function.
1405         (_Jv_JNI_FromReflectedField): Now static.
1406         (MethodClass): New define.
1407         (_Jv_JNI_FromReflectedMethod): New function.
1408         (_Jv_JNI_ToReflectedMethod): Likewise.
1409         Include Method.h.
1410         (_Jv_JNI_IsAssignableFrom): Renamed.
1411         (_Jv_JNI_GetStringRegion): New function.
1412         Include StringIndexOutOfBoundsException.h.
1413         (_Jv_JNI_GetStringUTFRegion): New function.
1414         (_Jv_JNIFunctions): Updated for new functions.
1415         (_Jv_JNI_GetPrimitiveArrayCritical): New function
1416         (_Jv_JNI_ReleasePrimitiveArrayCritical): Likewise.
1417         (_Jv_JNI_GetStringCritical): New function.
1418         (_Jv_JNI_ReleaseStringCritical): Likewise.
1419         (get_throwable): Removed.
1420         (GCJ_JV_JNIENV_FRIEND): Removed.
1421         (__GCJ_JNI_IMPL__): Define.
1422         Include method.h.
1423
1424         * resolve.cc (get_ffi_type_from_signature): Handle case where
1425         boolean is an int.
1426
1427 Tue Jan 25 08:51:16 2000  Tom Tromey  <tromey@ferrule.cygnus.com>
1428
1429         * interpret.cc (run): Don't call println.
1430         Don't include PrintStream.h.
1431
1432         * gcj/field.h (struct _Jv_Field): Use "jshort" as type for
1433         nameIndex.  Use "jint" as type for boffset.
1434         * java/lang/Class.h (struct _Jv_Method): Made accflags a
1435         _Jv_ushort.
1436         (Class): Likewise.  Also changed type of method_count,
1437         vtable_method_count, size_in_bytes, field_count,
1438         static_field_count, interface_count.
1439         * gcj/array.h (__JArray): Made `length' a const jsize, not an
1440         int.
1441
1442 2000-01-21  Tom Tromey  <tromey@cygnus.com>
1443
1444         * java/lang/reflect/natConstructor.cc (newInstance): Use
1445         _Jv_CallAnyMethodA.
1446         * include/jvm.h: Declare _Jv_CallAnyMethodA.
1447         * java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Renamed
1448         from _Jv_CallNonvirtualMethodA.  Changed interface; overloaded.
1449         Include <jni.h>.
1450         (COPY): Removed.
1451         (invoke): Use _Jv_CallAnyMethodA.
1452         (VAL): Redefined.
1453         * java/lang/Class.h (Class): Declare JvGetFirstStaticField,
1454         JvNumStaticFields, JvNumMethods, and JvGetFirstMethod as friend
1455         functions.
1456         (struct _Jv_Method): Added getNextMethod method.
1457         (JvNumMethods): New function.
1458         (JvGetFirstMethod): Likewise.
1459         * gcj/field.h (JvGetFirstStaticField): New function.
1460         (JvNumStaticFields): Likewise.
1461         (getNextField): Renamed from getNextInstanceField.
1462         (struct _Jv_Field): New method getClass.
1463         * jni.cc: Wrote many new functions.
1464         * include/jni.h (JNI_TRUE): Define.
1465         (JNI_FALSE): Likewise.
1466         (jobject, jclass, jstring, jarray, jthrowable, jobjectArray,
1467         jbyteArray, jshortArray, jintArray, jlongArray, jbooleanArray,
1468         jcharArray, jfloatArray, jdoubleArray): New typedefs.
1469         (jfieldID, jmethodID): Likewise.
1470         (JNI_COMMIT, JNI_ABORT): New defines.
1471         (JNINativeMethod): New struct.
1472         (struct JNINativeInterface): Correctly declared more entries.
1473         (class _Jv_JNIEnv): Added `ex' member.
1474         (JNI_VERSION_1_1): New define.
1475         (JNI_VERSION_1_2): Likewise.
1476
1477         * boehm.cc (_Jv_MarkObj): Use getNextField, not
1478         getNextInstanceField.
1479
1480 2000-01-20  Tom Tromey  <tromey@cygnus.com>
1481
1482         * resolve.cc (StringClass): Removed.
1483         * defineclass.cc (StringClass): Removed.
1484
1485 2000-01-19  Bryce McKinlay  <bryce@albatross.co.nz>
1486
1487         * NEWS: updated.
1488
1489 2000-01-19  Tom Tromey  <tromey@cygnus.com>
1490
1491         * interpret.cc (PC_REGISTER_ASM): Removed.
1492
1493         * java/lang/natThrowable.cc: Don't use `#pragma implementation'.
1494         From Bryce McKinlay.
1495
1496         * All files: Updated copyright to reflect Cygnus purchase.
1497
1498 2000-01-18  Bryce McKinlay <bryce@albatross.co.nz>
1499
1500         * configure: Rebuilt.
1501         * configure.in: Recognize --disable-interpreter.
1502
1503 2000-01-18  Andrew Haley  <aph@cygnus.com>
1504
1505         * name-finder.cc (lookup): Check for dladdr function.
1506         acconfig.h (HAVE_DLADDR): Add.
1507         configure.in: Check for HAVE_DLADDR
1508         configure: Rebuilt.
1509         include/config.h.in:  Rebuilt.
1510
1511 2000-01-17  Andrew Haley  <aph@cygnus.com>
1512
1513         * prims.cc (_Jv_RunMain): Set the name of this executable.
1514
1515 2000-01-17  Tom Tromey  <tromey@cygnus.com>
1516
1517         * java/lang/natThrowable.cc (fillInStackTrace): Return `this' even
1518         when backtrace can't be computed.
1519
1520         * configure: Rebuilt.
1521         * configure.in: Fixed typo in AC_CONFIG_SUBDIRS call.
1522
1523         * java/lang/Runtime.java (loadLibraryInternal): Declare.
1524         * java/lang/natClassLoader.cc (_Jv_FindClass): Removed dead copy.
1525         (_Jv_FindClassInCache): Likewise.
1526         (_Jv_FindClass): Don't conditionalize body on INTERPRETER.
1527         (findSystemClass): Try to load class from compiled module.
1528         Include Runtime.h.
1529         * java/lang/natRuntime.cc (load): Use UTF-8 copy of filename.
1530         (loadLibrary): Likewise.
1531         (lt_preloaded_symbols): Define.
1532         (loadLibraryInternal): New method.
1533         * include/config.h.in: Rebuilt.
1534         * acconfig.h (USE_LTDL): Added.
1535         * Makefile.am (SUBDIRS): Added $(DIRLTDL).
1536         (INCLUDES): Added $(INCLTDL).
1537         (libgcj_la_DEPENDENCIES): Added $(LIBLTDL).
1538         (libgcj_la_LIBADD): Likewise.
1539         * aclocal.m4, configure: Rebuilt.
1540         * configure.in: Added libltdl support.
1541
1542 2000-01-15  Tom Tromey  <tromey@cygnus.com>
1543
1544         * prims.cc (_Jv_PrimClass): Use `JV_STATE_NOTHING', not `0'.
1545
1546 2000-01-14  Andrew Haley  <aph@cygnus.com>
1547
1548         * java/lang/natThrowable.cc: New file.
1549
1550         * java/lang/Throwable.java (fillInStackTrace): Make native.
1551         (printStackTrace): Call native method to do this.
1552         (Throwable): Call fillInStackTrace.
1553         (stackTrace): New variable.
1554         
1555         * include/jvm.h: Add _Jv_ThisExecutable functions.
1556         
1557         * prims.cc: (_Jv_execName): New variable.
1558         (catch_segv): Call fillInStackTrace.
1559         (catch_fpe): Ditto.
1560         (_Jv_ThisExecutable): New functions.
1561         (JvRunMain): Set the name of this executable.
1562
1563         * Makefile.am: Add java/lang/natThrowable.cc.
1564         Add name-finder.cc.
1565         * Makefile.in: Rebuilt.
1566
1567         * acconfig.h: Add HAVE_PROC_SELF_EXE.
1568
1569         * configure.in: Force link with __frame_state_for in
1570         FORCELIBGCCSPEC.  Add new checks for backtrace.
1571         * include/config.h.in: Rebuilt.
1572
1573         * name-finder.cc: New file.
1574         * include/name-finder.h: New file.
1575
1576 2000-01-16  Anthony Green  <green@cygnus.com>
1577
1578         * java/lang/StringBuffer.java (StringBuffer): Don't special case
1579         null argument.
1580
1581 2000-01-16  Jeff Sturm  <jsturm@sigma6.com>
1582
1583         * java/io/StreamTokenizer.java (nextToken): Avoid unread(TT_EOF).
1584
1585 2000-01-13  Tom Tromey  <tromey@cygnus.com>
1586
1587         * java/lang/natClassLoader.cc (_Jv_FindClass): Register `loader',
1588         not system loader, as initiating loader.
1589
1590 2000-01-11  Tom Tromey  <tromey@cygnus.com>
1591
1592         * java/lang/natSystem.cc (getpwuid_adaptor): New adaptor for
1593         HP/UX.  From David Scott Urban.
1594
1595 2000-01-10  Jeff Sturm  <jsturm@sigma6.com>
1596
1597         * java/lang/natMath.cc (pow): Cast args to `double', not
1598         `jdouble'.
1599         (atan2): Likewise.
1600         (IEEEremainder): Likewise.
1601         * java/lang/mprec.h: Don't wrap includes in `extern "C"'.
1602         * java/lang/fdlibm.h: Don't wrap includes in `extern "C"'.
1603
1604 2000-01-09  Anthony Green  <green@cygnus.com>
1605
1606         * java/lang/natString.cc (init): Test for overflow condition
1607         during out of bounds check.
1608         (getChars): Throw StringIndexOutOfBoundsException, not
1609         ArrayIndexOutOfBoundsException.
1610         (getBytes): Ditto.
1611         (regionMatches): Obey case option during string comparison.
1612
1613         * configure.host (ligcj_interpreter): New variable.  Enable
1614         interpreter by default on IA-32.
1615         * configure.in:  Examine libgcj_interpreter.
1616         * configure: Rebuilt.
1617
1618 2000-01-07  Tom Tromey  <tromey@cygnus.com>
1619
1620         * mauve-libgcj: Don't disable ClassTest.
1621
1622         * java/lang/natClass.cc (getClasses): Wrote.
1623
1624 2000-01-06  Tom Tromey  <tromey@cygnus.com>
1625
1626         * java/lang/natClass.cc (_getConstructors): Correctly check
1627         whether method name is the init name.
1628         (getMethod): Look at accflags on method in `klass', not `this'.
1629
1630 2000-01-05  Tom Tromey  <tromey@cygnus.com>
1631
1632         * java/lang/natClass.cc (getMethod): Compute offset relative to
1633         `klass's methods table, not `this's table.
1634
1635         * java/lang/reflect/natMethod.cc (_Jv_CallNonvirtualMethodA):
1636         In unwrapping/widening case, check whether `k' is null, not
1637         whether it is primitive.  Initialize `num' from `argelts', not
1638         `paramelts'.  Correct create and pass arguments to ffi_call.
1639         Don't let presence of `this' argument affect index used to look in
1640         argument arrays.
1641         (COPY): Set appropriate element in `values' vector.
1642
1643         * java/lang/natClass.cc: Include <gcj/method.h>.
1644
1645         * java/lang/Class.h (_getMethods): Correctly declare as private,
1646         not public.
1647
1648         * java/lang/Class.h (_getMethods): Declare.
1649         * java/lang/Class.java (_getMethods): Declare.
1650         * java/lang/natClass.cc (getDeclaringClass): Always return NULL.
1651         (getDeclaredClasses): Always return empty array.
1652         (_getMethods): New method.
1653         (getMethods): Wrote.
1654         (getDeclaredMethod): Return `rmethod'.
1655         (finit_name): New global.
1656         (getDeclaredMethods): Check for finit_name.
1657         (_getMethods): Likewise.
1658         (getMethod): Only return public methods.
1659
1660         * java/lang/reflect/natMethod.cc (get_ffi_type): Test size of
1661         jboolean and select correct ffi type on that basis.
1662         (_Jv_CallNonvirtualMethodA): Handle `void' return type.
1663         Constructor call always has `void' return type.
1664
1665 2000-01-04  Tom Tromey  <tromey@cygnus.com>
1666
1667         * java/lang/Class.h (getSignature): Updated.
1668         * java/lang/Class.java (getSignature): Updated.
1669         * java/lang/natClass.cc (getSignature): Added `is_constructor'
1670         argument.
1671         (getConstructor): Ensure constructor is public.
1672         (_getConstructors): Check for public-ness of constructor when
1673         `declared' is false, not when it is true.
1674
1675 2000-01-04  Warren Levy  <warrenl@cygnus.com>
1676
1677         * java/net/natPlainDatagramSocketImpl.cc (peek): Removed unnecesary
1678         comment.
1679         (receive): Set the sender's address in the DatagramPacket.
1680
1681 2000-01-04  Tom Tromey  <tromey@cygnus.com>
1682
1683         * java/lang/reflect/natConstructor.cc (newInstance): Pass
1684         declaring class as return_type argument to
1685         _Jv_CallNonvirtualMethodA.
1686         * java/lang/reflect/natMethod.cc (_Jv_CallNonvirtualMethodA): In
1687         constructor case, create object and use it as `this' argument.
1688         * java/lang/Class.h (_getConstructors): Declare.
1689         (_getFields): Declare.
1690         * java/lang/Class.java (getConstructors): Wrote.
1691         (_getConstructors): New native method.
1692         (getDeclaredConstructors): Wrote.
1693         (_getFields): Declare new native method.
1694         * java/lang/natClass.cc (_Jv_LookupInterfaceMethod): Removed
1695         incorrect comment.
1696         (getMethod): Work correctly when class is primitive.
1697         (getDeclaredMethods): Likewise.  Compute offset using `method',
1698         not `mptr'.
1699         (getDeclaredMethod): Likewise.
1700         (getConstructor): Wrote.
1701         (ConstructorClass): New define.
1702         (getDeclaredConstructor): Wrote.
1703         (_getConstructors): New method.
1704         (_getFields): New method.
1705         (getFields): Wrote.
1706
1707         * Makefile.in: Rebuilt.
1708         * Makefile.am (AM_CXXFLAGS): Added -D_GNU_SOURCE.
1709
1710         * prims.cc: Remove `#pragma implementation'.
1711         * gcj/array.h: Remove `#pragma interface'.
1712
1713         * prims.cc (_Jv_equaln): New function.
1714         * java/lang/Class.java (getSignature): Declare.
1715         * resolve.cc (_Jv_LookupDeclaredMethod): Moved to natClass.cc.
1716         * java/lang/natClass.cc (_Jv_LookupDeclaredMethod): Moved from
1717         resolve.cc.
1718         (getSignature): New method.
1719         (getDeclaredMethod): Wrote.
1720         (getMethod): Wrote.
1721         Include StringBuffer.h.
1722         * java/lang/Class.h (Class): Added _Jv_FromReflectedConstructor
1723         as a friend.  Unconditionally declare _Jv_LookupDeclaredMethod as
1724         a friend.
1725         (getSignature): Declare.
1726         * include/jvm.h (_Jv_GetTypesFromSignature): Declare.
1727         (_Jv_equaln): Declare.
1728         (_Jv_CallNonvirtualMethodA): Declare.
1729         * Makefile.in: Rebuilt.
1730         * Makefile.am (nat_source_files): Added natConstructor.cc.
1731         (java/lang/reflect/Constructor.h): New target.
1732         * java/lang/reflect/natConstructor.cc: New file.
1733         * java/lang/reflect/Constructor.java (newInstance): Now native.
1734         (declaringClass): Renamed from decl_class.
1735         (offset): Renamed from index.
1736         (getType): New native method.
1737         (getModifiers): Now native.
1738         (getParameterTypes): Call getType if required.
1739         (hashCode): Include hash code from declaring class.
1740         (modifiers): Removed.
1741         (toString): Call getType if required.
1742         * gcj/method.h (_Jv_FromReflectedConstructor): New function.
1743         * java/lang/reflect/natMethod.cc (hack_call): New method.
1744         Removed `#if 0' around FFI code.
1745         Include <gnu/gcj/RawData.h>.
1746         (invoke): Use _Jv_CallNonvirtualMethodA.  Throw
1747         IllegalArgumentException when argument object and class disagree.
1748         (_Jv_GetTypesFromSignature): New function.
1749         (getType): Use it.
1750         (ObjectClass): New define.
1751         (_Jv_CallNonvirtualMethodA): New function.
1752         * java/lang/reflect/Method.java (hack_trampoline): New method.
1753         (hack_call): New native method.