首页
社区
课程
招聘
[旧帖] [分享]C#写的汇编反编译器 0.00雪花
发表于: 2009-10-20 14:05 1603

[旧帖] [分享]C#写的汇编反编译器 0.00雪花

2009-10-20 14:05
1603
C#写的汇编反编译器已经完成,可以反编译机器码了(参照了很多代码才完成的)。我的目的是想写一个编译器,这个编译器用C#语法(目的:C#.net的调试环境太舒服了,我想自己写个编译器D#,用他可以写操作系统,而调试时将代码放到微软平台上,调试通过后再将他用D#编译成机器码,这样效率和调试就可以兼顾了)不知道我的想法大家是否赞同。我本人比较喜欢C#。但是用它写操作系统不太现实。而我又非常喜欢他的调试环境。所以萌生了这种折中想法。希望大家给我个意见,或者大家仪器开发。我英语不太好所以希望有Intel手册第二卷(要翻译的)发给我一份,我可以将C#写的反编译器发给你(这个编译器可以反编译64位的)。希望大家切磋。我认为用C#写操作系统很有可能的。只不过没有人去写它的高效编译器而已,指针方面可以用另一个途径达到效果。guodemone@vip.sina.com

[注意]传递专业知识、拓宽行业人脉——看雪讲师团队等你加入!

收藏
免费 0
支持
分享
最新回复 (5)
雪    币: 4560
活跃值: (1002)
能力值: ( LV4,RANK:50 )
在线值:
发帖
回帖
粉丝
2
C#写操作系统貌似效率不会很高吧,光资源回收就够忙的
2009-10-20 14:39
0
雪    币: 74
活跃值: (10)
能力值: ( LV4,RANK:50 )
在线值:
发帖
回帖
粉丝
3
C#不错啊,虽然接触很少,但觉得也大有用武之地
2009-10-20 14:57
0
雪    币: 306
活跃值: (13)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
4
好厉害。。。等楼主发文。
2009-10-20 15:01
0
雪    币: 31
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
5
二楼同志还没有看懂我写的文字,我的意思是“用”C#的语法和它在微软平台的调试器,但是编译器是自己来写,最终目标就是它能把代码编译到任何平台,我希望将编译器器做小点,让它跟着代码一块儿发布,这样大家用【D#,我起的名字,哈哈】,免于好多人上手不会安装。如果我的想法能够行动通,那么只要会在微软平台写C#的人,就能用我写的编译器编译到其他平台运行。不过我一个人的力量太小了,看看咱们论坛有没有有志之士和我一起做这项工作。其实我的目的是想借用C#的壳子来写操作系统。因为.net的运行效率太低,所以想到重写编译器,让我的编译器直接将C#源码编译成机器码,这样效率不就同C/C++一样了吗?你们说呢?
2009-10-20 16:05
0
雪    币: 31
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
6
请英文好的通知帮我翻译一下,谢谢,我的英语自上学开始就及过一次个格。我真的对英语是个白痴。
/*
* Codes for Addressing Method:
* ---------------------------
* A  - Direct address. The instruction has no ModR/M byte; the address
*      of the operand is encoded in the instruction; and no base register,
*      index register, or scaling factor can be applied.
* C  - The reg field of the ModR/M byte selects a control register.
* D  - The reg field of the ModR/M byte selects a debug register.
* E  - A ModR/M byte follows the opcode and specifies the operand. The
*      operand is either a general-purpose register or a memory address.
*      In case of the register operand, the R/M field of the ModR/M byte
*      selects a general register.
* F  - Flags Register.
* G  - The reg field of the ModR/M byte selects a general register.
* H  - A ModR/M byte follows the opcode and specifies the operand. The
*      operand is either a general-purpose register or a memory address.
*      In case of the register operand, the reg field of the ModR/M byte
*      selects a general register.
* I  - Immediate data. The operand value is encoded in subsequent bytes of
*      the instruction.
* J  - The instruction contains a relative offset to be added to the
*      instruction pointer register.
* M  - The ModR/M byte may refer only to memory.
* N  - The R/M field of the ModR/M byte selects a packed-quadword  MMX
        technology register.
* O  - The instruction has no ModR/M byte; the offset of the operand is
*      coded as a word or double word (depending on address size attribute)
*      in the instruction. No base register, index register, or scaling
*      factor can be applied.
* P  - The reg field of the ModR/M byte selects a packed quadword MMX
*      technology register.
* Q  - A ModR/M byte follows the opcode and specifies the operand. The
*      operand is either an MMX technology register or a memory address.
*      If it is a memory address, the address is computed from a segment
*      register and any of the following values: a base register, an
*      index register, a scaling factor, and a displacement.
* R  - The mod field of the ModR/M byte may refer only to a general register.
* S  - The reg field of the ModR/M byte selects a segment register.
* T  - The reg field of the ModR/M byte selects a test register.
* U  - The R/M field of the ModR/M byte selects a 128-bit XMM register.
* V  - The reg field of the ModR/M byte selects a 128-bit XMM register.
* W  - A ModR/M byte follows the opcode and specifies the operand. The
*      operand is either a 128-bit XMM register or a memory address. If
*      it is a memory address, the address is computed from a segment
*      register and any of the following values: a base register, an
*      index register, a scaling factor, and a displacement.
* X  - Memory addressed by the DS:rSI register pair.
* Y  - Memory addressed by the ES:rDI register pair.
*/

/*
* Codes for Operand Type:
* ----------------------
* a  - Two one-word operands in memory or two double-word operands in
*      memory, depending on operand-size attribute (used only by the BOUND
*      instruction).
* b  - Byte, regardless of operand-size attribute.
* d  - Doubleword, regardless of operand-size attribute.
* dq - Double-quadword, regardless of operand-size attribute.
* p  - 32-bit or 48-bit pointer, depending on operand-size attribute.
* pd - 128-bit packed double-precision floating-point data.
* pi - Quadword MMX technology register (packed integer)
* ps - 128-bit packed single-precision floating-point data.
* q  - Quadword, regardless of operand-size attribute.
* s  - 6-byte or 10-byte pseudo-descriptor.
* si - Doubleword integer register (scalar integer)
* ss - Scalar element of a 128-bit packed single-precision floating data.
* sd - Scalar element of a 128-bit packed double-precision floating data.
* v  - Word, doubleword or quadword, depending on operand-size attribute.
* w  - Word, regardless of operand-size attr.
*/
2009-10-20 16:07
0
游客
登录 | 注册 方可回帖
返回
//