2
3
4
9#include <ae2f/c90/StdInt.h>
10#include "../vec.auto.h"
25#define SCALE_HEADER_SIZE
26 ((size_t)(sizeof(x_scale) + sizeof(size_t)))
28#define get_scale_header_from_vec(h_alloc) ((size_t* ae2f_restrict)((h_alloc)->m_p))
31#define get_last_scale_from_vec(h_alloc)
34#define get_buf_from_scale(h_alloc, c_scale)
36 ? (void* ae2f_restrict)(((uintptr_t)(h_alloc)->m_p) + ((uintptr_t)(c_scale).m_buf))
39#define get_buf_from_scale2(buf_T, h_alloc, c_scale)
42#define get_nxt_from_scale(h_alloc, c_scale)
43 (x_scale* ae2f_restrict)(((uintptr_t)(h_alloc)->m_p) + ((uintptr_t)(c_scale).m_nxt))
45#define get_prv_from_scale(h_alloc, c_scale)
46 (x_scale* ae2f_restrict)(((uintptr_t)(h_alloc)->m_p) + ((uintptr_t)(c_scale).m_prv))
49
50
51
52
55 const size_t c_init_sz
58 _aclspv_grow_vec(_aclspv_malloc, _aclspv_free, *h_alloc, c_init_sz +
SCALE_HEADER_SIZE);
76
77
78
79
88 assert(
"non-alloc" && 0);
93 assert(
"misconfigured" && 0);
99 assert(
"exceeded" && 0);
107 assert(ret->m_id == c_idx);
112
113
114
115
118 const size_t c_newsize
130 _aclspv_grow_vec_with_copy(
131 _aclspv_malloc, _aclspv_free, _aclspv_memcpy
137 unless(h_alloc->m_p)
return 1;
141 return !(h_alloc && h_alloc->m_p);
159
160
161
162
165 const size_t c_init_size_opt
171 const size_t newsz = lst->m_buf + lst->m_sz + c_init_size_opt + (size_t)
sizeof(x_scale);
175 assert(h_alloc->m_p);
179 _aclspv_grow_vec_with_copy(
180 _aclspv_malloc, _aclspv_free, _aclspv_memcpy, L_new
185 assert(h_alloc->m_p);
189 lst->m_nxt = lst->m_buf + lst->m_sz;
198 nxt->m_buf = lst->m_nxt + (size_t)
sizeof(x_scale);
199 nxt->m_sz = c_init_size_opt;
201 nxt->m_id = lst->m_id + 1;
202 nxt->m_prv = lst->m_buf - (size_t)
sizeof(x_scale);
#define ae2f_WhenCXX(a)
Appears when the current language is C.
#define ae2f_WhenC(a)
Appears when the current language is C++.
#define unless(a)
Invokes when condition is false.
#define ae2f_extern
Suggests the existence of external variable or function, in naming of C. [non-mangling].
#define ACLSPV_ABI_DECL
Declaration as ABI.
#define ae2f_retnew
The returning pointer does not alias to existing object.
#define ae2f_assume(a)
tells the compiler that value if a is false, below this keyword is not expected to be reached.
#define ae2f_unexpected_but_if(a)
#define ae2f_ccpure
Keyword as [[pure]] on C23.
#define ae2f_expected_but_else(a)
#define ae2f_expected_if(a)
#define ae2f_ccconst
Keyword as [[const]] on C23..
#define ae2f_noexcept
marker that this function does not throw something.
#define ae2f_restrict
Keyword as restrict on C99.
#define ae2f_expected_not(a)
expectes a as false.
#define ae2f_unreachable()
tells the compiler that below this keyword is not expected to be reached.
#define ae2f_fallthrough
explicitly tells compiler that fallthrough on switch is expected.
#define ae2f_inline
inline
#define ae2f_expected(a)
expectes a as true.
#define util_emitx_spec_constant(h_wrds, c_wrdcount, c_ty, c_retid, c_val)
#define util_emitx_variable(h_wrds, c_wrdcount, c_type, c_retid, c_storage_class)
#define util_emitx_spec_constant_op2(h_wrds, c_wrdcount, c_retid, c_ty, c_operator, c_opr_0, c_opr_1)
#define util_emitx_type_array(h_wrds, c_wrdcount, c_retid, c_elm_type_id, c_arrcount_id)
#define util_emitx_type_pointer(h_wrds, c_wrdcount, c_retid, c_storage_class, c_elm_type_id)
#define get_buf_from_scale(h_alloc, c_scale)
#define get_last_scale_from_vec(h_alloc)
#define get_prv_from_scale(h_alloc, c_scale)
#define SCALE_HEADER_SIZE
#define get_first_scale_from_vec(h_alloc)
#define get_nxt_from_scale(h_alloc, c_scale)
#define get_scale_header_from_vec(h_alloc)
#define aclspv_opcode_t
integer as operation code
aclspv_wrd_t aclspv_wrdcount_t
the integer type represents the number of word.
#define ACLSPV_MASK_OPCODE
mask for opcode
#define aclspv_wrd_t
integer as word
#define ACLSPV_MASK_NOPRNDS
mask for number of operands
x_aclspv_vec m_scale_vars
aclspv_wrdcount_t m_num_type_uniques
x_aclspv_vec m_cursors
cache for cursors for parsing one function for its use see util/cursor.h
x_aclspv_vec m_constant_cache
x_aclspv_vec m_ret
word count for m_ret
aclspv_wrd_t m_is_logical
when on, ignores m_is_buffer_64.
aclspv_wrdcount_t m_num_cursor
number of m_cursors. for its use see util/cursor.h
x_aclspv_vec m_type_uniques
cache for complex types which needs to be stored somewhere for its use see util/type_unique....
aclspv_wrdcount_t m_arr_count_id
util_bind_unified m_unified
#define mk_noprnds(c_num_opprm)
#define emit_opcode(h_wrds, c_wrdcount, c_opcode, c_num_opprm_opt)
try emit opcode with num_opprm
#define sz_to_count(c_sz)
byte size to word count
#define get_wrd_of_vec(vec)
get word buffer from vector
aclspv_wrdcount_t spvsz_t
#define count_to_sz(c_count)
word count to byte size
#define set_oprnd_count_for_opcode(cr_wrd, c_num_opprm)
#define opcode_to_wrd(c_opcode, c_num_opprm)