Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
qemu
提交
45c7b743
Q
qemu
项目概览
openeuler
/
qemu
通知
10
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Q
qemu
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
45c7b743
编写于
10月 15, 2011
作者:
R
Richard Henderson
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
target-sparc: Undo cpu_fpr rename.
Signed-off-by:
N
Richard Henderson
<
rth@twiddle.net
>
上级
ac11f776
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
28 addition
and
28 deletion
+28
-28
target-sparc/translate.c
target-sparc/translate.c
+28
-28
未找到文件。
target-sparc/translate.c
浏览文件 @
45c7b743
...
...
@@ -63,7 +63,7 @@ static TCGv cpu_tmp0;
static
TCGv_i32
cpu_tmp32
;
static
TCGv_i64
cpu_tmp64
;
/* Floating point registers */
static
TCGv_i32
cpu_
_
fpr
[
TARGET_FPREGS
];
static
TCGv_i32
cpu_fpr
[
TARGET_FPREGS
];
static
target_ulong
gen_opc_npc
[
OPC_BUF_SIZE
];
static
target_ulong
gen_opc_jump_pc
[
2
];
...
...
@@ -126,12 +126,12 @@ static inline void gen_update_fprs_dirty(int rd)
/* floating point registers moves */
static
TCGv_i32
gen_load_fpr_F
(
DisasContext
*
dc
,
unsigned
int
src
)
{
return
cpu_
_
fpr
[
src
];
return
cpu_fpr
[
src
];
}
static
void
gen_store_fpr_F
(
DisasContext
*
dc
,
unsigned
int
dst
,
TCGv_i32
v
)
{
tcg_gen_mov_i32
(
cpu_
_
fpr
[
dst
],
v
);
tcg_gen_mov_i32
(
cpu_fpr
[
dst
],
v
);
gen_update_fprs_dirty
(
dst
);
}
...
...
@@ -146,13 +146,13 @@ static TCGv_i64 gen_load_fpr_D(DisasContext *dc, unsigned int src)
src
=
DFPREG
(
src
);
#if TCG_TARGET_REG_BITS == 32
tcg_gen_mov_i32
(
TCGV_HIGH
(
ret
),
cpu_
_
fpr
[
src
]);
tcg_gen_mov_i32
(
TCGV_LOW
(
ret
),
cpu_
_
fpr
[
src
+
1
]);
tcg_gen_mov_i32
(
TCGV_HIGH
(
ret
),
cpu_fpr
[
src
]);
tcg_gen_mov_i32
(
TCGV_LOW
(
ret
),
cpu_fpr
[
src
+
1
]);
#else
{
TCGv_i64
t
=
tcg_temp_new_i64
();
tcg_gen_extu_i32_i64
(
ret
,
cpu_
_
fpr
[
src
]);
tcg_gen_extu_i32_i64
(
t
,
cpu_
_
fpr
[
src
+
1
]);
tcg_gen_extu_i32_i64
(
ret
,
cpu_fpr
[
src
]);
tcg_gen_extu_i32_i64
(
t
,
cpu_fpr
[
src
+
1
]);
tcg_gen_shli_i64
(
ret
,
ret
,
32
);
tcg_gen_or_i64
(
ret
,
ret
,
t
);
tcg_temp_free_i64
(
t
);
...
...
@@ -173,9 +173,9 @@ static void gen_store_fpr_D(DisasContext *dc, unsigned int dst, TCGv_i64 v)
tcg_gen_mov_i32
(
cpu__fpu
[
dst
],
TCGV_HIGH
(
v
));
tcg_gen_mov_i32
(
cpu__fpu
[
dst
+
1
],
TCGV_LOW
(
v
));
#else
tcg_gen_trunc_i64_i32
(
cpu_
_
fpr
[
dst
+
1
],
v
);
tcg_gen_trunc_i64_i32
(
cpu_fpr
[
dst
+
1
],
v
);
tcg_gen_shri_i64
(
v
,
v
,
32
);
tcg_gen_trunc_i64_i32
(
cpu_
_
fpr
[
dst
],
v
);
tcg_gen_trunc_i64_i32
(
cpu_fpr
[
dst
],
v
);
#endif
gen_update_fprs_dirty
(
dst
);
...
...
@@ -188,37 +188,37 @@ static TCGv_i64 gen_dest_fpr_D(void)
static
void
gen_op_load_fpr_QT0
(
unsigned
int
src
)
{
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
upmost
));
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
+
1
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
+
1
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
upper
));
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
+
2
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
+
2
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
lower
));
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
+
3
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
+
3
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
lowest
));
}
static
void
gen_op_load_fpr_QT1
(
unsigned
int
src
)
{
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
offsetof
(
CPU_QuadU
,
l
.
upmost
));
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
+
1
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
+
1
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
offsetof
(
CPU_QuadU
,
l
.
upper
));
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
+
2
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
+
2
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
offsetof
(
CPU_QuadU
,
l
.
lower
));
tcg_gen_st_i32
(
cpu_
_
fpr
[
src
+
3
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
tcg_gen_st_i32
(
cpu_fpr
[
src
+
3
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt1
)
+
offsetof
(
CPU_QuadU
,
l
.
lowest
));
}
static
void
gen_op_store_QT0_fpr
(
unsigned
int
dst
)
{
tcg_gen_ld_i32
(
cpu_
_
fpr
[
dst
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_ld_i32
(
cpu_fpr
[
dst
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
upmost
));
tcg_gen_ld_i32
(
cpu_
_
fpr
[
dst
+
1
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_ld_i32
(
cpu_fpr
[
dst
+
1
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
upper
));
tcg_gen_ld_i32
(
cpu_
_
fpr
[
dst
+
2
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_ld_i32
(
cpu_fpr
[
dst
+
2
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
lower
));
tcg_gen_ld_i32
(
cpu_
_
fpr
[
dst
+
3
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
tcg_gen_ld_i32
(
cpu_fpr
[
dst
+
3
],
cpu_env
,
offsetof
(
CPUSPARCState
,
qt0
)
+
offsetof
(
CPU_QuadU
,
l
.
lowest
));
}
...
...
@@ -228,10 +228,10 @@ static void gen_move_Q(int rd, int rs)
rd
=
QFPREG
(
rd
);
rs
=
QFPREG
(
rs
);
tcg_gen_mov_i32
(
cpu_
_fpr
[
rd
],
cpu_
_fpr
[
rs
]);
tcg_gen_mov_i32
(
cpu_
_fpr
[
rd
+
1
],
cpu_
_fpr
[
rs
+
1
]);
tcg_gen_mov_i32
(
cpu_
_fpr
[
rd
+
2
],
cpu_
_fpr
[
rs
+
2
]);
tcg_gen_mov_i32
(
cpu_
_fpr
[
rd
+
3
],
cpu_
_fpr
[
rs
+
3
]);
tcg_gen_mov_i32
(
cpu_
fpr
[
rd
],
cpu
_fpr
[
rs
]);
tcg_gen_mov_i32
(
cpu_
fpr
[
rd
+
1
],
cpu
_fpr
[
rs
+
1
]);
tcg_gen_mov_i32
(
cpu_
fpr
[
rd
+
2
],
cpu
_fpr
[
rs
+
2
]);
tcg_gen_mov_i32
(
cpu_
fpr
[
rd
+
3
],
cpu
_fpr
[
rs
+
3
]);
gen_update_fprs_dirty
(
rd
);
}
#endif
...
...
@@ -5251,9 +5251,9 @@ void gen_intermediate_code_init(CPUSPARCState *env)
offsetof
(
CPUState
,
gregs
[
i
]),
gregnames
[
i
]);
for
(
i
=
0
;
i
<
TARGET_FPREGS
;
i
++
)
cpu_
_
fpr
[
i
]
=
tcg_global_mem_new_i32
(
TCG_AREG0
,
offsetof
(
CPUState
,
fpr
[
i
]),
fregnames
[
i
]);
cpu_fpr
[
i
]
=
tcg_global_mem_new_i32
(
TCG_AREG0
,
offsetof
(
CPUState
,
fpr
[
i
]),
fregnames
[
i
]);
/* register helpers */
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录