[syslinux] Re: Menu system limitations

H. Peter Anvin hpa at zytor.com
Wed Apr 28 11:20:35 PDT 2004


Murali Krishnan Ganapathy wrote:
> The only limit AFAIK is memory. All memory is allocated statically at 
> compile time. The maximum size for a COM file is 64K. The code plus all 
> the data should fit into this. Assuming about 256 bytes per item (that 
> is on the higher side), and 10K for code, and about 6K for the stack, 
> you have a limit of about 200 items. If you go over the limit, you 
> should not be able to compile the code (the compiler should complain 
> that your final executable is more than 64K).
> 
> If your items can be dynamically generated, then you may be able to 
> leverage the additional 64K available for COM files (this would mean 
> changing the code, since currently the code assumes a 16bit pointer). If 
> you need more than 200 and odd items and they are static, I see one 
> simple workaround...
> 
> * Cut your menu tree at some level (say level 2). Then you will have a 
> mainmenu.com which displays the first two levels of the menu, and for 
> each possible level 2 choice, you will have a different menu.com file. 
> Choosing a item from the mainmenu, will call one of the helper menu.com.
> 

Well, the simplest way to undo that limitation would be to switch to com32.

	-hpa




More information about the Syslinux mailing list