Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_jdk
提交
49997e44
D
dragonwell8_jdk
项目概览
openanolis
/
dragonwell8_jdk
通知
4
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell8_jdk
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
49997e44
编写于
5月 24, 2012
作者:
N
nloodin
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
16facaaa
ec8f3196
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
22 addition
and
2 deletion
+22
-2
src/share/demo/jvmti/java_crw_demo/java_crw_demo.c
src/share/demo/jvmti/java_crw_demo/java_crw_demo.c
+20
-1
src/share/javavm/export/classfile_constants.h
src/share/javavm/export/classfile_constants.h
+2
-1
未找到文件。
src/share/demo/jvmti/java_crw_demo/java_crw_demo.c
浏览文件 @
49997e44
...
@@ -89,6 +89,12 @@
...
@@ -89,6 +89,12 @@
(ci)->input_position <= (ci)->input_len && \
(ci)->input_position <= (ci)->input_len && \
(ci)->output_position <= (ci)->output_len) )
(ci)->output_position <= (ci)->output_len) )
#define BUFSIZE 256
#ifdef _WIN32
#define snprintf(buffer, count, format, ...) _snprintf_s(buffer, count, _TRUNCATE, format, ##__VA_ARGS__)
#endif
/* Typedefs for various integral numbers, just for code clarity */
/* Typedefs for various integral numbers, just for code clarity */
typedef
unsigned
ClassOpcode
;
/* One opcode */
typedef
unsigned
ClassOpcode
;
/* One opcode */
...
@@ -651,6 +657,7 @@ cpool_setup(CrwClassImage *ci)
...
@@ -651,6 +657,7 @@ cpool_setup(CrwClassImage *ci)
unsigned
int
index2
;
unsigned
int
index2
;
unsigned
len
;
unsigned
len
;
char
*
utf8
;
char
*
utf8
;
char
message
[
BUFSIZE
];
ipos
=
i
;
ipos
=
i
;
index1
=
0
;
index1
=
0
;
...
@@ -689,8 +696,20 @@ cpool_setup(CrwClassImage *ci)
...
@@ -689,8 +696,20 @@ cpool_setup(CrwClassImage *ci)
utf8
[
len
]
=
0
;
utf8
[
len
]
=
0
;
write_bytes
(
ci
,
(
void
*
)
utf8
,
len
);
write_bytes
(
ci
,
(
void
*
)
utf8
,
len
);
break
;
break
;
case
JVM_CONSTANT_MethodType
:
index1
=
copyU2
(
ci
);
break
;
case
JVM_CONSTANT_MethodHandle
:
index1
=
copyU1
(
ci
);
index2
=
copyU2
(
ci
);
break
;
case
JVM_CONSTANT_InvokeDynamic
:
index1
=
copyU2
(
ci
);
index2
=
copyU2
(
ci
);
break
;
default:
default:
CRW_FATAL
(
ci
,
"Unknown constant"
);
snprintf
(
message
,
BUFSIZE
,
"Unknown tag: %d, at ipos %hu"
,
tag
,
ipos
);
CRW_FATAL
(
ci
,
message
);
break
;
break
;
}
}
fillin_cpool_entry
(
ci
,
ipos
,
tag
,
index1
,
index2
,
(
const
char
*
)
utf8
,
len
);
fillin_cpool_entry
(
ci
,
ipos
,
tag
,
index1
,
index2
,
(
const
char
*
)
utf8
,
len
);
...
...
src/share/javavm/export/classfile_constants.h
浏览文件 @
49997e44
...
@@ -86,7 +86,8 @@ enum {
...
@@ -86,7 +86,8 @@ enum {
JVM_CONSTANT_InterfaceMethodref
=
11
,
JVM_CONSTANT_InterfaceMethodref
=
11
,
JVM_CONSTANT_NameAndType
=
12
,
JVM_CONSTANT_NameAndType
=
12
,
JVM_CONSTANT_MethodHandle
=
15
,
// JSR 292
JVM_CONSTANT_MethodHandle
=
15
,
// JSR 292
JVM_CONSTANT_MethodType
=
16
// JSR 292
JVM_CONSTANT_MethodType
=
16
,
// JSR 292
JVM_CONSTANT_InvokeDynamic
=
18
};
};
/* JVM_CONSTANT_MethodHandle subtypes */
/* JVM_CONSTANT_MethodHandle subtypes */
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录