Skip to content
Low-level programming · Higher-level thinking
Login Register
Forum / News

Ziron 2 - development has resumed

A community discussion post from the original code:zIRON forum.

Replies

Emil_halim member
Posts
639
Threads
104
Location
Alex, Egypt

Hi Colin,

i think , ret or return may not has a return value , just like my example.

also the @ does not compile , the compiler gave this error

Instruction usage is not supported! code: eax = @fff;

http://www.freewebs.com/ogremagic/index.htm

Colin admin
Posts
928
Threads
49
Location
Bulgaria

I will try fit these fixes into my schedule over the weekend. I will let you know.

Colin admin
Posts
928
Threads
49
Location
Bulgaria

OK I have uploaded the latest beta

Download Here

when calling a label, the label should not call ret (since the internal assembler will try to calculate the locals offset, instead you should use lret (label return)

e.g.

program PE32_CUI 'test';

#include 'win_def.zir';

goto start;
aaa:
	mov eax, 5
	lret 0;
	
start:
	eax = @aaa;
	call eax

ExitProcess(0);
Emil_halim member
Posts
639
Threads
104
Location
Alex, Egypt

ok , thanks for that updating.

as for beta release i can accept that lret uses to return from subroutine , but actual assemblers using normal ret when return from routine.

  

http://www.freewebs.com/ogremagic/index.htm

Emil_halim member
Posts
639
Threads
104
Location
Alex, Egypt

also , call should use a label directly ,instead of load address in eax then call eax.

thank you for the blugin system.

http://www.freewebs.com/ogremagic/index.htm

Colin admin
Posts
928
Threads
49
Location
Bulgaria

Other assemblers do not auto manage stack for functions. And you can call label directly, it was just an example.