Register | Login
Forum Index > News > Ziron 2 Release
Author Message
Pages: 1 2 3 4
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1372] Ziron 2 Release - posted: 2013-03-11 20:15:01
Hello there, this is not actually an official release yet, there is still many things to be done and added, but I'm releasing this alpha release so people can submit bugs of the current supported feature set.

Download Ziron 2 Alpha

Now there is some changes, and you won't be able to compile old ziron 1 samples just yet, this will not be until the official release. However the features that are implemented are much better than the predecessor.

For example, we now have support for complex if, while repeat statements:

Code:
if ((eax == 5) and ((ebx == 2) or ((edx != 23) and (ecx > 15))) { ...


There is also now uninitialized and initialized data, consts are written to read only memory, Support for unicode and other things you can find for yourself.

Once i have an offical release of Ziron 2 i will replace all documentation with up-to-date Ziron 2 documentation.

Also 1 thing to note is Ziron 2 supports only 318 opcodes so far, but i will add another 100+ for the beta release.

instructions supported for the alpha release:

Code:
or, bt, jo, jb, jc, jz, je, ja, js, jp, jl, jg, aaa, add, adc, and, 
cmp, cbw, clc, cld, cmc, daa, das, jmp, sbb, sub, lea, xor, nop, ud2, stc, std, 
dec, inc, pop, bsf, bsr, btc, btr, bts, shl, rcl, rol, ror, sal, sar, shr, rcr, 
mov, div, mul, neg, not, ret, jne, jnz, jno, jae, jnb, jnc, jbe, jna, jns, jnp, 
jpo, jge, jnl, jle, jng, jpe, call, cdqe, cwde, emms, fabs, fchs, fcos, fld1, fldz, 
fnop, fsin, ftst, fxam, goto, int3, push, sahf, seta, setb, setc, sete, setg, 
setl, seto, setp, sets, setz, test, idiv, retn, jnae, jnbe, jnge, jnle, 
fcom, fadd, fdiv, fmul, fsub, pand, cpuid, f2xm1, fclex, femms, finit, fldpi, 
fprem, fptan, fsqrt, fwait, leave, mwait, pause, popad, popfd, popfq, fyl2x, cmova, 
cmovb, cmovc, cmove, cmovg, cmovl, cmovo, cmovp, cmovs, 
cmovz, setae, setbe, setge, setle, setna, setnb, setnc, 
setne, setng, setnl, setno, setnp, setns, setnz, setpe, 
setpo, fcomp, fdivr, fsubr, addpd, addps, addsd, addss, 
andpd, andps, pslld, psllq, psllw, psrad, psraw, psrld, 
psrlq, psrlw, psubb, psubd, psubq, maxpd, maxps, maxsd, 
maxss, minpd, minps, minsd, minss, pabsb, pabsd, pabsw, 
paddb, paddd, paddq, paddw, pandn, pavgb, pavgw, psubw, 
ptest, divpd, divps, divsd, divss, mulpd, mulps, mulsd, 
mulss, lddqu, subpd, subps, subsd, subss, xorpd, xorps, 
fcompp, fldl2e, fldl2t, fldlg2, fldln2, fnclex, fninit, fpatan, 
fprem1, fscale, lfence, mfence, sfence, pushad, pushfd, pushfq, 
cmovae, cmovbe, cmovge, cmovle, cmovna, cmovnb, cmovnc, cmovne, 
cmovng, cmovnl, cmovno, cmovnp, cmovns, cmovnz, cmovpe, cmovpo, 
popcnt, setnae, setnbe, setnge, setnle, andnpd, andnps, comisd, 
comiss, haddpd, haddps, hsubpd, hsubps, paddsb, paddsw, phaddw, 
phsubd, phsubw, pmaxsb, pmaxsd, pmaxsw, pmaxub, pmaxud, pmaxuw, 
pminsb, pminsd, pminsw, pminub, pminud, pminuw, pmuldq, pmulhw, 
pmulld, pmullw, psignb, psignd, psignw, psubsb, psubsw, pslldq, 
psrldq, sqrtpd, sqrtps, sqrtsd, sqrtss, fdecstp, fincstp, frndint, 
fsincos, fucompp, fyl2xp1, monitor, cmovnae, cmovnbe, cmovnge, cmovnle, 
movq2dq, paddusb, paddusw, pcmpeqb, pcmpeqd, pcmpeqq, pcmpeqw, pcmpgtb, 
pcmpgtd, pcmpgtq, pcmpgtw, phaddsw, phsubsw, pmaddwd, pmulhuw, pmuludq, 
psubusb, psubusw, ucomisd, ucomiss, addsubpd, addsubps


high level blocks supported:

Code:
if, while, repeat until


Has support for functions, global and local variables and numerous other things which i will go into detail for the proper release.

also note there is no inline or macro support yet.

Please let me know what you think and i hope you enjoy playing around with Ziron 2 alpha.

a small sample to get you started:

Code:
program PE32_CUI 'my app';

#include 'win_def.zir';
#include 'zirutils.zir';

#set frame off;
procedure ShowMessageW(wchar* title, msg) {
  MessageBoxW(0, msg, title, 0);
}

procedure ShowMessageA(char* title, msg) {
  MessageBox(0, msg, title, 0);
}
#set frame on;

//
//
//

mov edi, 0

while (edi <> 6) {
  if (edi == 0) {
    ShowMessageW("[CN] 信息", "世界您好!");  
  } elseif (edi == 1) {
    ShowMessageW("[JP] メッセージ", "ハローワールド!");  
  } elseif (edi == 2) {
    ShowMessageW("[BG] Собщение", "Здравей Свят!");
  } elseif (edi == 3) {
    ShowMessageW("[RU] Сообщение", "Привет мир!");  
  } elseif (edi == 4) {
    ShowMessageW("[DE] Nachricht", "Hallo Welt!");      
  } else {  
    ShowMessageA('[EN] Message', 'Hello World!'); 
  }

  inc edi  
}

ExitProcess(0);


note: not really any includes have been added yet, so needed windows functions must be imported for the alpha

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1375] - posted: 2013-03-24 17:45:49
I am happy to announce the beta release of Ziron 2

Download

changelog since the alpha version:

Code:
24.03.2013: Ziron Assembler 2.0.0.1 Beta
  
  # Instruction "mov" now supports global variable types.
  # Added support for block types.
  # Static arrays are now declarable.
  # Implemented return functionality, e.g. return 5; return MyFunc(); etc...
  # Added high level assign for registers.
  # Some high level math operations for registers, ++, --, +=, -=, >>, <<, *=
  # High level cmp instruction via ==, <>, != etc, e.g. eax == 5;
  # Uses clause implemented.
  # High level base expression assignment.
  # Math operations for base expressions, global and local variables.
  # Fixed minus displacements for base expressions.
  # Support for block type variables. e.g. eax = myBlock.a.b.d;
  # Multi-line comments implemented. /* comment */
  # Added intrinsic directive #echo.
  # Added inline macro system.
  # Return macro added. e.g. $return eax;
  # Assigning strings to registers, assigns the pointer of a const.
  # Macro variables.
  # Macro vars can now accept mathematical expressions. e.g. $temp = (5 + 5) * 5 shl 3;
  # Macro vars are now able to accept tokens. e.g. $opcode = mov;
  # Added special macro variable $argc - results in the counted arguments to macro.
  # Added directive $if, e.g. $if $argc <> 2:
  # Now possible to re-assign macro variables.
  # Added intrinsic macro tokentype. e.g. tokentype(500) will return TOKEN_NUMBER.
  # Added prefix's lock, rep, repe, repz, repn, repne; USE with caution, NO opcode check added yet.
  # Added opcodes: scasb, scasw, scasd, movsb, movsw, movsd, stosb, stosw, stosd
  # Added support for mov reg, @var
  # Added mm, mm0-7 as alternative to st0-7
  # Added opcode movq.
  # MMX_SUPPORT is defined as true by default.
  # Added type keyword; e.g. type MYWORD = DWORD;
  # Added opcodes: aad, aam, aas, lodsb, lodsw, lodsd, fld, fstp, fild, fist, fiadd, ficom, 
        fidiv, fimul, fistp, fisub, fisttp, ficomp, fidivr, fisubr


This release has a total of 356 opcodes added.

there is still a few features of Ziron 1 i need to complete, but this hopefully should be shortly, also it only produces exe cui and gui apps right now, but this will be finished for official release, i hope to get started soon on finishing the 64-bit updates also.

Enjoy and please let me know of any bugs etc

-Colin

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1376] - posted: 2013-03-27 22:46:10
After some important fixes and additions, Here is the second beta Download

Code:
27.03.2013: Ziron Assembler 2.0.0.2 Beta
  
  # Assigning variable or variable pointer to register; the register assumes the var-type.
  # Added as keyword for use with registers. e.g. edx as MyBlock;
  # Improved how single line comments are handled.
  # Added support for negative numbers and floats.
  # Improvements to the type* pointer handler.
  # Function declarations no longer require (). e.g. function myFunc: DWord;
  # Consts now accepts mathematical equations. e.g. const sum = (5 + 5) * 12;
  # Enum's are now supported.
  # A fix with size information held for blocks.
  # Added union keyword for use inside of a block.
  # Possible to direct call function to local and global variables.
  # Fixed a mistake regarding locals.
  # Fixed mov op, @localvar and push @localvar
  # Fixed lea not accepting some base expressions with size override.
  # Consts will correctly accept ansi and wide strings.
  # Mov will now accept first op global var and second op register.
  # Added intrinsic ord. e.g. al = ord('a');
  # Implemented opcodes movsx and movzx
  # Return now will correctly return in register best fit. e.g. 4 = EAX, 2 = AX; etc.
  # Assigning function to register will assign same size register. e.g. cl = myFunc(); = cl = al;
  # Fixed push local char pointer onto stack.
  # Small update to mov instructions: eax = al = movzx eax, al and movzx/movsx eax, ecx = mov eax, ecx etc.
  # Implemented opcodes int3 and int imm8


Ziron 2 is almost to Ziron 1 standard, plus extra smile

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1378] - posted: 2013-04-05 21:34:02
This may very well be the final beta before an official release, I'm hoping now it should be on the same level or higher than Ziron 1


Download Ziron 2 beta 3


changelog for this beta:

Code:
05.03.2013: Ziron Assembler 2.0.0.3 Beta

  # Mov now supports segments.
  # Segments can be assigned to in high level.
  # Implemented opcodes clc, cld, cli, sti, cmc, hlt
  # Internal optimisations for bit mode.
  # Improvement to many opcodes for 16 bit mode.
  # Improved memory operand handler.
  # Support for 16-bit addressing mode.
  # Instruction jmp/goto now supports immediate operand or imm:label/imm.
  # Optimisations to linker plugin.
  # Added exports keyword. e.g. exports func1, func2;
  # Linker plugin now supports exported functions.
  # Added linker output PE32_DLL
  # Function declarations name = nameA will now create idents for both names.
  # Push now accepts method/label pointers.
  # Support for compiled resource files via #resource 'file.res';
  # Added keyword entry.
  # Fixed bug regarding stack frame.
  # Linker can now output relocations.
  # Fixed a bug regarding global variables in some cases the data section was not written.
  # Possible to assign values directly to global variable.
  # Local variables can be assigned to globals.
  # Local vars and Memory operands can be assigned to each other. e.g. [eax] = [edx];
  # Added support for $elseif.
  # Functions now use internal dependancy reference to prevent un-used functions being written.
  # Fixed a bug making it possible to access out of scope identifiers.
  # Main code is now refered to as RTLMain.
  # Fixed a bug where in some cases the assembler will end up in a continuous loop.
  # Fixed a bug regarding /* multi-line comments */
  # Fixed passing local var pointers to macros.
  # Fixed several jump table entries for if statements.
  # Added "break if (...);" statement for loops.
  # Added a few more alternatives for compare symbols >= => <= etc.
  # Fixed alu instructions using type[reg], imm
  # Implemented opcodes xchg, imul
  # Added intrinsic macro sizeof. e.g. eax = sizeof 'This text';
  # Blocks now support functions which pass "this" as a parameter.
  # @[exp] is now supported, this included assumed. e.g. @edi.myData
  # Fixed macro vars causing error on multiple calls.
  # Now shows total lines and time taken for compile and linker time.
  # Designed a new icon.
  # Assumed register states are no longer lost on macro calls.
  # Inline now supports op style macros.


Please submit any queries directly to this thread for beta releases, and please let me know of which features are missing from Ziron 2 so i can implement them for the release smile

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1381] - posted: 2013-04-11 17:46:35
Due to some bugs i decided to release another beta before finalizing some things.


Download Ziron 2 beta 4


changelog for this beta:

Code:
11.04.2013: Ziron Assembler 2.0.0.4 Beta

  # Possible to declare method pointers. e.g. procedure* MyProc();
  # Able to assign function pointers to variables.
  # Callable global variables. via call instruction or method pointer.
  # Possible to declare and call functions without parentheses.
  # Pushing pointer to local var will no longer use eax.
  # Fixed function calls directly from local or global variable blocks.
  # Fixed scale issue with memory operands.
  # Fixed a bug regarding negative numbers.
  # Implemented directive repeat. e.g. $repeat 10: ...
  # Fixed a bug with macros defined with no args not able to accept args.
  # Possible to access macro arguments via $arg[n]
  # Fix to $argc directive.
  # Macros will now raise an error on invalid param count.
  # Macros now can accept uncounted args via ; e.g. inline procedure mac(;) { ...
  # Macros can now also have named + uncounted args via inline procedure mac($arg1, $arg2, ;) { ...
  # Fixed $elseif not checking arguments.
  # Added intrinsic macro tokentext. e.g. tokentext(eax) will result to 'eax'
  # Macro ord now supports registers. e.g. ord(eax) or ord(ax) results in 0
  # Added new var type "sysint" - sysint size depends on the bit mode from #set
  # Added general purpose register refs based on bit #set. gp_ax, gp_cx .. gp_di.
  # 32 bit registers are no longer exposed in 16 bit mode.
  # Fixed data length was wrong for array types.
  # Fixed bug when linker would pad file by 512 bytes when data section was already aligned.
  # Initialized arrays implemented. e.g DWord count[5] = [0,2,4,6,8];
  # Initialized data now supports ansi strings.
  # Data types can now be compared via $if dword == int32:
  # Added intrinsic macro casttype.
  # Added intrinsic $substr, takes 3 params, returns text, text, offset, length, e.g. $text = $substr('Ziron', 1, 3);
  # Added intrinsic $strindex, takes 2 params, returns int, e.g. $index = $strindex('Testing', 'ing');
  # Using #set frame off in 16 bit mode does nothing.
  # New defined type 'sysword' which will default to the architecture word size, 32-bit = dword, 64-bit = qword etc
  # Possible to typecast registers and variables using [type]data; e.g. myMacro( [char*]edx );
  # Type* and pointer are now seperate identifiers.
  # Added intrinsic macro's IsPtrType and IsSignedType.


Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1386] - posted: 2013-12-11 05:00:08
Ziron 2 has a current stable release available for the past several month, I, unfortunately have not had the time to continue adding features/updates, so I am making an official release of the current stable version until the coming months when I can continue development.


Download Ziron 2.0.0.5


The following changelog has not changed for 2 month, but updated for release:

Code:
11.12.2013: Ziron Assembler 2.0.0.5

  # Assembler now shows assembled file count.
  # Assembler will automatically create *file*.build.bat if one does not exist.
  # Added directive #tryinclude, this will not fail if file does not exist.


I hope to continue general development of Ziron 2 soon, meanwhile if any requests come in I will try to get them done ASAP.

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1387] - posted: 2013-12-16 04:08:33
Fixed many problems with the previous release, this should be a much better release candidate than the 2.0.0.5 smile


Download Ziron 2.0.0.6


changelog:

Code:
16.12.2013: Ziron Assembler 2.0.0.6

  # Fixed an issue with break unable to work inside of nested if statements.
  # Fixed block fields not being accessible.
  # reg as 0; is now accepted to nullify assumed type.
  # Fixed moving word or byte data to var.
  # rtl dw2str fixed, and rtl _console_write_dword added, print now supports dword cast.
  # Fixed function register size on returning to global variables.
  # Fixed, sometimes assembler not showing error for unsupported instruction usage.
  # Fixes to ALU instructions usage #inst #var, #val
  # Fixed that sometimes byte size immediate values were encoded in 4 bytes.
  # Push will now emit smaller code for immediate values that will fit 1 byte.
  # Fixed sizeof not working correctly with data types.
  # Fixed comparing 2 immediate values for creating inifite loops.
  # Assume "as" can be used in assignment. e.g. edx = [ebx] as MYBLOCK;
  # Re-added rtl ch.zir
  # Repeat will now act as inifite loop by using a semicolon instead of a control op. e.g. repeat { /* code */ };
  # Declaration of multiple variables by type using comma is possible. e.g. Dword a,b=1,c;
  # Fixed ALU instructions usage #inst [#mem], #reg and #inst #reg, [#mem]
  # Fixed a problem with memory operand's scale always being a minimum of 4.
  # Added exitif; exitif (...); or exitif if (...);


please let me know of any other bugs or issues.

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Admin
Site Admin

avatar

(send private message)

Posts: 933
Topics: 55

Location:
OverHertz Studio
[1388] - posted: 2014-01-05 23:03:20
Hello, hope everyone has had a nice new year.


Download Ziron 2.0.0.7


changelog:

Code:
05.01.2014: Ziron Assembler 2.0.0.7

  # Fixed macro vars containing strings unable to be re-assigned.
  # Fixed ALU instruction usage #inst [#reg], #imm16
  # Fixed cpuid not being accessible.
  # Added MSCOFF support to linker plugin. (experimental)
  # Plugin interface: consts, vars and functions all have a field symbolindex, 0 is reserved and can be used to check if they have no entry.
  # Added emacros, see zirutils.zir for emacro "using" as example.
  # Fixed issue with macro $arg[$n] when out of bounds with negative numbers.


a very nice feature addition is extended macros "emacro", an example is in the zirutils.zir include file:

Code:
emacro using(;) {
  $if $STATE == MACRO_START:
    $c = 0;  
    
    $repeat $argc:
      push $arg[$c];
    
      $c = $c + 1;
    $end;
  $elseif $STATE == MACRO_END:
    $repeat $argc:  
      $c = $c - 1;    
      
      pop $arg[$c];      
    $end;
  $end;    
}


emacros currently support 2 states, MACRO_START and MACRO_END, the macro is called on both states and will allow you to do as the above, a simple usage like so:

Code:
program PE32_CUI 'test';

#include 'win_def.zir';
#include 'console.zir';
#include 'zirutils.zir';

edx = 200;
ecx = 200;

using(ecx,edx) {
  ecx = 500;
  edx = 500;
}

//ecx and edx should be 200....
print([dword]ecx, '\r\n', [dword]edx, '\r\n');

wait_key();
ExitProcess(0);


I will probably make a tutorial on macros when i get time smile

please let me know of any other bugs or issues.

Download Ziron
Get free hosting for Ziron related fan-sites and Ziron projects, contact me in private message.
Pages: 1 2 3 4
create new reply


Quick reply:

Message:



Currently Active Users:
There are currently 2 user(s) online. 0 member(s) and 2 guest(s)
Most users ever online was 1046, January 28, 2022, 2:08 pm.


Statistics:
Threads: 225 | Posts: 1848 | Members: 51 | Active Members: 51
Welcome to our newest member, yecate
const Copyright = '2011-2024 © OverHertz Ltd. All rights reserved.';
Web development by OverHertz Ltd