source:
vbox/trunk/src/libs/softfloat-3e/TestFloat-3e-patch.diff@
94484
Last change on this file since 94484 was 94484, checked in by , 3 years ago | |
---|---|
|
|
File size: 10.1 KB |
-
Makefile.kmk
diff -Nru TestFloat-3e-virgin/Makefile.kmk TestFloat-3e/Makefile.kmk
old new 1 # $Id: TestFloat-3e-patch.diff 94484 2022-04-06 00:28:10Z vboxsync $ 2 ## @file 3 # Sub-Makefile for TestFloat-3e. 4 # 5 6 # 7 # Copyright (C) 2022 Oracle Corporation 8 # 9 # This file is part of VirtualBox Open Source Edition (OSE), as 10 # available from http://www.virtualbox.org. This file is free software; 11 # you can redistribute it and/or modify it under the terms of the GNU 12 # General Public License (GPL) as published by the Free Software 13 # Foundation, in version 2 as it comes in the "COPYING" file of the 14 # VirtualBox OSE distribution. VirtualBox OSE is distributed in the 15 # hope that it will be useful, but WITHOUT ANY WARRANTY of any kind. 16 # 17 18 SUB_DEPTH = ../../.. 19 include $(KBUILD_PATH)/subheader.kmk 20 21 # 22 # Basis template for building test stuff. 23 # 24 TEMPLATE_VBoxTestFloat = Template for building SoftFloat-3e 25 TEMPLATE_VBoxTestFloat_EXTENDS = VBoxR3DllNonPedantic 26 TEMPLATE_VBoxTestFloat_SDKS = $(TEMPLATE_VBoxR3DllNonPedantic_SDKS) VBOX_SOFTFLOAT 27 TEMPLATE_VBoxTestFloat_DEFS = $(TEMPLATE_VBoxR3DllNonPedantic_DEFS) \ 28 FLOAT16 \ 29 FLOAT64 \ 30 EXTFLOAT80 \ 31 FLOAT128 \ 32 FLOAT_ROUND_ODD 33 ifn1of ($(KBUILD_TARGET), win) 34 TEMPLATE_VBoxTestFloat_DEFS.amd64 = $(TEMPLATE_VBoxR3DllNonPedantic_DEFS.amd64) LONG_DOUBLE_IS_EXTFLOAT80 35 endif 36 if1of ($(KBUILD_TARGET), win) 37 TEMPLATE_VBoxTestFloat_INCS.amd64 = ../softfloat-3e/build/Win-amd64-VCC $(TEMPLATE_VBoxR3DllNonPedantic_INCS.amd64) 38 else 39 TEMPLATE_VBoxTestFloat_INCS.amd64 = build/Linux-x86_64-GCC $(TEMPLATE_VBoxR3DllNonPedantic_INCS.amd64) 40 endif 41 TEMPLATE_VBoxTestFloat_INCS = $(TEMPLATE_VBoxR3DllNonPedantic_INCS) \ 42 source/subj-C \ 43 source 44 45 # -wd4068: test_a_ui32_z_f16.c(48): warning C4068: unknown pragma 'STDC' 46 # -wd4146: primitives.h(74): warning C4146: unary minus operator applied to unsigned type, result still unsigned 47 # -wd4715: genCases_f16.c(336) : warning C4715: 'f16Random': not all control paths return a value 48 TEMPLATE_VBoxTestFloat_CFLAGS.win = $(TEMPLATE_VBoxR3DllNonPedantic_CFLAGS) -wd4068 -wd4146 -wd4715 49 50 # 51 # For linking test executables. 52 # 53 TEMPLATE_VBoxTestFloatExe = Template for building SoftFloat-3e programs. 54 TEMPLATE_VBoxTestFloatExe_EXTENDS = VBoxTestFloat 55 TEMPLATE_VBoxTestFloatExe_INST = $(INST_TESTCASE) 56 TEMPLATE_VBoxTestFloatExe_LIBS = \ 57 $(VBox-TestFloat_1_TARGET) \ 58 $(TEMPLATE_VBoxTestFloat_LIBS) 59 60 # -wd4098: testfloat.c(438): warning C4098: 'subjFunction_az_extF80_rx': 'void' function returning a value 61 # -wd4102: testfloat.c(767): warning C4102: 'test_abz_f16': unreferenced label 62 # -wd4701: testfloat.c(1410) : warning C4701: potentially uninitialized local variable 'roundingMode' used 63 TEMPLATE_VBoxTestFloatExe_CFLAGS.win = $(TEMPLATE_VBoxTestFloat_CFLAGS.win) -wd4098 -wd4102 -wd4701 64 65 66 # 67 # Library. 68 # 69 LIBRARIES += VBox-TestFloat 70 VBox-TestFloat_TEMPLATE := VBoxTestFloat 71 VBox-TestFloat_INSTTYPE := none 72 VBox-TestFloat_SOURCES := \ 73 source/uint128_inline.c \ 74 source/uint128.c \ 75 source/fail.c \ 76 source/functions_common.c \ 77 source/functionInfos.c \ 78 source/standardFunctionInfos.c \ 79 source/random.c \ 80 source/genCases_common.c \ 81 source/genCases_writeTestsTotal.c \ 82 source/verCases_inline.c \ 83 source/verCases_common.c \ 84 source/verCases_writeFunctionName.c \ 85 source/readHex.c \ 86 source/writeHex.c \ 87 source/writeCase_a_ui32.c \ 88 source/writeCase_a_ui64.c \ 89 source/writeCase_a_f16.c \ 90 source/writeCase_ab_f16.c \ 91 source/writeCase_abc_f16.c \ 92 source/writeCase_a_f32.c \ 93 source/writeCase_ab_f32.c \ 94 source/writeCase_abc_f32.c \ 95 source/writeCase_a_f64.c \ 96 source/writeCase_ab_f64.c \ 97 source/writeCase_abc_f64.c \ 98 source/writeCase_a_extF80M.c \ 99 source/writeCase_ab_extF80M.c \ 100 source/writeCase_a_f128M.c \ 101 source/writeCase_ab_f128M.c \ 102 source/writeCase_abc_f128M.c \ 103 source/writeCase_z_bool.c \ 104 source/writeCase_z_ui32.c \ 105 source/writeCase_z_ui64.c \ 106 source/writeCase_z_f16.c \ 107 source/writeCase_z_f32.c \ 108 source/writeCase_z_f64.c \ 109 source/writeCase_z_extF80M.c \ 110 source/writeCase_z_f128M.c \ 111 source/testLoops_common.c \ 112 \ 113 source/test_a_ui32_z_f16.c \ 114 source/test_a_ui32_z_f32.c \ 115 source/test_a_ui32_z_f64.c \ 116 source/test_a_ui32_z_extF80.c \ 117 source/test_a_ui32_z_f128.c \ 118 source/test_a_ui64_z_f16.c \ 119 source/test_a_ui64_z_f32.c \ 120 source/test_a_ui64_z_f64.c \ 121 source/test_a_ui64_z_extF80.c \ 122 source/test_a_ui64_z_f128.c \ 123 source/test_a_i32_z_f16.c \ 124 source/test_a_i32_z_f32.c \ 125 source/test_a_i32_z_f64.c \ 126 source/test_a_i32_z_extF80.c \ 127 source/test_a_i32_z_f128.c \ 128 source/test_a_i64_z_f16.c \ 129 source/test_a_i64_z_f32.c \ 130 source/test_a_i64_z_f64.c \ 131 source/test_a_i64_z_extF80.c \ 132 source/test_a_i64_z_f128.c \ 133 source/test_a_f16_z_ui32_rx.c \ 134 source/test_a_f16_z_ui64_rx.c \ 135 source/test_a_f16_z_i32_rx.c \ 136 source/test_a_f16_z_i64_rx.c \ 137 source/test_a_f16_z_ui32_x.c \ 138 source/test_a_f16_z_ui64_x.c \ 139 source/test_a_f16_z_i32_x.c \ 140 source/test_a_f16_z_i64_x.c \ 141 source/test_a_f16_z_f32.c \ 142 source/test_a_f16_z_f64.c \ 143 source/test_a_f16_z_extF80.c \ 144 source/test_a_f16_z_f128.c \ 145 source/test_az_f16.c \ 146 source/test_az_f16_rx.c \ 147 source/test_abz_f16.c \ 148 source/test_abcz_f16.c \ 149 source/test_ab_f16_z_bool.c \ 150 source/test_a_f32_z_ui32_rx.c \ 151 source/test_a_f32_z_ui64_rx.c \ 152 source/test_a_f32_z_i32_rx.c \ 153 source/test_a_f32_z_i64_rx.c \ 154 source/test_a_f32_z_ui32_x.c \ 155 source/test_a_f32_z_ui64_x.c \ 156 source/test_a_f32_z_i32_x.c \ 157 source/test_a_f32_z_i64_x.c \ 158 source/test_a_f32_z_f16.c \ 159 source/test_a_f32_z_f64.c \ 160 source/test_a_f32_z_extF80.c \ 161 source/test_a_f32_z_f128.c \ 162 source/test_az_f32.c \ 163 source/test_az_f32_rx.c \ 164 source/test_abz_f32.c \ 165 source/test_abcz_f32.c \ 166 source/test_ab_f32_z_bool.c \ 167 source/test_a_f64_z_ui32_rx.c \ 168 source/test_a_f64_z_ui64_rx.c \ 169 source/test_a_f64_z_i32_rx.c \ 170 source/test_a_f64_z_i64_rx.c \ 171 source/test_a_f64_z_ui32_x.c \ 172 source/test_a_f64_z_ui64_x.c \ 173 source/test_a_f64_z_i32_x.c \ 174 source/test_a_f64_z_i64_x.c \ 175 source/test_a_f64_z_f16.c \ 176 source/test_a_f64_z_f32.c \ 177 source/test_a_f64_z_extF80.c \ 178 source/test_a_f64_z_f128.c \ 179 source/test_az_f64.c \ 180 source/test_az_f64_rx.c \ 181 source/test_abz_f64.c \ 182 source/test_abcz_f64.c \ 183 source/test_ab_f64_z_bool.c \ 184 source/test_a_extF80_z_ui32_rx.c \ 185 source/test_a_extF80_z_ui64_rx.c \ 186 source/test_a_extF80_z_i32_rx.c \ 187 source/test_a_extF80_z_i64_rx.c \ 188 source/test_a_extF80_z_ui32_x.c \ 189 source/test_a_extF80_z_ui64_x.c \ 190 source/test_a_extF80_z_i32_x.c \ 191 source/test_a_extF80_z_i64_x.c \ 192 source/test_a_extF80_z_f16.c \ 193 source/test_a_extF80_z_f32.c \ 194 source/test_a_extF80_z_f64.c \ 195 source/test_a_extF80_z_f128.c \ 196 source/test_az_extF80.c \ 197 source/test_az_extF80_rx.c \ 198 source/test_abz_extF80.c \ 199 source/test_ab_extF80_z_bool.c \ 200 source/test_a_f128_z_ui32_rx.c \ 201 source/test_a_f128_z_ui64_rx.c \ 202 source/test_a_f128_z_i32_rx.c \ 203 source/test_a_f128_z_i64_rx.c \ 204 source/test_a_f128_z_ui32_x.c \ 205 source/test_a_f128_z_ui64_x.c \ 206 source/test_a_f128_z_i32_x.c \ 207 source/test_a_f128_z_i64_x.c \ 208 source/test_a_f128_z_f16.c \ 209 source/test_a_f128_z_f32.c \ 210 source/test_a_f128_z_f64.c \ 211 source/test_a_f128_z_extF80.c \ 212 source/test_az_f128.c \ 213 source/test_az_f128_rx.c \ 214 source/test_abz_f128.c \ 215 source/test_abcz_f128.c \ 216 source/test_ab_f128_z_bool.c \ 217 \ 218 source/genCases_ui32.c \ 219 source/genCases_ui64.c \ 220 source/genCases_i32.c \ 221 source/genCases_i64.c \ 222 source/genCases_f16.c \ 223 source/genCases_f32.c \ 224 source/genCases_f64.c \ 225 source/genCases_extF80.c \ 226 source/genCases_f128.c 227 228 229 PROGRAMS += tstTestFloat 230 tstTestFloat_TEMPLATE = VBoxTestFloatExe 231 tstTestFloat_SOURCES = \ 232 source/testfloat.c \ 233 source/subjfloat_functions.c \ 234 source/subj-C/subjfloat.c 235 236 PROGRAMS += tstTestFloatVer 237 tstTestFloatVer_TEMPLATE = VBoxTestFloatExe 238 tstTestFloatVer_SOURCES = \ 239 source/testfloat_ver.c \ 240 source/verLoops.c 241 242 PROGRAMS += tstTestFloatGen 243 tstTestFloatGen_TEMPLATE = VBoxTestFloatExe 244 tstTestFloatGen_SOURCES = \ 245 source/testfloat_gen.c \ 246 source/genLoops.c 247 248 PROGRAMS += tstTestFloatTime 249 tstTestFloatTime_TEMPLATE = VBoxTestFloatExe 250 tstTestFloatTime_SOURCES = \ 251 source/timesoftfloat.c 252 tstTestFloatTime_CFLAGS.win = -wd4459 # timesoftfloat.c(4201): warning C4459: declaration of 'exact' hides global declaration 253 254 PROGRAMS += tstTestFloat2 255 tstTestFloat2_TEMPLATE = VBoxTestFloatExe 256 tstTestFloat2_SOURCES = \ 257 source/testsoftfloat.c \ 258 source/slowfloat.c 259 260 include $(FILE_KBUILD_SUB_FOOTER) 261 262 -
source/testfloat.c
diff -Nru TestFloat-3e-virgin/source/testfloat.c TestFloat-3e/source/testfloat.c
old new 1353 1353 bool standardFunctionHasFixedRounding; 1354 1354 int roundingCode; 1355 1355 bool exact; 1356 uint_fast8_t roundingPrecision, roundingMode ;1356 uint_fast8_t roundingPrecision, roundingMode = 0; 1357 1357 1358 1358 functionCode = standardFunctionInfoPtr->functionCode; 1359 1359 functionAttribs = functionInfos[functionCode].attribs; -
source/testsoftfloat.c
diff -Nru TestFloat-3e-virgin/source/testsoftfloat.c TestFloat-3e/source/testsoftfloat.c
old new 793 793 int functionAttribs; 794 794 uint_fast8_t roundingPrecision; 795 795 int roundingCode; 796 uint_fast8_t roundingMode ;796 uint_fast8_t roundingMode = 0; 797 797 int exactCode; 798 798 bool exact; 799 799 int tininessCode; -
source/timesoftfloat.c
diff -Nru TestFloat-3e-virgin/source/timesoftfloat.c TestFloat-3e/source/timesoftfloat.c
old new 4794 4794 ) 4795 4795 { 4796 4796 int functionAttribs, exactCode; 4797 uint_fast8_t roundingMode , tininessMode;4797 uint_fast8_t roundingMode = softfloat_round_near_even, tininessMode; 4798 4798 4799 4799 functionNamePtr = functionInfos[functionCode].namePtr; 4800 4800 functionAttribs = functionInfos[functionCode].attribs;
Note:
See TracBrowser
for help on using the repository browser.