Commit dd5d6281 by Tom Tromey

expr.c (build_java_jsr): Use emit_jump, not expand_goto.

	* expr.c (build_java_jsr): Use emit_jump, not expand_goto.

	* javaop.h (WORD_TO_INT): New function.
	(IMMEDIATE_s4): Use WORD_TO_INT.
	* jcf.h (JPOOL_INT): Ditto.

	* gjavah.c (decode_signature_piece): Don't treat `$' as namespace
	separator.

From-SVN: r33636
parent 8c8de5fc
2000-04-19 Tom Tromey <tromey@cygnus.com>
2000-05-03 Andrew Haley <aph@cygnus.com>
* expr.c (build_java_jsr): Use emit_jump, not expand_goto.
* javaop.h (WORD_TO_INT): New function.
(IMMEDIATE_s4): Use WORD_TO_INT.
* jcf.h (JPOOL_INT): Ditto.
* gjavah.c (decode_signature_piece): Don't treat `$' as namespace
separator.
2000-05-02 Tom Tromey <tromey@cygnus.com>
* expr.c (build_jni_stub): Cache the result of
_Jv_LookupJNIMethod.
2000-04-19 Tom Tromey <tromey@cygnus.com>
* class.c (add_method_1): Set both DECL_EXTERNAL and METHOD_NATIVE
on native function.
......
......@@ -560,7 +560,7 @@ build_java_jsr (where, ret)
tree ret_label = fold (build1 (ADDR_EXPR, return_address_type_node, ret));
push_value (ret_label);
flush_quick_stack ();
expand_goto (where);
emit_jump (label_rtx (where));
expand_label (ret);
}
......
......@@ -990,8 +990,7 @@ decode_signature_piece (stream, signature, limit, need_space)
while (*signature && *signature != ';')
{
int ch = UTF8_GET (signature, limit);
/* `$' is the separator for an inner class. */
if (ch == '/' || ch == '$')
if (ch == '/')
fputs ("::", stream);
else
jcf_print_char (stream, ch);
......
......@@ -98,7 +98,7 @@ union Word {
#endif
#ifndef IMMEDIATE_s4
#define IMMEDIATE_s4 (PC+=4, CHECK_PC_IN_RANGE(PC), \
((jint)((BCODE[PC-4] << 24) | (BCODE[PC-3] << 16) \
(WORD_TO_INT((BCODE[PC-4] << 24) | (BCODE[PC-3] << 16) \
| (BCODE[PC-2] << 8) | (BCODE[PC-1]))))
#endif
......@@ -109,6 +109,16 @@ WORD_TO_FLOAT(jword w)
return wu.f;
}
/* Sign extend w. */
static inline jint
WORD_TO_INT(jword w)
{
jint n = w;
n ^= (jint)1 << 31;
n -= (jint)1 << 31;
return n;
}
static inline jlong
WORDS_TO_LONG(jword hi, jword lo)
{
......
......@@ -131,7 +131,7 @@ typedef struct JCF {
#define JPOOL_UTF_DATA(JCF, INDEX) \
((JCF)->buffer+JPOOL_UINT(JCF, INDEX)+2)
#endif
#define JPOOL_INT(JCF, INDEX) ((jint) JPOOL_UINT (JCF, INDEX))
#define JPOOL_INT(JCF, INDEX) (WORD_TO_INT(JPOOL_UINT (JCF, INDEX)))
#define JPOOL_FLOAT(JCF, INDEX) WORD_TO_FLOAT (JPOOL_UINT (JCF, INDEX))
#define CPOOL_INDEX_IN_RANGE(CPOOL, INDEX) \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment