Repository navigation
Expand file tree
/
Copy pathchangelog.txt
More file actions
247 lines (204 loc) · 14.2 KB
/
Copy pathchangelog.txt
File metadata and controls
247 lines (204 loc) · 14.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
17.02.2026
bugfix: - Corrected 64 bit problem in trunc function and others that used same schema
(round, near, down, ceil, mod and fracc).
16.10.2024
bugfix: - Removed "ptr" obliteration in TrimString macro
11.09.2024
added: - round function (x86-32/64,FPU) -> round to current FPU setting (near by default)
added: - down function (x86-32/64,FPU) -> round to smaller integer
added: - rnear function (x86-32/64,FPU) -> round to near integer
18.08.2024
added: - fracc function (x86-32/64,FPU)
30.01.2024
added: - ceil function (x86-32/64,FPU)
bugfix: - missing inclusion of FlowControl.inc in math.inc
04.04.2023 Version 2.0.3
added: - @while/@break/@endw control flow
- @dothis/@breakthis/@whilethis control flow
11.10.2022
added: - Pseudo push/pop XMM registers
05.09.2022
added: - ForLpD / Next : modified ascendent integer loop
- Helper macros to translate 32 to 64 bits
30.12.2021
added: - Pseudo pushad/popad registers (freg_pushad/freg_popad)
- Pseudo peek (for registers) and peekv (for variables)
bugfix: - typos in Loops
20.12.2021
change: - Loops updated for different bitness, variable size and registers
19.12.2021
added: - IfElse test for ML64
06.12.2021
added: - x64_console test for ML64
moved: - ConstDiv.inc, macros.inc and strings to new directory "accs"
added: - macros64G.inc to "accs"
03.12.2021
added: - updated @if/@else/@endif macros from Mabdelouahab.
- example mabm2.asm to use this macros.
- r4IsNotNaN : macro to check (similar to r4IsValid but specific for NaN)
- added r8Is_NotNaN and r4Is_NotNaN for IfElse evaluations.
21.05.2021
added: - r8IsNotNaN : macro to check (similar to r8IsValid but specific for NaN)
09.04.2021
added: - Pseudo push/pop variables (freg_pushv/freg_popv)
- freg_correction for unbalanced number of push or pop
29.03.2021
added: - Pseudo push/pop registers (freg_push/freg_pop)
29.12.2020
added: - ForLp / Next : Ascendent integer loop
- ForLpN / NextN : Descendent integer loop
- ForLpR / NextR : REAL8 loop
16.10.2020
added: - fSlvW : macro wrapper of fSlv to manage some compound operators(*=, /=, +=, -=, ++, --)
02.10.2020
bugfix: - corrected notification of local stack space requierement by fSlvTLS().
25.10.2017 Version 2.0.2
added: - log2d(x) (SSE2, REAL8 only, x86 only): approximation of log2(x), relativ error less than 2.5E-15.
bugfix: - ScanForFlt(): invalid hexadecimal initializer were accepted (invalid leading digit)
- Summation of two identical bracket expressions did cause an unwarranted error message.
- broken asin-function fixed.
- fTest(): third parameter (exponent difference) were mistakenly loaded into FPU, which cause FPU-stack imbalance
17.04.2014 Version 2.0.1
improvement: - @GetArgByIndex(), FOR loop breaks on match
- fSlvVolatileGPReg/fSlvVolatileXmmRegs: push/pop operation added
- typecasts for XMM registers are allowed: REAL4/8 ptr XmmReg
added: - fpuSetRoundingMode- and fpuSetControlWord macro
- global flag FSF_NO_INT_CONSTS
- internal: @IsTypedXmmReg()
change: - the default real-precision of the @fSlvI() and @fSlvI64 macros
has changed from REAL4 to REAL8.
- internal: fcmpx does enumerate tokens
- @IsReal/IntType: can also handle typecasted XMM registers (REAL4 and REAL8).
Also, a special implementation for jWasm has add to avoid the usage of the OPATTR-operator, which is
currently not compatible to MASM (will be removed if the bug in jWasm is fixed).
- SSE2 back end: integer constants must fit in 32 bits. (because they are assigned to equates "=" for conversion: int->real)
- some MOVLPD instructions replaced by MOVSD
bugfix: - @fSlvTSA -> global int type used for local real type
- integer back end: for reg0-mem32/64 -> MOV was used instead SUB
- SSE2 back end: faEQ() fixed
- sgn()-function: ORPS used instead ORPD
- for compare operations, XMM register arguments were not marked as non-volatile.
- internal: fcmpx: attribute list was processed after FSEN_INIT.
10.02.2013 Version 2.0.0
added: - Back end macro-interface introduced.
The different instruction sets (x86-integer,FPU,SSE2/FPU) are implemented in so called back ends.
A back end consist of macros that are called by the fSlv-macros when a specific operation
is requested. The main advatage is that the back ends does not need to interpret the parser's result.
Also, the back end can be dynamically changed.
- x64-support (JWASM only)
The macros assumes:
- to be called from .code-section
- that the stack is align to 16 and the shadow space (MS-FASTCALL) is allocated (32 Bytes)
- to be allowed to use the shadowspace
The macros take care of the FASTCALL calling convention (Microsoft) and does only use
the XMM registers XMM0-XMM5. However, the used registers can be changed using
the fSlvVolatileXmmRegs-macro.
As for x32, no GPR is modified (unless fSlvVolatileGPReg is used to mark them as volatile).
- SSE2 support
The SSE2 instruction set can be enabled by setting the global flag FSF_USE_SSE2
or by using the fSlvSelectBackEnd-macro. For x64, SSE2 is used by default.
The SSE2-back end use the FPU, if there is no SSE2 implentation for the requested operation.
Currently this applies to exponential, logarithm and trigonometric functions.
- the function-descriptor-macro and it's code producing counterpart has been extended
to fit the new requirements.
- Static library (x32): \macros\SmplMath\lib\x32\SmplMath.lib
- Static library (x64): \macros\SmplMath\lib\x64\SmplMath.lib
- root2(x,a,b) : x^(a/b), a&b = integers
- fTest-macro: test for zero
- internal: fpu_is_integer-function
- rsqrtss(x) (SSE2, REAL4 only): 1/sqrt(x), error less equal 1.5*2^-12
- rcpss(x) (SSE2, REAL4 only): 1/x, error less equal 1.5*2^-12
- expd(x) (SSE2/REAL8 only): approximation of e^x, error less than 4.0E-14
- typedef: BOOLEAN_BYTE
- macro: - fSlvVolatileXmmRegs
- fSlvLoadBackEnd
- fSlvSelectBackEnd
- fSlvVolatileGPReg
- fSlvI64()
- new global flags: FSF_USE_FPU, FSF_USE_SSE2
- macro: fSlvRegRecursiveExpr: allows to register recursive expressions
- floating point values can be specified in hexadecimal notation. e.g: 3F800000r
- include file: expressions.inc : contains some predefined expressions. (not included by math.inc)
improvement: - acos, asin, root, log() and ln() revised
- @IsInteger/real support edx::eax
- x64 support for all existing functions
- SSE2 implementations for the functions:
sqrt,abs,rad,deg,limit,min,max,sgn
- predefined expressions: - arguments begining with # are treated as expressions that can be solved by MASM's preprocessor.
- common macro function can be called. The macro name must have
the "?$"-prefix. e.g.: ?$macroFnc(...). Because the macros are called
in context of the parser, code generation is forbidden.
change: - the exponentation operator "^" has been changed (fpu_st1_pow_st0):
For negative bases, the function checks if the exponent is an integer value.
In this case the result's signe is changed, if the exponent is odd.
The result for negativ bases in combination with a non-integer exponents is allways positiv.
Also the function respons to some special values: 0^0=1, x^0=1, 0^x=0, 0^(-x)=div. by zero
- the macros support multiple, comma seperated expressions.
- the __MODULE__-constant is gone out of use.
- constant integer expressions (+-*/^) may be calculated while assembling if the local integer size is 4
and the result is also an integer.
- constant rvalues for division may be replaced by a multiplication with the reciprocal (implemented in the back ends)
- the macros R4/8/10 are renamed for x64: _R4/8/10. For x32, corresponding EQU's added.
- function-descriptor: FNCD_USES_SSE has been removed!
- The Paser does handle assignments "="
- @ScanForFlt(): - GOTO-constructs replaced by corresponding IF/ENDIF constructs.
The resaon is that MASM (all versions) somtimes get "confused" with nested macros that
use the GOTO directives. A typical error is A2002, "... cannot have more than one ELSE clause per IF block".
- the macro now support FP values written in hexadecimal notation (with R-suffix).
bugfix: - fSlv rejects variables named "s"
- @TrimStr() did not work correct for arguments with commas.
- function calls with one (non-constant) argument fails due a bug in fslv_call_fnc().
This bug was hidden/bypassed by the faulty implimentation of @TrimStr().
- regx_oprt_reg0: fxch before exponentation
- The parser may emit missplaced "push" tokens.
- negativ signs may be discarded for constant expressions like: 1-1.0 -> 1+1.0
misc.: - GOTO has been removed from all macros because it simply cause to strange errors (for all version of MASM)
04.09.2012 Version 1.1.0 (unpublished)
18.03.2012 Version 1.0.13
improvement: faEQ(a,b,f) compare simplified: return((abs(a-b) <= abs(a*f))?1:0)
20.02.2012 Version 1.0.12
bugfix: lst_create-macro: invalid parameter usage
20.01.2012 Version 1.0.11
added: - atan2 function
- pop-Attribute
- free-Attribute
improvement: FPU registers can be used as destination operand
17.01.2012 Version 1.0.10
bugfix: r8IsValid() fixed
misc: examples modified
04.01.2012 Version 1.0.9
bugfix: BYTE-registers (AL,AH,CL,...) were treated as unsgined values.
added: - @fSlvTSA()-macro: preliminary version, not documented
- new include file: macro.inc , preliminary version, not documented
13.12.2011 Version 1.0.8
bugfix: - GPRs fails for functions with one argument (->fslv_call_fnc)
- The Smplmath-includes can't be used for modular programing
improvement: If __MODULE__ is defined, the SmplMath-includes does not create code or
constants. Instead EXTERNDEFs and PROTOs are used.This is needed for
modular programing. Example:
...
__MODULE__ TEXTEQU <>
include \macros\SmplMath\math.inc
...
21.11.2011 Version 1.0.7
bugfix: Because of a misconception of the @ScanForFlt()-macro,
expression could be parsed incorrectly (->tmt_check_for_single_argument)
This was also a problem in some other macros.
improvement: @ScanForFlt() -> "blanks"-keyword added
20.11.2011 Version 1.0.6
added: R4/8/10 macros
27.10.2011: Version 1.0.5
> bug fix: in fSlvSetPrecision
> some corrections in documentaion
> unicode.inc: - all macros redesigned
- CWSTR renamed to WCSTR
- cwsz$ renamed to wcsz$
> eaxmples modified
12.09.2011: Version 1.0.4
the mod-function was not documented and noted in math_functions.inc
27.08.2011: Version 1.0.3
added: min/max functions
07.08.2011: Version 1.0.2
improvement: ldl-macro now supports [TEXT]EQU's
05.08.2011: Version 1.0.1
bug fix: expressions in braces may parsed incorrectly