summaryrefslogtreecommitdiffstats
path: root/chksum.c
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2022-10-15 00:13:58 -0700
committerKaz Kylheku <kaz@kylheku.com>2022-10-15 00:13:58 -0700
commitdb49aeca0b8cdf6695c3fc0754274398da0234d5 (patch)
tree126a5c227ec88b0649730aa5e4466279d7fb52dc /chksum.c
parent227d89b5ec4b967c87cd24d7074ec71e8aad0448 (diff)
downloadtxr-db49aeca0b8cdf6695c3fc0754274398da0234d5.tar.gz
txr-db49aeca0b8cdf6695c3fc0754274398da0234d5.tar.bz2
txr-db49aeca0b8cdf6695c3fc0754274398da0234d5.zip
args: don't use alloca for const size cases.
* args.h (args_decl_list): This macro now handles only constant values of N. It declares an anonyous container struct type which juxtaposes the struc args header with exactly N values. This is simply defined as a local variable without alloca. (args_decl_constsize): Like args_decl, but requiring a constant N; implemented via args_decl_list. (args_decl_list_dyn): New name for the old args_decl_list which calls alloca. No places in the code depend on this at all, except the definition of args_decl. (args_decl): Retargeted to args_decl_list_dyn. There is some inconsistency in the macro naming in that args_decl_constsize depends on args_decl_list, and args_decl depends on arg_decl_list_dyn. This was done to minimize diffs. Most direct uses of args_decl_list have a constant size, but a large number of args_decl uses do not have a constant size. * eval.c (op_catch): Use args_decl_constsize. * ffi.c (ffi_struct_in, ffi_struct_get, union_out): Likewise. * ftw.c (ftw_callback): Likewise. * lib.c (funcall, funcall1, funcall2, funcall3, funcall4, uniq, relate): Likewise. * socket.c (sockaddr_in_unpack, sockaddr_in6_unpack, sockaddr_un_unpack): Likewise. * stream.c (formatv): Likewise. * struct.c (struct_from_plist, struct_from_args, make_struct_lit): Likewise. * sysif.c (termios_unpack): Likewise. * time.c (broken_time_struct): Likewise.
Diffstat (limited to 'chksum.c')
0 files changed, 0 insertions, 0 deletions