⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 todo

📁 开源的nasm编译器源码,研究编译器原理很有帮且
💻
字号:
NASM TODO list==============This, like the AUTHORS file, is intended for easy readability by both human and machine, thus the format.  F: feature  V: version you should expect it by  R: responsible person or - if unassigned  C: % complete  D: description  D: maybe on multiple lines  Anything that doesn't start with /^[FVRCD]:/ should be ignored.  F:-line triggers new entry.  Empty V,R,C assume: V: ?, R: -, C: 0%=============F: i18n via gettextF: Convert shallow code model to deep code modelD: Tired of messing between lots of unrelated files (especially .c/.h stuff)F: Automated dependency generation for MakefileD: Current looks awful and will break if anything changes.F: Move output modules out*.c to output/ subdirR: madfireC: 10%== THESE ARE FROM old NASM's Wishlist== THEY NEED SEVERE REVISING (seems they weren't updated for a couple of years or so)F: Check misc/ide.cfg into RCS as Watcom IDE enhancement thingyV: 0.98D: (nop@dlc.fi)F: Package the Linux Assembler HOWTOV: 0.98F: 3DNow!, SSE and other extensions need documentingV: 0.98D: hpa: Does it really make sense to have a whole instruction setD: reference packaged with the assembler?F: prototypes of lrotate don't match in test/*. Fix.V: 0.98F: Build djgpp binaries for 0.98 onwards. Look into PMODE/W as a stubV: 0.98D: it might be a lot better than CWSDPMI. It's in PMW133.ZIP.F: %undef operator that goes along with %defineV: ?C: 100%F: Fix `%error' giving error messages twice.V: 0.99D: Not especially important, as changes planned for 1.1x below will makeD: the preprocessor be only called once.F: Sort out problems with OBJV: 0.99D: * TLINK32 doesn't seem to like SEGDEF32 et al. So for that, weD:   should avoid xxx32 records wherever we can.D: * However, didn't we change _to_ using xxx32 at some stage? TryD:   to remember why and when.D: * Apparently Delphi's linker has trouble with two or moreD:   globals being defined inside a PUBDEF32. Don't even know if itD:   _can_ cope with a PUBDEF16.D: * Might need extra flags. *sigh*F: Symbol table output may possibly be useful.V: 0.99D: Ken Martwick (kenm@efn.org) wants the following format:D: 	labelname	type	offset(hex)	repetition countD: Possibly include xref addresses after repetition count?F: ELF fixesV: 0.99D: There are various other bugs in outelf.c that make certain kindsD: of relocation not work. See zbrown.asm. Looks like we may have to doD: a major rewrite of parts of it. Compare some NASM code output withD: equivalent GAS code output. Look at the ELF spec. Generally fix things.F: ELF fixesV: 0.99D: NASM is currently using a kludge in ELF that involves definingD: a symbol at a zero absolute offset. This isn't needed, as theD: documented solution to the problem that this solves is to useD: SHN_UNDEF.F: Debug information, in all formats it can be usefully done in.V: 0.99D: * including line-number record support.D: * "George C. Lindauer" <gclind01@starbase.spd.louisville.edu>D:   wants to have some say in how this goes through.D: * Andrew Crabtree <andrewc@rosemail.rose.hp.com> wants to help out.F: Think about a line-continuation character.V: 0.99F: Consider allowing declaration of two labels on the same line,V: 0.99D: syntax 'label1[:] label2[:] ... instruction'.D: Need to investigate feasibility.F: Quoting of quotes by doubling them, in string and char constants.V: 0.99F: Two-operand syntax for SEGMENT/SECTION macro to avoid warningsD: of ignored section parameters on reissue of __SECT__.D: Or maybe skip the warning if the given parameters are identical toD: what was actually stored. Investigate.				V: 0.99F: Apparently we are not missing a PSRAQ instruction, because itD: doesn't exist.  Check that it doesn't exist as an undocumentedD: instruction, or something stupid like that.V: 0.99F: Any assembled form starting 0x80 can also start 0x82.V: 1.00D: ndisasm should know this. New special code in instruction encodings, probably.F: Pointing an EQU at an external symbol now generates an error.V: 1.05D: There may be a better way of handling this; we should look into it.D: Ideally, the label mechanism should be changed to cope with oneD: label being declared relative to another - that may work, but could beD: a pain to implement (or is it? it may be easy enough that you justD: need to declare a new offset in the same segment...) This should be doneD: before v1.0 is released. There is a comment regarding this in labels.c,D: towards the end of the file, which discusses ways of fixing this.F: nested %rep used to cause a panic.V: 1.10D: Now a more informative error message is produced. This problem whouldD: be fixed before v1.0.D: See comment in switch() statement block for PP_REP in do_directive()D: in preproc.c (line 1585, or thereabouts)F: ContributionD: zgraeme.tar contains improved hash table routinesD: contributed by Graeme Defty <graeme@HK.Super.NET> for use in theD: label manager.F: ContributionD: zsyntax.zip contains a syntax-highlighting mode forD: NASM, for use with the Aurora text editor (??).F: ContributionD: zvim.zip contains a syntax-highlighting mode for NASM, for use with vim.F: ContributionD: zkendal1.zip and zkendal2.zip contain KendallD: Bennett's (<KendallB@scitechsoft.com>) alternative syntax stuff,D: providing an alternative syntax mode for NASM which allows a macroD: set to be written that allows the same source files to beD: assembled with NASM and TASM.R: Kendall BennettC: 100%F: Add the UD2 instruction.C: 100%F: Add the four instructions documented in 24368901.pdf (Intel's own document).C: 100%F: Some means of avoiding MOV memoffs,EAX which apparently theD: Pentium pairing detector thinks modifies EAX. Similar means ofD: choosing instruction encodings where necessary.V: 1.10?F: The example of ..@ makes it clear that a ..@ label isn't justD: local, but doesn't make it clear that it isn't just global either.F: hpa wants an evaluator operator for ceil(log2(x)).F: Extra reloc types in ELFD: R_386_16 type 20, PC16 is 21, 8 is 22, PC8 is 23.D: Add support for the 16s at least.F: Lazy section creation or selective section outputD: in COFF/win32 at least and probably other formats: don't bother to emit a sectionD: if it contains no data. Particularly the default auto-createdD: section. We believe zero-length sections crash at least WLINK (in win32).F: Make the flags field in `struct itemplate' in insns.h a long instead of an int.C: 100%?F: Implement %ifref to check whether a single-line macro has ever been expanded since (last re) definition. Or maybe not. We'll see.F: add pointer to \k{insLEAVE} and \k{insENTER} in chapters about	mixed-language programming.F: Some equivalent to TASM's GLOBAL directiveD: ie something which defines a symbol as external if it doesn't end up being definedD: but defines it as public if it does end up being defined.F: Documentation doesn't explain about C++ name mangling.F: see if BITS can be made to do anything sensible in obj (eg set the default new-segment property to Use32).F: OBJ: coalesce consecutive offset and segment fixups for the same location into full-32bit-pointer fixups.D: This is apparently necessary because some twazzock in the PowerBASIC developmentD: team didn't design to support the OMF spec the way the rest of theD: world sees it.F: Allow % to be separated from the rest of a preproc directive, for	alternative directive indentation styles.F: __DATE__, __TIME__, and text variants of __NASM_MAJOR__ and __NASM_MINOR__.F: Warn on TIMES combined with multi-line macros.V: 1.00D: TIMES gets applied to first line only - should bring to users' attention.F: Re-work the evaluator, again, with a per-object-format fixupD: routine, so as to be able to cope with section offsets "really"D: being pure numbers; should be able to allow at _least_ the twoD: common idiomsD:   TIMES 510-$ DB 0            ; bootsectorD:   MOV AX,(PROG_END-100H)/16   ; .COM TSRD: Would need to call the fixup throughout the evaluator, and theD: fixup would have to be allowed to return UNKNOWN on pass one if itD: had to. (_Always_ returning UNKNOWN on pass one, though a lovelyD: clean design, breaks the first of the above examples.)V: 1.10F: Preprocessor identifier concatenation?V: 1.10F: Arbitrary section names in `bin'.V: 0.98.09D: Is this necessary? Is it even desirable?D: hpa: Desirable, yes.  Necessary?  Probably not, but there are definitely cases where it becomes quite useful.R: madfireC: 100%F: Ability to read from a pipe.V: 1.10D: Obviously not useful under dos, so memory problems with storingD: entire input file aren't a problem either.F: File caching under DOS/32 bit...V: 1.10?D: maybe even implement discardable buffers that get thrown awayD: when we get a NULL returned from malloc(). Only really useful underD: DOS. Think about it.F: possibly spool out the pre-processed stuff to a file, to avoid having to re-process it.V: 1.10?D: Possible problems with preprocessor values not known on pass 1? Have a look...F: Or maybe we can spool out a pre-parsed version...?V: 1.10D: Need to investigate feasibility. Does the results from the parserD: change from pass 1 to pass 2? Would it be feasible to alter it so thatD: the parser returns an invariant result, and this is then processedD: afterwards to resolve label references, etc?F: Subsection support?F: A good ALIGN mechanism, similar to GAS's.V: 0.98p1D: GAS pads out space by means of the following (32-bit) instructions:D:         8DB42600000000    lea esi,[esi+0x0]D:         8DB600000000      lea esi,[esi+0x0]D:         8D742600          lea esi,[esi+0x0]D:         8D7600            lea esi,[esi+0x0]D:         8D36              lea esi,[esi]D:         90                nopD: It uses up to two of these instructions to do up to 14-byte pads;D: when more than 14 bytes are needed, it issues a (short) jump toD: the end of the padded section and then NOPs the rest. Come up withD: a similar scheme for 16 bit mode, and also come up with a way toD: use it - internal to the assembler, so that programs using ALIGND: don't knock over preprocess-only mode.D:   Also re-work the macro form so that when given one argument in aD: code section it calls this feature.R: Panos MinosC: 100%?F: Possibly a means whereby FP constants can be specified as immediate operands to non-FP instructions.D: * Possible syntax: MOV EAX,FLOAT 1.2 to get a single-precision FPD:   constant. Then maybe MOV EAX,HI_FLOAT 1.2 and MOV EAX,LO_FLOATD:   1.2 to get the two halves of a double-precision one. Best toD:   ignore extended-precision in case it bites.D: * Alternatively, maybe MOV EAX,FLOAT(4,0-4,1.2) to get bytes 0-4D:   (ie 0-3) of a 4-byte constant. Then HI_FLOAT is FLOAT(8,4-8,x)D:   and LO_FLOAT is FLOAT(8,0-4,x). But this version allows two-byteD:   chunks, one-byte chunks, even stranger chunks, and pieces ofD:   ten-byte reals to be bandied around as well.F: A UNION macro might be quite coolD: now that ABSOLUTE is sane enough to be able to handle it.F: An equivalent to gcc's ## stringify operator, plus string concatenationD: somehow implemented without undue ugliness, so asD: to be able to do `%include "/my/path/%1"' in a macro, or somethingD: similar...F: Actually _do_ something with the processor, privileged andD: undocumented flags in the instruction table. When this happens,D: consider allowing PMULHRW to map to either of the Cyrix or AMDD: versions?D: hpa: The -p option to ndisasm now uses this to some extent.V: 1.10F: Maybe NEC V20/V30 instructions?					?D: hpa: What are they?  Should be trivial to implement.F: Yet more object formats.D: * Possibly direct support for .EXE files?V: 1.10F: Symbol map in binary format. Format-specific options...V: 1.10?F: REDESIGN: Think about EQU dependency, and about start-point specification in OBJ. Possibly re-think directive support.V: 1.20?F: Think about a wrapper program like gcc?V: 2.00?D: Possibly invent a _patch_ for gcc so that it can take .asm files on the command line?D: If a wrapper happens, think about adding an option to cause theD: resulting executable file to be executed immediately, thusD: allowing NASM source files to have #!... (probably silly)F: Multi-platform support?D: If so: definitely Alpha; possibly Java byte code;D: probably ARM/StrongARM; maybe Sparc; maybe Mips; maybeD: Vax. Perhaps Z80 and 6502, just for a laugh?F: Consider a 'verbose' option that prints information about the resulting object file onto stdout.F: Line numbers in the .lst file don't match the line numbers in the input.D: They probably should, rather than the current matching of the post-preprocessor line numbers.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -