MCPcopy Create free account

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

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

↓ 2 callersFunctionfind_hi20_value_for_reloc
Find the hi20 value for a PCREL_LO12 relocation, dispatching to the appropriate variant based on whether we're building an executable or shared lib.
src/backend/riscv/linker/reloc.rs:460
↓ 2 callersFunctionfind_inline_call_sites
Find call sites in a function that are eligible for inlining. `caller_has_section`: true if the caller has a custom section attribute. When true, call
src/passes/inline.rs:1146
↓ 2 callersFunctionfind_isolated_cmp
Find position of an isolated `>` or `<` that is not part of `>>`, `<<`, `>=`, or `<=`, and not inside parentheses.
src/backend/asm_preprocess.rs:972
↓ 2 callersFunctionfind_preheader
Find a suitable preheader block for a loop. The preheader must be the single predecessor of the header that is not part of the loop body. Returns None
src/passes/loop_analysis.rs:116
↓ 2 callersMethodfixup_unsized_array
Fix up allocation size and strides for unsized arrays (int a[] = {...}). Also updates c_type from Array(elem, None) to Array(elem, Some(count)) so tha
src/ir/lowering/global_decl.rs:524
↓ 2 callersMethodflat_scalar_count_for_layout
Compute the flat scalar count for a struct/union layout. For structs: sum of flat scalar counts of all fields. For unions: the maximum flat scalar cou
src/ir/lowering/const_eval_init_size.rs:126
↓ 2 callersFunctionfloat_const
Create a float constant (F32 or F64) appropriate for the return type.
src/passes/simplify.rs:1552
↓ 2 callersFunctionfold_cast
Evaluate a type cast on a constant. For signed source types, we sign-extend to get the correct i64 representation. For unsigned source types, we zero
src/passes/constant_fold.rs:798
↓ 2 callersFunctionfold_memory_operands
Fold `movl -N(%ebp), %ecx; addl %ecx, %eax` into `addl -N(%ebp), %eax`.
src/backend/i686/codegen/peephole.rs:1388
↓ 2 callersFunctionfor_each_hoistable_operand
(inst: &Instruction, mut f: impl FnMut(u32))
src/passes/licm.rs:268
↓ 2 callersFunctionfor_each_terminator_target
(term: &Terminator, mut f: impl FnMut(BlockId))
src/passes/cfg_simplify.rs:183
↓ 2 callersMethodformat
(&mut self, mut n: usize)
src/frontend/preprocessor/macro_defs.rs:1465
↓ 2 callersFunctionformat_operand
(op: &Operand)
src/passes/inline.rs:1739
↓ 2 callersFunctiongc_collect_sections_elf64
Perform `--gc-sections`: BFS reachability from entry points, return the set of dead (unreachable) `(object_idx, section_idx)` pairs. Starting from en
src/backend/linker_common/gc_sections.rs:21
↓ 2 callersMethodget_addr_space_of_struct_expr
Get the address space of a struct/union variable expression (for `.` member access). Walks through the expression to find the underlying variable and
src/ir/lowering/pointer_analysis.rs:490
↓ 2 callersMethodget_array_root_name
Get the root array name from a full expression (including outer subscript). Handles reverse subscript by checking both base and index.
src/ir/lowering/lvalue.rs:652
↓ 2 callersMethodget_asm_operand_addr_space
Detect address space for an inline asm operand expression. For expressions like `*(typeof(var) __seg_gs *)(uintptr_t)&var`, returns the address space
src/ir/lowering/stmt_asm.rs:623
↓ 2 callersMethodget_call_return_struct_size
For indirect calls (function pointer calls), determine if the return type is a struct, union, or vector and return its size. Returns None if not an ag
src/ir/lowering/expr_types.rs:216
↓ 2 callersFunctionget_const_i128_shift_amount
Extract a constant shift amount from an operand (for optimizing 128-bit shifts). Returns Some(amount) if the operand is a constant in the range [0, 12
src/backend/traits.rs:1441
↓ 2 callersMethodget_field_ctype
Get the CType of a struct/union field. Recursively searches anonymous struct/union members to find the field, matching the behavior of StructLayout::f
src/ir/lowering/expr_types.rs:982
↓ 2 callersMethodget_layout_for_expr
Try to get the struct layout for an expression (value, not pointer).
src/ir/lowering/structs.rs:847
↓ 2 callersMethodget_member_access_field_type
Get the C type of the result of a member access expression. Walks chains like `s.a.b` to return the type of the final field `b`.
src/ir/lowering/const_eval_global_addr.rs:604
↓ 2 callersMethodget_or_create_section
(&mut self, name: &str, section_type: u32, flags: u64, comdat_group: Option<String>)
src/backend/elf_writer_common.rs:339
↓ 2 callersFunctionget_or_create_trampoline
Get or create a trampoline block for a (pred, target) critical edge.
src/ir/mem2reg/phi_eliminate.rs:168
↓ 2 callersMethodget_phys_reg_for_value
Get the physical register assigned to a value, if any. Returns None when the value is stack-allocated or not register-assigned. Backends with register
src/backend/traits.rs:178
↓ 2 callersMethodget_struct_layout_for_type
Get the struct layout for a type specifier.
src/frontend/sema/const_eval.rs:475
↓ 2 callersMethodget_struct_union_layout_by_tag
Look up a struct/union layout by tag name, returning a cheap Rc clone.
src/ir/lowering/types.rs:281
↓ 2 callersMethodgp_reg_count
Returns the number of GP registers consumed by this parameter classification. Used by variadic function handling to compute the correct va_start offse
src/backend/call_abi.rs:197
↓ 2 callersMethodhandle_ifdef
(&mut self, rest: &str, negate: bool)
src/frontend/preprocessor/pipeline.rs:901
↓ 2 callersMethodhandle_include
Handle #include directive. Returns the preprocessed content of the included file, or None if the include couldn't be resolved (falls back to old behav
src/frontend/preprocessor/includes.rs:307
↓ 2 callersMethodhandle_line_directive
(&mut self, rest: &str, source_line_num: usize)
src/frontend/preprocessor/pipeline.rs:932
↓ 2 callersMethodhandle_pragma_pack_token
Check if current token is a pragma pack directive and handle it. Returns true if a pragma pack token was consumed.
src/frontend/parser/parse.rs:986
↓ 2 callersMethodhandle_pragma_visibility_token
Handle #pragma GCC visibility push/pop synthetic tokens. Returns true if a token was consumed.
src/frontend/parser/parse.rs:1037
↓ 2 callersMethodhas_any_stores
Whether the loop has any store operations at all (to any target).
src/passes/licm.rs:341
↓ 2 callersFunctionhas_array_field_designators
Check if any initializer items use the `[N].field` designator pattern (e.g., `[0].name = "hello", [0].value = 42`).
src/ir/lowering/global_init_helpers.rs:49
↓ 2 callersFunctionhas_indirect_memory_access
(s: &str)
src/backend/x86/codegen/peephole/types.rs:727
↓ 2 callersFunctionhas_side_effects
Check if an instruction has side effects (must not be removed).
src/passes/dce.rs:263
↓ 2 callersFunctionhex_digit_val
(c: u8)
src/frontend/lexer/scan.rs:1181
↓ 2 callersMethodinfer_field_ctype
Infer the CType of a struct/union field access.
src/frontend/sema/type_checker.rs:480
↓ 2 callersMethodinfer_struct_eightbyte_classes
Infer SysV ABI eightbyte classification for a struct argument expression. This is used for variadic struct args that don't have pre-registered classif
src/ir/lowering/expr_calls.rs:706
↓ 2 callersMethodinfo
(&self)
src/backend/arm/linker/types.rs:44
↓ 2 callersMethodinit_array_compound_literal
( &mut self, alloca: Value, items: &[InitializerItem], type_spec: &TypeSpecifier, ty: IrType,
src/ir/lowering/expr_access.rs:257
↓ 2 callersFunctioninline_call_site
Inline a single call site. Returns true if successful. `global_max_block_id` is the module-global max block ID, updated on success.
src/passes/inline.rs:1186
↓ 2 callersFunctioninsert_dynsym
( dynlib_syms: &mut HashMap<String, (String, u8, u32, Option<String>, bool, u8)>, sym: DynSymInfo,
src/backend/i686/linker/input.rs:242
↓ 2 callersFunctioninsert_phis
Determine where phi nodes need to be inserted. Returns a map: block_index -> set of alloca indices that need phis there.
src/ir/mem2reg/promote.rs:364
↓ 2 callersMethodinsert_struct_layout_scoped
Insert a struct layout into the cache, tracking the change in the current scope frame so it can be undone on scope exit.
src/ir/lowering/structs.rs:173
↓ 2 callersFunctioninstruction_modifies_stack
Check if an instruction implicitly modifies the stack pointer or accesses the stack in ways that would make push/pop elimination incorrect. This catch
src/backend/x86/codegen/peephole/passes/push_pop.rs:65
↓ 2 callersMethodinteger_rank
Integer conversion rank for C types (C11 6.3.1.1). Higher rank = larger type. Used by usual arithmetic conversions.
src/common/types.rs:1478
↓ 2 callersMethodintern_string_as_global_addr
Intern a string literal and return a GlobalAddr referencing it.
src/ir/lowering/global_init.rs:333
↓ 2 callersMethodinvalidate_ctype_cache_scoped
Invalidate a ctype_cache entry for a struct/union tag, tracking the change in the current scope frame so it can be restored on scope exit.
src/ir/lowering/structs.rs:179
↓ 2 callersFunctioninvert_cc
Invert a condition code (e.g., "e" -> "ne", "l" -> "ge")
src/backend/x86/codegen/peephole/types.rs:996
↓ 2 callersFunctioninvert_cc
Invert a condition code.
src/backend/i686/codegen/peephole.rs:531
↓ 2 callersFunctioninvert_cmp_op
Invert a comparison operator (negate the condition).
src/passes/simplify.rs:482
↓ 2 callersFunctionir_type_size
Return the byte size for an IrType.
src/ir/mem2reg/promote.rs:810
↓ 2 callersFunctionirconst_to_bits
(val: &IrConst)
src/common/const_eval.rs:298
↓ 2 callersMethodis_32bit
Whether this target uses 32-bit pointers (ILP32 data model).
src/backend/mod.rs:222
↓ 2 callersFunctionis_64bit_reg
Check if a register name is a 64-bit (X) register or SP.
src/backend/arm/assembler/encoder/mod.rs:151
↓ 2 callersFunctionis_alias_ident_char
Check if a byte is a valid identifier character for register alias matching. Similar to is_ident_char but does NOT include '.' since register names li
src/backend/arm/assembler/parser.rs:1025
↓ 2 callersFunctionis_anon_member_designator
Check if a field is an anonymous struct/union member being targeted by a field designator. This detects the case where a designator like `.x` resolves
src/ir/lowering/global_init_helpers.rs:37
↓ 2 callersMethodis_barrier
(self)
src/backend/i686/codegen/peephole.rs:109
↓ 2 callersFunctionis_branch_reloc_type
Returns true if the given ELF relocation type is a branch/jump relocation that should be deferred for intra-section resolution at assembly time.
src/backend/arm/assembler/elf_writer.rs:57
↓ 2 callersMethodis_common
(&self)
src/frontend/parser/ast.rs:243
↓ 2 callersMethodis_commutative
Returns true if this operation is commutative (a op b == b op a).
src/ir/ops.rs:57
↓ 2 callersFunctionis_constant_condition
Check if a condition operand is a known constant or can be trivially resolved to a constant within the block. When the condition is constant, the bran
src/passes/if_convert.rs:186
↓ 2 callersFunctionis_control_reg
(name: &str)
src/backend/x86/assembler/encoder/registers.rs:38
↓ 2 callersFunctionis_debug_reg
(name: &str)
src/backend/x86/assembler/encoder/registers.rs:53
↓ 2 callersMethodis_expr_unsigned
Check if an expression has an unsigned type, using the expr_types cache or falling back to type inference from the AST structure.
src/frontend/sema/const_eval.rs:551
↓ 2 callersMethodis_expr_unsigned_for_const
Check if an expression has an unsigned type for constant evaluation.
src/ir/lowering/const_eval.rs:533
↓ 2 callersMethodis_function_variadic
Check if a function is variadic.
src/ir/lowering/expr_calls.rs:945
↓ 2 callersFunctionis_ident_char
Check if a byte is a valid identifier character (alphanumeric, underscore, dot).
src/backend/arm/assembler/parser.rs:928
↓ 2 callersFunctionis_ident_char
Check if a byte is an identifier character (alphanumeric or underscore).
src/backend/x86/assembler/parser.rs:2110
↓ 2 callersFunctionis_ident_start
Shared utility functions for the preprocessor module. Provides both char-oriented and byte-oriented helpers for scanning C source text. The byte-orie
src/frontend/preprocessor/utils.rs:10
↓ 2 callersFunctionis_if_start
Check if a line starts a new conditional assembly block (.if, .ifc, .ifdef, .ifndef).
src/backend/x86/assembler/parser.rs:2115
↓ 2 callersFunctionis_irp_start
(trimmed: &str)
src/backend/asm_preprocess.rs:202
↓ 2 callersFunctionis_irp_start
(trimmed: &str)
src/backend/arm/assembler/parser.rs:204
↓ 2 callersFunctionis_irpc_start
(trimmed: &str)
src/backend/arm/assembler/parser.rs:208
↓ 2 callersFunctionis_line_marker
Check if a line (as bytes) is a GCC-style line marker: # <digit>... "filename" Returns true only for line markers, not for preprocessor directives lik
src/common/source.rs:535
↓ 2 callersFunctionis_live
(inst: &Instruction, used: &[bool])
src/passes/dce.rs:249
↓ 2 callersFunctionis_movq_reg_reg
(trimmed: &str, first_reg: &str, second_reg: &str)
src/backend/x86/codegen/peephole/passes/loop_trampoline.rs:78
↓ 2 callersFunctionis_movslq_reg_reg
(trimmed: &str, first_reg: &str, second_reg: &str)
src/backend/x86/codegen/peephole/passes/loop_trampoline.rs:93
↓ 2 callersFunctionis_neg_one
Check if an operand is -1 for the given integer type. This is the two's complement representation: all bits set. Used for x * (-1) => neg(x) optimizat
src/passes/simplify.rs:1117
↓ 2 callersFunctionis_neon_scalar_d_reg_op
── Helper: detect scalar d-register 3-operand NEON operations ──────────────
src/backend/arm/assembler/encoder/neon.rs:1778
↓ 2 callersMethodis_noinline
(&self)
src/frontend/parser/ast.rs:83
↓ 2 callersMethodis_noreturn_call
Check if an expression diverges (never falls through to subsequent code). This includes calls to noreturn functions (`abort()`, `exit()`, `__builtin_u
src/frontend/sema/analysis.rs:1246
↓ 2 callersFunctionis_numeric_label
Check if a label name is a GNU assembler numeric label (e.g., "1", "42").
src/backend/arm/assembler/mod.rs:129
↓ 2 callersFunctionis_numeric_label
Check if a string is a numeric local label (just digits, e.g., "1", "42").
src/backend/elf/numeric_labels.rs:21
↓ 2 callersFunctionis_numeric_label_ref
Check if a string looks like a GNU numeric label reference (e.g. "2f", "1b", "42f").
src/backend/arm/assembler/parser.rs:2428
↓ 2 callersFunctionis_numeric_label_ref
Check if a string looks like a GNU numeric label reference (e.g. "2f", "1b", "42f").
src/backend/riscv/assembler/parser.rs:609
↓ 2 callersFunctionis_one
Check if an operand is one.
src/passes/simplify.rs:1110
↓ 2 callersMethodis_paren_declarator
Determine if a '(' starts a parenthesized declarator vs. a parameter list.
src/frontend/parser/declarators.rs:129
↓ 2 callersFunctionis_ppnumber_context
Check whether position `pos` in `bytes` is part of a pp-number token.
src/frontend/preprocessor/macro_defs.rs:1147
↓ 2 callersFunctionis_register
Check if a string is a valid RISC-V register name.
src/backend/riscv/assembler/parser.rs:1018
↓ 2 callersFunctionis_rept_start
(trimmed: &str)
src/backend/asm_preprocess.rs:198
↓ 2 callersFunctionis_rept_start
Parse assembly text into a list of statements. Expand .rept/.endr, .irp/.endr, and .irpc/.endr blocks by repeating contained lines. TODO: extract expa
src/backend/arm/assembler/parser.rs:199
↓ 2 callersFunctionis_side_effect_free
Check if a function is pure (no observable side effects and result depends only on inputs/constants). A pure function has no stores, no calls, no load
src/passes/ipcp.rs:209
↓ 2 callersMethodis_type_complex
Check if a TypeSpecifier resolves to a complex type (through typedefs).
src/ir/lowering/types.rs:81
↓ 2 callersMethodis_typedef_label
Check if the current position is a typedef name followed by ':', which means it's a label (not a declaration). In C, label names can shadow typedef na
src/frontend/parser/parse.rs:540
↓ 2 callersFunctionis_value_const_in_block
Check if an operand is a constant within the block (either directly or via Copy).
src/passes/if_convert.rs:219
↓ 2 callersMethodis_volatile
(&self)
src/frontend/parser/ast.rs:242
↓ 2 callersFunctionis_widened_from_matching_type
Check whether an operand was widened from a type matching the target_ty (same size and same signedness). Used to validate that right-shift narrowing i
src/passes/narrow.rs:453
← previousnext →1,601–1,700 of 6,057, ranked by callers