diff --git a/tests/test/tminmax.pp b/tests/test/minmax.inc similarity index 99% rename from tests/test/tminmax.pp rename to tests/test/minmax.inc index 53f9b95fee..4bc28756b6 100644 --- a/tests/test/tminmax.pp +++ b/tests/test/minmax.inc @@ -1,5 +1,3 @@ -{ %opt=-Oonofastmath } { with fast math, the operands of min/max might be swapped and this breaks the tests using NaN } - {$mode objfpc} uses Math; diff --git a/tests/test/tminmax1.pp b/tests/test/tminmax1.pp new file mode 100644 index 0000000000..18ccbbb70a --- /dev/null +++ b/tests/test/tminmax1.pp @@ -0,0 +1,2 @@ +{ %opt=-O- -O1 } { ensure we test code generation without constant propagation } +{$I minmax.inc } \ No newline at end of file diff --git a/tests/test/tminmax2.pp b/tests/test/tminmax2.pp new file mode 100644 index 0000000000..6e4e131d80 --- /dev/null +++ b/tests/test/tminmax2.pp @@ -0,0 +1,3 @@ +{ %opt=-Oonofastmath -O3 } { with fast math, the operands of min/max might be swapped and this breaks the tests using NaN, + but test constant propagation and thus simplification } +{$I minmax.inc } \ No newline at end of file