authorgravatar for 111569638+0Ahmed-0@users.noreply.github.comAhmed <111569638+0Ahmed-0@users.noreply.github.com> 2024-03-13 22:30:48+00:00
committergravatar for git@vexu.euVeikka Tuominen <git@vexu.eu> 2024-03-14 19:43:24+02:00
log5c8eda36d6de6e9858a7527af3a1e9851969189e
treefa7ac5db71c3e2e421489ec02dda995f88faf00c
parent400145ee3bb0740cc274a75b7c612d799811b5fe

chore: Fix some typos


10 files changed, 14 insertions(+), 14 deletions(-)

lib/compiler_rt/addf3.zig+1-1
...@@ -114,7 +114,7 @@ pub inline fn addf3(comptime T: type, a: T, b: T) T {...@@ -114,7 +114,7 @@ pub inline fn addf3(comptime T: type, a: T, b: T) T {
114 // If a == -b, return +zero.114 // If a == -b, return +zero.
115 if (aSignificand == 0) return @bitCast(@as(Z, 0));115 if (aSignificand == 0) return @bitCast(@as(Z, 0));
116116
117 // If partial cancellation occured, we need to left-shift the result117 // If partial cancellation occurred, we need to left-shift the result
118 // and adjust the exponent:118 // and adjust the exponent:
119 if (aSignificand < integerBit << 3) {119 if (aSignificand < integerBit << 3) {
120 const shift = @as(i32, @intCast(@clz(aSignificand))) - @as(i32, @intCast(@clz(integerBit << 3)));120 const shift = @as(i32, @intCast(@clz(aSignificand))) - @as(i32, @intCast(@clz(integerBit << 3)));
lib/compiler_rt/addo.zig+1-1
...@@ -25,7 +25,7 @@ inline fn addoXi4_generic(comptime ST: type, a: ST, b: ST, overflow: *c_int) ST...@@ -25,7 +25,7 @@ inline fn addoXi4_generic(comptime ST: type, a: ST, b: ST, overflow: *c_int) ST
25 // and the sign of a+b+carry is the same as a (or equivalently b).25 // and the sign of a+b+carry is the same as a (or equivalently b).
26 // Slower routine: res = ~(a ^ b) & ((sum ^ a)26 // Slower routine: res = ~(a ^ b) & ((sum ^ a)
27 // Faster routine: res = (sum ^ a) & (sum ^ b)27 // Faster routine: res = (sum ^ a) & (sum ^ b)
28 // Overflow occured, iff (res < 0)28 // Overflow occurred, iff (res < 0)
29 if (((sum ^ a) & (sum ^ b)) < 0)29 if (((sum ^ a) & (sum ^ b)) < 0)
30 overflow.* = 1;30 overflow.* = 1;
31 return sum;31 return sum;
lib/compiler_rt/divtf3.zig+1-1
...@@ -140,7 +140,7 @@ inline fn div(a: f128, b: f128) f128 {...@@ -140,7 +140,7 @@ inline fn div(a: f128, b: f128) f128 {
140 var reciprocal: u128 = undefined;140 var reciprocal: u128 = undefined;
141141
142 // NOTE: This operation is equivalent to __multi3, which is not implemented142 // NOTE: This operation is equivalent to __multi3, which is not implemented
143 // in some architechure143 // in some architecture
144 var r64q63: u128 = undefined;144 var r64q63: u128 = undefined;
145 var r64q127: u128 = undefined;145 var r64q127: u128 = undefined;
146 var r64cH: u128 = undefined;146 var r64cH: u128 = undefined;
lib/compiler_rt/emutls.zig+2-2
...@@ -145,7 +145,7 @@ const ObjectArray = struct {...@@ -145,7 +145,7 @@ const ObjectArray = struct {
145 }145 }
146};146};
147147
148// Global stucture for Thread Storage.148// Global structure for Thread Storage.
149// It provides thread-safety for on-demand storage of Thread Objects.149// It provides thread-safety for on-demand storage of Thread Objects.
150const current_thread_storage = struct {150const current_thread_storage = struct {
151 var key: std.c.pthread_key_t = undefined;151 var key: std.c.pthread_key_t = undefined;
...@@ -358,7 +358,7 @@ test "__emutls_get_address with default_value" {...@@ -358,7 +358,7 @@ test "__emutls_get_address with default_value" {
358 try expect(y.* == 9012); // the modified storage persists358 try expect(y.* == 9012); // the modified storage persists
359}359}
360360
361test "test default_value with differents sizes" {361test "test default_value with different sizes" {
362 if (!builtin.link_libc or builtin.os.tag != .openbsd) return error.SkipZigTest;362 if (!builtin.link_libc or builtin.os.tag != .openbsd) return error.SkipZigTest;
363363
364 const testType = struct {364 const testType = struct {
lib/compiler_rt/fmod.zig+3-3
...@@ -58,7 +58,7 @@ pub fn __fmodx(a: f80, b: f80) callconv(.C) f80 {...@@ -58,7 +58,7 @@ pub fn __fmodx(a: f80, b: f80) callconv(.C) f80 {
58 // - fmodx(val, NaN)58 // - fmodx(val, NaN)
59 // - fmodx(inf, val)59 // - fmodx(inf, val)
60 // The sign on checked values does not matter.60 // The sign on checked values does not matter.
61 // Doing (a * b) / (a * b) procudes undefined results61 // Doing (a * b) / (a * b) produces undefined results
62 // because the three cases always produce undefined calculations:62 // because the three cases always produce undefined calculations:
63 // - 0 / 063 // - 0 / 0
64 // - val * NaN64 // - val * NaN
...@@ -163,7 +163,7 @@ pub fn fmodq(a: f128, b: f128) callconv(.C) f128 {...@@ -163,7 +163,7 @@ pub fn fmodq(a: f128, b: f128) callconv(.C) f128 {
163 // - fmodq(val, NaN)163 // - fmodq(val, NaN)
164 // - fmodq(inf, val)164 // - fmodq(inf, val)
165 // The sign on checked values does not matter.165 // The sign on checked values does not matter.
166 // Doing (a * b) / (a * b) procudes undefined results166 // Doing (a * b) / (a * b) produces undefined results
167 // because the three cases always produce undefined calculations:167 // because the three cases always produce undefined calculations:
168 // - 0 / 0168 // - 0 / 0
169 // - val * NaN169 // - val * NaN
...@@ -239,7 +239,7 @@ pub fn fmodq(a: f128, b: f128) callconv(.C) f128 {...@@ -239,7 +239,7 @@ pub fn fmodq(a: f128, b: f128) callconv(.C) f128 {
239 aPtr_u64[high_index] = highA;239 aPtr_u64[high_index] = highA;
240 aPtr_u64[low_index] = lowA;240 aPtr_u64[low_index] = lowA;
241241
242 // Combine the exponent with the sign, normalize if happend to be denormalized242 // Combine the exponent with the sign, normalize if happened to be denormalized
243 if (expA <= 0) {243 if (expA <= 0) {
244 aPtr_u16[exp_and_sign_index] = @as(u16, @truncate(@as(u32, @bitCast((expA +% 120))))) | signA;244 aPtr_u16[exp_and_sign_index] = @as(u16, @truncate(@as(u32, @bitCast((expA +% 120))))) | signA;
245 amod *= 0x1p-120;245 amod *= 0x1p-120;
lib/compiler_rt/mulf3_test.zig+1-1
...@@ -13,7 +13,7 @@ const __muldf3 = @import("muldf3.zig").__muldf3;...@@ -13,7 +13,7 @@ const __muldf3 = @import("muldf3.zig").__muldf3;
13const __mulsf3 = @import("mulsf3.zig").__mulsf3;13const __mulsf3 = @import("mulsf3.zig").__mulsf3;
1414
15// return true if equal15// return true if equal
16// use two 64-bit integers intead of one 128-bit integer16// use two 64-bit integers instead of one 128-bit integer
17// because 128-bit integer constant can't be assigned directly17// because 128-bit integer constant can't be assigned directly
18fn compareResultLD(result: f128, expectedHi: u64, expectedLo: u64) bool {18fn compareResultLD(result: f128, expectedHi: u64, expectedLo: u64) bool {
19 const rep: u128 = @bitCast(result);19 const rep: u128 = @bitCast(result);
lib/compiler_rt/rem_pio2_large.zig+2-2
...@@ -174,14 +174,14 @@ const PIo2 = [_]f64{...@@ -174,14 +174,14 @@ const PIo2 = [_]f64{
174/// z = (z-x[i])*2**24174/// z = (z-x[i])*2**24
175///175///
176///176///
177/// y[] ouput result in an array of double precision numbers.177/// y[] output result in an array of double precision numbers.
178/// The dimension of y[] is:178/// The dimension of y[] is:
179/// 24-bit precision 1179/// 24-bit precision 1
180/// 53-bit precision 2180/// 53-bit precision 2
181/// 64-bit precision 2181/// 64-bit precision 2
182/// 113-bit precision 3182/// 113-bit precision 3
183/// The actual value is the sum of them. Thus for 113-bit183/// The actual value is the sum of them. Thus for 113-bit
184/// precison, one may have to do something like:184/// precision, one may have to do something like:
185///185///
186/// long double t,w,r_head, r_tail;186/// long double t,w,r_head, r_tail;
187/// t = (long double)y[2] + (long double)y[1];187/// t = (long double)y[2] + (long double)y[1];
lib/compiler_rt/subo.zig+1-1
...@@ -34,7 +34,7 @@ inline fn suboXi4_generic(comptime ST: type, a: ST, b: ST, overflow: *c_int) ST...@@ -34,7 +34,7 @@ inline fn suboXi4_generic(comptime ST: type, a: ST, b: ST, overflow: *c_int) ST
34 // and the sign of a-b-carry is opposite of a (or equivalently same as b).34 // and the sign of a-b-carry is opposite of a (or equivalently same as b).
35 // Faster routine: res = (a ^ b) & (sum ^ a)35 // Faster routine: res = (a ^ b) & (sum ^ a)
36 // Slower routine: res = (sum^a) & ~(sum^b)36 // Slower routine: res = (sum^a) & ~(sum^b)
37 // Overflow occured, iff (res < 0)37 // Overflow occurred, iff (res < 0)
38 if (((a ^ b) & (sum ^ a)) < 0)38 if (((a ^ b) & (sum ^ a)) < 0)
39 overflow.* = 1;39 overflow.* = 1;
40 return sum;40 return sum;
test/standalone/stack_iterator/unwind.zig+1-1
...@@ -19,7 +19,7 @@ noinline fn frame3(expected: *[4]usize, unwound: *[4]usize) void {...@@ -19,7 +19,7 @@ noinline fn frame3(expected: *[4]usize, unwound: *[4]usize) void {
19}19}
2020
21noinline fn frame2(expected: *[4]usize, unwound: *[4]usize) void {21noinline fn frame2(expected: *[4]usize, unwound: *[4]usize) void {
22 // Excercise different __unwind_info / DWARF CFI encodings by forcing some registers to be restored22 // Exercise different __unwind_info / DWARF CFI encodings by forcing some registers to be restored
23 if (builtin.target.ofmt != .c) {23 if (builtin.target.ofmt != .c) {
24 switch (builtin.cpu.arch) {24 switch (builtin.cpu.arch) {
25 .x86 => {25 .x86 => {
tools/update_spirv_features.zig+1-1
...@@ -243,7 +243,7 @@ fn gather_extensions(allocator: Allocator, spirv_registry_root: []const u8) ![]c...@@ -243,7 +243,7 @@ fn gather_extensions(allocator: Allocator, spirv_registry_root: []const u8) ![]c
243 if (!std.mem.endsWith(u8, ext_entry.name, ".asciidoc"))243 if (!std.mem.endsWith(u8, ext_entry.name, ".asciidoc"))
244 continue;244 continue;
245245
246 // Unfortunately, some extension filenames are incorrect, so we need to look for the string in tne 'Name Strings' section.246 // Unfortunately, some extension filenames are incorrect, so we need to look for the string in the 'Name Strings' section.
247 // This has the following format:247 // This has the following format:
248 // ```248 // ```
249 // Name Strings249 // Name Strings