2003-04-30  H.J. Lu <hjl@gnu.org>

	* config/tc-ia64.c (stmt_float_cons): Fix alignment for real10
	and add real16.
	(md_pseudo_table): Add "xreal16", "xreal16.ua", "real16" and
	"real16.ua".
	(md_atof): Add 6 byte padding of zero for real16.

gas/testsuite/

2003-04-29  H.J. Lu <hjl@gnu.org>

	* gas/ia64/ia64.exp: Add real.

	* gas/ia64/real.s: New file.
	* gas/ia64/real.d: Likewise.
This commit is contained in:
H.J. Lu 2003-04-30 21:38:55 +00:00
parent 070203902f
commit 165a7f90d4
6 changed files with 56 additions and 5 deletions

View File

@ -1,3 +1,11 @@
2003-04-30 H.J. Lu <hjl@gnu.org>
* config/tc-ia64.c (stmt_float_cons): Fix alignment for real10
and add real16.
(md_pseudo_table): Add "xreal16", "xreal16.ua", "real16" and
"real16.ua".
(md_atof): Add 6 byte padding of zero for real16.
2003-04-29 Nick Clifton <nickc@redhat.com>
* config/obj-elf.c (obj_elf_symver): Skip whitespace before the

View File

@ -4410,19 +4410,25 @@ static void
stmt_float_cons (kind)
int kind;
{
size_t size;
size_t alignment;
switch (kind)
{
case 'd': size = 8; break;
case 'x': size = 10; break;
case 'd':
alignment = 8;
break;
case 'x':
case 'X':
alignment = 16;
break;
case 'f':
default:
size = 4;
alignment = 4;
break;
}
ia64_do_align (size);
ia64_do_align (alignment);
float_cons (kind);
}
@ -4899,6 +4905,7 @@ const pseudo_typeS md_pseudo_table[] =
{ "xreal4", dot_xfloat_cons, 'f' },
{ "xreal8", dot_xfloat_cons, 'd' },
{ "xreal10", dot_xfloat_cons, 'x' },
{ "xreal16", dot_xfloat_cons, 'X' },
{ "xstring", dot_xstringer, 0 },
{ "xstringz", dot_xstringer, 1 },
@ -4909,6 +4916,7 @@ const pseudo_typeS md_pseudo_table[] =
{ "xreal4.ua", dot_xfloat_cons_ua, 'f' },
{ "xreal8.ua", dot_xfloat_cons_ua, 'd' },
{ "xreal10.ua", dot_xfloat_cons_ua, 'x' },
{ "xreal16.ua", dot_xfloat_cons_ua, 'X' },
/* annotations/DV checking support */
{ "entry", dot_entry, 0 },
@ -4952,6 +4960,7 @@ pseudo_opcode[] =
{ "real4", stmt_float_cons, 'f' },
{ "real8", stmt_float_cons, 'd' },
{ "real10", stmt_float_cons, 'x' },
{ "real16", stmt_float_cons, 'X' },
{ "string", stringer, 0 },
{ "stringz", stringer, 1 },
@ -4963,6 +4972,7 @@ pseudo_opcode[] =
{ "real4.ua", float_cons, 'f' },
{ "real8.ua", float_cons, 'd' },
{ "real10.ua", float_cons, 'x' },
{ "real16.ua", float_cons, 'X' },
};
/* Declare a register by creating a symbol for it and entering it in
@ -10586,6 +10596,12 @@ md_atof (type, lit, size)
md_number_to_chars (lit, (long) (*word--), sizeof (LITTLENUM_TYPE));
lit += sizeof (LITTLENUM_TYPE);
}
if (type == 'X')
{
/* It is 10 byte floating point with 6 byte padding. */
memset (lit, 0, 6);
*size = 8 * sizeof (LITTLENUM_TYPE);
}
return 0;
}

View File

@ -1,3 +1,10 @@
2003-04-30 H.J. Lu <hjl@gnu.org>
* gas/ia64/ia64.exp: Add real.
* gas/ia64/real.s: New file.
* gas/ia64/real.d: Likewise.
2003-04-29 Nick Clifton <nickc@redhat.com>
* gas/elf/elf.exp: Invoke symver test.

View File

@ -41,4 +41,6 @@ if [istarget "ia64-*"] then {
run_dump_test "ltoff22x-1"
run_dump_test "dependency-1"
run_dump_test "real"
}

View File

@ -0,0 +1,10 @@
#objdump: -s -j .data
#name: ia64 real10 and real16 (LSB)
.*: +file format .*
Contents of section .data:
0000 ffcdcccc cccccccc ccfc3f00 00000000 ................
0010 cdcccccc cccccccc fc3fffcd cccccccc ................
0020 ccccccfb 3f000000 00000000 00000000 ................
0030 cdcccccc cccccccc fb3f0000 00000000 ................

View File

@ -0,0 +1,8 @@
.data
.lsb
data1 -1
real10.ua 0.2
real10 0.2
data1 -1
real16.ua 0.1
real16 0.1