MCPcopy Create free account

hub / github.com/anthropics/claudes-c-compiler / functions

Functions6,057 in github.com/anthropics/claudes-c-compiler

↓ 8 callersMethodoperand_to_rcx
Load an operand directly into %rcx, avoiding the push/pop pattern. This is the key optimization: instead of loading to rax, pushing, loading the other
src/backend/x86/codegen/emit.rs:504
↓ 8 callersMethodoperand_to_t0_t1
Load a 128-bit operand into t0 (low) : t1 (high).
src/backend/riscv/codegen/emit.rs:375
↓ 8 callersMethodoperand_to_x0_x1
Load a 128-bit operand into x0 (low) : x1 (high).
src/backend/arm/codegen/emit.rs:1073
↓ 8 callersMethodparse_abstract_declarator_suffix
Parse an abstract declarator suffix: pointer(s), parenthesized pointer groups, and array dimensions after a type name. Used by cast expressions, sizeo
src/frontend/parser/types.rs:891
↓ 8 callersMethodpreferred_align_ctx
Preferred (natural) alignment in bytes, as returned by GCC's __alignof__. On i686, this differs from align_ctx() for long long (8 vs 4) and double (8
src/common/types.rs:1370
↓ 8 callersFunctionread_u32_le
(data: &[u8], off: usize)
src/backend/linker_common/eh_frame.rs:346
↓ 8 callersFunctionreplace_macro_param
Replace `\param` in a macro body line with the argument value, but only when `\param` is followed by a non-identifier character (or end of string). G
src/backend/asm_preprocess.rs:843
↓ 8 callersMethodresolve_expr_aliases
Resolve .set/.equ aliases in an expression string. Replaces symbol names (like `.L__gpr_num_t0`) with their numeric values.
src/backend/elf/writer_base.rs:429
↓ 8 callersMethodset_file
Set the __FILE__ macro body without allocating a full MacroDef. If __FILE__ already exists in the table, only its body is updated. Otherwise, a new en
src/frontend/preprocessor/macro_defs.rs:186
↓ 8 callersMethodset_inline
(&mut self, v: bool)
src/frontend/parser/ast.rs:95
↓ 8 callersMethodsizeof_expr
Compute sizeof for an expression operand (sizeof expr). Returns the size in bytes of the expression's type.
src/ir/lowering/expr_sizeof.rs:224
↓ 8 callersMethodskip_cv_qualifiers
(&mut self)
src/frontend/parser/parse.rs:569
↓ 8 callersFunctionstrip_comment
Strip trailing comment from a line using x86 comment style (`#`).
src/backend/x86/assembler/parser.rs:357
↓ 8 callersMethodto_i128
Extract as i128 (integer constants only; floats return None). Unlike to_i64(), this preserves the full 128-bit value.
src/ir/constants.rs:336
↓ 8 callersMethodtype_spec_to_ctype
Convert an AST TypeSpecifier to a CType. Delegates to the shared `TypeConvertContext::resolve_type_spec_to_ctype` default method, which handles all 22
src/frontend/sema/analysis.rs:1776
↓ 8 callersMethoduses_packed_complex_float
Returns true if the target uses x86-64 style packed _Complex float ABI (two F32s packed into a single F64/xmm register). Returns false for ARM/RISC-V
src/ir/lowering/lower.rs:271
↓ 8 callersMethodwrite_dep_file
Write a Make-compatible dependency file for the given input/output. Format: "output: input\n" This is a minimal dependency file that tells make the ob
src/driver/external_tools.rs:339
↓ 8 callersFunctionx87_classify
Classify an x87 value for arithmetic special-case handling. Returns (is_unnormal, is_inf, is_nan). For unnormals/pseudo-values, the caller should retu
src/common/long_double.rs:1356
↓ 7 callersMethodadd_to_hash
(&mut self, i: u64)
src/common/fx_hash.rs:26
↓ 7 callersFunctionalign_up
Align `offset` up to the next multiple of `align`.
src/common/types.rs:1177
↓ 7 callersFunctionas_f64_const_mapped
Extract a constant floating-point value, resolving through const map.
src/passes/constant_fold.rs:454
↓ 7 callersFunctionassert_sub_matches
(a: &[u8; 16], b: &[u8; 16], label: &str)
src/common/long_double.rs:2758
↓ 7 callersMethodbitcast_float_to_int
Bitcast a float/double to its integer bit representation via memory. F32 -> I32, F64 -> I64. Uses alloca+store+load for a true bitcast. Note: F128 cla
src/ir/lowering/expr_builtins_fpclass.rs:76
↓ 7 callersMethodclassify_sysv_eightbytes
Classify each 8-byte "eightbyte" of this struct/union per the System V AMD64 ABI. Returns a vector with one entry per eightbyte (so 1 entry for size
src/common/types.rs:714
↓ 7 callersMethodcompute_array_element_addr
Compute the address of an array element: base_addr + index * elem_size. For multi-dimensional arrays, uses the correct stride for the subscript depth.
src/ir/lowering/lvalue.rs:196
↓ 7 callersMethodcompute_struct_union_layout_packed
(&self, fields: &[StructFieldDecl], is_union: bool, max_field_align: Option<usize>)
src/ir/lowering/types.rs:319
↓ 7 callersMethodctype_size
Get the size in bytes for a CType.
src/frontend/sema/const_eval.rs:545
↓ 7 callersMethoddecomposes_complex_long_double
Returns true if the target decomposes _Complex long double into 2 F128 scalar components for function argument/parameter passing. On ARM64 (AAPCS64):
src/ir/lowering/lower.rs:288
↓ 7 callersMethodemit
(&mut self, s: &str)
src/backend/common.rs:807
↓ 7 callersMethodemit_add_sp_offset
Emit `add dest, sp, #offset` handling large offsets. Uses x19 frame base when available, falls back to x17 scratch.
src/backend/arm/codegen/emit.rs:797
↓ 7 callersMethodemit_f64_store_from_x87
Store the x87 st(0) value as F64 into a destination stack slot. Pops st(0).
src/backend/i686/codegen/emit.rs:608
↓ 7 callersMethodemit_memcpy_at_offset
Emit memcpy from src to base + byte_offset.
src/ir/lowering/lower.rs:1163
↓ 7 callersMethodencode_avx_broadcast
Encode AVX vbroadcastss/vbroadcastsd
src/backend/x86/assembler/encoder/avx.rs:781
↓ 7 callersFunctionencode_fp_1src
Encode FP 1-source ops: FRINTN/P/M/Z/A/X/I Format: 0 00 11110 ftype 1 opcode 10000 Rn Rd
src/backend/arm/assembler/encoder/fp_scalar.rs:117
↓ 7 callersFunctionencode_j
J-type: imm[20|10:1|11|19:12] | rd[11:7] | opcode[6:0]
src/backend/riscv/assembler/encoder/mod.rs:310
↓ 7 callersFunctionencode_load
(operands: &[Operand], funct3: u32)
src/backend/riscv/assembler/encoder/base.rs:147
↓ 7 callersMethodencode_shift
(&mut self, ops: &[Operand], mnemonic: &str, shift_op: u8)
src/backend/i686/assembler/encoder/gp_integer.rs:848
↓ 7 callersMethodencode_sse_mem_only
Encode an SSE instruction with a single memory operand and a ModR/M extension. Format: [opcode bytes] ModR/M(ext, mem) Used for ldmxcsr (0F AE /2) and
src/backend/x86/assembler/encoder/sse.rs:605
↓ 7 callersMethodencode_suffixless_shift
(&mut self, ops: &[Operand], shift_op: u8)
src/backend/x86/assembler/encoder/x87_misc.rs:358
↓ 7 callersFunctionencode_v_arith_vx
Encode vector arithmetic VX (vector-scalar): funct6[31:26] | vm[25] | vs2[24:20] | rs1[19:15] | funct3[14:12]=100 | vd[11:7] | OP_V
src/backend/riscv/assembler/encoder/vector.rs:134
↓ 7 callersMethodeval_const_expr
Try to evaluate a constant expression at compile time. Returns None if the expression cannot be evaluated. This delegates to the richer SemaConstEval
src/frontend/sema/analysis.rs:1835
↓ 7 callersMethodeval_init_scalar
Evaluate an initializer to a scalar constant (handles both Expr and arbitrarily nested brace-wrapped Lists like `{{{42}}}`).
src/ir/lowering/global_init_bytes.rs:285
↓ 7 callersMethodexpr_produces_packed_struct_data
Check if an expression produces packed struct data (non-address value) rather than a pointer to struct data. This happens for small structs (<= 8 byte
src/ir/lowering/structs.rs:560
↓ 7 callersFunctionfold_float_binop
Evaluate a binary operation on two constant floats. Uses Rust's native f64 arithmetic which is IEEE 754 compliant.
src/passes/constant_fold.rs:475
↓ 7 callersMethodget_addr_space_of_ptr_expr
Get the address space of a pointer expression (e.g., `__seg_gs` from a `typeof(x) __seg_gs *` cast). Returns `AddressSpace::Default` if unknown or the
src/ir/lowering/pointer_analysis.rs:475
↓ 7 callersFunctionget_or_create_id
Look up or create an ID for a name that may not already exist.
src/passes/dead_statics.rs:89
↓ 7 callersMethodget_pointee_type_of_expr
Get the pointee type for a pointer expression - i.e., what type you get when dereferencing it.
src/ir/lowering/pointer_analysis.rs:394
↓ 7 callersFunctionget_standard_linker_symbols
Return the standard set of linker-defined symbols that all backends should provide. This ensures consistent symbol definitions across x86-64, i686, A
src/backend/elf/linker_symbols.rs:73
↓ 7 callersMethodinteger_promoted
Apply C integer promotion rules (C11 6.3.1.1): Types smaller than int are promoted to int (or unsigned int if int cannot represent all values, but for
src/common/types.rs:1450
↓ 7 callersMethodis_const
(&self)
src/frontend/parser/ast.rs:241
↓ 7 callersMethodis_constant_true_expr
Check if an expression is a compile-time constant that evaluates to true (non-zero). Used to detect infinite loops like `while(1)` and `for(;1;)`, and
src/frontend/sema/analysis.rs:1294
↓ 7 callersMethodis_defined
(&self)
src/backend/arm/linker/types.rs:42
↓ 7 callersFunctionis_label_like
Check if a string looks like a label (alphanumeric, underscore, dot).
src/backend/x86/assembler/parser.rs:1379
↓ 7 callersFunctionis_rex_required_8bit
Does this 8-bit register require REX prefix for access (spl, bpl, sil, dil)?
src/backend/x86/assembler/encoder/registers.rs:123
↓ 7 callersMethodis_stack
Returns true if this argument is passed on the stack (any kind).
src/backend/call_abi.rs:62
↓ 7 callersFunctionis_thin_archive
Returns true if `data` starts with the thin archive magic `!<thin>\n`.
src/backend/elf/archive.rs:8
↓ 7 callersMethodis_type_bool
Check if a TypeSpecifier resolves to a Bool type (through typedefs).
src/ir/lowering/types.rs:47
↓ 7 callersMethodis_used
(&self)
src/frontend/parser/ast.rs:87
↓ 7 callersFunctionis_valid_gp_reg
(reg: RegId)
src/backend/x86/codegen/peephole/passes/helpers.rs:12
↓ 7 callersFunctionline_info
(kind: LineKind, ts: u16)
src/backend/x86/codegen/peephole/types.rs:184
↓ 7 callersMethodlookup
(&self, name: &str)
src/common/symbol_table.rs:51
↓ 7 callersMethodlookup_expr_type
Look up the pre-annotated CType for an expression from sema's expr_types map. This is O(1) and preserves signedness information (e.g. unsigned int fro
src/frontend/sema/const_eval.rs:499
↓ 7 callersMethodlower_expr_to_complex
Lower an expression to a complex value, converting if needed. Returns a Value (pointer to the complex {real, imag} pair).
src/ir/lowering/stmt.rs:604
↓ 7 callersMethodlvalue_addr
Get the address (as a Value) from an LValue.
src/ir/lowering/lvalue.rs:161
↓ 7 callersFunctionmark_reachable
Mark a symbol ID as reachable if not already, growing the reachable vec as needed.
src/passes/dead_statics.rs:138
↓ 7 callersMethodmerge
Merge two eightbyte classifications per SysV ABI rules: - NoClass + X = X - Integer + anything = Integer - SSE + SSE = SSE
src/common/types.rs:125
↓ 7 callersMethodpacked_size
Returns the size (and alignment) in bytes for this enum. Non-packed enums are always 4 bytes (int). Packed enums use the smallest integer type that ca
src/common/types.rs:256
↓ 7 callersFunctionparse_reg
Parse an AArch64 register name to an internal ID (0-30, or special). x0/w0 → 0, x1/w1 → 1, ..., x30/w30 → 30, sp → 31, xzr/wzr → 32.
src/backend/arm/codegen/peephole.rs:94
↓ 7 callersFunctionpush_bytes_as_elements
Convert a byte buffer to GlobalInit elements by pushing each byte as I8. This is the standard bytes-to-compound conversion used throughout the compoun
src/ir/lowering/global_init_helpers.rs:199
↓ 7 callersFunctionread_u64_le
(data: &[u8], off: usize)
src/backend/linker_common/eh_frame.rs:354
↓ 7 callersMethodregister_struct_type
Register a struct/union type definition from a TypeSpecifier, computing and caching its layout in self.types.struct_layouts. Also recursively register
src/ir/lowering/structs.rs:23
↓ 7 callersMethodresolve_generic_selection_expr
Resolve a _Generic selection to the matched association's expression. Returns the matched expression (or the default), or None if no match. Both resol
src/ir/lowering/expr_types.rs:593
↓ 7 callersFunctionresolve_lib
(name: &str, paths: &[String])
src/backend/arm/linker/input.rs:84
↓ 7 callersMethodresolve_span
Resolve a span to a human-readable source location. When a line map is available (preprocessor emitted line markers), resolves through the line map t
src/common/source.rs:338
↓ 7 callersMethodset_fastcall
(&mut self, v: bool)
src/frontend/parser/ast.rs:104
↓ 7 callersMethodset_used
(&mut self, v: bool)
src/frontend/parser/ast.rs:103
↓ 7 callersMethodset_volatile
(&mut self, v: bool)
src/frontend/parser/ast.rs:254
↓ 7 callersMethodset_weak
(&mut self, v: bool)
src/frontend/parser/ast.rs:102
↓ 7 callersMethodstore_scalar_dest
Store a scalar result from x0 (or w0) into the dest stack slot.
src/backend/arm/codegen/intrinsics.rs:39
↓ 7 callersFunctiontype_has_pointer_elements
Check if a CType contains pointer elements (directly or through arrays/structs).
src/ir/lowering/global_init_helpers.rs:136
↓ 7 callersFunctionwrite_shdr32
Append an ELF32 section header to `buf`.
src/backend/elf/io.rs:112
↓ 7 callersFunctionwrite_shdr64
Append an ELF64 section header to `buf`.
src/backend/elf/io.rs:93
↓ 7 callersMethodx87_bytes
Get the x87 80-bit byte representation for any float constant. For LongDouble, converts stored f128 bytes to x87 format (lossy: 112→64 bit mantissa).
src/ir/constants.rs:219
↓ 7 callersFunctionx87_to_f64
Get the f64 approximation from x87 bytes, for use when we still need f64. This is a convenience alias for x87_bytes_to_f64.
src/common/long_double.rs:1869
↓ 6 callersFunction_mm256_setzero_si256
include/avxintrin.h:104
↓ 6 callersFunctionanalyze_allocas
Analyze all allocas in a function to determine which are address-taken. An alloca is "address-taken" if its value (the pointer) is used by any instru
src/passes/licm.rs:114
↓ 6 callersMethodanalyze_declaration
Perform shared declaration analysis for both local and global variable declarations. Computes all type-related properties (base type, array info, poi
src/ir/lowering/global_decl.rs:376
↓ 6 callersMethodapply_vector_size
Apply `__attribute__((vector_size(N)))` to this declaration analysis. When a non-typedef variable is declared with an inline vector_size attribute, th
src/ir/lowering/definitions.rs:181
↓ 6 callersFunctionas_i64_const_mapped
Extract a constant integer value from an operand, resolving through const map.
src/passes/constant_fold.rs:401
↓ 6 callersFunctionassert_copy_bool
Assert result is a Copy of I8 constant (used for boolean results).
src/passes/simplify.rs:1685
↓ 6 callersFunctionclassify_cast
Backward-compatible wrapper: classifies casts with x86 F128 semantics (F128 treated as F64 approximation).
src/backend/cast.rs:152
↓ 6 callersMethodclassify_result_to_bool
Convert a libc classification result to a boolean (non-zero -> 1, zero -> 0).
src/ir/lowering/expr_builtins_fpclass.rs:56
↓ 6 callersMethodcomplex_to_complex
Convert a complex value from one complex type to another (e.g., ComplexFloat -> ComplexDouble).
src/ir/lowering/complex.rs:399
↓ 6 callersFunctioncompute_signed_magic_32
Compute the magic number for signed 32-bit division by `d`. Returns (magic_number, shift_amount). The result is: mulhi(x, magic) + adjust >> shift, th
src/passes/div_by_const.rs:592
↓ 6 callersFunctioncompute_unsigned_magic_32
Compute the magic number for unsigned 32-bit division by `d`. Returns (magic_number, post_shift, needs_add) where: - If !needs_add: result = (x * magi
src/passes/div_by_const.rs:410
↓ 6 callersMethodemit_add_fp_offset
Emit `add dest, x29, #offset` handling large offsets. Uses x17 (IP1) as scratch for offsets > 4095.
src/backend/arm/codegen/emit.rs:835
↓ 6 callersMethodemit_addi_sp
Emit: `sp = sp + imm`, handling large immediates via t6.
src/backend/riscv/codegen/emit.rs:298
↓ 6 callersMethodemit_cleanup_calls
Emit cleanup function calls for variables with __attribute__((cleanup(func))). Calls func(&var) for each cleanup variable, in reverse declaration orde
src/ir/lowering/lower.rs:378
↓ 6 callersMethodemit_f128_load_to_x87
Load an F128 operand into x87 ST(0), using full 80-bit precision when available. This is used for F128 arithmetic and for pushing F128 call arguments.
src/backend/x86/codegen/f128.rs:556
↓ 6 callersMethodemit_neon_binary_128
(&mut self, dest_ptr: &Value, args: &[Operand], neon_inst: &str)
src/backend/arm/codegen/intrinsics.rs:10
← previousnext →501–600 of 6,057, ranked by callers