Add some additional conversions for ELF assembler output.
This commit is contained in:
parent
29ee3faf63
commit
5a3ab70cb5
@ -1,20 +1,23 @@
|
|||||||
void munchit(char *);
|
void munchit(char *);
|
||||||
%%
|
%%
|
||||||
|
.\.l\ [._A-Za-z][A-Za-z0-9_.]*/\, {printf("%c.l",yytext[0]);munchit(yytext+3);}
|
||||||
|
.\.w\ [._A-Za-z][A-Za-z0-9_.]*/\, {printf("%c.w",yytext[0]);munchit(yytext+3);}
|
||||||
\..*\n printf("%s", yytext);
|
\..*\n printf("%s", yytext);
|
||||||
pea[ ][_A-Za-z][A-Za-z0-9_]*$ {printf("pea");munchit(yytext+3);}
|
pea[ ][._A-Za-z][A-Za-z0-9_.]*$ {printf("pea");munchit(yytext+3);}
|
||||||
\ [_A-Za-z][A-Za-z0-9_]*/\, munchit(yytext);
|
\ [._A-Za-z][A-Za-z0-9_.]*/\, munchit(yytext);
|
||||||
. putchar(*yytext);
|
. putchar(*yytext);
|
||||||
%%
|
%%
|
||||||
/* $NetBSD: txlt.l,v 1.3 2001/03/02 16:43:25 mhitch Exp $ */
|
/* $NetBSD: txlt.l,v 1.4 2001/12/17 05:45:08 mhitch Exp $ */
|
||||||
|
|
||||||
void
|
void
|
||||||
munchit(s)
|
munchit(s)
|
||||||
char *s;
|
char *s;
|
||||||
{
|
{
|
||||||
putchar(*s++);
|
putchar(*s++);
|
||||||
if (!strncmp(s, "fp", 2) ||
|
if ((!strncmp(s, "fp", 2) ||
|
||||||
!strncmp(s, "sp", 2) ||
|
!strncmp(s, "sp", 2) ||
|
||||||
((*s == 'a') || (*s == 'd')) && ((s[1]-'0')<=7))
|
((*s == 'a') || (*s == 'd')) && ((s[1]-'0')<=7)) &&
|
||||||
|
(s[2] == 0 || s[2] == ','))
|
||||||
printf("%s", s);
|
printf("%s", s);
|
||||||
else
|
else
|
||||||
printf("%%pc@(%s)",s);
|
printf("%%pc@(%s)",s);
|
||||||
|
Loading…
Reference in New Issue
Block a user