亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? dis.c

?? m68k系列反匯編的C語言源碼,供學習編譯原理的同學使用。實用!
?? C
?? 第 1 頁 / 共 3 頁
字號:
/* *                 Author:  Christopher G. Phillips *              Copyright (C) 1994 All Rights Reserved * *                              NOTICE * * Permission to use, copy, modify, and distribute this software and * its documentation for any purpose and without fee is hereby granted * provided that the above copyright notice appear in all copies and * that both the copyright notice and this permission notice appear in * supporting documentation. * * The author makes no representations about the suitability of this * software for any purpose.  This software is provided ``as is'' * without express or implied warranty. */#include <stdio.h>#include <stdlib.h>#include <string.h>#include <ctype.h>#include "dis.h"#define ISASCII(c)	(0x20 <= (c) && (c) <= 0x7e)#ifdef DEBUG#define INITIAL		0x01#define DELETIONS	0x02#define TRY		0x04#define LASTTRY		0x08#define MAKEGOOD	0x10#define OVERLAPS	0x20#define LABELS		0x40int	debug = 0;#endiflong		curoffset;	/* current offset into file */short		flags;		/* flags for current instruction */m68kaddr	required[3];	/* instructions that must be valid for current				   instruction to also be valid */int		pcrelative = 0;	/* used to signal that PC-relative addresses				   referenced by JMP and JSR instructions				   should be stored in ``required'' */extern char	instbuf[];	/* used to store the nibbles of an				   instruction in hexadecimal */extern size_t	leninstbuf;	/* current length of string in instbuf */struct inst	*insts;		/* instruction database */m68kaddr	maxoffset;	/* last offset that may hold an instruction *//* * These macros are used for convenience.  They do the following: * * NREQD(o)	returns the number of instructions instruction ``o'' depends on * JUMP(o)	returns whether instruction ``o'' changes PC unconditionally *		(modulo ``jfile'' instructions) * FETCH(o,s)	returns whether instruction ``o'' is valid and has size ``s'' *		(for ``s'' positive) * DELETE(o)	renders instruction ``o'' invalid * SETLABEL(o)	marks instruction ``o'' as requiring a label in the output */#define NREQD(o)	(insts[o].flags & 3)#define JUMP(o)		(insts[o].flags & (ISBRA | ISRTS | ISJMP | ISJSR))#define FETCH(o,s)	(/* (o) >= 0 && */ (o) <= maxoffset && \			  ((s) == -1 && insts[o].size \			  || insts[o].size == (s)))#define DELETE(o)	do { \				free(insts[o].required); \				insts[o].required = NULL; \				insts[o].size = 0; \				insts[o].flags = 0; \			} while (0);#define SETLABEL(o)	if ((o) >= initialpc && (o) <= initialpc + maxoffset) \				insts[(o) - initialpc].flags |= ISLABELstatic short	longestinstsize;	/* max possible instruction length */static long	gfsize = 0;		/* file size */static m68kaddr	*notinsts = NULL;	/* array of values in ``nfile'' */static size_t	nnotinsts = 0;static m68kaddr	*breaks = NULL;		/* array of values in ``bfile'' */static size_t	nbreaks = 0;#ifndef NOBADstatic m68kaddr	*bad;	/* addresses that cause instructions to be deleted */static m68kaddr	*good;	/* addresses that cause instructions to be accepted			   in the final output */#endif/* * Free dynamically allocated memory * and longjmp back to process the next object file. */static voidjumpfree(void){#ifndef NOBAD	m68kaddr	offset;	for (offset = 0; offset <= maxoffset; offset += (odd ? 1 : WORDSIZE)) {		if (dobad && insts[offset].size == 0)			fprintf(stderr,"%s: Instruction %lx: deleted because of %lx\n",			  sfile, (long)(offset + initialpc), (long)bad[offset]);		if (insts[offset].flags & ISGOOD		  && bad[offset])			fprintf(stderr,"%s: Instruction %lx: assumed good because of %lx, deleted because of %lx\n",			  sfile, (long)(offset + initialpc), (long)good[offset],			  (long)bad[offset]);	}	free(bad);	bad = NULL;	free(good);	good = NULL;#endif	while (gfsize--)		free(insts[gfsize].required);	free(insts);	insts = NULL;	gfsize = 0;	longjmp(jmp, 1);}/* * Search ``p'' for a string of at least ``minlen'' consecutive * printable characters.  Return the index of the start of the string (or -1). */static intfindstring(size_t stored, const unsigned char *p){	int	i;	int	inarow;	for (inarow = i = 0; i < stored; i++, p++)		if (use_isprint && isprint(*p) || !use_isprint && ISASCII(*p)) {			if (++inarow >= minlen)				return i - inarow + 1;		} else			inarow = 0;	return -1;}/* * ``p'' contains the nibbles of a floating-point constant in hexadecimal. * These nibbles are converted into longword values and passed to ``fpoint'' * which formats the floating-point value in ``s'' (in printable form). */static intsfpoint(int type, const unsigned char *p, char *s){	u32bit_t	longwords[3];	size_t		nlongwords;	size_t		i, j;	switch (type) {	case SINGLE:    nlongwords = 1; break;	case DOUBLE:    nlongwords = 2; break;	case EXTENDED: case PACKED:			nlongwords = 3; break;	}	/*	 * Convert string to longs.	 */	for (i = 0; i < nlongwords; i++) {		longwords[i] = 0;		for (j = 0; j < 2 * WORDSIZE; j++)			longwords[i] += (*p++)			  << (CHAR_BIT * (2 * WORDSIZE - 1 - j));	}	return fpoint(longwords, type, s);}/* * Output constants.  Return how many floating-point constants were output. * * todo		number of input bytes to output. * p		nibbles of the constant(s) in hexadecimal. * floattype	floating-point type expected (or 0). * numforce	specifies how many floating-point constants should be output *		regardless of value if ``floattype'' is nonzero, else specifies *		that output must be forced if nonzero. * * Returns the number of bytes output. */static size_tdcflush(size_t todo, const unsigned char *p, int floattype, int numforce){	char		format[BUFSIZ];	int		i;	m68kaddr	value;	size_t		n;	size_t		j;	size_t		length;	int		lflags;	int		first = 1;	int		dofp;	size_t		total = todo;	while (todo) {		lflags = ops2f(1);		if ((length = fsizeof(floattype)) == 0)			floattype = 0;		/*		 * Determine if a floating-point constant should be output.		 * After forced constants are output, we stay with the		 * same type until we get NaN or Denormalized.		 */		dofp = 0;		if (floattype && length <= todo) {			if (sfpoint(floattype, p, format) != -1)				dofp = 1;		}		if (floattype && --numforce >= 0 || dofp) {			dofp = 1;			lflags |= size2f(floattype);		} else if (floattype)			return total - todo;		/*		 * For integral constants, we do 2 words at a time.		 * If the address is odd, we do the first byte by itself.		 */		if (!dofp) {			length = 2 * WORDSIZE;			if (todo < length) {				if (numforce)					length = todo;				else					return total - todo;			}			if (first && (ppc & 1) && length != todo)				length = 1;			if ((length % WORDSIZE) == 0) {				lflags |= size2f(WORD);				for (n = 0, i = 0; i < length / 2; i++) {					for (value = 0, j = 0; j < WORDSIZE;					  j++)						value += p[i * WORDSIZE + j]						  << (CHAR_BIT						  * (WORDSIZE - 1 - j));						value = signextend(value, 16);					if (i)						n += sprintf(format + n, ",");					n += sprintf(format + n, "#%d", value);				}			} else {				lflags |= size2f(BYTE);				for (n = 0, i = 0; i < length; i++) {					if (i)						n += sprintf(format + n, ",");					n += sprintf(format + n, "#%u", p[i]);				}			}		}		leninstbuf = 0;		for (i = 0; i < length; i++)			leninstbuf += sprintf(instbuf + leninstbuf, "%02x",			  p[i]);		pc += length;		instprint(lflags, "DC", format);		todo -= length;		p += length;		first = 0;	}	return total - todo;}/* * Output a string. * Return number of characters output. */static size_tascflush(size_t stored, const unsigned char *p, int force){	char	format[BUFSIZ];	size_t	length;	size_t	i;	size_t	n;	size_t	left;	size_t	nbytes;	for (length = 0; length < stored; length++)		if (use_isprint && !isprint(p[length])		  || !use_isprint && !ISASCII(p[length]))			break;	if (length == stored && !force)		return 0;	format[0] = '\'';	left = length;	while (left) {		n = 1;		leninstbuf = 0;		nbytes = (left > slenprint) ? slenprint : left;		for (i = length - left; i < length - left + nbytes; i++) {			leninstbuf += sprintf(instbuf + leninstbuf, "%02x",			  p[i]);			n += sprintf(format + n, "%c", p[i]);			/*			 * Double single quotes in strings.			 */			if (p[i] == '\'')				format[n++] = '\'';		}		format[n++] = '\'';		format[n++] = '\0';		pc += nbytes;		instprint(ops2f(1) | size2f(BYTE), "DC", format);		left -= nbytes;	}	return length;}/* * Convert a floating-point-label type to a floating-point type. */static intfl2ftype(int lflags){	if (lflags & ISLABEL) {		if (lflags & L_ISSINGLE)			return SINGLE;		if (lflags & L_ISDOUBLE)			return DOUBLE;		if (lflags & L_ISEXTENDED)			return EXTENDED;		if (lflags & L_ISPACKED)			return PACKED;	}	return 0;}/* * Output the ``stored'' input bytes contained in ``consts''. * If flags specifies a floating-point type, output floating-point * constants of that type as long as the input looks like them. * Output strings as appropriate.  Otherwise, output integral constants. * Return number of input bytes *not* output. */static size_tflush(size_t stored, const unsigned char *consts, int lflags, int force){	size_t	length;	int	spos = -2;	int	labelfptype = fl2ftype(lflags);	int	labelfpsize = fsizeof(labelfptype);	int	first = 1;	while (stored) {		spos = findstring(stored, consts);		if (first && labelfpsize && stored >= labelfpsize) {			if (spos == -1)				length = stored / labelfpsize * labelfpsize;			else if (spos > labelfpsize)				length = spos / labelfpsize * labelfpsize;			else				length = labelfpsize;			/*			 * Force a floating-point constant.			 */			length = dcflush(length, consts, labelfptype, 1);			stored -= length;			consts += length;			first = 0;			continue;		}		if (spos) {			int	lforce = 1;			/*			 * Output integral constant(s).			 */			if (spos < 0) {				if (force)					length = stored;				else {					if (stored < minlen)						return stored;					length = stored - minlen + 1;					lforce = 0;				}			} else				length = spos;			if (length > 0) {				if ((length = dcflush(length, consts, 0,				  lforce)) == 0)					return stored;				stored -= length;				consts += length;			} else				return stored;		}		if (spos >= 0) {			/*			 * Output string.			 */			if ((length = ascflush(stored, consts, force)) == 0)				return stored;			stored -= length;			consts += length;		}		first = 0;	}	return 0;}/* * Read a word (and extension words as necessary) from the input file * and determine if it is a possible instruction. * * ``valid'' is set to signal this. */static intvalidinst(void){	m68kword	inst;	valid = 0;	if (nextword(&inst) == 0) {		switch (inst >> 12) {		case 0:			bit_movep_immediate(inst);			break;		case 1:			movebyte(inst);			break;		case 2:			movelong(inst);			break;		case 3:			moveword(inst);			break;		case 4:			misc(inst);			break;		case 5:			addq_subq_scc_dbcc_trapcc(inst);			break;		case 6:			valid = bcc_bsr(inst);			break;		case 7:			moveq(inst);			break;		case 8:			or_div_sbcd(inst);			break;		case 9:			sub_subx(inst);			break;		case 10:			aline(inst);			break;		case 11:			cmp_eor(inst);			break;		case 12:			and_mul_abcd_exg(inst);			break;		case 13:			add_addx(inst);			break;		case 14:			shift_rotate_bitfield(inst);			break;		case 15:			coprocessor(inst);			if (!valid)				fline(inst);			break;		}	}	return valid;}/* * Now that we know where the constants are, make another pass * to determine which of them are referenced using the PC-relative * addressing mode. */static voiddcpass(void){	m68kaddr	offset;	pass = DCLABELSPASS;	if (fseek(infp, 0, SEEK_SET) == -1) {		perror("fseek");		jumpfree();	}	for (curoffset = offset = 0; offset <= maxoffset; )		if (insts[offset].size) {			if (curoffset != offset			  && fseek(infp, curoffset = offset, SEEK_SET) == -1) {				perror("fseek");				jumpfree();			}			flags = 0;			pc = ppc = offset + initialpc;			leninstbuf = 0;			validinst();			offset += insts[offset].size;		} else if (odd)			offset++;		else			offset += WORDSIZE;}/* * Make a pass over the input, outputting things as we currently see them. */static voidprintall(void){	m68kaddr	offset;	unsigned char	consts[BUFSIZ];	size_t		stored = 0;	if (fseek(infp, 0, SEEK_SET) == -1) {		perror("fseek");		jumpfree();	}	pc = ppc = initialpc;	leninstbuf = 0;	pass = DEBUGPASS;	for (curoffset = offset = 0; offset < gfsize /* = maxoffset */;	  offset += (odd ? 1 : WORDSIZE)) {		/*		 * Determine if there might be a valid instruction		 * which has the bytes at ``offset'' as operands.		 */		if (insts[offset].size == 0) {			int	i = 0;			size_t	size;			for (size = odd ? 1 : WORDSIZE; size <= longestinstsize			  && size <= offset; size += (odd ? 1 : WORDSIZE))				if (size < insts[offset - size].size) {					i = 1;					break;				}			if (i)				continue;		}		if (curoffset != offset		  && fseek(infp, curoffset = offset, SEEK_SET) == -1) {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
美国毛片一区二区| 欧美性大战久久久| 91黄色免费观看| 2021中文字幕一区亚洲| 一区二区免费在线播放| 国内外成人在线视频| 欧美日韩国产一区| 亚洲乱码中文字幕| 国产伦精品一区二区三区免费 | 欧美高清在线视频| 丝袜亚洲另类欧美| 99久久精品免费| 亚洲精品一区二区三区99| 亚洲午夜激情网站| 91国偷自产一区二区开放时间 | 国产在线观看免费一区| 欧美丝袜自拍制服另类| 综合久久久久久| 成人视屏免费看| 久久亚洲一区二区三区明星换脸 | 欧美午夜寂寞影院| 日韩久久一区二区| 岛国av在线一区| 久久久99精品免费观看| 色婷婷av一区二区三区软件| 国产日产欧美一区| 国产精品一区免费视频| 欧美tickle裸体挠脚心vk| 奇米一区二区三区av| 欧美一区二区网站| 视频一区欧美精品| 日韩无一区二区| 麻豆成人免费电影| 欧美大片日本大片免费观看| 日韩激情av在线| 91精品在线一区二区| 七七婷婷婷婷精品国产| 欧美电影免费观看高清完整版在线 | 亚洲在线一区二区三区| 91欧美一区二区| 一区二区视频在线| 91国产丝袜在线播放| 亚洲制服欧美中文字幕中文字幕| 色婷婷久久99综合精品jk白丝| 亚洲欧美日韩中文播放| 在线观看欧美黄色| 无吗不卡中文字幕| 欧美一区二区啪啪| 国产一区二区三区四| 国产日韩欧美精品综合| av电影天堂一区二区在线观看| 亚洲欧美怡红院| 欧美日韩一区二区三区不卡| 日韩成人一级片| 精品成人免费观看| 高清成人在线观看| 亚洲欧美偷拍卡通变态| 欧美日韩精品三区| 久久www免费人成看片高清| 国产亚洲一区二区在线观看| eeuss鲁一区二区三区| 亚洲一线二线三线久久久| 日韩欧美一级二级三级| 99视频在线精品| 午夜精品一区在线观看| 精品处破学生在线二十三| 91小视频在线| 免费看黄色91| 国产精品白丝在线| 日韩午夜激情免费电影| 不卡一区二区三区四区| 丝袜美腿成人在线| 国产精品久久久久影院亚瑟| 欧美日韩国产成人在线免费| 国产在线视频精品一区| 亚洲国产日韩一区二区| 日本一区二区免费在线观看视频 | 在线国产电影不卡| 久久99久久久久| 亚洲色图欧洲色图| 精品日韩欧美在线| 欧美日韩中文一区| 不卡的av电影| 激情偷乱视频一区二区三区| 亚洲欧美另类小说视频| 久久天堂av综合合色蜜桃网| 在线观看欧美黄色| 粉嫩一区二区三区在线看| 亚洲3atv精品一区二区三区| 国产精品久久久久久亚洲伦| 日韩欧美卡一卡二| 欧美日韩在线一区二区| 99re热视频精品| 国产福利一区二区三区在线视频| 日本中文字幕一区二区有限公司| 亚洲精品欧美激情| 国产精品蜜臀在线观看| 久久久国产精品午夜一区ai换脸| 69堂成人精品免费视频| 在线精品亚洲一区二区不卡| 972aa.com艺术欧美| 福利视频网站一区二区三区| 狠狠色狠狠色综合| 青青青爽久久午夜综合久久午夜| 亚洲国产精品久久人人爱蜜臀| 中文字幕一区二区三区乱码在线 | 国产主播一区二区三区| 日本va欧美va瓶| 天堂av在线一区| 天堂午夜影视日韩欧美一区二区| 亚洲激情自拍视频| 亚洲精品成人悠悠色影视| √…a在线天堂一区| 中文字幕视频一区| 国产精品传媒视频| 国产精品久久久久久久浪潮网站| 国产欧美一区二区精品婷婷| 精品国产亚洲在线| 久久久亚洲欧洲日产国码αv| 26uuu久久综合| 国产三级久久久| 国产欧美日韩视频一区二区| 国产欧美日韩亚州综合 | 欧美一区二区三区在线看| 欧美色视频在线观看| 欧美亚洲一区二区三区四区| 欧美日韩在线综合| 欧美一级搡bbbb搡bbbb| 亚洲精品一区二区三区香蕉| 国产色一区二区| 国产精品美女久久久久aⅴ | 日韩国产精品久久久久久亚洲| 日本美女一区二区三区视频| 看片的网站亚洲| 国产99久久久国产精品免费看| 成人精品视频一区二区三区尤物| 99久久er热在这里只有精品66| 国产人成一区二区三区影院| 国产精品美女久久久久久久久久久| 国产精品二三区| 亚洲成a人v欧美综合天堂下载| 日韩电影一区二区三区四区| 国内精品写真在线观看| 不卡一二三区首页| 精品视频一区 二区 三区| 日韩一区二区三区精品视频| 精品国产乱子伦一区| 中文字幕日韩精品一区| 亚洲高清免费视频| 国内精品不卡在线| 色综合咪咪久久| 91精品在线免费| 国产精品乱人伦中文| 亚洲成人你懂的| 国产精品综合av一区二区国产馆| 99视频在线观看一区三区| 欧美老人xxxx18| 欧美激情一区二区| 日韩精品一级中文字幕精品视频免费观看| 国产老女人精品毛片久久| 97se亚洲国产综合在线| 日韩午夜激情免费电影| 亚洲精品视频一区二区| 国产在线观看免费一区| 欧美日韩综合一区| 国产精品久久久久久久蜜臀| 老色鬼精品视频在线观看播放| 91麻豆国产福利在线观看| 精品少妇一区二区三区日产乱码| 一区二区三区在线免费| 国产成人精品aa毛片| 欧美精选一区二区| 亚洲视频精选在线| 国产成+人+日韩+欧美+亚洲| 欧美日韩大陆一区二区| 亚洲丝袜自拍清纯另类| 国产精品一线二线三线| 欧美一区二区视频在线观看| 亚洲人成网站影音先锋播放| 丁香五精品蜜臀久久久久99网站| 欧美一区二区三区四区在线观看| 一区二区三区鲁丝不卡| 99久久99精品久久久久久| 精品人伦一区二区色婷婷| 视频在线观看一区| 欧美午夜理伦三级在线观看| 综合久久综合久久| 成人aa视频在线观看| 中日韩av电影| 成人污视频在线观看| 国产日韩欧美a| 久久99久久精品| 日韩三级高清在线| 日韩二区三区在线观看| 欧美色图一区二区三区| 亚洲成在线观看| 欧美日高清视频| 日韩福利电影在线| 日韩午夜激情免费电影| 欧美bbbbb|