c++ builder里汇编语句编译出现out of hash space错误。(100分)

Y

yjbin

Unregistered / Unconfirmed
GUEST, unregistred user!
这个函数我以前在另一个软件里编译过的,肯定没有问题。

现在c++ builder5.0下编译时出现out of hash space 的错误。
已经设project/option/compiler/pre-compiler headers = None
各位有遇到过此问题吗?如何解决?
这个函数是在win9x系统下使扬声器发声的。


void BeepWin9x(unsigned short pitch, unsigned long duration)
{

asm mov bx, pitch
asm mov ax, 34DDh
asm mov dx, 0012h
asm cmp dx, bx
asm jnb stop
asm div bx
asm mov bx, ax
asm in al, 61h
asm test al, 3
asm jne j1
asm or al, 3
asm out 61h, al
asm mov al, 0B6h
asm out 43h, al
j1:
asm mov al, bl
asm out 42h, al
asm mov al, bh
asm out 42h, al
stop: ;

Sleep(duration);

asm in al,61H
asm and al, 0fcH
asm out 61H, al

}
 
顶部